@SuppressWarnings("unchecked") private void writeObject (ObjectOutputStream stream) throws IOException { // JBAS-2071 - sync on FCI to ensure targets and vid are consistent ArrayList currentTargets = null; long vid = 0; synchronized (this.familyClusterInfo) { // JBAS-6345 -- write an ArrayList for compatibility with AS 3.x/4.x clients currentTargets = new ArrayList(this.familyClusterInfo.getTargets()); vid = this.familyClusterInfo.getCurrentViewId (); } stream.writeUTF(key); stream.writeObject(currentTargets); stream.writeLong(vid); stream.writeObject(loadBalancePolicy); }
/** Externalize this instance. */ @SuppressWarnings("unchecked") public void writeExternal(final ObjectOutput out) throws IOException { // JBAS-2071 - sync on FCI to ensure targets and vid are consistent ArrayList currentTargets = null; long vid = 0; synchronized (this.familyClusterInfo) { // JBAS-6345 -- write an ArrayList for compatibility with AS 3.x/4.x clients currentTargets = new ArrayList(this.familyClusterInfo.getTargets()); vid = this.familyClusterInfo.getCurrentViewId (); } out.writeObject(currentTargets); out.writeLong(vid); out.writeObject(this.loadBalancePolicy); out.writeObject(this.proxyFamilyName); }
/** * Externalize this instance and handle obtaining the remoteInvoker stub */ public void writeExternal(final ObjectOutput out) throws IOException { out.writeInt(CURRENT_VERSION); out.writeUTF(getLocator().getOriginalURI()); out.writeBoolean(isStrictRMIException()); // JBAS-2071 - sync on FCI to ensure targets and vid are consistent ArrayList targets = null; long vid = 0; synchronized (this.familyClusterInfo) { // JBAS-6345 -- write an ArrayList for compatibility with AS 3.x/4.x clients targets = new ArrayList(this.familyClusterInfo.getTargets ()); vid = this.familyClusterInfo.getCurrentViewId (); } out.writeObject(targets); out.writeObject(this.loadBalancePolicy); out.writeObject(this.proxyFamilyName); out.writeLong(vid); }
HARMIResponse rsp = target.invoke(this.familyClusterInfo.getCurrentViewId (), mi); if (rsp.newReplicants != null)
mi.setValue("CLUSTER_VIEW_ID", new Long(familyClusterInfo.getCurrentViewId())); String target = (String) getRemoteTarget(invocation); boolean failoverAuthorized = true;
invocation.setValue("CLUSTER_VIEW_ID", new Long(this.familyClusterInfo.getCurrentViewId())); log.trace("Client cluster view id: " + familyClusterInfo.getCurrentViewId()); log.trace(printPossibleTargets());