You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by "rpuch (via GitHub)" <gi...@apache.org> on 2025/05/06 11:16:49 UTC

[PR] IGNITE-25303 Throw StorageExceptions from tx state storages [ignite-3]

rpuch opened a new pull request, #5759:
URL: https://github.com/apache/ignite-3/pull/5759

   https://issues.apache.org/jira/browse/IGNITE-25303


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] IGNITE-25303 Throw StorageExceptions from tx state storages [ignite-3]

Posted by "tkalkirill (via GitHub)" <gi...@apache.org>.
tkalkirill commented on code in PR #5759:
URL: https://github.com/apache/ignite-3/pull/5759#discussion_r2075538795


##########
modules/transactions/src/main/java/org/apache/ignite/internal/tx/storage/state/rocksdb/TxStateRocksDbStorage.java:
##########
@@ -160,7 +160,7 @@ public void destroy() {
 
             sharedStorage.db().deleteRange(start, end);
         } catch (Exception e) {
-            throw new IgniteInternalException("Failed to destroy the transaction state storage of the table: " + id, e);
+            throw new TxStateStorageException("Failed to destroy the transaction state storage of the table: " + id, e);

Review Comment:
   Same



##########
modules/transactions/src/main/java/org/apache/ignite/internal/tx/storage/state/rocksdb/TxStateRocksDbStorage.java:
##########
@@ -146,7 +146,7 @@ public void close() {
             reverse(resources);
             closeAll(resources);
         } catch (Exception e) {
-            throw new IgniteInternalException("Failed to stop transaction state storage of the table: " + id, e);
+            throw new TxStateStorageException("Failed to stop transaction state storage of the table: " + id, e);

Review Comment:
   Optional, I would do something like this: `throw new TxStateStorageException("Failed to stop transaction state storage of the table: {}", e, id);`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] IGNITE-25303 Throw StorageExceptions from tx state storages [ignite-3]

Posted by "tkalkirill (via GitHub)" <gi...@apache.org>.
tkalkirill commented on code in PR #5759:
URL: https://github.com/apache/ignite-3/pull/5759#discussion_r2075340377


##########
modules/transactions/src/main/java/org/apache/ignite/internal/tx/storage/state/rocksdb/TxStateRocksDbPartitionStorage.java:
##########
@@ -120,7 +123,7 @@ private static short shortPartitionId(int intValue) {
     /**
      * Starts the storage.
      *
-     * @throws IgniteInternalException In case when the operation has failed.
+     * @throws StorageException In case when the operation has failed.

Review Comment:
   I suggest making an exception for module `ignite-transactions`, say `TxStorageException`, and throwing it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] IGNITE-25303 Throw StorageExceptions from tx state storages [ignite-3]

Posted by "rpuch (via GitHub)" <gi...@apache.org>.
rpuch merged PR #5759:
URL: https://github.com/apache/ignite-3/pull/5759


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org