[
https://issues.apache.org/jira/browse/IGNITE-29178?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Vladislav Pyatkov updated IGNITE-29178:
---------------------------------------
Description:
A {{SELECT}} query can hang when a topology change starts while a transaction
is active.
Reproduction scenario:
{code:java}
ignite.createCache("unrelated");
sql("CREATE TABLE test (id INT PRIMARY KEY, val INT)");
sql("INSERT INTO test VALUES (1, 0)");
try (Transaction tx = ignite.transactions().txStart()) {
sql("UPDATE test SET val = 1 WHERE id = 1");
runAsync(() -> ignite.destroyCache("unrelated"));
waitForCacheStopExchangeToStart();
sql("SELECT * FROM test"); // Hangs.
tx.commit();
}{code}
The query remains blocked until the transaction times out. With no transaction
timeout, it can hang indefinitely.
Reproducer: [^SqlTransactionsCacheDestroyTest.java]
was:
A {{SELECT}} query can hang when a topology change starts while a transaction
is active.
Reproduction scenario:{{{{}}{}}}
{code:java}
ignite.createCache("unrelated");
sql("CREATE TABLE test (id INT PRIMARY KEY, val INT)");
sql("INSERT INTO test VALUES (1, 0)");
try (Transaction tx = ignite.transactions().txStart()) {
sql("UPDATE test SET val = 1 WHERE id = 1");
runAsync(() -> ignite.destroyCache("unrelated"));
waitForCacheStopExchangeToStart();
sql("SELECT * FROM test"); // Hangs.
tx.commit();
}{code}
The query remains blocked until the transaction times out. With no transaction
timeout, it can hang indefinitely.
Reproducer: [^SqlTransactionsCacheDestroyTest.java]
> SQL Calcite: SELECT hangs during a topology change within a transaction
> -----------------------------------------------------------------------
>
> Key: IGNITE-29178
> URL: https://issues.apache.org/jira/browse/IGNITE-29178
> Project: Ignite
> Issue Type: Bug
> Affects Versions: 2.18
> Reporter: Kirill Tkalenko
> Assignee: Kirill Tkalenko
> Priority: Major
> Labels: calcite, sql, transaction
> Attachments: SqlTransactionsCacheDestroyTest.java
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> A {{SELECT}} query can hang when a topology change starts while a transaction
> is active.
> Reproduction scenario:
> {code:java}
> ignite.createCache("unrelated");
> sql("CREATE TABLE test (id INT PRIMARY KEY, val INT)");
> sql("INSERT INTO test VALUES (1, 0)");
> try (Transaction tx = ignite.transactions().txStart()) {
> sql("UPDATE test SET val = 1 WHERE id = 1");
> runAsync(() -> ignite.destroyCache("unrelated"));
> waitForCacheStopExchangeToStart();
>
> sql("SELECT * FROM test"); // Hangs.
>
> tx.commit();
> }{code}
> The query remains blocked until the transaction times out. With no
> transaction timeout, it can hang indefinitely.
> Reproducer: [^SqlTransactionsCacheDestroyTest.java]
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)