Class AtnTracing
- java.lang.Object
-
- io.helidon.security.integration.common.AtnTracing
-
public class AtnTracing extends Object
Authentication tracing support.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
error(String message)
Log error and finish the span.void
error(Throwable throwable)
Log error and finish the span.Optional<SpanContext>
findParent()
Find closes parent span context.Optional<Span>
findParentSpan()
Deprecated.will be removed once security context works withSpanContext
.void
finish()
Finish the span.void
logService(Subject serviceSubject)
Log authenticated service.void
logStatus(SecurityResponse.SecurityStatus status)
Log response status.void
logUser(Subject userSubject)
Log authenticated user.protected SpanTracingConfig
spanConfig()
-
-
-
Method Detail
-
logUser
public void logUser(Subject userSubject)
Log authenticated user.- Parameters:
userSubject
- subject of the user
-
logService
public void logService(Subject serviceSubject)
Log authenticated service.- Parameters:
serviceSubject
- subject of the service
-
finish
public void finish()
Finish the span.
-
error
public void error(String message)
Log error and finish the span.- Parameters:
message
- log this message as the cause of failure
-
error
public void error(Throwable throwable)
Log error and finish the span.- Parameters:
throwable
- throwable causing security to fail
-
findParent
public Optional<SpanContext> findParent()
Find closes parent span context.- Returns:
- span context if found
-
findParentSpan
@Deprecated public Optional<Span> findParentSpan()
Deprecated.will be removed once security context works withSpanContext
. Needed for backward compatibilityFind closes parent span.- Returns:
- span context if found
-
logStatus
public void logStatus(SecurityResponse.SecurityStatus status)
Log response status. This is to be used by authorization, authentication and outbound security. Top level security only traces proceed or deny.- Parameters:
status
- status to log
-
spanConfig
protected SpanTracingConfig spanConfig()
-
-