[
https://issues.apache.org/jira/browse/IGNITE-17419?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Igor Sapego updated IGNITE-17419:
---------------------------------
Description:
Code like below throws uninformative exception:
{noformat}
java.util.concurrent.CompletionException:
org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
at
java.base/java.util.concurrent.CompletableFuture.reportJoin(CompletableFuture.java:412)
at
java.base/java.util.concurrent.CompletableFuture.join(CompletableFuture.java:2044)
Caused by: org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
at
org.apache.ignite.internal.client.TcpClientChannel.processNextMessage(TcpClientChannel.java:313)
at
org.apache.ignite.internal.client.TcpClientChannel.onMessage(TcpClientChannel.java:152)
{noformat}
{code:java}
tx = client().transactions().begin();
ses.execute(tx, "INSERT INTO testExecuteDdlDml VALUES (?, ?)",
200, "hello " + Integer.MAX_VALUE);
tx.commit();
// Outdated tx.
Transaction tx0 = tx;
assertThrows(CompletionException.class, () -> {
ses.executeAsync(tx0, "INSERT INTO testExecuteDdlDml VALUES (?, ?)",
Integer.MAX_VALUE, "hello " + Integer.MAX_VALUE).join();
});
{code}
The exception message should be somethings like "Transaction is outdated"
was:
Code like below throws uninformative exception:
{noformat}
java.util.concurrent.CompletionException:
org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
at
java.base/java.util.concurrent.CompletableFuture.reportJoin(CompletableFuture.java:412)
at
java.base/java.util.concurrent.CompletableFuture.join(CompletableFuture.java:2044)
Caused by: org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
at
org.apache.ignite.internal.client.TcpClientChannel.processNextMessage(TcpClientChannel.java:313)
at
org.apache.ignite.internal.client.TcpClientChannel.onMessage(TcpClientChannel.java:152)
{noformat}
{code:java}
tx = client().transactions().begin();
ses.execute(tx, "INSERT INTO testExecuteDdlDml VALUES (?, ?)",
200, "hello " + Integer.MAX_VALUE);
tx.commit();
// Outdated tx.
Transaction tx0 = tx;
assertThrows(CompletionException.class, () -> {
ses.executeAsync(tx0, "INSERT INTO testExecuteDdlDml VALUES (?, ?)",
Integer.MAX_VALUE, "hello " + Integer.MAX_VALUE).join();
});
{code}
> Uninformative exception raised if execution processed with outdated
> transaction.
> --------------------------------------------------------------------------------
>
> Key: IGNITE-17419
> URL: https://issues.apache.org/jira/browse/IGNITE-17419
> Project: Ignite
> Issue Type: Improvement
> Components: thin client
> Affects Versions: 3.0.0-alpha5
> Reporter: Evgeny Stanilovsky
> Priority: Major
> Labels: ignite-3
>
> Code like below throws uninformative exception:
> {noformat}
> java.util.concurrent.CompletionException:
> org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
> ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
> ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
> at
> java.base/java.util.concurrent.CompletableFuture.reportJoin(CompletableFuture.java:412)
> at
> java.base/java.util.concurrent.CompletableFuture.join(CompletableFuture.java:2044)
> Caused by: org.apache.ignite.client.IgniteClientException: IGN-CMN-1 Trace
> ID:642ffaf4-a907-4a0e-baf5-eb9d1ef70d47 IGN-CMN-1 Trace
> ID:b35d2c8f-98df-4a0c-b43a-c4c94744294b Failed to find resource with id: 1
> at
> org.apache.ignite.internal.client.TcpClientChannel.processNextMessage(TcpClientChannel.java:313)
> at
> org.apache.ignite.internal.client.TcpClientChannel.onMessage(TcpClientChannel.java:152)
> {noformat}
> {code:java}
> tx = client().transactions().begin();
> ses.execute(tx, "INSERT INTO testExecuteDdlDml VALUES (?, ?)",
> 200, "hello " + Integer.MAX_VALUE);
> tx.commit();
> // Outdated tx.
> Transaction tx0 = tx;
> assertThrows(CompletionException.class, () -> {
> ses.executeAsync(tx0, "INSERT INTO testExecuteDdlDml VALUES (?,
> ?)",
> Integer.MAX_VALUE, "hello " + Integer.MAX_VALUE).join();
> });
> {code}
> The exception message should be somethings like "Transaction is outdated"
--
This message was sent by Atlassian Jira
(v8.20.10#820010)