User: vlada Date: 01/10/01 21:05:56 Modified: src/main/org/jboss/ha/framework/interfaces HAPartition.java HARMIClient.java Log: rather than using machine dependent system time to track if client's view of cluster has changed use logical viewID from cluster Revision Changes Path 1.2 +2 -1 jbossmx/src/main/org/jboss/ha/framework/interfaces/HAPartition.java Index: HAPartition.java =================================================================== RCS file: /cvsroot/jboss/jbossmx/src/main/org/jboss/ha/framework/interfaces/HAPartition.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- HAPartition.java 2001/09/30 15:19:32 1.1 +++ HAPartition.java 2001/10/02 04:05:56 1.2 @@ -20,7 +20,8 @@ public DistributedReplicantManager getDistributedReplicantManager(); public DistributedState getDistributedStateService (); - + public long getCurrentViewId(); + // *************************** // *************************** // RPC multicast communication 1.2 +7 -15 jbossmx/src/main/org/jboss/ha/framework/interfaces/HARMIClient.java Index: HARMIClient.java =================================================================== RCS file: /cvsroot/jboss/jbossmx/src/main/org/jboss/ha/framework/interfaces/HARMIClient.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- HARMIClient.java 2001/09/30 15:19:32 1.1 +++ HARMIClient.java 2001/10/02 04:05:56 1.2 @@ -30,7 +30,7 @@ * * @author <a href="mailto:[EMAIL PROTECTED]">Sacha Labourey</a> * @author <a href="mailto:[EMAIL PROTECTED]">Bill Burke</a> - * @version $Revision: 1.1 $ + * @version $Revision: 1.2 $ * * <p><b>Revisions:</b> * @@ -45,7 +45,7 @@ protected String key = null; protected ArrayList targets = null; protected LoadBalancePolicy loadBalancePolicy; - protected transient long tag = 0; + protected transient long currentViewId = 0; protected transient Object local = null; public HARMIClient () @@ -89,16 +89,7 @@ targets.addAll (newTargets); } } - - public long getTag () - { - return tag; - } - - public void setTag (long tag) - { - this.tag = tag; - } + public Object getRemoteTarget () { @@ -139,7 +130,8 @@ } // nothing found } - + + public Method findLocalMethod (Method method, Object[] args) throws Exception { return method; @@ -185,12 +177,12 @@ RemoteMethodInvocation rmi = new RemoteMethodInvocation (null, method, args); MarshalledObject mo = new MarshalledObject (rmi); // Is this step actually necessary? Can I just do method.invoke(target, args); ? - HARMIResponse rsp = target.invoke (tag, mo); + HARMIResponse rsp = target.invoke (currentViewId, mo); if (rsp.newReplicants != null) { System.out.println ("new set of replicants"); setTargets (rsp.newReplicants); - setTag (rsp.tag); + currentViewId = rsp.currentViewId; } return rsp.response; }
_______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development