target.apidocs.com.google.api.services.pubsub.model.BigQueryConfig.html Maven / Gradle / Ivy
BigQueryConfig (Cloud Pub/Sub API v1-rev20240918-2.0.0)
com.google.api.services.pubsub.model
Class BigQueryConfig
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.pubsub.model.BigQueryConfig
-
public final class BigQueryConfig
extends com.google.api.client.json.GenericJson
Configuration for a BigQuery subscription.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Cloud Pub/Sub API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
BigQueryConfig()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
BigQueryConfig
clone()
Boolean
getDropUnknownFields()
Optional.
String
getServiceAccountEmail()
Optional.
String
getState()
Output only.
String
getTable()
Optional.
Boolean
getUseTableSchema()
Optional.
Boolean
getUseTopicSchema()
Optional.
Boolean
getWriteMetadata()
Optional.
BigQueryConfig
set(String fieldName,
Object value)
BigQueryConfig
setDropUnknownFields(Boolean dropUnknownFields)
Optional.
BigQueryConfig
setServiceAccountEmail(String serviceAccountEmail)
Optional.
BigQueryConfig
setState(String state)
Output only.
BigQueryConfig
setTable(String table)
Optional.
BigQueryConfig
setUseTableSchema(Boolean useTableSchema)
Optional.
BigQueryConfig
setUseTopicSchema(Boolean useTopicSchema)
Optional.
BigQueryConfig
setWriteMetadata(Boolean writeMetadata)
Optional.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getDropUnknownFields
public Boolean getDropUnknownFields()
Optional. When true and use_topic_schema is true, any fields that are a part of the topic
schema that are not part of the BigQuery table schema are dropped 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.
- Returns:
- value or
null
for none
-
setDropUnknownFields
public BigQueryConfig setDropUnknownFields(Boolean dropUnknownFields)
Optional. When true and use_topic_schema is true, any fields that are a part of the topic
schema that are not part of the BigQuery table schema are dropped 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.
- Parameters:
dropUnknownFields
- dropUnknownFields or null
for none
-
getServiceAccountEmail
public String getServiceAccountEmail()
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](https://cloud.google.com/iam/docs/service-agents), service-{project_number}@gcp-sa-
pubsub.iam.gserviceaccount.com, is used.
- Returns:
- value or
null
for none
-
setServiceAccountEmail
public BigQueryConfig setServiceAccountEmail(String serviceAccountEmail)
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](https://cloud.google.com/iam/docs/service-agents), service-{project_number}@gcp-sa-
pubsub.iam.gserviceaccount.com, is used.
- Parameters:
serviceAccountEmail
- serviceAccountEmail or null
for none
-
getState
public String getState()
Output only. An output-only field that indicates whether or not the subscription can receive
messages.
- Returns:
- value or
null
for none
-
setState
public BigQueryConfig setState(String state)
Output only. An output-only field that indicates whether or not the subscription can receive
messages.
- Parameters:
state
- state or null
for none
-
getTable
public String getTable()
Optional. The name of the table to which to write data, of the form
{projectId}.{datasetId}.{tableId}
- Returns:
- value or
null
for none
-
setTable
public BigQueryConfig setTable(String table)
Optional. The name of the table to which to write data, of the form
{projectId}.{datasetId}.{tableId}
- Parameters:
table
- table or null
for none
-
getUseTableSchema
public Boolean getUseTableSchema()
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.
- Returns:
- value or
null
for none
-
setUseTableSchema
public BigQueryConfig setUseTableSchema(Boolean useTableSchema)
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.
- Parameters:
useTableSchema
- useTableSchema or null
for none
-
getUseTopicSchema
public Boolean getUseTopicSchema()
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.
- Returns:
- value or
null
for none
-
setUseTopicSchema
public BigQueryConfig setUseTopicSchema(Boolean useTopicSchema)
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.
- Parameters:
useTopicSchema
- useTopicSchema or null
for none
-
getWriteMetadata
public Boolean getWriteMetadata()
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.
- Returns:
- value or
null
for none
-
setWriteMetadata
public BigQueryConfig setWriteMetadata(Boolean writeMetadata)
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.
- Parameters:
writeMetadata
- writeMetadata or null
for none
-
set
public BigQueryConfig set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public BigQueryConfig clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2024 Google. All rights reserved.