Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Fixed
-
None
-
None
Description
INSERT DELAYED might work differently depending on an engine. For example, on MyISAM it works in a classic way (returns and leaves the delayed operation in a separate thread). On InnoDB it produces ER_DELAYED_NOT_SUPPORTED. It would also be understandable if, when not supported, it worked as a normal INSERT.
However with SPIDER, it doesn't do either of this. It doesn't return an error, doesn't spawn a delayed operation, and doesn't work as normal INSERT. For normal INSERT, SPIDER honors lock_wait_timeout, but for INSERT DELAYED it doesn't.
Test case:
CREATE TABLE mysql.spider_tables( |
db_name char(64) not null default '', |
table_name char(64) not null default '', |
link_id int not null default 0, |
priority bigint not null default 0, |
server char(64) default null, |
scheme char(64) default null, |
host char(64) default null, |
port char(5) default null, |
socket text default null, |
username char(64) default null, |
password char(64) default null, |
ssl_ca text default null, |
ssl_capath text default null, |
ssl_cert text default null, |
ssl_cipher char(64) default null, |
ssl_key text default null, |
ssl_verify_server_cert tinyint not null default 0, |
default_file text default null, |
default_group char(64) default null, |
tgt_db_name char(64) default null, |
tgt_table_name char(64) default null, |
link_status tinyint not null default 1, |
PRIMARY KEY (db_name, table_name, link_id), |
KEY idx1 (priority) |
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin; |
|
install soname 'ha_spider.so'; |
create database remote; |
|
CREATE TABLE remote.t1 (i INT) ENGINE=MyISAM; |
|
eval CREATE TABLE t1 (i INT) |
ENGINE=SPIDER
|
CONNECTION='host "localhost", socket "$MASTER_MYSOCK", user "root", password "", prt "2000000"' |
COMMENT='database "remote", table "t1"'; |
|
LOCK TABLE t1 READ; |
|
--connect (con1,localhost,root,,)
|
|
SET lock_wait_timeout=1; |
--echo # It hangs here
|
INSERT DELAYED INTO t1 VALUES (1); |
bzr version-info
revision-id: svoj@mariadb.org-20130627111848-b8kc0z60ywwpqavz
|
revno: 3762
|
branch-nick: 10.0
|
Attachments
Issue Links
- relates to
-
MDEV-4438 Spider storage engine
- Closed