public class RedactableArgument extends Object
log.info("Opened bucket {}", RedactableArgument.redactMeta(bucketName));Or when including sensitive information in an Exception message:
throw new RuntimeException("Failed to process " + RedactableArgument.redactUser(documentId));The global redaction level is controlled by calling
LogRedaction.setRedactionLevel(RedactionLevel)
LogRedaction
Modifier and Type | Method and Description |
---|---|
String |
message()
The message of this redactable argument.
|
static RedactableArgument |
redactMeta(Object message)
A redactable argument of meta data.
|
static RedactableArgument |
redactSystem(Object message)
A redactable argument of system data.
|
static RedactableArgument |
redactUser(Object message)
A redactable argument of user data.
|
String |
toString() |
com.couchbase.client.core.logging.RedactableArgument.ArgumentType |
type()
The type of this redactable argument.
|
public static RedactableArgument redactUser(Object message)
message
- the message to redact.RedactableArgument
.public static RedactableArgument redactMeta(Object message)
message
- the message to redact.RedactableArgument
.public static RedactableArgument redactSystem(Object message)
message
- the message to redact.RedactableArgument
.public com.couchbase.client.core.logging.RedactableArgument.ArgumentType type()
public String message()
Copyright © 2020 Couchbase, Inc.. All rights reserved.