Class EnvironmentFilterSpecification

java.lang.Object
io.micronaut.management.endpoint.env.EnvironmentFilterSpecification

public final class EnvironmentFilterSpecification extends Object
This class is passed to an instance of EnvironmentEndpointFilter (if one is defined) each time the EnvironmentEndpoint is invoked.
Since:
3.3.0
Author:
Tim Yates
  • Method Details

    • maskAll

      Turn on global masking. Items can be unmasked by executing any of the exclude methods.
      Returns:
      this
    • maskNone

      Turn off global masking. Items can be masked by executing any of the exclude methods.
      Returns:
      this
    • exclude

      Adds a predicate to test property keys. If the maskAll() flag is set then this will be used for exceptions (values in clear-text). If the maskNone() flag is set then this will be those values that are masked.
      Parameters:
      keyPredicate - A predicate to match against property keys for masking
      Returns:
      this
    • exclude

      Adds literal strings to the list of excluded keys. If the maskAll() flag is set then this list will be used for exceptions (values in clear-text). If the maskNone() flag is set then this list will be those values that are masked.
      Parameters:
      keys - Literal keys that should be excluded
      Returns:
      this
    • exclude

      @NonNull public EnvironmentFilterSpecification exclude(@NonNull Pattern... keyPatterns)
      Adds regular expression patterns to the list of known masks. If the maskAll() flag is set then this list will be used for exceptions (values in clear-text). If the maskNone() flag is set then this list will be those values that are masked. Patterns must match the entire property key.
      Parameters:
      keyPatterns - The patterns used to compare keys to exclude them
      Returns:
      this
    • legacyMasking

      @NonNull public EnvironmentFilterSpecification legacyMasking()
      Configures the key masking to behave as it did prior to 3.3.0.
      Returns:
      this