| .. | .. |
|---|
| 1 | +/* |
|---|
| 2 | +* Copyright @ 2013 CurisTEC, S.A.S. All Rights Reserved. |
|---|
| 3 | +*/ |
|---|
| 1 | 4 | package net.curisit.securis.ioc; |
|---|
| 2 | 5 | |
|---|
| 3 | 6 | import java.lang.annotation.ElementType; |
|---|
| .. | .. |
|---|
| 7 | 10 | |
|---|
| 8 | 11 | import jakarta.interceptor.InterceptorBinding; |
|---|
| 9 | 12 | |
|---|
| 10 | | -@Target({ |
|---|
| 11 | | - ElementType.METHOD, ElementType.TYPE |
|---|
| 12 | | -}) |
|---|
| 13 | +/** |
|---|
| 14 | +* EnsureTransaction |
|---|
| 15 | +* <p> |
|---|
| 16 | +* CDI interceptor binding to mark resource methods that require a |
|---|
| 17 | +* transaction boundary. Interceptors (e.g., in a request filter / writer |
|---|
| 18 | +* interceptor) can check this annotation to begin/commit/rollback. |
|---|
| 19 | +* |
|---|
| 20 | +* Usage: |
|---|
| 21 | +* {@code @EnsureTransaction} on JAX-RS methods. |
|---|
| 22 | +* |
|---|
| 23 | +* @author JRA |
|---|
| 24 | +* Last reviewed by JRA on Oct 5, 2025. |
|---|
| 25 | +*/ |
|---|
| 26 | +@Target({ ElementType.METHOD, ElementType.TYPE }) |
|---|
| 13 | 27 | @Retention(RetentionPolicy.RUNTIME) |
|---|
| 14 | 28 | @InterceptorBinding |
|---|
| 15 | | -public @interface EnsureTransaction { |
|---|
| 16 | | - |
|---|
| 17 | | -} |
|---|
| 29 | +public @interface EnsureTransaction { } |
|---|