Annotation Interface OracleTransactional.Recoverable
- Enclosing class:
OracleTransactional
@Documented
@Retention(RUNTIME)
@Target({ANNOTATION_TYPE,METHOD,TYPE})
public static @interface OracleTransactional.Recoverable
Oracle-specific companion annotation for ambiguous commit recovery.
Use this annotation together with Transactional or
OracleTransactional. It does not start a transaction by itself.
Recovery is attempted only for the intercepted synchronous execution that
starts and owns the transaction commit boundary.
- Since:
- 5.2
- Author:
- radovanradic
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumPolicy used when the outcome cannot be determined. -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionlongBackoff in milliseconds between retry attempts.intMaximum number of retry attempts after the initial attempt.Exception types that should trigger recovery handling.Policy to apply when the commit outcome cannot be determined.
-
Element Details
-
on
Exception types that should trigger recovery handling.The default is
SQLRecoverableException. Custom types should be used only for wrapper exceptions that still represent the same ambiguous commit / lost acknowledgement failure semantics.- Returns:
- The exception types that should trigger recovery handling.
- Default:
{java.sql.SQLRecoverableException.class}
-
maxAttempts
int maxAttemptsMaximum number of retry attempts after the initial attempt.- Returns:
- The maximum number of retry attempts.
- Default:
1
-
backoff
long backoffBackoff in milliseconds between retry attempts.- Returns:
- The backoff in milliseconds.
- Default:
100L
-
unknownOutcomePolicy
OracleTransactional.Recoverable.OutcomePolicy unknownOutcomePolicyPolicy to apply when the commit outcome cannot be determined.- Returns:
- The policy to apply for unknown commit outcomes.
- Default:
FAIL
-