How to configure flowable with AS400/DB2

I am trying to configure flowable with as400/db2 and I found a solution to my problem on the activity forum.
Could you try to fix this issue?

https://community.alfresco.com/thread/222969-how-to-configure-activiti-with-as400db2

Hi,

Is the issue that the databaseTypeMapping is not in the list for the as400/db2 case? What is the exact string value that we should add?

Best regards,

Tijs

Hi,
the exact string from the logfile is ‘DB2 UDB for AS/400’.
And could you tell me when you would lauch a new release?

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.flowable.idm.engine.IdmEngine]: Factory method ‘idmEngine’ threw exception; nested exception is org.flowable.engine.common.api.FlowableException: couldn’t deduct database type from database product name 'DB2 UDB for AS/400’
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)
… 61 more
Caused by: org.flowable.engine.common.api.FlowableException: couldn’t deduct database type from database product name 'DB2 UDB for AS/400’
at org.flowable.engine.common.AbstractEngineConfiguration.initDatabaseType(AbstractEngineConfiguration.java:325)
at org.flowable.engine.common.AbstractEngineConfiguration.initDataSource(AbstractEngineConfiguration.java:312)
at org.flowable.idm.engine.IdmEngineConfiguration.init(IdmEngineConfiguration.java:191)
at org.flowable.idm.engine.IdmEngineConfiguration.buildIdmEngine(IdmEngineConfiguration.java:177)
at org.flowable.app.conf.FlowableIdmEngineConfiguration.idmEngine(FlowableIdmEngineConfiguration.java:61)
at org.flowable.app.conf.FlowableIdmEngineConfiguration$$EnhancerBySpringCGLIB$$6b6ed2fd.CGLIB$idmEngine$6()
at org.flowable.app.conf.FlowableIdmEngineConfiguration$$EnhancerBySpringCGLIB$$6b6ed2fd$$FastClassBySpringCGLIB$$b8df4cd5.invoke()
at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)
at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:358)
at org.flowable.app.conf.FlowableIdmEngineConfiguration$$EnhancerBySpringCGLIB$$6b6ed2fd.idmEngine()
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)
… 62 more

Ty

That doesn’t look like the technical string, it probable needs to be something like DB2/400, see flowable-engine/modules/flowable-engine-common/src/main/java/org/flowable/engine/common/AbstractEngineConfiguration.java at 859e46a38015211714bdb1e6380797b36b7fa320 · flowable/flowable-engine · GitHub

On workaround for now is to subclass the engine configuration, and add your own mapping to the databaseTypeMappings.