Hello,
I want to cache my read only queries(complex joins involved) in the weblogic server 5.1 which is clustered. We tried toplink but it failed to do caching for joins, cocobase is also ruled out. Is there any other commercial OR mapping tool which can get the work done, or should I design singleton classes with hashtables and session beans for caching? I will appreciate any comments.
Thanks
Vaneet
-
Caching of the database queries (9 messages)
- Posted by: vaneet gupta
- Posted on: January 30 2001 11:45 EST
Threaded Messages (9)
- Caching of the database queries by Michael Braun on January 30 2001 15:42 EST
- Caching of the database queries by Dave Wolf on January 30 2001 22:55 EST
- Caching of the database queries by vaneet gupta on January 31 2001 10:43 EST
-
Caching of the database queries by Dave Wolf on January 31 2001 02:13 EST
-
Caching of the database queries by Tony Wiegand on January 31 2001 05:33 EST
-
Caching of the database queries by Dave Wolf on January 31 2001 09:49 EST
-
Caching of the database queries by Steve Snodgrass on February 01 2001 08:31 EST
- Caching of the database queries by vaneet gupta on February 08 2001 09:39 EST
-
Caching of the database queries by Steve Snodgrass on February 01 2001 08:31 EST
-
Caching of the database queries by Dave Wolf on January 31 2001 09:49 EST
-
Caching of the database queries by Tony Wiegand on January 31 2001 05:33 EST
-
Caching of the database queries by Dave Wolf on January 31 2001 02:13 EST
- Caching of the database queries by vaneet gupta on January 31 2001 10:43 EST
- memcached for read only and CSQLCache for write through cache by Prabakaran Thirumalai on June 01 2008 13:09 EDT
-
Caching of the database queries[ Go to top ]
- Posted by: Michael Braun
- Posted on: January 30 2001 15:42 EST
- in response to vaneet gupta
For a similar problem, we use one stateless session bean to store results from previous selects.
Michael -
Caching of the database queries[ Go to top ]
- Posted by: Dave Wolf
- Posted on: January 30 2001 22:55 EST
- in response to vaneet gupta
Dont use singleton design patterns. They tend to be not singletons at all due to custom ClassLoader implementations used by application server vendors.
What about a simple stateless bean which acts as the cache and stores the data as readonly static members. This meets properly with section 18.1.2 of the spec and would give you a logical if not physical singleton access to cached data.
Dave Wolf
Internet Applications Division
Sybase
-
Caching of the database queries[ Go to top ]
- Posted by: vaneet gupta
- Posted on: January 31 2001 10:43 EST
- in response to Dave Wolf
Hi Dave,
Thanks for your reply. I was going thro' the 18.1.2 (programming restriction) specs and I am not sure which particular restriction you were talking about.
Thanks again.
Vaneet -
Caching of the database queries[ Go to top ]
- Posted by: Dave Wolf
- Posted on: January 31 2001 14:13 EST
- in response to vaneet gupta
The restriction on avoiding non read-only static members. This restriction exists due to custom class loader restrictions and the possibility some containers may use mulple VM's.
Dave Wolf
Internet Applications Division
Sybase
-
Caching of the database queries[ Go to top ]
- Posted by: Tony Wiegand
- Posted on: January 31 2001 17:33 EST
- in response to Dave Wolf
Dave,
Does this mean if your app servers uses multiple jvm within a system or your running in a clustered environment you can't reliably cache data in your session bean?
Tony -
Caching of the database queries[ Go to top ]
- Posted by: Dave Wolf
- Posted on: January 31 2001 21:49 EST
- in response to Tony Wiegand
Tony,
Well is can be a concern if the cache is not read-only as you will find the static and singleton data is out of sync across VM's or ClassLoaders. In readonly data this wouldnt be an issue, but in dynamic data it would be. Thats why 18.1.2 forbids doing it.
Dave Wolf
Internet Applications Division
Sybase
-
Caching of the database queries[ Go to top ]
- Posted by: Steve Snodgrass
- Posted on: February 01 2001 08:31 EST
- in response to Dave Wolf
Why not use the new CachedRowSet class (available at Suns site though the early access program) and attach it to the server context via JNDI? We have been using the CachedRowSet for a couple of weeks now and while we haven't used it in this capacity I don't see any reason why it wouldn't work. -
Caching of the database queries[ Go to top ]
- Posted by: vaneet gupta
- Posted on: February 08 2001 09:39 EST
- in response to Steve Snodgrass
Hi Steve,
Can you provide a sample code of what you had implemented using CachedRowSet. I will appreciate it. You can mail it at vaneet dot gupta at csfb dot com
Thanks
Vaneet -
memcached for read only and CSQLCache for write through cache[ Go to top ]
- Posted by: Prabakaran Thirumalai
- Posted on: June 01 2008 13:09 EDT
- in response to vaneet gupta
Memcached is an option which shall be tried for read only result set based cache. It is also highly scalable. If you want to cache tables which shall be modified also, then result set based read only cache options may not solve your purpose. CSQL Cache, middle tier fully transactional bidirectional updateable caching mechanism might help in that case. It gives 20- 100 times performance improvement. Check out the below article for more infomation http://www.general.databasecorner.com/resource,4200,csql-main-memory-database-management-system-and-middle-tier-cache.aspx It is open source product and shall be downloaded from the below link http://www.sourceforge.net/projects/csql http://www.databasecache.com