users@glassfish.java.net

Sharing state between cluster nodes

From: <glassfish_at_javadesktop.org>
Date: Mon, 29 Sep 2008 07:46:01 PDT

Hi,

is it possible with Glassfish 2 to preserve "state" (some pojo) in a cluster so that it's accessible from all nodes? Perhaps by storing it into the JNDI tree, if it's replicated across the cluster?

I've got an EJB application which is invoked via web services. Just for an example let's say these services are used to access a shopping basket application.
As the web tier isn't implemented in java at all, I cannot use stateful JaxWS web services but would implement the session management by passing a basketId between client and server.
Now where to store the basket objects? As my services are running on a cluster I cannot manage the baskets in a singleton. One approach would be by storing them into a database but I wonder if it's possible to put them into something "ram-ish" where they are replicated through the cluster.

Any ideas?

Thanks,

Norbert
[Message sent by forum member 'realsnowbird' (realsnowbird)]

http://forums.java.net/jive/thread.jspa?messageID=302348