Class CloudStorageConfig (1.133.0)

public final class CloudStorageConfig extends GeneratedMessageV3 implements CloudStorageConfigOrBuilder

Configuration for a Cloud Storage subscription.

Protobuf type google.pubsub.v1.CloudStorageConfig

Static Fields

AVRO_CONFIG_FIELD_NUMBER

public static final int AVRO_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

BUCKET_FIELD_NUMBER

public static final int BUCKET_FIELD_NUMBER
Field Value
Type Description
int

FILENAME_DATETIME_FORMAT_FIELD_NUMBER

public static final int FILENAME_DATETIME_FORMAT_FIELD_NUMBER
Field Value
Type Description
int

FILENAME_PREFIX_FIELD_NUMBER

public static final int FILENAME_PREFIX_FIELD_NUMBER
Field Value
Type Description
int

FILENAME_SUFFIX_FIELD_NUMBER

public static final int FILENAME_SUFFIX_FIELD_NUMBER
Field Value
Type Description
int

MAX_BYTES_FIELD_NUMBER

public static final int MAX_BYTES_FIELD_NUMBER
Field Value
Type Description
int

MAX_DURATION_FIELD_NUMBER

public static final int MAX_DURATION_FIELD_NUMBER
Field Value
Type Description
int

MAX_MESSAGES_FIELD_NUMBER

public static final int MAX_MESSAGES_FIELD_NUMBER
Field Value
Type Description
int

SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER

public static final int SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER
Field Value
Type Description
int

STATE_FIELD_NUMBER

public static final int STATE_FIELD_NUMBER
Field Value
Type Description
int

TEXT_CONFIG_FIELD_NUMBER

public static final int TEXT_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static CloudStorageConfig getDefaultInstance()
Returns
Type Description
CloudStorageConfig

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

newBuilder()

public static CloudStorageConfig.Builder newBuilder()
Returns
Type Description
CloudStorageConfig.Builder

newBuilder(CloudStorageConfig prototype)

public static CloudStorageConfig.Builder newBuilder(CloudStorageConfig prototype)
Parameter
Name Description
prototype CloudStorageConfig
Returns
Type Description
CloudStorageConfig.Builder

parseDelimitedFrom(InputStream input)

public static CloudStorageConfig parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static CloudStorageConfig parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static CloudStorageConfig parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static CloudStorageConfig parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static CloudStorageConfig parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static CloudStorageConfig parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static CloudStorageConfig parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CloudStorageConfig
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<CloudStorageConfig> parser()
Returns
Type Description
Parser<CloudStorageConfig>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getAvroConfig()

public CloudStorageConfig.AvroConfig getAvroConfig()

Optional. If set, message data will be written to Cloud Storage in Avro format.

.google.pubsub.v1.CloudStorageConfig.AvroConfig avro_config = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
CloudStorageConfig.AvroConfig

The avroConfig.

getAvroConfigOrBuilder()

public CloudStorageConfig.AvroConfigOrBuilder getAvroConfigOrBuilder()

Optional. If set, message data will be written to Cloud Storage in Avro format.

.google.pubsub.v1.CloudStorageConfig.AvroConfig avro_config = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
CloudStorageConfig.AvroConfigOrBuilder

getBucket()

public String getBucket()

Required. User-provided name for the Cloud Storage bucket. The bucket must be created by the user. The bucket name must be without any prefix like "gs://". See the bucket naming requirements.

string bucket = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The bucket.

getBucketBytes()

public ByteString getBucketBytes()

Required. User-provided name for the Cloud Storage bucket. The bucket must be created by the user. The bucket name must be without any prefix like "gs://". See the bucket naming requirements.

string bucket = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for bucket.

getDefaultInstanceForType()

public CloudStorageConfig getDefaultInstanceForType()
Returns
Type Description
CloudStorageConfig

getFilenameDatetimeFormat()

public String getFilenameDatetimeFormat()

Optional. User-provided format string specifying how to represent datetimes in Cloud Storage filenames. See the datetime format guidance.

string filename_datetime_format = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The filenameDatetimeFormat.

getFilenameDatetimeFormatBytes()

public ByteString getFilenameDatetimeFormatBytes()

Optional. User-provided format string specifying how to represent datetimes in Cloud Storage filenames. See the datetime format guidance.

string filename_datetime_format = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for filenameDatetimeFormat.

getFilenamePrefix()

public String getFilenamePrefix()

Optional. User-provided prefix for Cloud Storage filename. See the object naming requirements.

string filename_prefix = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The filenamePrefix.

