AnsweredAssumed Answered

'Error while closing command context' while testing Camel task

Question asked by arnoldschrijver on Aug 4, 2014
Latest reply on Aug 5, 2014 by arnoldschrijver
Hi,

I was experimenting a bit with the Camel tasks in Activiti 5.16 and received ActivitiObjectNotFoundException and I am not sure where this is coming from. My unit tests pass apparently, but I want to get rid of the stacktrace as well.

The stacktrace I get is:

[blockcode]

13:24:54.738 [main] DEBUG o.a.e.i.interceptor.CommandContext - Error while closing command context
org.activiti.engine.ActivitiObjectNotFoundException: Could not find a deployment with id '4'.
   at org.activiti.engine.impl.persistence.deploy.DeploymentManager.removeDeployment(DeploymentManager.java:132) ~[activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.cmd.DeleteDeploymentCmd.execute(DeleteDeploymentCmd.java:41) ~[activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.cmd.DeleteDeploymentCmd.execute(DeleteDeploymentCmd.java:24) ~[activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.interceptor.CommandInvoker.execute(CommandInvoker.java:24) ~[activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:57) ~[activiti-engine-5.16.jar:5.16]
   at org.activiti.spring.SpringTransactionInterceptor$1.doInTransaction(SpringTransactionInterceptor.java:47) [activiti-spring-5.16.jar:5.16]
   at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:133) [spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.activiti.spring.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:45) [activiti-spring-5.16.jar:5.16]
   at org.activiti.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:37) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:40) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:35) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.RepositoryServiceImpl.deleteDeployment(RepositoryServiceImpl.java:90) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.impl.test.TestHelper.annotationDeploymentTearDown(TestHelper.java:121) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.test.ActivitiRule.finished(ActivitiRule.java:265) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.test.ActivitiRule.finishedQuietly(ActivitiRule.java:179) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.test.ActivitiRule.access$400(ActivitiRule.java:86) [activiti-engine-5.16.jar:5.16]
   at org.activiti.engine.test.ActivitiRule$1.evaluate(ActivitiRule.java:135) [activiti-engine-5.16.jar:5.16]
   at org.junit.rules.RunRules.evaluate(RunRules.java:20) [junit-4.11.jar:na]
   at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:72) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:233) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:87) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238) [junit-4.11.jar:na]
   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63) [junit-4.11.jar:na]
   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236) [junit-4.11.jar:na]
   at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53) [junit-4.11.jar:na]
   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229) [junit-4.11.jar:na]
   at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) [junit-4.11.jar:na]
   at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:71) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.junit.runners.ParentRunner.run(ParentRunner.java:309) [junit-4.11.jar:na]
   at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:176) [spring-test-4.0.6.RELEASE.jar:4.0.6.RELEASE]
   at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264) [surefire-junit4-2.16.jar:2.16]
   at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153) [surefire-junit4-2.16.jar:2.16]
   at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124) [surefire-junit4-2.16.jar:2.16]
   at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200) [surefire-booter-2.16.jar:2.16]
   at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153) [surefire-booter-2.16.jar:2.16]
   at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103) [surefire-booter-2.16.jar:2.16]

[/blockcode]

I created a small project with a single unit test that demonstrates the issue
Anyone knows what's the cause of the error?

Outcomes