Package com.perfino.annotation
Annotation Type ClassTransaction
-
@Target(TYPE) @Retention(CLASS) public @interface ClassTransaction
Create transactions for all public instance methods of the annotated class. For any class that is instrumented with this annotation, all public methods will be instrumented except for methods that are annotated with@NoTransaction
. Any invocation of an instrumented method will create a transaction with the specifiednaming
.Overridden methods in derived classes are not instrumented unless the
inheritance()
parameter is set accordingly. If you specify@ClassTransaction
on an interface, you have to setinheritance()
to something other thanMode.NONE
, otherwise no method will be instrumented.See the package overview for an overview of the perfino API.
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.String
group
Specify a group name for the perfino UI configuration.Inheritance
inheritance
Specify how overridden methods in derived classes should be handled.Part[]
naming
Specify the name of the transactions that are created by the instrumented methods.ReentryInhibition
reentryInhibition
Specify under what conditions this transaction should be created as a nested transaction.boolean
staticMethods
Also intercept static methods.
-
-
-
Element Detail
-
naming
Part[] naming
Specify the name of the transactions that are created by the instrumented methods. The name is expressed as a concatenation of name parts. See the documentation forPart
for a detailed explanation.You can pass a single
@Part
or an array of parts with the syntax{@Part(...), @Part(...), @Part(...)}
.- Default:
- {@com.perfino.annotation.Part(com.perfino.annotation.Part.Type.CLASS)}
-
-
-
group
java.lang.String group
Specify a group name for the perfino UI configuration. To configure options in the perfino UI that apply to different DevOps transactions, set the group parameter for those transactions to a common string. For example, policies are usually the same for a number of transactions. By setting the group in the annotations, you can avoid multiple identical configuration steps in UI.- Default:
- ""
-
-
-
inheritance
Inheritance inheritance
Specify how overridden methods in derived classes should be handled. By default, overridden methods are not instrumented. This means that abstract methods in the annotated class and overridden methods in derived classes that do not callsuper()
will not generate any transactions.If you set the inheritance parameter to something other than
Mode.NONE
, overridden and implemented methods will be instrumented according to the rules in theInheritance
parameter. See the documentation forInheritance
for a detailed explanation.- Default:
- @com.perfino.annotation.Inheritance(com.perfino.annotation.Inheritance.Mode.NONE)
-
-
-
reentryInhibition
ReentryInhibition reentryInhibition
Specify under what conditions this transaction should be created as a nested transaction. If another transaction is underway, you might want to limit the creation of further transactions. By default, no transactions with the same name are nested.- Default:
- com.perfino.annotation.ReentryInhibition.NAME
-
-