-
1. Re: Different clients ,same state content
darranl Sep 8, 2003 8:13 AM (in response to freemanhill)Have a look at the 'JBoss Clustering' documentation, if you do not already have a copy you can buy one by following the 'Buy JBoss doco' link to the right.
There is a section that discusses the 'JBoss Clustering Framework', this covers distributed state which might be what you are looking for. -
2. Re: Different clients ,same state content
freemanhill Sep 8, 2003 10:19 PM (in response to freemanhill)Of cource we had bought it.
JBossClustering.pdf,Date 2003-04-02.
Thanks in advance for timely reply. -
3. Re: Different clients ,same state content
freemanhill Sep 8, 2003 10:26 PM (in response to freemanhill)Another question,
If I do as the docu,our source codes can only for JBoss.Is there any other way to implement our target only using Stardard J2EE components?
Thanks all -
4. Re: Different clients ,same state content
slaboure Sep 9, 2003 4:12 AM (in response to freemanhill)Why do you need clustering for? Your question simply state that you have multiple client that request the same information and you want it to be cached, right? Do you have any specific clustering need or not?
cheers,
sacha -
5. Re: Different clients ,same state content
freemanhill Sep 9, 2003 10:24 PM (in response to freemanhill)Thanks for reply.
Our project is a mobile application system.
But one handset client every time request with different http seesion. And we want to save state of all clients.
We had read the Clustering Docu,but there is no sample source codes for DS(Page 70 of 89).
How we can do?
Thanks again... -
6. Re: Different clients ,same state content
slaboure Sep 10, 2003 1:40 AM (in response to freemanhill)OK, but will you use a cluster or not?
If not, then you can simply use an MBean service that will remember your "handy" sessions.
If you will, then simply look at the DS API, it is really easy to use.
Cheers,
sacha -
7. Re: Different clients ,same state content
freemanhill Sep 10, 2003 4:36 AM (in response to freemanhill)Thanks in advance.
But we do not find some way to construct DS object.Here are Constructors of org.jboss.ha.framework.serverDistributedStateImpl.
public DistributedStateImpl () {} // for JMX checks
public DistributedStateImpl (HAPartition partition, MBeanServer server)
{
this.partition = partition;
this.mbeanServer = server;
this.log = Logger.getLogger (this.getClass ());
}
And in out servlet how can we construct it?
new DistributedState() or new DistributedState(HaPartition myPartition,MBeanServer myServer)
If choose the second,and how to construct HaPartition and MBeanServer?
When we try
myPartition = (HAPartition)jndiContext.lookup("/HAPartion/DefaultPartition");
server log comes out "HAPartion not bound"!
How should we do?
Thanks again,
Hill -
8. Re: Different clients ,same state content
freemanhill Sep 11, 2003 12:12 AM (in response to freemanhill)My mistake...
And as you say, it is really easy to use.
org.jboss.ha.framework.server.util.DistributedTimedCachePolicy explain it clearly.
Our grateful thanks are due to your reply.