• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

skeema / skeema / 7508575741
92%

Build:
DEFAULT BRANCH: main
Ran 12 Jan 2024 11:37PM UTC
Jobs 1
Files 75
Run time 5s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

12 Jan 2024 11:00PM UTC coverage: 93.28% (-0.03%) from 93.31%
7508575741

push

github

evanelias
MariaDB: fix FK-related workspace cleanup stalls caused by server bug

In MariaDB 10.6+, the cleanup step of Skeema's workspace logic can potentially
encounter a stall if any tables have foreign key constraints. The stall length
depends on the server setting for innodb_lock_wait_timeout, which defaults to
50 seconds. Since this is longer than Skeema's default query timeout (20 sec),
the problem typically manifests as a timeout when Skeema tries to clean up the
workspace.

The root cause of this problem is almost certainly the MariaDB server bug
tracked at https://jira.mariadb.org/browse/MDEV-32899, which will be fixed in
the upcoming set of MariaDB point releases (10.6.17, 10.11.7, 11.0.5, 11.1.4,
11.2.3, 11.3.2). These have not been released yet, and Skeema will nonetheless
need a workaround for affected server versions anyway.

This commit solves the problem by setting a low session-level
innodb_lock_wait_timeout whenever concurrently dropping tables during the
workspace cleanup step. Any resulting lock-wait-timeout error (1205) will be
retried once, serially, by logic that is already in place to handle similar
(but unrelated) locking issues with FKs in MySQL 8+.

This commit also improves error reporting in various functions along the
workspace cleanup code path.

Prior to this commit, in theory the Skeema workspace cleanup error could
occur randomly/inconsistently but only when *all* of the following are true:

* At least one table has a foreign key constraint
* Server is MariaDB 10.6+ (any point release)
* Server InnoDB buffer pool size is below 32GB (above this size, Skeema will
  automatically switch to serial drop table for workspace cleanup)
* Skeema's temp-schema-threads option is set to 2 or more (default 5)
* Server innodb_lock_wait_timeout (default 50 sec) exceeds Skeema's query
  timeout (default 20s, see readTimeout in connect-options)

However, in practice this problem only came up in CI (GitHub Actions) and has
never been reproduced l... (continued)

9634 of 10328 relevant lines covered (93.28%)

1.12 hits per line

Jobs
ID Job ID Ran Files Coverage
1 7508575741.1 12 Jan 2024 11:37PM UTC 0
93.28
GitHub Action Run
Source Files on build 7508575741
Detailed source file information is not available for this build.
  • Back to Repo
  • a5ed51d4 on github
  • Prev Build on main (#7427939308)
  • Next Build on main (#7561896741)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc