Package com.google.cloud.functions.v1
Class SecretVolume
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessageV3
-
- com.google.cloud.functions.v1.SecretVolume
-
- All Implemented Interfaces:
SecretVolumeOrBuilder
,com.google.protobuf.Message
,com.google.protobuf.MessageLite
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Serializable
public final class SecretVolume extends com.google.protobuf.GeneratedMessageV3 implements SecretVolumeOrBuilder
Configuration for a secret volume. It has the information necessary to fetch the secret value from Secret Manager and make it available as files mounted at the requested paths within the application container. Secret value is not a part of the configuration. Every file system read operation performs a lookup in Secret Manager to retrieve the secret value.
Protobuf typegoogle.cloud.functions.v1.SecretVolume
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SecretVolume.Builder
Configuration for a secret volume.static class
SecretVolume.SecretVersion
Configuration for a single version.static interface
SecretVolume.SecretVersionOrBuilder
-
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
-
-
Field Summary
Fields Modifier and Type Field Description static int
MOUNT_PATH_FIELD_NUMBER
static int
PROJECT_ID_FIELD_NUMBER
static int
SECRET_FIELD_NUMBER
static int
VERSIONS_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
static SecretVolume
getDefaultInstance()
SecretVolume
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
String
getMountPath()
The path within the container to mount the secret volume.com.google.protobuf.ByteString
getMountPathBytes()
The path within the container to mount the secret volume.com.google.protobuf.Parser<SecretVolume>
getParserForType()
String
getProjectId()
Project identifier (preferrably project number but can also be the project ID) of the project that contains the secret.com.google.protobuf.ByteString
getProjectIdBytes()
Project identifier (preferrably project number but can also be the project ID) of the project that contains the secret.String
getSecret()
Name of the secret in Secret Manager (not the full resource name).com.google.protobuf.ByteString
getSecretBytes()
Name of the secret in Secret Manager (not the full resource name).int
getSerializedSize()
SecretVolume.SecretVersion
getVersions(int index)
List of secret versions to mount for this secret.int
getVersionsCount()
List of secret versions to mount for this secret.List<SecretVolume.SecretVersion>
getVersionsList()
List of secret versions to mount for this secret.SecretVolume.SecretVersionOrBuilder
getVersionsOrBuilder(int index)
List of secret versions to mount for this secret.List<? extends SecretVolume.SecretVersionOrBuilder>
getVersionsOrBuilderList()
List of secret versions to mount for this secret.int
hashCode()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
boolean
isInitialized()
static SecretVolume.Builder
newBuilder()
static SecretVolume.Builder
newBuilder(SecretVolume prototype)
SecretVolume.Builder
newBuilderForType()
protected SecretVolume.Builder
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
protected Object
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
static SecretVolume
parseDelimitedFrom(InputStream input)
static SecretVolume
parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static SecretVolume
parseFrom(byte[] data)
static SecretVolume
parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static SecretVolume
parseFrom(com.google.protobuf.ByteString data)
static SecretVolume
parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static SecretVolume
parseFrom(com.google.protobuf.CodedInputStream input)
static SecretVolume
parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static SecretVolume
parseFrom(InputStream input)
static SecretVolume
parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static SecretVolume
parseFrom(ByteBuffer data)
static SecretVolume
parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.protobuf.Parser<SecretVolume>
parser()
SecretVolume.Builder
toBuilder()
void
writeTo(com.google.protobuf.CodedOutputStream output)
-
Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
MOUNT_PATH_FIELD_NUMBER
public static final int MOUNT_PATH_FIELD_NUMBER
- See Also:
- Constant Field Values
-
PROJECT_ID_FIELD_NUMBER
public static final int PROJECT_ID_FIELD_NUMBER
- See Also:
- Constant Field Values
-
SECRET_FIELD_NUMBER
public static final int SECRET_FIELD_NUMBER
- See Also:
- Constant Field Values
-
VERSIONS_FIELD_NUMBER
public static final int VERSIONS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
- Overrides:
newInstance
in classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3
-
getMountPath
public String getMountPath()
The path within the container to mount the secret volume. For example, setting the mount_path as `/etc/secrets` mounts the secret value files under the `/etc/secrets` directory. This directory is also completely shadowed and unavailable to mount any other secrets. Recommended mount paths: /etc/secrets Restricted mount paths: /cloudsql, /dev/log, /pod, /proc, /var/log
string mount_path = 1;
- Specified by:
getMountPath
in interfaceSecretVolumeOrBuilder
- Returns:
- The mountPath.
-
getMountPathBytes
public com.google.protobuf.ByteString getMountPathBytes()
The path within the container to mount the secret volume. For example, setting the mount_path as `/etc/secrets` mounts the secret value files under the `/etc/secrets` directory. This directory is also completely shadowed and unavailable to mount any other secrets. Recommended mount paths: /etc/secrets Restricted mount paths: /cloudsql, /dev/log, /pod, /proc, /var/log
string mount_path = 1;
- Specified by:
getMountPathBytes
in interfaceSecretVolumeOrBuilder
- Returns:
- The bytes for mountPath.
-
getProjectId
public String getProjectId()
Project identifier (preferrably project number but can also be the project ID) of the project that contains the secret. If not set, it is populated with the function's project, assuming that the secret exists in the same project as the function.
string project_id = 2;
- Specified by:
getProjectId
in interfaceSecretVolumeOrBuilder
- Returns:
- The projectId.
-
getProjectIdBytes
public com.google.protobuf.ByteString getProjectIdBytes()
Project identifier (preferrably project number but can also be the project ID) of the project that contains the secret. If not set, it is populated with the function's project, assuming that the secret exists in the same project as the function.
string project_id = 2;
- Specified by:
getProjectIdBytes
in interfaceSecretVolumeOrBuilder
- Returns:
- The bytes for projectId.
-
getSecret
public String getSecret()
Name of the secret in Secret Manager (not the full resource name).
string secret = 3;
- Specified by:
getSecret
in interfaceSecretVolumeOrBuilder
- Returns:
- The secret.
-
getSecretBytes
public com.google.protobuf.ByteString getSecretBytes()
Name of the secret in Secret Manager (not the full resource name).
string secret = 3;
- Specified by:
getSecretBytes
in interfaceSecretVolumeOrBuilder
- Returns:
- The bytes for secret.
-
getVersionsList
public List<SecretVolume.SecretVersion> getVersionsList()
List of secret versions to mount for this secret. If empty, the `latest` version of the secret is made available in a file named after the secret under the mount point.
repeated .google.cloud.functions.v1.SecretVolume.SecretVersion versions = 4;
- Specified by:
getVersionsList
in interfaceSecretVolumeOrBuilder
-
getVersionsOrBuilderList
public List<? extends SecretVolume.SecretVersionOrBuilder> getVersionsOrBuilderList()
List of secret versions to mount for this secret. If empty, the `latest` version of the secret is made available in a file named after the secret under the mount point.
repeated .google.cloud.functions.v1.SecretVolume.SecretVersion versions = 4;
- Specified by:
getVersionsOrBuilderList
in interfaceSecretVolumeOrBuilder
-
getVersionsCount
public int getVersionsCount()
List of secret versions to mount for this secret. If empty, the `latest` version of the secret is made available in a file named after the secret under the mount point.
repeated .google.cloud.functions.v1.SecretVolume.SecretVersion versions = 4;
- Specified by:
getVersionsCount
in interfaceSecretVolumeOrBuilder
-
getVersions
public SecretVolume.SecretVersion getVersions(int index)
List of secret versions to mount for this secret. If empty, the `latest` version of the secret is made available in a file named after the secret under the mount point.
repeated .google.cloud.functions.v1.SecretVolume.SecretVersion versions = 4;
- Specified by:
getVersions
in interfaceSecretVolumeOrBuilder
-
getVersionsOrBuilder
public SecretVolume.SecretVersionOrBuilder getVersionsOrBuilder(int index)
List of secret versions to mount for this secret. If empty, the `latest` version of the secret is made available in a file named after the secret under the mount point.
repeated .google.cloud.functions.v1.SecretVolume.SecretVersion versions = 4;
- Specified by:
getVersionsOrBuilder
in interfaceSecretVolumeOrBuilder
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessageV3
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
- Specified by:
writeTo
in interfacecom.google.protobuf.MessageLite
- Overrides:
writeTo
in classcom.google.protobuf.GeneratedMessageV3
- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSize
in interfacecom.google.protobuf.MessageLite
- Overrides:
getSerializedSize
in classcom.google.protobuf.GeneratedMessageV3
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in interfacecom.google.protobuf.Message
- Overrides:
equals
in classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacecom.google.protobuf.Message
- Overrides:
hashCode
in classcom.google.protobuf.AbstractMessage
-
parseFrom
public static SecretVolume parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SecretVolume parseFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static SecretVolume parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static SecretVolume parseDelimitedFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static SecretVolume parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseFrom
public static SecretVolume parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static SecretVolume parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
newBuilderForType
public SecretVolume.Builder newBuilderForType()
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.Message
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.MessageLite
-
newBuilder
public static SecretVolume.Builder newBuilder()
-
newBuilder
public static SecretVolume.Builder newBuilder(SecretVolume prototype)
-
toBuilder
public SecretVolume.Builder toBuilder()
- Specified by:
toBuilder
in interfacecom.google.protobuf.Message
- Specified by:
toBuilder
in interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected SecretVolume.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForType
in classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static SecretVolume getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<SecretVolume> parser()
-
getParserForType
public com.google.protobuf.Parser<SecretVolume> getParserForType()
- Specified by:
getParserForType
in interfacecom.google.protobuf.Message
- Specified by:
getParserForType
in interfacecom.google.protobuf.MessageLite
- Overrides:
getParserForType
in classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
public SecretVolume getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
-