getFilenamePrefixBytes()

public ByteString getFilenamePrefixBytes()

Optional. User-provided prefix for Cloud Storage filename. See the object naming requirements.

string filename_prefix = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for filenamePrefix.

getFilenameSuffix()

public String getFilenameSuffix()

Optional. User-provided suffix for Cloud Storage filename. See the object naming requirements. Must not end in "/".

string filename_suffix = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The filenameSuffix.

getFilenameSuffixBytes()

public ByteString getFilenameSuffixBytes()

Optional. User-provided suffix for Cloud Storage filename. See the object naming requirements. Must not end in "/".

string filename_suffix = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for filenameSuffix.

getMaxBytes()

public long getMaxBytes()

Optional. The maximum bytes that can be written to a Cloud Storage file before a new file is created. Min 1 KB, max 10 GiB. The max_bytes limit may be exceeded in cases where messages are larger than the limit.

int64 max_bytes = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The maxBytes.

getMaxDuration()

public Duration getMaxDuration()

Optional. The maximum duration that can elapse before a new Cloud Storage file is created. Min 1 minute, max 10 minutes, default 5 minutes. May not exceed the subscription's acknowledgement deadline.

.google.protobuf.Duration max_duration = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Duration

The maxDuration.

getMaxDurationOrBuilder()

public DurationOrBuilder getMaxDurationOrBuilder()

Optional. The maximum duration that can elapse before a new Cloud Storage file is created. Min 1 minute, max 10 minutes, default 5 minutes. May not exceed the subscription's acknowledgement deadline.

.google.protobuf.Duration max_duration = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DurationOrBuilder

getMaxMessages()

public long getMaxMessages()

Optional. The maximum number of messages that can be written to a Cloud Storage file before a new file is created. Min 1000 messages.

int64 max_messages = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The maxMessages.

getOutputFormatCase()

public CloudStorageConfig.OutputFormatCase getOutputFormatCase()
Returns
Type Description
CloudStorageConfig.OutputFormatCase

getParserForType()

public Parser<CloudStorageConfig> getParserForType()
Returns
Type Description
Parser<CloudStorageConfig>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

getServiceAccountEmail()

public String getServiceAccountEmail()

Optional. The service account to use to write to Cloud Storage. The subscription creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The serviceAccountEmail.

getServiceAccountEmailBytes()

public ByteString getServiceAccountEmailBytes()

Optional. The service account to use to write to Cloud Storage. The subscription creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for serviceAccountEmail.

getState()

public CloudStorageConfig.State getState()

Output only. An output-only field that indicates whether or not the subscription can receive messages.

.google.pubsub.v1.CloudStorageConfig.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
CloudStorageConfig.State

The state.

getStateValue()

public int getStateValue()

Output only. An output-only field that indicates whether or not the subscription can receive messages.

.google.pubsub.v1.CloudStorageConfig.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The enum numeric value on the wire for state.

getTextConfig()

public CloudStorageConfig.TextConfig getTextConfig()

Optional. If set, message data will be written to Cloud Storage in text format.

.google.pubsub.v1.CloudStorageConfig.TextConfig text_config = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
CloudStorageConfig.TextConfig

The textConfig.

getTextConfigOrBuilder()

public CloudStorageConfig.TextConfigOrBuilder getTextConfigOrBuilder()

Optional. If set, message data will be written to Cloud Storage in text format.

.google.pubsub.v1.CloudStorageConfig.TextConfig text_config = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
CloudStorageConfig.TextConfigOrBuilder

hasAvroConfig()

public boolean hasAvroConfig()

Optional. If set, message data will be written to Cloud Storage in Avro format.

.google.pubsub.v1.CloudStorageConfig.AvroConfig avro_config = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the avroConfig field is set.

hasMaxDuration()

public boolean hasMaxDuration()

Optional. The maximum duration that can elapse before a new Cloud Storage file is created. Min 1 minute, max 10 minutes, default 5 minutes. May not exceed the subscription's acknowledgement deadline.

.google.protobuf.Duration max_duration = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the maxDuration field is set.

hasTextConfig()

public boolean hasTextConfig()

Optional. If set, message data will be written to Cloud Storage in text format.

.google.pubsub.v1.CloudStorageConfig.TextConfig text_config = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the textConfig field is set.

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public CloudStorageConfig.Builder newBuilderForType()
Returns
Type Description
CloudStorageConfig.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected CloudStorageConfig.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
CloudStorageConfig.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public CloudStorageConfig.Builder toBuilder()
Returns
Type Description
CloudStorageConfig.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException