Interface ParameterManagerOperations

All Known Implementing Classes:
ParameterManagerTemplate

public interface ParameterManagerOperations
Describes supported operations that one can perform on the Parameter Manager API.

For some methods you may specify the parameter from GCP Parameter Manager by URI string. The following parameter URI syntax is supported:

1. Long form - specify the project ID, location ID, parameter ID, and version ID pm@projects/{project-id}/locations/{location-id}/parameters/{parameter-id}/versions/{version-id}

2. Long form - specify location ID, parameter ID, and version ID pm@locations/{location-id}/parameters/{parameter-id}/versions/{version-id}

3. Short form - specify project ID, location ID, parameter ID, and version ID pm@{project-id}/{location-id}/{parameter-id}/{version-id}

4. Shortest form - specify locationID, parameter ID and version ID, use default GCP project configured pm@{location-id}/{parameter-id}/{version-id}

  • Method Summary

    Modifier and Type
    Method
    Description
    void
    createParameter(String locationId, String parameterId, String versionId, byte[] payload)
    Creates a new parameter or a new version of existing parameter with the provided payload.
    void
    createParameter(String locationId, String parameterId, String versionId, byte[] payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
    Creates a new parameter or a new version of existing parameter with the provided payload in given format.
    void
    createParameter(String locationId, String parameterId, String versionId, String payload)
    Creates a new parameter or a new version of existing parameter with the provided payload.
    void
    createParameter(String projectId, String locationId, String parameterId, String versionId, byte[] payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
    Creates a new parameter or a new version of existing parameter with the provided payload.
    void
    createParameter(String locationId, String parameterId, String versionId, String payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
    Creates a new parameter or a new version of existing parameter with the provided payload in provided format.
    void
    createParameter(String projectId, String locationId, String parameterId, String versionId, String payload)
    Creates a new parameter or a new version of existing parameter with the provided payload.
    void
    createParameter(String projectId, String locationId, String parameterId, String versionId, String payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
    Creates a new parameter or a new version of existing parameter with the provided payload.
    void
    deleteParameter(String locationId, String parameterId)
    Deletes the specified parameterId under the default-configured project for specified locationId.
    void
    deleteParameter(String projectId, String locationId, String parameterId)
    Deletes the specified parameterID under the specified projectId for specified locationId.
    void
    deleteParameterVersion(String locationId, String parameterId, String versionId)
    Deletes the specified parameter version under the default-configured project for specified locationId.
    void
    deleteParameterVersion(String projectId, String locationId, String parameterId, String versionId)
    Deletes the specified parameter version under the specified projectId for specified locationId.
    void
    disableParameterVersion(String locationId, String parameterId, String versionId)
    Disables the specified parameter version under the default-configured project for specified locationId.
    void
    disableParameterVersion(String projectId, String locationId, String parameterId, String versionId)
    Disables the specified parameter version under the specified projectId for specified locationId.
    void
    enableParameterVersion(String locationId, String parameterId, String versionId)
    Enables the specified parameter version under the default-configured project for specified locationId.
    void
    enableParameterVersion(String projectId, String locationId, String parameterId, String versionId)
    Enables the specified parameter version under the specified projectId for specified locationId.
    byte[]
    getParameterBytes(String parameterIdentifier)
    Gets the parameter data as a byte array from the specified parameterIdentifier.
    getParameterString(String parameterIdentifier)
    Gets the parameter data as a string from the specified parameterIdentifier.
    boolean
    parameterExists(String locationId, String parameterId)
    Checks if the specified parameterID exists in the default-configured project for specified locationId.
    boolean
    parameterExists(String projectId, String locationId, String parameterId)
    Checks if the specified parameterID exists in the specified project for specified locationId.
    boolean
    parameterVersionExists(String locationId, String parameterId, String versionId)
    Checks if the specified parameter version exists in the default-configured project for the specified locationId.
    boolean
    parameterVersionExists(String projectId, String locationId, String parameterId, String versionId)
    Checks if the specified parameter version exists in the specified project for the specified locationId.
    byte[]
    Gets the rendered parameter data as a byte array from the specified parameterIdentifier.
    Gets the rendered parameter data as a string from the specified parameterIdentifier.
  • Method Details

    • createParameter

      void createParameter(String locationId, String parameterId, String versionId, String payload)
      Creates a new parameter or a new version of existing parameter with the provided payload.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a string.
    • createParameter

      void createParameter(String projectId, String locationId, String parameterId, String versionId, String payload)
      Creates a new parameter or a new version of existing parameter with the provided payload.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a string.
    • createParameter

      void createParameter(String locationId, String parameterId, String versionId, String payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
      Creates a new parameter or a new version of existing parameter with the provided payload in provided format.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a string.
      format - the parameter format (JSON or YAML or UNFORMATTED).
    • createParameter

      void createParameter(String projectId, String locationId, String parameterId, String versionId, String payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
      Creates a new parameter or a new version of existing parameter with the provided payload.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a string.
      format - the parameter format (JSON or YAML or UNFORMATTED).
    • createParameter

      void createParameter(String locationId, String parameterId, String versionId, byte[] payload)
      Creates a new parameter or a new version of existing parameter with the provided payload.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a byte array.
    • createParameter

      void createParameter(String locationId, String parameterId, String versionId, byte[] payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
      Creates a new parameter or a new version of existing parameter with the provided payload in given format.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a byte array.
      format - the parameter format (JSON or YAML or UNFORMATTED).
    • createParameter

      void createParameter(String projectId, String locationId, String parameterId, String versionId, byte[] payload, com.google.cloud.parametermanager.v1.ParameterFormat format)
      Creates a new parameter or a new version of existing parameter with the provided payload.

      If there is already a parameter saved in ParameterManager with the specified parameterId, then it simply creates a new version with given id under the parameter with the specified payload.

      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the parameter location string.
      parameterId - the parameter ID of the parameter to create.
      versionId - the version ID of the parameter version to create.
      payload - the parameter payload as a byte array.
      format - the parameter format (JSON or YAML or UNFORMATTED).
    • enableParameterVersion

      void enableParameterVersion(String locationId, String parameterId, String versionId)
      Enables the specified parameter version under the default-configured project for specified locationId.
      Parameters:
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to enable.
      versionId - the version ID to be enabled.
    • enableParameterVersion

      void enableParameterVersion(String projectId, String locationId, String parameterId, String versionId)
      Enables the specified parameter version under the specified projectId for specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to enable.
      versionId - the version ID to be enabled.
    • disableParameterVersion

      void disableParameterVersion(String locationId, String parameterId, String versionId)
      Disables the specified parameter version under the default-configured project for specified locationId.
      Parameters:
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to enable.
      versionId - the version ID to be enabled.
    • disableParameterVersion

      void disableParameterVersion(String projectId, String locationId, String parameterId, String versionId)
      Disables the specified parameter version under the specified projectId for specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to enable.
      versionId - the version ID to be enabled.
    • deleteParameter

      void deleteParameter(String locationId, String parameterId)
      Deletes the specified parameterId under the default-configured project for specified locationId.
      Parameters:
      parameterId - the parameter ID of the parameter to delete.
      locationId - the location string where given parameter is present.
    • deleteParameter

      void deleteParameter(String projectId, String locationId, String parameterId)
      Deletes the specified parameterID under the specified projectId for specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to delete.
    • deleteParameterVersion

      void deleteParameterVersion(String locationId, String parameterId, String versionId)
      Deletes the specified parameter version under the default-configured project for specified locationId.
      Parameters:
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to delete.
      versionId - the version ID to be deleted.
    • deleteParameterVersion

      void deleteParameterVersion(String projectId, String locationId, String parameterId, String versionId)
      Deletes the specified parameter version under the specified projectId for specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to delete.
      versionId - the version ID to be deleted.
    • parameterExists

      boolean parameterExists(String locationId, String parameterId)
      Checks if the specified parameterID exists in the default-configured project for specified locationId.
      Parameters:
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to check.
      Returns:
      true if the parameter exists in Parameter Manager; false otherwise
    • parameterExists

      boolean parameterExists(String projectId, String locationId, String parameterId)
      Checks if the specified parameterID exists in the specified project for specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where given parameter is present.
      parameterId - the parameter ID of the parameter to check.
      Returns:
      true if the parameter exists in Parameter Manager; false otherwise
    • parameterVersionExists

      boolean parameterVersionExists(String locationId, String parameterId, String versionId)
      Checks if the specified parameter version exists in the default-configured project for the specified locationId.
      Parameters:
      locationId - the location string where the given parameter version is present.
      parameterId - the parameter ID of the parameter to check.
      versionId - the version ID of the parameter version to check.
      Returns:
      true if the parameter version exists in Parameter Manager; false otherwise
    • parameterVersionExists

      boolean parameterVersionExists(String projectId, String locationId, String parameterId, String versionId)
      Checks if the specified parameter version exists in the specified project for the specified locationId.
      Parameters:
      projectId - unique identifier of your GCP project.
      locationId - the location string where the given parameter version is present.
      parameterId - the parameter ID of the parameter to check.
      versionId - the version ID of the parameter version to check.
      Returns:
      true if the parameter version exists in Parameter Manager; false otherwise
    • getParameterString

      String getParameterString(String parameterIdentifier)
      Gets the parameter data as a string from the specified parameterIdentifier.

      The parameterIdentifier must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs of ParameterManagerOperations for the protocol format).

      If the parameter ID string is passed in, then this will return the data of the parameter for the default project at the latest version.

      Parameters:
      parameterIdentifier - a pm@ formatted string specifying the parameter version.
      Returns:
      The parameter data as a string
    • getParameterBytes

      byte[] getParameterBytes(String parameterIdentifier)
      Gets the parameter data as a byte array from the specified parameterIdentifier.

      The parameterIdentifier must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs of ParameterManagerOperations for the protocol format).

      If the parameter ID string is passed in, then this will return the data of the parameter for the default project at the latest version.

      Parameters:
      parameterIdentifier - a pm@ formatted string specifying the parameter version.
      Returns:
      The parameter data as a byte array
    • renderedParameterVersionString

      String renderedParameterVersionString(String parameterIdentifier)
      Gets the rendered parameter data as a string from the specified parameterIdentifier.

      The parameterIdentifier must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs of ParameterManagerOperations for the protocol format).

      If the parameter ID string is passed in, then this will return the rendered data of the parameter for the default project at the latest version.

      Parameters:
      parameterIdentifier - a pm@ formatted string specifying the parameter version.
      Returns:
      The rendered parameter data as a string
    • renderedParameterVersionBytes

      byte[] renderedParameterVersionBytes(String parameterIdentifier)
      Gets the rendered parameter data as a byte array from the specified parameterIdentifier.

      The parameterIdentifier must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs of ParameterManagerOperations for the protocol format).

      If the parameter ID string is passed in, then this will return the rendered data of the parameter for the default project at the latest version.

      Parameters:
      parameterIdentifier - a pm@ formatted string specifying the parameter version.
      Returns:
      The rendered parameter data as a byte array