Class ConfigurationKey

java.lang.Object
io.strimzi.kafka.oauth.services.ConfigurationKey

public class ConfigurationKey extends Object
JAAS configuration for the validator or the client can specify the oauth.config.id configuration property in order to associate a configuration identifier with the metrics so that the metrics are then grouped, and can be queried by that id.

If oauth.config.id is not specified a configuration id is calculated from other configuration parameters in a way that is stable across application restarts.

The configuration id is set on the metrics as context attribute.

OAuth validators for the various listeners are cashed in a global singleton and indexed by the ConfigurationKey. Usually multiple listener are configured differently and are each handled by its own instance of the validator. But if more listeners are configured with exactly the same configuration parameters, they will share the same ConfigurationKey and will all be handled my a single validator instance.

  • Constructor Details

    • ConfigurationKey

      public ConfigurationKey(String configId, ValidatorKey validatorKey)
      Create a new instance
      Parameters:
      configId - Configuration id for this validator
      validatorKey - Validator key for this validator
  • Method Details

    • getConfigId

      public String getConfigId()
      Get the config id
      Returns:
      The config id
    • getValidatorKey

      public ValidatorKey getValidatorKey()
      Get the validator key
      Returns:
      The validator key
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object