Flowable Eclipse eror , please help

I have added all required maven depedencies, and jars. The same program is working with all activiti files. but not with Flowable.
Exception in thread “main” java.lang.VerifyError: Bad type on operand stack
Exception Details:
Location:
org/flowable/engine/impl/cfg/IdmEngineConfigurator.configure(Lorg/flowable/engine/common/impl/AbstractEngineConfiguration;)V @24: invokevirtual
Reason:
Type ‘org/flowable/idm/engine/IdmEngineConfiguration’ (current frame, stack[2]) is not assignable to ‘org/flowable/engine/common/impl/AbstractEngineConfiguration’
Current Frame:
bci: @24
flags: { }
locals: { ‘org/flowable/engine/impl/cfg/IdmEngineConfigurator’, ‘org/flowable/engine/common/impl/AbstractEngineConfiguration’ }
stack: { ‘org/flowable/engine/impl/cfg/IdmEngineConfigurator’, ‘org/flowable/engine/common/impl/AbstractEngineConfiguration’, ‘org/flowable/idm/engine/IdmEngineConfiguration’ }
Bytecode:
0000000: 2ab4 000b c700 0e2a bb00 0c59 b700 0db5
0000010: 000b 2a2b 2ab4 000b b600 0e2a b400 0bb6
0000020: 000f 572a 2b2a b400 0bb6 0010 b1
Stackmap Table:
same_frame(@18)

at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.initConfigurators(ProcessEngineConfigurationImpl.java:1211)
at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.init(ProcessEngineConfigurationImpl.java:821)
at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:798)
at servicetask.TestFlow1.main(TestFlow1.java:24)

My source code for testing Flowable process is…

package servicetask;
import java.util.HashMap;
import java.util.Map;

import org.flowable.engine.ProcessEngine;
import org.flowable.engine.RepositoryService;
import org.flowable.engine.RuntimeService;
import org.flowable.engine.impl.cfg.StandaloneInMemProcessEngineConfiguration;
import org.flowable.engine.runtime.ProcessInstance;
import org.flowable.identitylink.service.IdentityLinkServiceConfiguration;
import org.flowable.variable.service.history.InternalHistoryVariableManager;
import org.flowable.common.engine.impl.scripting.ScriptingEngines;
import org.flowable.engine.common.impl.ScriptingEngineAwareEngineConfiguration;
import org.flowable.engine.common.api.FlowableException;
import org.flowable.job.service.impl.asyncexecutor.FailedJobCommandFactory;
import org.flowable.task.service.history.InternalHistoryTaskManager;
import org.flowable.image.ProcessDiagramGenerator;
import org.flowable.variable.api.types.VariableTypes;
import org.flowable.job.api.TimerJobQuery;
public class TestFlow1 {

public static void main(String[] args) {
	// TODO Auto-generated method stub
	ProcessEngine processEngine = new StandaloneInMemProcessEngineConfiguration().setEnableProcessDefinitionInfoCache(true).buildProcessEngine();
	 
	Map<String,Object>variableMap=new HashMap<String,Object>();
	variableMap.put("name","Flowable");
	variableMap.put("abc",5);							 
	   
	   RepositoryService repositoryService = processEngine.getRepositoryService();
	   RuntimeService runtimeService = processEngine.getRuntimeService();
	   
	   // deploy process definition
	   repositoryService.createDeployment().addClasspathResource("ServiceProcess.bpmn").deploy();
	   
	   // this will invoke OldServiceTask
	   ProcessInstance processInstance = 
	   		runtimeService.startProcessInstanceByKey("myProcess",variableMap);

	   String processDefinitionId = processInstance.getProcessDefinitionId();
	   
	   // change service task class name
	   System.out.println("==== changing service task class name ====");
	   
	  // DynamicBpmnService dynamicBpmnService = processEngine.getDynamicBpmnService();
	  // ObjectNode infoNode = dynamicBpmnService
	   					//.changeServiceTaskClassName("dynamicServiceTask", 
	   						//	"org.activiti.examples.NewServiceTask");
	   
	   //dynamicBpmnService.saveProcessDefinitionInfo(processDefinitionId, infoNode);
	   
	   // this will invoke NewServiceTask
	   //processInstance = runtimeService.startProcessInstanceByKey("dynamic-service-task");
}

}

I am confused, please let me know what went wrong.
Note: same program is working in activiti.

I have created a maven project and wrote th same testing frogram using all activiti imports, and same is working.
code is below.

package servicetask;
import java.util.HashMap;
import java.util.Map;

