[MDEV-14843] Assertion `s_tx_list.size() == 0' failed in myrocks::Rdb_transaction::term_mutex Created: 2018-01-01 Updated: 2018-03-28 Resolved: 2018-03-26 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - RocksDB |
| Affects Version/s: | 10.2 |
| Fix Version/s: | 10.2.14 |
| Type: | Bug | Priority: | Major |
| Reporter: | Elena Stepanova | Assignee: | Sergei Petrunia |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Sprint: | 10.3.6-1 | ||||||||
| Description |
|
|
| Comments |
| Comment by Sergei Petrunia [ 2018-03-21 ] | |||||||||||||||||
|
One can change ALTER TABLE t1 FORCE; to any other statement that starts a MyRocks transaction, for example insert into t1 values (1); | |||||||||||||||||
| Comment by Sergei Petrunia [ 2018-03-22 ] | |||||||||||||||||
|
Ok, the failing assert shows that a MyRocks transaction remains in the global MyRocks transaction list ( s_tx_list) when the plugin is unloaded. MyRocks keeps a per-thread Rdb_transaction object. The object remains allocated even if there is no real active transaction. This is a patch to remove an active transaction from the current thread: https://gist.github.com/spetrunia/a74cef1272c9e8a42114d13eefed7d9c . The original testcase for this bug does not crash with this patch. However, one can easily construct a slightly modified testcase which will still cause the same assertion failure:
| |||||||||||||||||
| Comment by Sergei Petrunia [ 2018-03-26 ] | |||||||||||||||||
|
If one adjusts the testcase to work with Percona Server, it will crash it, too: https://gist.github.com/spetrunia/48175603a1b6d38df7aecaad3fc3023b |