Annotation Type TransactionalAdvice
-
@Target({ANNOTATION_TYPE,METHOD,TYPE}) @Retention(RUNTIME) @Around @Type(TransactionalInterceptor.class) @Internal public @interface TransactionalAdviceMeta annotation that other transactional annotations like Spring's andjavax.transaction.Transactionalmap to such as to enable transactional advice. Shouldn't be used directly.This annotation is declared with a target of
ElementType.ANNOTATION_TYPEso that is used only as a meta-annotation. In actual code you would usejavax.transaction.Transaction- Since:
- 1.0
- Author:
- graemerocher
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description TransactionDefinition.IsolationisolationThe transaction isolation level.java.lang.Class<? extends java.lang.Throwable>[]noRollbackForDefines the exceptions that will not result in a rollback.TransactionDefinition.PropagationpropagationThe transaction propagation type.booleanreadOnlytrueif the transaction is read-only.java.lang.Class<? extends java.lang.Throwable>[]rollbackForDefines the exceptions that will not result in a rollback.inttimeoutThe timeout for this transaction.java.lang.StringtransactionManagerA qualifier value for the specified transaction.java.lang.StringvalueAlias fortransactionManager().
-
-
-
Element Detail
-
value
@AliasFor(member="transactionManager") java.lang.String value
Alias fortransactionManager().- Returns:
- The transaction manager
- See Also:
transactionManager()
- Default:
- ""
-
-
-
transactionManager
@AliasFor(member="value") java.lang.String transactionManager
A qualifier value for the specified transaction.May be used to determine the target transaction manager, matching the qualifier value (or the bean name) of a specific
SynchronousTransactionManagerbean definition.- Returns:
- The transaction manager
- Since:
- 4.2
- See Also:
value()
- Default:
- ""
-
-
-
propagation
TransactionDefinition.Propagation propagation
The transaction propagation type.Defaults to
TransactionDefinition.Propagation.REQUIRED.- Returns:
- The propagation
- Default:
- io.micronaut.transaction.TransactionDefinition.Propagation.REQUIRED
-
-
-
isolation
TransactionDefinition.Isolation isolation
The transaction isolation level.Defaults to
TransactionDefinition.Isolation.DEFAULT.- Returns:
- The isolation level
- Default:
- io.micronaut.transaction.TransactionDefinition.Isolation.DEFAULT
-
-
-
readOnly
boolean readOnly
trueif the transaction is read-only.Defaults to
false.This just serves as a hint for the actual transaction subsystem; it will not necessarily cause failure of write access attempts. A transaction manager which cannot interpret the read-only hint will not throw an exception when asked for a read-only transaction but rather silently ignore the hint.
- Returns:
- Whether is read-only transaction
- Default:
- false
-
-