Win a copy of JDBC Workbook this week in the JDBC and Relational Databases forum
or A Day in Code in the A Day in Code forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

OSCache

 
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have a J2EE web application for reporting. When user logged in he/she can view a menu having different reports. Each report is associated with a filter page, where user can select some filter values and can view the report on the basis of selected filter values. The filter page is same for all reports. On the filter page there are select boxes into which values are populating from the database by running different queries for each select box (we says filter value). So, following steps are performing -

* Connecting to Database
* Running Query
* Setting returned records to bean
* Display filter page by fetching records from bean

If user request for any other report, above steps are repeating again to populate filter page, which is obviously not a good design as connecting to database again and again is very expensive. So, I have decided to change the design.

I have decided to use OSCache to cache the filter values (Bean objects) at server (user�s session). So that, if user would go to see another report then a filter page with cached filter values will be presented to him/her. In this way we are not going to hit the database server again until user�s session expired.

I have gone through the documentation but still fighting to implement as the documentation, examples etc. are limited. I haven�t found any good example or help from the web.

I would appreciate if anybody helps me as it�s really urgent.

Thanks a lot.
 
Beware the other head of science - it bites! Nibble on this message:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic