We use ATG Dynamo 5.1, BMP for a financial application. following is the problem that I am facing. I execute a findBy method which results in 500 rows. I loop through each one of the 500 ejb objects to do a getXXX() method(close to 15 getters) and put each one of them in a hashmap and make a hashmap array and send it to JSP. This results in a major performance hit showing 500 records in a page as it takes to close to good 3 minutes. I cant override the architecture in place, but I am wondering if there is any other better way to do this to overcome this difficulty. I reasearched real closely and it takes .25 seconds to loop through one bean in the memory to do all the getters and putting in the hashmap...
any suggestions, please let me know.
I feel that since you are showing the records in the JSP and since no user, i mean the client, shall not be interested in viewing all the results, you cud better go for paging.The Paging here i mean that you get only 10 or 15 records at a time and maintain a pointer to the last read record, and show him a next link to bring the next set of data, as the query shall be same and as the PreparedStatement or the Query Language (if a CMP) shall be cached by ATG , i feel your statement shall take minimal time than the first time execution.
If at all you are using oracle or MS SQL 7+ i dont think it shall create a Plan of action for the query , since it might have created that in the first go only, so thus next time its gonna be still more faster.
The two scenarios which can help you is either paging the data or gettting the data which the user wants showing the selection criteria in the User interface, as select those commodities greater than price=15 and vendor="middleware", something like this.
Ok buddy i hope i conveyed to my fullest extent