public void setCorrelationKey(CorrelationKey key) { _ckeySet = new CorrelationKeySet(); _ckeySet.add(key); }
public void setCorrelationKey(CorrelationKey ckey) { keySet = new CorrelationKeySet(); keySet.add(ckey); } }
/** * Restores the state of this correlation key set from a canonical form. * * @param canonicalForm a canonical form of correlation key set */ public void restore(String canonicalForm) { if( canonicalForm == null || canonicalForm.trim().length() == 0 ) return; if( canonicalForm.startsWith("@") ) { parseCanonicalForm(canonicalForm); } else { version = VERSION_1; add( new CorrelationKey(canonicalForm) ); } }
public CorrelationKeySet getKeySet() { // backward-compatibility; add up keys if( _keys.size() > 0 && _keySet == null ) { _keySet = new CorrelationKeySet(); } for (CorrelationKey aKey : _keys) { if (aKey != null && !_keySet.contains(aKey)) { _keySet.add(aKey); } } return _keySet; }
public CorrelationKeySet getCorrelationKeySet() { // backward compatibility; add up if (_correlationKey != null) { if( _correlationKeySet == null ) { _correlationKeySet = new CorrelationKeySet(); } if(!_correlationKeySet.contains(_correlationKey)) { _correlationKeySet.add(_correlationKey); } } return _correlationKeySet; }
} else if( ch == ',' ) { if( buf.toString().trim().length() != 0 ) { add( new CorrelationKey(buf.toString()) ); } else if( ch == '?' ) { // this is only a convenient feature for testing if( buf.toString().trim().length() != 0 ) { add( new OptionalCorrelationKey(buf.toString()) ); version = buf.toString(); } else { add( new CorrelationKey(buf.toString()) );
newKeySet.add(new CorrelationKey(""+old.getCSetId(), old.getValues())); Selector newSelector = new Selector(sel.idx, sel.plinkInstance, sel.opName, sel.oneWay, sel.messageExchangeId, newKeySet, "one");
newKeySet.add(new CorrelationKey(""+selCKey.getCorrelationSetName(), selCKey.getValues())); Selector newSelector = new Selector(sel.idx, sel.plinkInstance, sel.opName, sel.oneWay, sel.messageExchangeId, newKeySet, "one");
private CorrelationKeySet computeCorrelationKeys(MyRoleMessageExchangeImpl mex) { CorrelationKeySet keySet = new CorrelationKeySet(); Operation operation = mex.getOperation(); Element msg = BpelRuntimeContextImpl.mergeHeaders(mex.getDAO().getRequest()); javax.wsdl.Message msgDescription = operation.getInput().getMessage(); Set<OScope.CorrelationSet> csets = _plinkDef.getNonInitiatingCorrelationSetsForOperation(operation); for (OScope.CorrelationSet cset : csets) { CorrelationKey key = computeCorrelationKey(cset, _process.getOProcess().messageTypes.get(msgDescription.getQName()), msg); keySet.add(key); } csets = _plinkDef.getJoinningCorrelationSetsForOperation(operation); for (OScope.CorrelationSet cset : csets) { CorrelationKey key = computeCorrelationKey(cset, _process.getOProcess().messageTypes.get(msgDescription.getQName()), msg); keySet.add(key); } // Let's creata a key based on the sessionId String mySessionId = mex.getProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID); if (mySessionId != null) keySet.add(new CorrelationKey("-1", new String[] { mySessionId })); return keySet; }
public boolean migrate(Set<BpelProcess> registeredProcesses, BpelDAOConnection connection) { for (BpelProcess process : registeredProcesses) { __log.debug("Migrating correlators data for process " + process.getConf().getProcessId()); ProcessDAO processDao = connection.getProcess(process.getConf().getProcessId()); for (OPartnerLink plink : process.getOProcess().getAllPartnerLinks()) { if (plink.hasMyRole()) { for (Iterator opI = plink.myRolePortType.getOperations().iterator(); opI.hasNext();) { Operation op = (Operation)opI.next(); CorrelatorDAO corr = processDao.getCorrelator(plink.getName() + "." + op.getName()); // Changing all routes if (corr != null) { for (MessageRouteDAO routeDAO : corr.getAllRoutes()) { CorrelationKey oldKey = routeDAO.getCorrelationKey(); if (oldKey != null) { CorrelationKeySet keySet = new CorrelationKeySet(); keySet.add(oldKey); routeDAO.setCorrelationKeySet(keySet); } } } } } } } return true; } }
for( OScope.CorrelationSet cset : _oevent.joinCorrelations ) { if(getBpelRuntimeContext().isCorrelationInitialized(_scopeFrame.resolve(cset))) { keySet.add(getBpelRuntimeContext().readCorrelation(_scopeFrame.resolve(cset))); throw new FaultException(_oevent.getOwner().constants.qnCorrelationViolation,"Correlation not initialized."); keySet.add(getBpelRuntimeContext().readCorrelation(_scopeFrame.resolve(cset))); keySet.add(new CorrelationKey("-1", new String[] {sessionId}));