Class: Google::Apis::PubsubV1::BigQueryConfig
- Inherits:
-
Object
- Object
- Google::Apis::PubsubV1::BigQueryConfig
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/pubsub_v1/classes.rb,
lib/google/apis/pubsub_v1/representations.rb,
lib/google/apis/pubsub_v1/representations.rb
Overview
Configuration for a BigQuery subscription.
Instance Attribute Summary collapse
-
#drop_unknown_fields ⇒ Boolean
(also: #drop_unknown_fields?)
Optional.
-
#service_account_email ⇒ String
Optional.
-
#state ⇒ String
Output only.
-
#table ⇒ String
Optional.
-
#use_table_schema ⇒ Boolean
(also: #use_table_schema?)
Optional.
-
#use_topic_schema ⇒ Boolean
(also: #use_topic_schema?)
Optional.
-
#write_metadata ⇒ Boolean
(also: #write_metadata?)
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ BigQueryConfig
constructor
A new instance of BigQueryConfig.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ BigQueryConfig
Returns a new instance of BigQueryConfig.
388 389 390 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 388 def initialize(**args) update!(**args) end |
Instance Attribute Details
#drop_unknown_fields ⇒ Boolean Also known as: drop_unknown_fields?
Optional. If true and use_topic_schema is true, drops any fields that are
part of the topic schema that are not part of the BigQuery table schema when
writing to BigQuery. Otherwise, the schemas must be kept in sync and any
messages with extra fields are not written and remain in the subscription's
backlog. If true and use_table_schema is true, drops any fields in the
message that are not part of the BigQuery table schema when writing to
BigQuery. Otherwise, the write to BigQuery will fail.
Corresponds to the JSON property dropUnknownFields
338 339 340 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 338 def drop_unknown_fields @drop_unknown_fields end |
#service_account_email ⇒ String
Optional. The service account to use to write to BigQuery. 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.
Corresponds to the JSON property serviceAccountEmail
348 349 350 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 348 def service_account_email @service_account_email end |
#state ⇒ String
Output only. An output-only field that indicates whether or not the
subscription can receive messages.
Corresponds to the JSON property state
354 355 356 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 354 def state @state end |
#table ⇒ String
Optional. The name of the table to which to write data, of the form projectId
.datasetId.tableId
Corresponds to the JSON property table
360 361 362 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 360 def table @table end |
#use_table_schema ⇒ Boolean Also known as: use_table_schema?
Optional. When true, use the BigQuery table's schema as the columns to write
to in BigQuery. use_table_schema and use_topic_schema cannot be enabled at
the same time.
Corresponds to the JSON property useTableSchema
367 368 369 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 367 def use_table_schema @use_table_schema end |
#use_topic_schema ⇒ Boolean Also known as: use_topic_schema?
Optional. When true, use the topic's schema as the columns to write to in
BigQuery, if it exists. use_topic_schema and use_table_schema cannot be
enabled at the same time.
Corresponds to the JSON property useTopicSchema
375 376 377 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 375 def use_topic_schema @use_topic_schema end |
#write_metadata ⇒ Boolean Also known as: write_metadata?
Optional. When true, write the subscription name, message_id, publish_time,
attributes, and ordering_key to additional columns in the table. The
subscription name, message_id, and publish_time fields are put in their own
columns while all other message properties (other than data) are written to a
JSON object in the attributes column.
Corresponds to the JSON property writeMetadata
385 386 387 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 385 def @write_metadata end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
393 394 395 396 397 398 399 400 401 |
# File 'lib/google/apis/pubsub_v1/classes.rb', line 393 def update!(**args) @drop_unknown_fields = args[:drop_unknown_fields] if args.key?(:drop_unknown_fields) @service_account_email = args[:service_account_email] if args.key?(:service_account_email) @state = args[:state] if args.key?(:state) @table = args[:table] if args.key?(:table) @use_table_schema = args[:use_table_schema] if args.key?(:use_table_schema) @use_topic_schema = args[:use_topic_schema] if args.key?(:use_topic_schema) @write_metadata = args[:write_metadata] if args.key?(:write_metadata) end |