import org.activiti.engine.ProcessEngine;
import org.activiti.engine.RepositoryService;
import org.activiti.engine.RuntimeService;
import org.activiti.engine.impl.cfg.StandaloneInMemProcessEngineConfiguration;
import org.activiti.engine.runtime.ProcessInstance;
public class te {

public static void main(String[] args) {
	// TODO Auto-generated method stub
	ProcessEngine processEngine = new StandaloneInMemProcessEngineConfiguration().setEnableProcessDefinitionInfoCache(true).buildProcessEngine();
	 
	Map<String,Object>variableMap=new HashMap<String,Object>();
	variableMap.put("name","Activiti");
	variableMap.put("abc",5);							 
	   
	   RepositoryService repositoryService = processEngine.getRepositoryService();
	   RuntimeService runtimeService = processEngine.getRuntimeService();
	   
	   // deploy process definition
	   repositoryService.createDeployment().addClasspathResource("ServiceProcess.bpmn").deploy();
	   
	   // this will invoke OldServiceTask
	   ProcessInstance processInstance = 
	   		runtimeService.startProcessInstanceByKey("myProcess",variableMap);

	   String processDefinitionId = processInstance.getProcessDefinitionId();
	   
	   // change service task class name
	   System.out.println("==== changing service task class name ====");
	   
	  // DynamicBpmnService dynamicBpmnService = processEngine.getDynamicBpmnService();
	  // ObjectNode infoNode = dynamicBpmnService
	   					//.changeServiceTaskClassName("dynamicServiceTask", 
	   						//	"org.activiti.examples.NewServiceTask");
	   
	   //dynamicBpmnService.saveProcessDefinitionInfo(processDefinitionId, infoNode);
	   
	   // this will invoke NewServiceTask
	   //processInstance = runtimeService.startProcessInstanceByKey("dynamic-service-task");
}

}

So, The question is, why the same code did not work with Flowable imports and depedencis.

That is a very weird error, typically indicating something is wrong with your classpath. Are you sure that you don’t have both libraries on the classpath? Have you made sure the project runs in isolation?

Can you paste the pom.xml you’re using when running with Flowable, that wat we can have a try too.

Below is my pom.xml

4.0.0
com.servicetask
servicetask
0.0.1-SNAPSHOT
com.servicetask

org.activiti activiti-engine 5.22.0 org.codehaus.groovy groovy-all
      <type>pom</type>
  </dependency>

  <!-- https://mvnrepository.com/artifact/org.activiti/activiti-dependencies -->
org.activiti activiti-dependencies 7-201710-EA pom com.h2database h2 1.4.200 test org.slf4j slf4j-jdk14 1.7.25 org.codehaus.groovy groovy-all 3.0.2 pom org.springframework spring-web 5.2.5.RELEASE test

I have both plugins, activiti and Flowable.
While creating project, I have created as Flowable Project, later converted to Maven project.

Even if compromise with activiti, while testugusig JUnit, ,
though everythig is correct in config.xml file, I am getting below eror.
java.lang.NoClassDefFoundError: org/springframework/core/ErrorCoded
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1016)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:151)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:802)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:700)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:623)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1016)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:151)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:802)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:700)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:623)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at org.activiti.engine.impl.cfg.BeansConfigurationHelper.parseProcessEngineConfiguration(BeansConfigurationHelper.java:32)
at org.activiti.engine.impl.cfg.BeansConfigurationHelper.parseProcessEngineConfigurationFromResource(BeansConfigurationHelper.java:48)
at org.activiti.engine.ProcessEngineConfiguration.createProcessEngineConfigurationFromResource(ProcessEngineConfiguration.java:244)
at org.activiti.engine.ProcessEngineConfiguration.createProcessEngineConfigurationFromResource(ProcessEngineConfiguration.java:240)
at org.activiti.engine.impl.test.TestHelper.getProcessEngine(TestHelper.java:228)
at org.activiti.engine.test.ActivitiRule.initializeProcessEngine(ActivitiRule.java:237)
at org.activiti.engine.test.ActivitiRule.starting(ActivitiRule.java:205)
at org.activiti.engine.test.ActivitiRule.startingQuietly(ActivitiRule.java:171)
at org.activiti.engine.test.ActivitiRule.access$000(ActivitiRule.java:86)
at org.activiti.engine.test.ActivitiRule$1.evaluate(ActivitiRule.java:124)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:542)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:770)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)
Caused by: java.lang.ClassNotFoundException: org.springframework.core.ErrorCoded
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
… 46 more

java.lang.NullPointerException
at org.flowable.designer.test.ProcessTestMyProcess.startProcess(ProcessTestMyProcess.java:26)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:567)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.activiti.engine.test.ActivitiRule$1.evaluate(ActivitiRule.java:126)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:542)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:770)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)

java.lang.NullPointerException
at org.activiti.engine.test.ActivitiRule.finished(ActivitiRule.java:273)
at org.activiti.engine.test.ActivitiRule.finishedQuietly(ActivitiRule.java:179)
at org.activiti.engine.test.ActivitiRule.access$400(ActivitiRule.java:86)
at org.activiti.engine.test.ActivitiRule$1.evaluate(ActivitiRule.java:135)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:542)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:770)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)


Confused…I know I am confusing others too, simply problem is, My Flow is not working.

Friends…my apologies for confusing all of you…
Today just now I could call a bean from Service task of Activiti, now I am 100% confident about implementing the same in Flowable.
I added the bean id in activiti.config.xml…
Steps followed are…

  1. Create an activiti project…
    2.create diagram and required java bean…and convert to maven project.
    3 create a unit test
  2. add bean id in config…
  3. bean has to be called as expression in service task…
    Thats all…
    run as junit test…
    and get result…
    Thank you alll…
    No pom.xml additions , nothing required…