You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ode.apache.org by mr...@apache.org on 2008/07/16 19:33:57 UTC
svn commit: r677358 -
/ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java
Author: mriou
Date: Wed Jul 16 10:33:57 2008
New Revision: 677358
URL: http://svn.apache.org/viewvc?rev=677358&view=rev
Log:
Fixed recovery tests as they used to wait until nothing is scheduled anymore.
Modified:
ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java
Modified: ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java
URL: http://svn.apache.org/viewvc/ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java?rev=677358&r1=677357&r2=677358&view=diff
==============================================================================
--- ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java (original)
+++ ode/branches/APACHE_ODE_1.X/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java Wed Jul 16 10:33:57 2008
@@ -270,7 +270,7 @@
private class SchedulerWrapper implements Scheduler {
MockScheduler _scheduler;
- long _nextSchedule;
+ long _nextSchedule;
SchedulerWrapper(BpelServerImpl server, TransactionManager txManager, DataSource dataSource) {
ExecutorService executorService = Executors.newCachedThreadPool();
@@ -281,7 +281,9 @@
public String schedulePersistedJob(Map<String,Object>jobDetail,Date when) throws ContextException {
String jobId = _scheduler.schedulePersistedJob(jobDetail, when);
- _nextSchedule = when == null ? System.currentTimeMillis() : when.getTime();
+ // Invocation checks get scheduled much later, we don't want (or need) to wait for them
+ if (!"INVOKE_CHECK".equals(jobDetail.get("type")))
+ _nextSchedule = when == null ? System.currentTimeMillis() : when.getTime();
return jobId;
}