# Database problem with change lock

**URL:** <https://forum.flowable.org/t/database-problem-with-change-lock/4420>\
**Category:** Flowable Engine\
**Created:** [August 27, 2019, 8:58pm UTC](https://forum.flowable.org/t/database-problem-with-change-lock/4420 "2019-08-27T20:58:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![pfranks](https://avatars.discourse-cdn.com/v4/letter/p/77aa72/32.png) [@pfranks](https://forum.flowable.org/u/pfranks)\
**Post date:** [August 27, 2019, 8:58pm UTC](https://forum.flowable.org/t/database-problem-with-change-lock/4420/1 "2019-08-27T20:58:15Z")

</div>

I have a deployment happening for my integration testing for flowable and once in a while it will get stuck with a change lock that occurs over and over again. How can I avoid this?

2019-08-27 21:12:48.132 INFO 8 — [main] liquibase.executor.jvm.JdbcExecutor : SELECT `LOCKED` FROM flowable.ACT\_DMN\_DATABASECHANGELOGLOCK WHERE ID=1  
2019-08-27 21:12:48.134 INFO 8 — [main] l.lockservice.StandardLockService : Waiting for changelog lock…

---

<div class="post-metadata">

**Author:** ![joram](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.flowable.org/joram/32/26_2.png) [@joram](https://forum.flowable.org/u/joram)\
**Post date:** [August 28, 2019, 3:58am UTC](https://forum.flowable.org/t/database-problem-with-change-lock/4420/2 "2019-08-28T03:58:11Z")

</div>

It could have a few reasons: connections limit reached, liquibase process killed in the middle, etc. However, eventually it should give a timeout (but might be very long depending on the database config).

What database are you using? Can you check some connection/transaction timeout settings?

---

<div class="post-metadata">

**Author:** ![pfranks](https://avatars.discourse-cdn.com/v4/letter/p/77aa72/32.png) [@pfranks](https://forum.flowable.org/u/pfranks)\
**Post date:** [August 28, 2019, 4:49pm UTC](https://forum.flowable.org/t/database-problem-with-change-lock/4420/3 "2019-08-28T16:49:54Z")

</div>

We’re using AWS RDS with the MySQL backend. I’ll check the specs but I doubt there’s enough traffic to cause problems.

Is the lock timeout a database setting or is it set by the app?

---

<div class="post-metadata">

**Author:** ![joram](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.flowable.org/joram/32/26_2.png) [@joram](https://forum.flowable.org/u/joram)\
**Post date:** [September 10, 2019, 11:50am UTC](https://forum.flowable.org/t/database-problem-with-change-lock/4420/4 "2019-09-10T11:50:34Z")

</div>

Sorry for the delay, this forum post slipped through.

It looks like Mysql support a ‘wait\_timeout’ settings. It seems AWS does support this: [https://aws.amazon.com/blogs/database/best-practices-for-configuring-parameters-for-amazon-rds-for-mysql-part-3-parameters-related-to-security-operational-manageability-and-connectivity-timeout/](https://aws.amazon.com/blogs/database/best-practices-for-configuring-parameters-for-amazon-rds-for-mysql-part-3-parameters-related-to-security-operational-manageability-and-connectivity-timeout/)

(but the default seems to be 4 hours)

However, I’m not sure where exactly this setting can be set in AWS (can’t find if it can be added to the jdbc url, too)
