Interface ParameterManagerOperations
- All Known Implementing Classes:
ParameterManagerTemplate
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 TypeMethodDescriptionvoid
createParameter
(String locationId, String parameterId, String versionId, byte[] payload) Creates a new parameter or a new version of existing parameter with the providedpayload
.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 providedpayload
in givenformat
.void
createParameter
(String locationId, String parameterId, String versionId, String payload) Creates a new parameter or a new version of existing parameter with the providedpayload
.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 providedpayload
.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 providedpayload
in providedformat
.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 providedpayload
.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 providedpayload
.void
deleteParameter
(String locationId, String parameterId) Deletes the specifiedparameterId
under the default-configured project for specifiedlocationId
.void
deleteParameter
(String projectId, String locationId, String parameterId) Deletes the specifiedparameterID
under the specifiedprojectId
for specifiedlocationId
.void
deleteParameterVersion
(String locationId, String parameterId, String versionId) Deletes the specified parameter version under the default-configured project for specifiedlocationId
.void
deleteParameterVersion
(String projectId, String locationId, String parameterId, String versionId) Deletes the specified parameter version under the specifiedprojectId
for specifiedlocationId
.void
disableParameterVersion
(String locationId, String parameterId, String versionId) Disables the specified parameter version under the default-configured project for specifiedlocationId
.void
disableParameterVersion
(String projectId, String locationId, String parameterId, String versionId) Disables the specified parameter version under the specifiedprojectId
for specifiedlocationId
.void
enableParameterVersion
(String locationId, String parameterId, String versionId) Enables the specified parameter version under the default-configured project for specifiedlocationId
.void
enableParameterVersion
(String projectId, String locationId, String parameterId, String versionId) Enables the specified parameter version under the specifiedprojectId
for specifiedlocationId
.byte[]
getParameterBytes
(String parameterIdentifier) Gets the parameter data as a byte array from the specifiedparameterIdentifier
.getParameterString
(String parameterIdentifier) Gets the parameter data as a string from the specifiedparameterIdentifier
.boolean
parameterExists
(String locationId, String parameterId) Checks if the specifiedparameterID
exists in the default-configured project for specifiedlocationId
.boolean
parameterExists
(String projectId, String locationId, String parameterId) Checks if the specifiedparameterID
exists in the specified project for specifiedlocationId
.boolean
parameterVersionExists
(String locationId, String parameterId, String versionId) Checks if the specified parameter version exists in the default-configured project for the specifiedlocationId
.boolean
parameterVersionExists
(String projectId, String locationId, String parameterId, String versionId) Checks if the specified parameter version exists in the specified project for the specifiedlocationId
.byte[]
renderedParameterVersionBytes
(String parameterIdentifier) Gets the rendered parameter data as a byte array from the specifiedparameterIdentifier
.renderedParameterVersionString
(String parameterIdentifier) Gets the rendered parameter data as a string from the specifiedparameterIdentifier
.
-
Method Details
-
createParameter
Creates a new parameter or a new version of existing parameter with the providedpayload
.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 specifiedpayload
.- 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 providedpayload
.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 specifiedpayload
.- 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 providedpayload
in providedformat
.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 specifiedpayload
.- 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 providedpayload
.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 specifiedpayload
.- 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
Creates a new parameter or a new version of existing parameter with the providedpayload
.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 specifiedpayload
.- 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 providedpayload
in givenformat
.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 specifiedpayload
.- 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 providedpayload
.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 specifiedpayload
.- 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
Enables the specified parameter version under the default-configured project for specifiedlocationId
.- 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 specifiedprojectId
for specifiedlocationId
.- 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
Disables the specified parameter version under the default-configured project for specifiedlocationId
.- 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 specifiedprojectId
for specifiedlocationId
.- 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
Deletes the specifiedparameterId
under the default-configured project for specifiedlocationId
.- Parameters:
parameterId
- the parameter ID of the parameter to delete.locationId
- the location string where given parameter is present.
-
deleteParameter
Deletes the specifiedparameterID
under the specifiedprojectId
for specifiedlocationId
.- 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
Deletes the specified parameter version under the default-configured project for specifiedlocationId
.- 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 specifiedprojectId
for specifiedlocationId
.- 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
Checks if the specifiedparameterID
exists in the default-configured project for specifiedlocationId
.- 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
Checks if the specifiedparameterID
exists in the specified project for specifiedlocationId
.- 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
Checks if the specified parameter version exists in the default-configured project for the specifiedlocationId
.- 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 specifiedlocationId
.- 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
Gets the parameter data as a string from the specifiedparameterIdentifier
.The
parameterIdentifier
must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs ofParameterManagerOperations
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
Gets the parameter data as a byte array from the specifiedparameterIdentifier
.The
parameterIdentifier
must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs ofParameterManagerOperations
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
Gets the rendered parameter data as a string from the specifiedparameterIdentifier
.The
parameterIdentifier
must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs ofParameterManagerOperations
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
Gets the rendered parameter data as a byte array from the specifiedparameterIdentifier
.The
parameterIdentifier
must be a fully qualified `pm@` protocol string which specifies the parameter (see javadocs ofParameterManagerOperations
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
-