Hi,
We are using Camunda7.8, Wildfly10.1 with MariaDB10.1 database and we have been seeing “deployment.lock” errors in the wildfly server logs. This error happens during code install or sometimes during server bounce (saw the same issue with camunda 7.7). I would appreciate if you could please address this issue.
We are using embedded process engine and the datasource section for the camunda database in our domain.xml are as shown below.
<datasource jndi-name="java:jboss/datasources/ProcessEngine"
pool-name="ProcessEngine"
enabled="true"
use-java-context="true"
use-ccm="true"
jta="true">
<connection-url>jdbc:mariadb://xxxx:3308/camundabpmn?connectTimeout=60000&socketTimeout=20000</connection-url>
<driver>org.mariadb</driver>
<transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation>
<pool>
<min-pool-size>10</min-pool-size>
<max-pool-size>100</max-pool-size>
<prefill>true</prefill>
<use-strict-min>false</use-strict-min>
<flush-strategy>FailingConnectionOnly</flush-strategy>
</pool>
<security>
<user-name>xxxx</user-name>
<password>xxxx</password>
</security>
<validation>
<valid-connection-checker class-name="org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLValidConnectionChecker"/>
<validate-on-match>false</validate-on-match>
<background-validation>true</background-validation>
<background-validation-millis>20000</background-validation-millis>
<use-fast-fail>true</use-fast-fail>
<exception-sorter class-name="org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLExceptionSorter"/>
</validation>
<timeout>
<blocking-timeout-millis>5000</blocking-timeout-millis>
<idle-timeout-minutes>15</idle-timeout-minutes>
<query-timeout>200</query-timeout>
<allocation-retry>1</allocation-retry>
<allocation-retry-wait-millis>3000</allocation-retry-wait-millis>
</timeout>
<statement>
<prepared-statement-cache-size>32</prepared-statement-cache-size>
<share-prepared-statements>true</share-prepared-statements>
</statement>
</datasource>
<drivers>
<driver name="org.mariadb" module="mariadb">
<xa-datasource-class>org.mariadb.jdbc.MySQLDataSource</xa-datasource-class>
</driver>
</drivers>
Error stack trace:
Error querying database. Cause: java.sql.SQLNonTransientConnectionException: Connection timed out
The error may exist in org/camunda/bpm/engine/impl/mapping/entity/Property.xml
The error may involve defaultParameterMap
The error occurred while setting parameters
SQL: SELECT VALUE_ FROM ACT_GE_PROPERTY WHERE NAME_ = ‘deployment.lock’ for update
Cause: java.sql.SQLNonTransientConnectionException: Connection timed out
at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:150)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:141)
at org.camunda.bpm.engine.impl.db.sql.DbSqlSession.lock(DbSqlSession.java:131)
at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.lock(DbEntityManager.java:268)
at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.lock(DbEntityManager.java:264)
at org.camunda.bpm.engine.impl.persistence.entity.PropertyManager.acquireExclusiveLock(PropertyManager.java:31)
at org.camunda.bpm.engine.impl.cmd.DeployCmd.acquireExclusiveLock(DeployCmd.java:418)
at org.camunda.bpm.engine.impl.cmd.DeployCmd$1.call(DeployCmd.java:129)
at org.camunda.bpm.engine.impl.cmd.DeployCmd$1.call(DeployCmd.java:126)
at org.camunda.bpm.engine.impl.interceptor.CommandContext.runWithoutAuthorization(CommandContext.java:473)
at org.camunda.bpm.engine.impl.cmd.DeployCmd.doExecute(DeployCmd.java:126)
at org.camunda.bpm.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:92)
at org.camunda.bpm.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:72)
at org.camunda.bpm.engine.impl.interceptor.CommandExecutorImpl.execute(CommandExecutorImpl.java:24)
at org.camunda.bpm.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:104)
... 33 more
Caused by: java.sql.SQLNonTransientConnectionException: Connection timed out
at org.mariadb.jdbc.internal.util.ExceptionMapper.get(ExceptionMapper.java:125)
at org.mariadb.jdbc.internal.util.ExceptionMapper.throwException(ExceptionMapper.java:71)
at org.mariadb.jdbc.MariaDbStatement.executeQueryEpilog(MariaDbStatement.java:226)