Thanks a lot Filip, SimpleTcpReplicationManager does indeed work the way i need it!
Vlad -----Original Message----- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Wed 5/26/2004 6:43 PM To: Tomcat Users List Cc: Subject: RE: A cluster question >Is there any other way to force replication apart from calling session.setAttribute(name, bean) yes, there is, but not using the DeltaManager, instead use SimpleTcpReplicationMananger and set useDirtyFlag="false" the useDirtyFlag is ignored on the delta manager, since the delta manager only replicates deltas. filip -----Original Message----- From: Ilyschenko, Vlad [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 26, 2004 9:32 AM To: Tomcat Users List Subject: A cluster question Hello, I have a session bean that changes its state as pages call methods on that bean. I want this bean to be replictated to other cluster members but it seems like it gets replicated only once, straight after it is created. Is there any other way to force replication apart from calling session.setAttribute(name, bean) ? I have tried useDirtyFlag true and false - no luck. The application is "distributed" and all other things do get replicated. Regards, Vlad This is a little test case for my problem: test.jsp: --------- <jsp:useBean id="mybean" class="TestBean" scope="session" /> <% out.print(mybean.a()); %> TestBean.java ------------- import org.apache.log4j.Logger; import java.io.Serializable; import java.io.IOException; import java.util.Random; public class TestBean implements Serializable{ private static Logger logger = Logger.getLogger(TestBean.class); private long m_a = 0; private Random rnd = new Random(System.currentTimeMillis()); public long a() { m_a = rnd.nextLong(); return m_a; } private void writeObject(java.io.ObjectOutputStream out) throws IOException { //logger.debug("Serialized"); System.out.println("Serialized"); out.defaultWriteObject(); } private void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); // logger.debug("Deserialized"); System.out.println("Deserialized"); } } **************************************************************************** **** The information contained in this email message may be confidential. If you are not the intended recipient, any use, interference with, disclosure or copying of this material is unauthorised and prohibited. Although this message and any attachments are believed to be free of viruses, no responsibility is accepted by Informa for any loss or damage arising in any way from receipt or use thereof. Messages to and from the company are monitored for operational reasons and in accordance with lawful business practices. If you have received this message in error, please notify us by return and delete the message and any attachments. Further enquiries/returns can be sent to [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
