Timeout error trying to lock table in h2

前端 未结 8 1474
无人共我
无人共我 2020-12-02 16:39

I get the following error under a certain scenario

When a different thread is populating a lot of users via the bulk upload operation and I was trying to view the li

相关标签:
8条回答
  • 2020-12-02 17:33

    I had MVCC=true in my connection string but still was getting error above. I had added ;DEFAULT_LOCK_TIMEOUT=10000;LOCK_MODE=0 and problem was solved

    0 讨论(0)
  • 2020-12-02 17:36

    For those having this issue with integration tests (i.e. server is accessing the h2 db and an integration test is accessing the db before calling the server, to prepare the test), adding a 'commit' to the script executed before the test makes sure that the data are in the database before calling the server (without MVCC=true - which I find is a bit 'weird' if it is not enabled by default).

    0 讨论(0)
提交回复
热议问题