Class ContentPreviewingServiceBuilder
java.lang.Object
com.linecorp.armeria.server.logging.ContentPreviewingServiceBuilder
Builds a new
ContentPreviewingService
.-
Method Summary
Modifier and TypeMethodDescriptionbuild
(HttpService delegate) Returns a newly-createdContentPreviewingService
decoratingdelegate
based on the properties of this builder.Function
<? super HttpService, ContentPreviewingService> Returns a newly-createdContentPreviewingService
decorator based on the properties of this builder.previewSanitizer
(BiFunction<? super RequestContext, String, ? extends @Nullable Object> previewSanitizer) Sets theBiFunction
to use to sanitize request and response content preview.requestPreviewSanitizer
(BiFunction<? super RequestContext, String, ? extends @Nullable Object> requestPreviewSanitizer) Sets theBiFunction
to use to sanitize request content preview.responsePreviewSanitizer
(BiFunction<? super RequestContext, String, ? extends @Nullable Object> responsePreviewSanitizer) Sets theBiFunction
to use to sanitize response content preview.
-
Method Details
-
requestPreviewSanitizer
public ContentPreviewingServiceBuilder requestPreviewSanitizer(BiFunction<? super RequestContext, String, ? extends @Nullable Object> requestPreviewSanitizer) Sets theBiFunction
to use to sanitize request content preview. It is common to have theBiFunction
that removes sensitive content, such as an address, before logging. If unset, will not sanitize request content preview. -
responsePreviewSanitizer
public ContentPreviewingServiceBuilder responsePreviewSanitizer(BiFunction<? super RequestContext, String, ? extends @Nullable Object> responsePreviewSanitizer) Sets theBiFunction
to use to sanitize response content preview. It is common to have theBiFunction
that removes sensitive content, such as an address, before logging. If unset, will not sanitize response content preview. -
previewSanitizer
public ContentPreviewingServiceBuilder previewSanitizer(BiFunction<? super RequestContext, String, ? extends @Nullable Object> previewSanitizer) Sets theBiFunction
to use to sanitize request and response content preview. It is common to have theBiFunction
that removes sensitive content, such as an address, before logging. If unset, will not sanitize response content preview. This method is a shortcut for:builder.requestContentSanitizer(previewSanitizer); builder.responseContentSanitizer(previewSanitizer);
- See Also:
-
build
Returns a newly-createdContentPreviewingService
decoratingdelegate
based on the properties of this builder. -
newDecorator
Returns a newly-createdContentPreviewingService
decorator based on the properties of this builder.
-