wood burning stoves 2.0*
The moose likes EJB and other Java EE Technologies and the fly likes Cache Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Cache" Watch "Cache" New topic
Author

Cache

PrashantSonar CSN
Greenhorn

Joined: Sep 30, 2003
Posts: 11
I have two system running on two seperate JVM's and two seperate App Servers(both are weblogic 6.1),the important functionality is on both the system there is a cache program which holds data in HashMap but both are shairing the same database..
So for commuincating with both the cache or synchronize the cache as changes happen at any end should be reflected at another end, currently I am using http call to notify the change at one end so accordingly another program removes the old values and when next request comes it refreshes the data. This is all happening in current scenario....
This complete thing is in Java programs so now I want only one cache for both the servers which will share the same database.
So Client want to use J2EE means ur EJB feature so what kind of bean is useful for this scenario..?
On which server it needs to be deployed or will there be any server clustering?
And how the notification process for synchronization of changes in database will happen...?
Throw some ideas.....
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
so now I want only one cache for both the servers which will share the same database.
It'll still be "two" caches if there are two server instances. Although, you could count a clustered environment as having only one cache because you're not the one who needs to synchronize it...
So Client want to use J2EE means ur EJB feature so what kind of bean is useful for this scenario..?
That would be entity beans.
On which server it needs to be deployed or will there be any server clustering?
If you want the two servers' caches to be synched, you'll have to cluster them. In that case, you'll deploy stuff on the "admin" server, which will in turn handle deploying the same stuff on the "managed" servers.
And how the notification process for synchronization of changes in database will happen...?
If you mean how will your application know when someone has manually added a row into the database using a command-line tool, it won't.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
 
wood burning stoves
 
subject: Cache