You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Vladimir Ozerov (JIRA)" <ji...@apache.org> on 2019/01/20 09:33:00 UTC

[jira] [Commented] (IGNITE-10054) sqlline hangs with concurrent operations

    [ https://issues.apache.org/jira/browse/IGNITE-10054?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16747414#comment-16747414 ] 

Vladimir Ozerov commented on IGNITE-10054:
------------------------------------------

Expected for now. Deadlock handling will be introduced in IGNITE-9322.

> sqlline hangs with concurrent operations
> ----------------------------------------
>
>                 Key: IGNITE-10054
>                 URL: https://issues.apache.org/jira/browse/IGNITE-10054
>             Project: Ignite
>          Issue Type: Bug
>          Components: mvcc
>    Affects Versions: 2.7
>            Reporter: Sergey Kozlov
>            Priority: Critical
>             Fix For: 2.8
>
>         Attachments: 15828.txt, 16696.txt, ignite-24507fea.0.log, ignite-c9ddebdb.0.log
>
>
> 1. Start 2 nodes cluster with PDS (wal_mode=FSYNC), activate
> 2. Start 1st {{bin/sqlline}} with following commands (in batch file):
> {noformat}
> create table t1 (a int, b int, primary key(a)) with "atomicity=TRANSACTIONAL_SNAPSHOT,backups=1";
> insert into t1 values (1,1);
> insert into t1 values (2,1);
> insert into t1 values (3,1);
> insert into t1 values (4,1);
> insert into t1 values (5,1);
> insert into t1 values (6,1);
> insert into t1 values (7,1);
> insert into t1 values (8,1);
> insert into t1 values (9,1);
> insert into t1 values (10,1);
> begin;
> update t1 set b=b+1;
> commit;
> begin;
> update t1 set b=b+1;
> commit;
> begin;
> update t1 set b=b+1;
> commit;
> begin;
> update t1 set b=b+1;
> commit;
> ...repeat TX many times...
> {noformat}
> 3. Start 2nd {{bin/sqlline}} with following commands (in batch file):
> {noformat}
> begin;
> update t1 set b=b-1;
> commit;
> begin;
> update t1 set b=b-1;
> commit;
> begin;
> update t1 set b=b-1;
> commit;
> ...repeat TX many times...
> {noformat}
> 4. After some time both {{sqlline}} hang:
> {noformat}
> 611/113163   commit;
> Error: Failed to execute DDL statement [stmt=commit, err=Failed to finish transaction because it has been rolled back [t
> imeout=0, tx=GridNearTxLocal[xid=f91ff90c661-00000000-0914-10f6-0000-000000000001, xidVersion=GridCacheVersion [topVer=1
> 52310006, order=1540829999519, nodeOrder=1], concurrency=PESSIMISTIC, isolation=REPEATABLE_READ, state=MARKED_ROLLBACK,
> invalidate=false, rollbackOnly=true, nodeId=c9ddebdb-c328-4283-97c5-a6634444887a, timeout=0, duration=11, label=null]]]
> (state=50000,code=1)
> java.sql.SQLException: Failed to execute DDL statement [stmt=commit, err=Failed to finish transaction because it has bee
> n rolled back [timeout=0, tx=GridNearTxLocal[xid=f91ff90c661-00000000-0914-10f6-0000-000000000001, xidVersion=GridCacheV
> ersion [topVer=152310006, order=1540829999519, nodeOrder=1], concurrency=PESSIMISTIC, isolation=REPEATABLE_READ, state=M
> ARKED_ROLLBACK, invalidate=false, rollbackOnly=true, nodeId=c9ddebdb-c328-4283-97c5-a6634444887a, timeout=0, duration=11
> , label=null]]]
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinConnection.sendRequest(JdbcThinConnection.java:750)
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute0(JdbcThinStatement.java:212)
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute(JdbcThinStatement.java:475)
>         at sqlline.Commands.execute(Commands.java:823)
>         at sqlline.Commands.sql(Commands.java:733)
>         at sqlline.SqlLine.dispatch(SqlLine.java:795)
>         at sqlline.SqlLine.runCommands(SqlLine.java:1706)
>         at sqlline.Commands.run(Commands.java:1317)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:498)
>         at sqlline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:38)
>         at sqlline.SqlLine.dispatch(SqlLine.java:791)
>         at sqlline.SqlLine.initArgs(SqlLine.java:595)
>         at sqlline.SqlLine.begin(SqlLine.java:643)
>         at sqlline.SqlLine.start(SqlLine.java:373)
>         at sqlline.SqlLine.main(SqlLine.java:265)
> 612/113163   begin;
> No rows affected (0 seconds)
> 613/113163   update t1 set b=b+1;
> {noformat}
> {noformat}
> Error: Failed to execute DDL statement [stmt=commit, err=Failed to finish transaction because it has been rolled back [t
> imeout=0, tx=GridNearTxLocal[xid=191ff90c661-00000000-0914-10f6-0000-000000000001, xidVersion=GridCacheVersion [topVer=1
> 52310006, order=1540829999505, nodeOrder=1], concurrency=PESSIMISTIC, isolation=REPEATABLE_READ, state=MARKED_ROLLBACK,
> invalidate=false, rollbackOnly=true, nodeId=c9ddebdb-c328-4283-97c5-a6634444887a, timeout=0, duration=11, label=null]]]
> (state=50000,code=1)
> java.sql.SQLException: Failed to execute DDL statement [stmt=commit, err=Failed to finish transaction because it has bee
> n rolled back [timeout=0, tx=GridNearTxLocal[xid=191ff90c661-00000000-0914-10f6-0000-000000000001, xidVersion=GridCacheV
> ersion [topVer=152310006, order=1540829999505, nodeOrder=1], concurrency=PESSIMISTIC, isolation=REPEATABLE_READ, state=M
> ARKED_ROLLBACK, invalidate=false, rollbackOnly=true, nodeId=c9ddebdb-c328-4283-97c5-a6634444887a, timeout=0, duration=11
> , label=null]]]
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinConnection.sendRequest(JdbcThinConnection.java:750)
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute0(JdbcThinStatement.java:212)
>         at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute(JdbcThinStatement.java:475)
>         at sqlline.Commands.execute(Commands.java:823)
>         at sqlline.Commands.sql(Commands.java:733)
>         at sqlline.SqlLine.dispatch(SqlLine.java:795)
>         at sqlline.SqlLine.runCommands(SqlLine.java:1706)
>         at sqlline.Commands.run(Commands.java:1317)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:498)
>         at sqlline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:38)
>         at sqlline.SqlLine.dispatch(SqlLine.java:791)
>         at sqlline.SqlLine.initArgs(SqlLine.java:595)
>         at sqlline.SqlLine.begin(SqlLine.java:643)
>         at sqlline.SqlLine.start(SqlLine.java:373)
>         at sqlline.SqlLine.main(SqlLine.java:265)
> 28/129750    begin;
> No rows affected (0 seconds)
> 29/129750    update t1 set b=b-1;
> 10 rows affected (0,014 seconds)
> 30/129750    commit;
> No rows affected (0,002 seconds)
> 31/129750    begin;
> No rows affected (0,001 seconds)
> 32/129750    update t1 set b=b-1;
> 10 rows affected (0,011 seconds)
> 33/129750    commit;
> No rows affected (0,004 seconds)
> 34/129750    begin;
> No rows affected (0,001 seconds)
> 35/129750    update t1 set b=b-1;
> 10 rows affected (0,011 seconds)
> 36/129750    commit;
> No rows affected (0,003 seconds)
> 37/129750    begin;
> No rows affected (0 seconds)
> 38/129750    update t1 set b=b-1;
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)