Note: the test case fails for me all the time right now, but it's still non-deterministic. Try several times if it doesn't fail for you.
INSTALL SONAME 'ha_rocksdb';
|
|
CREATE TABLE t1 (a INT, KEY(a)) ENGINE=RocksDB;
|
INSERT INTO t1 VALUES (1),(2);
|
|
CREATE TABLE t2 (b INT) ENGINE=RocksDB;
|
CREATE OR REPLACE VIEW v2 AS SELECT * FROM t2;
|
|
CREATE OR REPLACE TABLE t3 (c INT) ENGINE=RocksDB;
|
BEGIN;
|
|
--connect (con1,localhost,root,,test)
|
SET lock_wait_timeout= 2;
|
--delimiter $
|
CREATE TRIGGER tr BEFORE UPDATE ON t3 FOR EACH ROW
|
BEGIN
|
DELETE FROM t1;
|
DELETE FROM non_existing_table;
|
END $
|
--delimiter ;
|
--send
|
ALTER TABLE t1 FORCE;
|
|
--connection default
|
DELETE FROM v2 WHERE b < 1;
|
--error ER_BAD_FIELD_ERROR
|
UPDATE t3 SET unknown_column = NULL;
|
|
--connection con1
|
--reap
|
INSERT INTO t1 VALUES (3);
|
|
# Cleanup
|
--disconnect con1
|
--connection default
|
COMMIT;
|
DROP VIEW v2;
|
DROP TABLE t1, t2, t3;
|
UNINSTALL SONAME 'ha_rocksdb';
|
Till recently (I suppose till changes Monty made in scope of MDEV-14970 / MDEV-14141, although I didn't bisect), the test case above caused the crash:
10.2.12
|
#3 <signal handler called>
|
#4 0x000055d7081bc333 in key_unpack (to=0x7fa5e017e7a0, table=0x7fa5d0371c70, key=0x7fa5d03765d0) at /data/src/10.2-bug/sql/key.cc:432
|
#5 0x000055d7080caf56 in print_keydup_error (table=0x7fa5d0371c70, key=0x7fa5d03765d0, msg=0x55d70abcf1f4 "Duplicate entry '%-.64s' for key '%-.192s'", errflag=0) at /data/src/10.2-bug/sql/handler.cc:3334
|
#6 0x000055d7080cb094 in print_keydup_error (table=0x7fa5d0371c70, key=0x7fa5d03765d0, errflag=0) at /data/src/10.2-bug/sql/handler.cc:3356
|
#7 0x000055d7080cb2e8 in handler::print_error (this=0x7fa5d0372878, error=121, errflag=0) at /data/src/10.2-bug/sql/handler.cc:3433
|
#8 0x000055d707e2fc00 in write_record (thd=0x7fa5ac000b00, table=0x7fa5d0371c70, info=0x7fa5e01804a0) at /data/src/10.2-bug/sql/sql_insert.cc:1958
|
#9 0x000055d707e2d471 in mysql_insert (thd=0x7fa5ac000b00, table_list=0x7fa5ac011208, fields=..., values_list=..., update_fields=..., update_values=..., duplic=DUP_ERROR, ignore=false) at /data/src/10.2-bug/sql/sql_insert.cc:1057
|
#10 0x000055d707e54af7 in mysql_execute_command (thd=0x7fa5ac000b00) at /data/src/10.2-bug/sql/sql_parse.cc:4415
|
#11 0x000055d707e5fa6e in mysql_parse (thd=0x7fa5ac000b00, rawbuf=0x7fa5ac011128 "INSERT INTO t1 VALUES (3)", length=25, parser_state=0x7fa5e0181200, is_com_multi=false, is_next_command=false) at /data/src/10.2-bug/sql/sql_parse.cc:7900
|
#12 0x000055d707e4d97c in dispatch_command (command=COM_QUERY, thd=0x7fa5ac000b00, packet=0x7fa5ac008941 "INSERT INTO t1 VALUES (3)", packet_length=25, is_com_multi=false, is_next_command=false) at /data/src/10.2-bug/sql/sql_parse.cc:1805
|
#13 0x000055d707e4c2da in do_command (thd=0x7fa5ac000b00) at /data/src/10.2-bug/sql/sql_parse.cc:1360
|
#14 0x000055d707f9a225 in do_handle_one_connection (connect=0x55d70adddcc0) at /data/src/10.2-bug/sql/sql_connect.cc:1335
|
#15 0x000055d707f99fb2 in handle_one_connection (arg=0x55d70adddcc0) at /data/src/10.2-bug/sql/sql_connect.cc:1241
|
#16 0x000055d7083b936e in pfs_spawn_thread (arg=0x55d70ac0d730) at /data/src/10.2-bug/storage/perfschema/pfs.cc:1863
|
#17 0x00007fa5e7bc6494 in start_thread (arg=0x7fa5e0182700) at pthread_create.c:333
|
#18 0x00007fa5e5fac93f in clone () from /lib/x86_64-linux-gnu/libc.so.6
|
Now it causes ER_DUP_KEY on a table which has no unique keys:
mysqltest: At line 31: query 'INSERT INTO t1 VALUES (3)' failed: 1022: Can't write; duplicate key in table 't1'
|
{"report":{"fcp":909.3999998569489,"ttfb":168.29999995231628,"pageVisibility":"visible","entityId":65863,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"f1d9eab4-012e-4e7f-a195-b1801c51e9a1","navigationType":0,"readyForUser":988.5,"redirectCount":0,"resourceLoadedEnd":1116.3999998569489,"resourceLoadedStart":173.39999985694885,"resourceTiming":[{"duration":300.80000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":173.39999985694885,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":173.39999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":474.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":300.59999990463257,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":173.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":173.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":474.2999999523163,"responseStart":0,"secureConnectionStart":0},{"duration":309.7999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":173.79999995231628,"connectEnd":173.79999995231628,"connectStart":173.79999995231628,"domainLookupEnd":173.79999995231628,"domainLookupStart":173.79999995231628,"fetchStart":173.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":173.79999995231628,"responseEnd":483.59999990463257,"responseStart":483.59999990463257,"secureConnectionStart":173.79999995231628},{"duration":342.89999985694885,"initiatorType":"script","name":"https://jira.mariadb.org/s/099b33461394b8015fc36c0a4b96e19f-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":174,"connectEnd":174,"connectStart":174,"domainLookupEnd":174,"domainLookupStart":174,"fetchStart":174,"redirectEnd":0,"redirectStart":0,"requestStart":174,"responseEnd":516.8999998569489,"responseStart":516.8999998569489,"secureConnectionStart":174},{"duration":346.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/94c15bff32baef80f4096a08aceae8bc-CDN/lu2bu7/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":174.20000004768372,"connectEnd":174.20000004768372,"connectStart":174.20000004768372,"domainLookupEnd":174.20000004768372,"domainLookupStart":174.20000004768372,"fetchStart":174.20000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":174.20000004768372,"responseEnd":520.7000000476837,"responseStart":520.7000000476837,"secureConnectionStart":174.20000004768372},{"duration":347,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":174.20000004768372,"connectEnd":174.20000004768372,"connectStart":174.20000004768372,"domainLookupEnd":174.20000004768372,"domainLookupStart":174.20000004768372,"fetchStart":174.20000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":174.20000004768372,"responseEnd":521.2000000476837,"responseStart":521.2000000476837,"secureConnectionStart":174.20000004768372},{"duration":348.10000014305115,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bu7/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":174.39999985694885,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":174.39999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":522.5,"responseStart":0,"secureConnectionStart":0},{"duration":347.2000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":174.39999985694885,"connectEnd":174.39999985694885,"connectStart":174.39999985694885,"domainLookupEnd":174.39999985694885,"domainLookupStart":174.39999985694885,"fetchStart":174.39999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":174.39999985694885,"responseEnd":521.5999999046326,"responseStart":521.5999999046326,"secureConnectionStart":174.39999985694885},{"duration":347.5,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":174.5,"connectEnd":174.5,"connectStart":174.5,"domainLookupEnd":174.5,"domainLookupStart":174.5,"fetchStart":174.5,"redirectEnd":0,"redirectStart":0,"requestStart":174.5,"responseEnd":522,"responseStart":522,"secureConnectionStart":174.5},{"duration":347.89999985694885,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":174.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":174.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":522.5999999046326,"responseStart":0,"secureConnectionStart":0},{"duration":347.7999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/3339d87fa2538a859872f2df449bf8d0-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":174.79999995231628,"connectEnd":174.79999995231628,"connectStart":174.79999995231628,"domainLookupEnd":174.79999995231628,"domainLookupStart":174.79999995231628,"fetchStart":174.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":174.79999995231628,"responseEnd":522.5999999046326,"responseStart":522.5999999046326,"secureConnectionStart":174.79999995231628},{"duration":719.0999999046326,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":180.70000004768372,"connectEnd":180.70000004768372,"connectStart":180.70000004768372,"domainLookupEnd":180.70000004768372,"domainLookupStart":180.70000004768372,"fetchStart":180.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":180.70000004768372,"responseEnd":899.7999999523163,"responseStart":899.7999999523163,"secureConnectionStart":180.70000004768372},{"duration":935.5999999046326,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":180.79999995231628,"connectEnd":180.79999995231628,"connectStart":180.79999995231628,"domainLookupEnd":180.79999995231628,"domainLookupStart":180.79999995231628,"fetchStart":180.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":180.79999995231628,"responseEnd":1116.3999998569489,"responseStart":1116.3999998569489,"secureConnectionStart":180.79999995231628},{"duration":290.39999985694885,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":711.2000000476837,"connectEnd":711.2000000476837,"connectStart":711.2000000476837,"domainLookupEnd":711.2000000476837,"domainLookupStart":711.2000000476837,"fetchStart":711.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":711.2000000476837,"responseEnd":1001.5999999046326,"responseStart":1001.5999999046326,"secureConnectionStart":711.2000000476837}],"fetchStart":1,"domainLookupStart":1,"domainLookupEnd":1,"connectStart":1,"connectEnd":1,"requestStart":36,"responseStart":169,"responseEnd":177,"domLoading":172,"domInteractive":1140,"domContentLoadedEventStart":1140,"domContentLoadedEventEnd":1178,"domComplete":2016,"loadEventStart":2016,"loadEventEnd":2017,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1118.7000000476837},{"name":"bigPipe.sidebar-id.end","time":1119.5},{"name":"bigPipe.activity-panel-pipe-id.start","time":1119.7000000476837},{"name":"bigPipe.activity-panel-pipe-id.end","time":1122.3999998569489},{"name":"activityTabFullyLoaded","time":1181.2999999523163}],"measures":[],"correlationId":"e96e45e53ebc72","effectiveType":"4g","downlink":9.1,"rtt":0,"serverDuration":76,"dbReadsTimeInMs":13,"dbConnsTimeInMs":21,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}