void fireEvent(BpelEvent event) { // Note that the eventListeners list is a copy-on-write array, so need // to mess with synchronization. for (org.apache.ode.bpel.iapi.BpelEventListener l : _contexts.eventListeners) { l.onEvent(event); } }
public void defer(final Runnable runnable) { _scheduler.registerSynchronizer(new Scheduler.Synchronizer() { public void afterCompletion(boolean success) { } public void beforeCompletion() { runnable.run(); } }); } public void onRollback(final Runnable runnable) {
/** * Retrives the base URI to use for local resource resolution. * * @return URI - instance representing the absolute file path to the physical location of the process definition folder. */ public URI getBaseResourceURI() { return this._pconf.getBaseURI(); }
public void onAsyncReply(MyRoleMessageExchange myRoleMex) throws BpelEngineException { Status mStat = myRoleMex.getStatus(); if ( mStat == Status.RESPONSE ) { currentResponse = myRoleMex.getResponse(); } myRoleMex.complete(); }
/** * Use the response from one of the subscribers as my response * * @return type */ @Override public Message getResponse() { return template.getResponse(); }
@Override public Status getStatus() { return template.getStatus(); }
public Void call() throws Exception { pmex.replyWithFailure(FailureType.NO_RESPONSE, "Response not received after " + _responseTimeout + "ms.", null); return null; } });
public Object call() throws Exception { JobInfo ji = new JobInfo("volatileJob", detail, 0); doExecute(ji); return null; } });
@Override public Operation getOperation() { return template.getOperation(); } }
public void afterCompletion(int status) { synch.afterCompletion(status == Status.STATUS_COMMITTED); } });
public void beforeCompletion() { synch.beforeCompletion(); } public void afterCompletion(int status) {
@Override public CorrelationStatus getCorrelationStatus() { return template.getCorrelationStatus(); }
@Override public PortType getPortType() { return template.getPortType(); }
/** * Use the EPR of one of the subscribers as my EPR * * @return type * * @throws BpelEngineException BpelEngineException */ @Override public EndpointReference getEndpointReference() throws BpelEngineException { return template.getEndpointReference(); }
private boolean checkRetry(JobDetails we) { // Only retry if the job is NOT in memory. Not that this does not guaranty that a retry will be scheduled. // Actually events are not retried if not persisted and the scheduler might choose to discard the event if it has been retried too many times. return !we.getInMem(); }
/** * Constructor that hardwires OpenJPA on a new in-memory database. Suitable for tests. */ public <E> ProcessStoreImpl(EndpointReferenceContext eprContext, TransactionManager mgr, ConfStoreDAOConnectionFactory cf, CacheProvider cacheProvider) { _eprContext = eprContext; _txm = mgr; _cf=cf; _cacheProvider = cacheProvider; _processStates = _cacheProvider.createCache(); }
public JobType getType() { return JobType.valueOf(type); } public void setType(JobType type) {
public void setType(JobType type) { this.type = type.toString(); } public String getChannel() {
public long getEstimatedHydratedSize() { return _pconf.getCBPFileSize() * PROCESS_MEMORY_TO_SERIALIZED_SIZE_RATIO; }
public void onRollback(final Runnable runnable) { _scheduler.registerSynchronizer(new Scheduler.Synchronizer() { public void afterCompletion(boolean success) { if (!success) runnable.run(); } public void beforeCompletion() { } }); }