Class GcpHsmGeneratedSecret

java.lang.Object
org.apache.beam.sdk.util.Secret
org.apache.beam.sdk.extensions.gcp.util.GcpHsmGeneratedSecret
All Implemented Interfaces:
Serializable

public class GcpHsmGeneratedSecret extends org.apache.beam.sdk.util.Secret
A Secret manager implementation that generates a secret using entropy from a GCP HSM key and stores it in Google Cloud Secret Manager. If the secret already exists, it will be retrieved.
See Also:
  • Constructor Details

  • Method Details

    • getSecretBytes

      public byte[] getSecretBytes()
      Returns the secret as a byte array. Assumes that the current active service account has permissions to read the secret.
      Specified by:
      getSecretBytes in class org.apache.beam.sdk.util.Secret
      Returns:
      The secret as a byte array.
    • getProjectId

      public String getProjectId()
      Returns the project ID of the secret.
      Returns:
      The project ID as a String.
    • getLocationId

      public String getLocationId()
      Returns the location ID of the secret.
      Returns:
      The location ID as a String.
    • getKeyRingId

      public String getKeyRingId()
      Returns the key ring ID of the secret.
      Returns:
      The key ring ID as a String.
    • getKeyId

      public String getKeyId()
      Returns the key ID of the secret.
      Returns:
      The key ID as a String.
    • getSecretId

      public String getSecretId()
      Returns the secret ID of the secret.
      Returns:
      The secret ID as a String.
    • equals

      public boolean equals(@Nullable Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object