Hi,
I'm trying to build a socket that saves time when users query on any of our web sites. The way it works is to hold an array of data in memory until the user closes the browser (or migrates away). When the user first hits our site, we go through a series of checks (does the user have a message, has the user retrieved the message...). All of those are different pages so, behind the scenes I run a query and get the data the user is eventually going to see into an array. Then the array is held in memory in case the user does some other stuff and then comes back.
The point here is to try to make the delivery of information fast to the user. No need to do a query over and over again when the user hits a page that should show static ResultSet data.
But, this is where it breaks down for me...
Here is what I want to do in the most efficient way possible (We've gotten 450,000 hits in the last week so I want to optimize both the speed and the memory of the app in the best possible trade off)...
I want to store the results of this query in a
String[][] (as well as others) in a Hashtable<Integer, String[][]> where a SessionID object singleton manages it all for me while the user is live. But, I don't know the best way to get the data into a String[][] object and I want to avoid looping ResultSet objects as much as possible...
Can someone help me determine the best way to get this query into a String[][] where:
String[0 through n] = CPA_Category.CategoryID and String [][0 through n] = CPACategory.CategoryName?