<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>GCP Connectors for Apache Flink</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/</link><description>Recent content on GCP Connectors for Apache Flink</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://flink-gcp.github.io/flink-connector-gcp/1.1/index.xml" rel="self" type="application/rss+xml"/><item><title>Delivery Guarantees</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/delivery-guarantees/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/delivery-guarantees/</guid><description>&lt;h1 id="delivery-guarantees"&gt;Delivery Guarantees&lt;a class="anchor" href="#delivery-guarantees"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;This page compares what a completed Flink checkpoint means for each sink and what can happen when
Flink restores an earlier checkpoint.&lt;/p&gt;
&lt;p&gt;The short version is that flushing before a checkpoint makes data durable, but does not by itself
prevent a restored job from writing the same record again.
BigQuery has checkpoint-coordinated exactly-once write methods.
Cloud Tasks also has opt-in, experimental checkpointed task creation within its documented retention and recovery scope; it keeps up with the at-least-once path at the measured rates and adds most of a checkpoint interval to task visibility latency.
Some other sinks can make a replay harmless when the record supplies a stable identity, but that is
not the same contract as a general-purpose exactly-once sink.&lt;/p&gt;</description></item><item><title>Dynamic destinations</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/dynamic-destinations/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/dynamic-destinations/</guid><description>&lt;h1 id="dynamic-destinations"&gt;Dynamic destinations&lt;a class="anchor" href="#dynamic-destinations"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;One sink instance can route records to many tables, topics or queues without splitting the stream into one sink per destination.
BigQuery, Cloud Pub/Sub, Cloud Tasks and Bigtable express that choice through a &lt;code&gt;destinationResolver&lt;/code&gt;, while Spanner takes the table from each serialized &lt;code&gt;Mutation&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The examples below start from each connector&amp;rsquo;s &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; job and replace its fixed destination with record-driven routing.
The connector example pages carry the surrounding job and the detailed options.&lt;/p&gt;</description></item><item><title>BigQuery</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/</guid><description>&lt;h1 id="bigquery-connector"&gt;BigQuery Connector&lt;a class="anchor" href="#bigquery-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;code&gt;flink-connector-gcp-bigquery&lt;/code&gt; module provides a bounded &lt;a href="#source"&gt;source&lt;/a&gt; and a &lt;a href="#sink"&gt;sink&lt;/a&gt; for Apache Flink.
The source reads tables and query results through the Storage Read API.
The sink offers a unified, &lt;code&gt;BigQueryIO&lt;/code&gt;-style write API over the Storage Write API and GCS-staged load jobs.
Experimental &lt;a href="#change-data-capture"&gt;CDC writes&lt;/a&gt; apply upserts and deletes to tables with a BigQuery primary key, using only the at-least-once default-stream write method.
The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigquery/"&gt;Table API / SQL connector&lt;/a&gt; also supports bounded reads, writes, and CDC ingestion.&lt;/p&gt;</description></item><item><title>BigQuery</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigquery/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigquery/</guid><description>&lt;h1 id="bigquery-sql-connector"&gt;BigQuery SQL Connector&lt;a class="anchor" href="#bigquery-sql-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;code&gt;bigquery&lt;/code&gt; connector provides a bounded &lt;a href="#source"&gt;source&lt;/a&gt; for BigQuery tables and query results, and a &lt;a href="#sink"&gt;sink&lt;/a&gt; for all three write methods through the module &lt;code&gt;flink-connector-gcp-bigquery&lt;/code&gt;.
The sink also supports experimental &lt;a href="#change-data-capture"&gt;CDC ingestion&lt;/a&gt;: upserts and deletes with a declared primary key, using only the at-least-once default-stream write method.
It maps onto the DataStream source and sink documented in
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/"&gt;BigQuery&lt;/a&gt; — that page carries the design,
the delivery guarantees and the error handling; this one carries the DDL surface. Per-feature
status is in the module README.&lt;/p&gt;</description></item><item><title>BigQuery</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/bigquery/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/bigquery/</guid><description>&lt;h1 id="bigquery-examples"&gt;BigQuery examples&lt;a class="anchor" href="#bigquery-examples"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigquery/"&gt;BigQuery quickstart&lt;/a&gt; owns the basic DataStream read and write jobs.
The examples below keep only the parts that change for a particular use case.&lt;/p&gt;
&lt;h2 id="datastream-source"&gt;DataStream source&lt;a class="anchor" href="#datastream-source"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Start with the Quickstart&amp;rsquo;s &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigquery/#read-a-table"&gt;bounded table read&lt;/a&gt;.
The cases below change its projection, billing project, snapshot, query, or stream assignment.&lt;/p&gt;
&lt;h3 id="reading-one-column-of-a-large-table"&gt;Reading one column of a large table&lt;a class="anchor" href="#reading-one-column-of-a-large-table"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The two push-down knobs are applied by BigQuery when the read session is created, so what they
exclude never leaves it — and the columns you leave out are not scanned, which is what the read is
charged for.&lt;/p&gt;</description></item><item><title>BigQuery</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigquery/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigquery/</guid><description>&lt;h1 id="write-to-and-read-from-bigquery"&gt;Write to and read from BigQuery&lt;a class="anchor" href="#write-to-and-read-from-bigquery"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Assumes the artifacts and credentials from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; index. The whole file, since it is the one worth
copying verbatim; the other connectors&amp;rsquo; pages show only the job.&lt;/p&gt;
&lt;h2 id="write-a-stream-to-a-table"&gt;Write a stream to a table&lt;a class="anchor" href="#write-a-stream-to-a-table"&gt;#&lt;/a&gt;&lt;/h2&gt;


&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;package&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;example&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;org.apache.flink.api.common.RuntimeExecutionMode&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;org.apache.flink.streaming.api.environment.StreamExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;com.google.cloud.bigquery.Field&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;com.google.cloud.bigquery.Schema&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;com.google.cloud.bigquery.StandardSQLTypeName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;io.github.flink.gcp.connector.bigquery.sink.BigQuerySink&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;io.github.flink.gcp.connector.bigquery.sink.TableDestination&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kn"&gt;import&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nn"&gt;io.github.flink.gcp.connector.bigquery.sink.serializer.json.JsonDocumentSerializationSchema&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kd"&gt;public&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;BigQueryQuickstartWrite&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kd"&gt;public&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kd"&gt;static&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kt"&gt;void&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;main&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;String&lt;/span&gt;&lt;span class="o"&gt;[]&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;args&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kd"&gt;throws&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Exception&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// JSON carries no schema, so this one is supplied rather than derived. Serializers for&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// input that does carry a schema — protobuf messages and Avro records — derive it.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Schema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;schema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Schema&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Field&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;order_id&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StandardSQLTypeName&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;STRING&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Field&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;amount&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StandardSQLTypeName&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;INT64&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;getExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;setRuntimeMode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;RuntimeExecutionMode&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;STREAMING&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// Not optional. Every sink here is at-least-once *only* with checkpointing: the checkpoint&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// is what makes Flink flush what the Google client libraries are still holding, so without&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// it those records are lost on failure.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;enableCheckpointing&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;60_000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;fromData&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;{\&amp;#34;order_id\&amp;#34;:\&amp;#34;a-1\&amp;#34;,\&amp;#34;amount\&amp;#34;:10}&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;{\&amp;#34;order_id\&amp;#34;:\&amp;#34;a-2\&amp;#34;,\&amp;#34;amount\&amp;#34;:20}&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;sinkTo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;BigQuerySink&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;String&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="n"&gt;builder&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;table&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TableDestination&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-project&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my_dataset&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;orders&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;serializer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;JsonDocumentSerializationSchema&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;schema&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;execute&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;bigquery-quickstart&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;The dataset must exist; the table need not, because the default create disposition is
&lt;code&gt;CREATE_IF_NEEDED&lt;/code&gt; and the schema above is what it is created from. The default write method is
&lt;code&gt;STORAGE_API_AT_LEAST_ONCE&lt;/code&gt;, which makes rows queryable within seconds — the other two, and when to
reach for them, are under
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/bigquery/#exactly-once"&gt;exactly-once&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>BigQuery</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigquery/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigquery/</guid><description>&lt;h1 id="bigquery-options"&gt;BigQuery options&lt;a class="anchor" href="#bigquery-options"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Every option the BigQuery sink and source take. What each one is &lt;em&gt;for&lt;/em&gt; is on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/"&gt;BigQuery connector&lt;/a&gt; page, linked from each
section; the three forms of the Default column are explained
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/#what-a-default-means"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="bigquerysinkbuilder"&gt;&lt;code&gt;BigQuerySink.builder()&lt;/code&gt;&lt;a class="anchor" href="#bigquerysinkbuilder"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;table&gt;
	&lt;thead&gt;
			&lt;tr&gt;
					&lt;th&gt;Option&lt;/th&gt;
					&lt;th&gt;Default&lt;/th&gt;
					&lt;th&gt;What it does&lt;/th&gt;
			&lt;/tr&gt;
	&lt;/thead&gt;
	&lt;tbody&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;writeMethod&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;STORAGE_API_AT_LEAST_ONCE&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Which write path the sink dispatches to at graph construction&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;table&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt;, unless &lt;code&gt;destinationResolver&lt;/code&gt; is set&lt;/td&gt;
					&lt;td&gt;Writes every record to one fixed table&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;destinationResolver&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;Resolves the table per record for every write method&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;serializer&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt;&lt;/td&gt;
					&lt;td&gt;Converts each record into the protobuf row the Storage Write API accepts, or into &lt;code&gt;null&lt;/code&gt; to skip it&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;createDisposition&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;CREATE_IF_NEEDED&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Whether a missing destination table is created or fails the job. It does not authorize or deny reconciliation of an existing CDC table. &lt;code&gt;CREATE_IF_NEEDED&lt;/code&gt; also lets &lt;code&gt;STORAGE_API_EXACTLY_ONCE&lt;/code&gt; wait out the post-creation propagation window at commit time, so &lt;code&gt;CREATE_NEVER&lt;/code&gt; opts out of both on that write path&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;tableCreateOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;plain tables&lt;/td&gt;
					&lt;td&gt;&lt;a href="#tablecreateoptions"&gt;Creation settings&lt;/a&gt; for every table the sink creates&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;tableCreateOptionsProvider&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;The same, resolved per destination. Overrides &lt;code&gt;tableCreateOptions&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;schemaUpdateOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;updates disabled&lt;/td&gt;
					&lt;td&gt;&lt;a href="#schemaupdateoptions"&gt;What the sink may change&lt;/a&gt; about a destination table&amp;rsquo;s schema&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;failureHandler&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;FailureHandler.failJob()&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;What happens to an explicit record-specific routing failure or a row that terminally fails — fail, drop, or dead-letter. The queue behind &lt;code&gt;sendToDeadLetterQueue(...)&lt;/code&gt; has &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/pubsub/#pubsubdeadletterqueuebuilder"&gt;options of its own&lt;/a&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;location&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;The BigQuery location shared by the destination tables. Setting it avoids a per-table metadata lookup when a write connection is opened and locates CDC maximum-staleness jobs; under &lt;code&gt;FILE_LOADS&lt;/code&gt; it is the location every load job runs in and is recovered under, derived from each job&amp;rsquo;s destination dataset when unset — which is what a sink routing to datasets in several regions should rely on&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;serviceAccountKeyFile&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;em&gt;unset → ADC&lt;/em&gt;&lt;/td&gt;
					&lt;td&gt;Uses the service account in this JSON key file for every BigQuery client and for GCS staging under &lt;code&gt;FILE_LOADS&lt;/code&gt;. The file is loaded at runtime and must exist on each TaskManager; rejected with either emulator endpoint&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;additionalFields&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;no additional fields&lt;/td&gt;
					&lt;td&gt;Appends ordered &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/#additional-physical-fields"&gt;additional physical fields&lt;/a&gt; after serialization for every write method&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;cdcOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;CDC disabled&lt;/td&gt;
					&lt;td&gt;Adds &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/#change-data-capture"&gt;CDC metadata&lt;/a&gt; to non-skipped rows. Requires &lt;code&gt;STORAGE_API_AT_LEAST_ONCE&lt;/code&gt; and a BigQuery primary key&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;cdcTableOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;primary key undeclared; maximum staleness unmanaged&lt;/td&gt;
					&lt;td&gt;Applies one &lt;a href="#cdctableoptions"&gt;CDC table contract&lt;/a&gt; to every destination. Required with a primary key when a missing table must be created or the reconciliation policy is &lt;code&gt;RECONCILE&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;cdcTableOptionsProvider&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;The same contract, resolved per destination. Overrides &lt;code&gt;cdcTableOptions&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;cdcTableReconciliationPolicy&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;VERIFY_ONLY&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Verifies without starting adoption or drift repair, or opts into convergence through &lt;code&gt;RECONCILE&lt;/code&gt;. Either policy resumes a matching pending attempt. Independent of &lt;code&gt;createDisposition&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;defaultStreamOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;a href="#defaultstreamoptions"&gt;defaults&lt;/a&gt;&lt;/td&gt;
					&lt;td&gt;Tuning for &lt;code&gt;STORAGE_API_AT_LEAST_ONCE&lt;/code&gt;; rejected for the other two&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;bufferedStreamOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt; for &lt;code&gt;STORAGE_API_EXACTLY_ONCE&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;a href="#bufferedstreamoptions"&gt;Tuning&lt;/a&gt; for that method; rejected for the other two&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;fileLoadsOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt; for &lt;code&gt;FILE_LOADS&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;a href="#fileloadsoptions"&gt;Settings&lt;/a&gt; for that method; rejected for the other two&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;emulatorEndpoint&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;Sends the Storage Write API traffic to a BigQuery emulator at &lt;code&gt;host:port&lt;/code&gt;, over plaintext and without credentials. Rejected under &lt;code&gt;FILE_LOADS&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;emulatorRestEndpoint&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;The same for table creation, schema updates and the CDC table contract, which go over REST — a transport BigQuery serves on a different port, so the two endpoints are separate&lt;/td&gt;
			&lt;/tr&gt;
	&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;The two emulator endpoints are for testing against a local emulator and nothing else: both use
plaintext and no credentials, and both are rejected under &lt;code&gt;FILE_LOADS&lt;/code&gt;, which stages files to Cloud
Storage that no emulator here stands in for. A malformed &lt;code&gt;host:port&lt;/code&gt; fails in the setter, on the
client, rather than as a connection error after the job is deployed.&lt;/p&gt;</description></item><item><title>Testing</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/testing/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/testing/</guid><description>&lt;h1 id="testing"&gt;Testing&lt;a class="anchor" href="#testing"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The suites fall into three kinds, split by what they need to run: nothing beyond Docker, real
Google Cloud credentials, or wall clock. &lt;code&gt;just verify&lt;/code&gt; runs the first kind and excludes the
other two, so an ordinary build is credential-free and its duration is bounded.&lt;/p&gt;
&lt;h2 id="unit-and-integration-tests"&gt;Unit and integration tests&lt;a class="anchor" href="#unit-and-integration-tests"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Name a unit test &lt;code&gt;*Test&lt;/code&gt; and an integration test &lt;code&gt;*ITCase&lt;/code&gt;. The build selects by the first
suffix alone: a class ending in &lt;code&gt;Test&lt;/code&gt; runs in the unit execution, and every other test class
lands in the integration execution — an unconventional name does not escape the build, it runs
in the wrong lane. Both kinds run in &lt;code&gt;just verify&lt;/code&gt;. The integration tests
talk to Docker-backed service emulators, so Docker must be running, but no Google Cloud project
is touched. An emulator is a convenience rather than an authority: the deviations that have
been measured are recorded on the connector pages, and the real service is exercised by the
gated suites below.&lt;/p&gt;</description></item><item><title>Gated E2E audit (September 2026)</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/e2e-audit-2026-09/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/e2e-audit-2026-09/</guid><description>&lt;h1 id="gated-e2e-audit-september-2026"&gt;Gated E2E audit (September 2026)&lt;a class="anchor" href="#gated-e2e-audit-september-2026"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;This records the source audit for &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/1346"&gt;#1346&lt;/a&gt;, within the &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/1344"&gt;weekly E2E repair&lt;/a&gt;.
The inventory contains 46 concrete gated classes: 42 selected by the weekly recipe and four separately approved manual classes.
Every row received a static review of gates, provisioning/ownership, waits and cancellation, assertion strength, and cleanup; inherited helpers are part of that review.
A static review is not evidence that a real-service run passed.
Runtime results belong to the associated run and PR records; the manual classes below are excluded from this repair&amp;rsquo;s billed execution.&lt;/p&gt;</description></item><item><title>Checks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/checks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/checks/</guid><description>&lt;h1 id="checks"&gt;Checks&lt;a class="anchor" href="#checks"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Beyond the Maven build, CI runs a suite of repository-specific checkers — scripts under
&lt;code&gt;scripts/&lt;/code&gt; (mostly Python, some shell), most behind a &lt;code&gt;just check-*&lt;/code&gt; recipe.
Several are deliberately two-way: they
hold the documentation to the source &lt;em&gt;and&lt;/em&gt; the source to the documentation, so an option that
loses its table row fails the same check as a table row that loses its option. A contributor
meeting one for the first time should know that its failure message names the repair, and that
it is cheaper to run the relevant checker locally than to discover it on the pull request.&lt;/p&gt;</description></item><item><title>Documentation versions</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/versions/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/versions/</guid><description>&lt;h1 id="documentation-versions"&gt;Documentation versions&lt;a class="anchor" href="#documentation-versions"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The site publishes the latest patch release of the current and previous connector minor series.
For example, after 1.2.1 is released, the selector offers 1.2.1 and the latest 1.1.x release.
A later 1.1.x patch updates that series without changing which series is current.
The count spans major versions: 2.0 and the last published 1.x minor occupy the two slots after 2.0 is released.
This documentation retention policy does not change the Flink versions a connector supports.&lt;/p&gt;</description></item><item><title>Cloud Pub/Sub</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/</guid><description>&lt;h1 id="cloud-pubsub-connector"&gt;Cloud Pub/Sub Connector&lt;a class="anchor" href="#cloud-pubsub-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Cloud Pub/Sub source and sink for Apache Flink, with multi-subscription consumption on the source
and dynamic per-record topic destinations on the sink, provided by the
&lt;code&gt;flink-connector-gcp-pubsub&lt;/code&gt; module.&lt;/p&gt;
&lt;p&gt;Per-feature implementation status is tracked in the
&lt;a href="https://github.com/flink-gcp/flink-connector-gcp/blob/main/flink-connector-gcp-pubsub/README.md"&gt;module README&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="lineage"&gt;Lineage&lt;a class="anchor" href="#lineage"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The source and sink returned by the public builders implement Flink&amp;rsquo;s &lt;code&gt;LineageVertexProvider&lt;/code&gt;.
The source reports one dataset per configured subscription, with namespace &lt;code&gt;pubsub&lt;/code&gt; and name &lt;code&gt;subscription:{project}:{subscription}&lt;/code&gt;; its vertex remains unbounded.
The sink reports a fixed topic as &lt;code&gt;pubsub&lt;/code&gt; / &lt;code&gt;topic:{project}:{topic}&lt;/code&gt;.
The last &lt;code&gt;topic(...)&lt;/code&gt; or &lt;code&gt;destinationResolver(...)&lt;/code&gt; call selects the effective destination; a dynamic resolver contributes an empty dataset list.
Each known dataset carries the shared &lt;code&gt;gcp&lt;/code&gt; physical-resource facet described in &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/lineage/"&gt;Lineage&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Cloud Pub/Sub</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/pubsub/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/pubsub/</guid><description>&lt;h1 id="cloud-pubsub-sql-connector"&gt;Cloud Pub/Sub SQL Connector&lt;a class="anchor" href="#cloud-pubsub-sql-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;code&gt;pubsub&lt;/code&gt; table connector, provided by the &lt;code&gt;flink-connector-gcp-pubsub&lt;/code&gt; module. It maps onto the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/"&gt;DataStream sink and source&lt;/a&gt;, which is where the
behavior behind every option is documented; this page covers the option surface and the decisions specific to SQL.&lt;/p&gt;
&lt;p&gt;Per-feature implementation status — including which directions are implemented — is tracked in the
&lt;a href="https://github.com/flink-gcp/flink-connector-gcp/blob/main/flink-connector-gcp-pubsub/README.md"&gt;module README&lt;/a&gt;. Most of
the option keys below are declared by &lt;code&gt;PubSubConnectorOptions&lt;/code&gt; — &lt;code&gt;format&lt;/code&gt;, &lt;code&gt;sink.parallelism&lt;/code&gt; and
&lt;code&gt;scan.parallelism&lt;/code&gt; come from Flink&amp;rsquo;s &lt;code&gt;FactoryUtil&lt;/code&gt; — and are applied by an internal table factory;
both it and the DataStream types the options map onto are in the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/api/java/"&gt;Java API reference&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Cloud Pub/Sub</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/pubsub/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/pubsub/</guid><description>&lt;h1 id="cloud-pubsub-examples"&gt;Cloud Pub/Sub examples&lt;a class="anchor" href="#cloud-pubsub-examples"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Starting from the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/pubsub/"&gt;Cloud Pub/Sub quickstart&lt;/a&gt; jobs.&lt;/p&gt;
&lt;h2 id="datastream-source"&gt;DataStream source&lt;a class="anchor" href="#datastream-source"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/pubsub/#read-a-stream-from-a-subscription"&gt;Quickstart consume job&lt;/a&gt;
is the canonical basic source example.
The worked case below changes how the source obtains its subscription.&lt;/p&gt;
&lt;h3 id="subscriptions-on-the-source"&gt;Subscriptions, on the source&lt;a class="anchor" href="#subscriptions-on-the-source"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;On the source, &lt;strong&gt;passing creation settings alongside a subscription is what authorises creating
it.&lt;/strong&gt; No separate disposition is needed, because there is no meaningful &amp;ldquo;create with defaults&amp;rdquo; — a
subscription without a topic is not a subscription, and only you know which topic to bind.&lt;/p&gt;</description></item><item><title>Cloud Pub/Sub</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/pubsub/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/pubsub/</guid><description>&lt;h1 id="publish-to-and-read-from-cloud-pubsub"&gt;Publish to and read from Cloud Pub/Sub&lt;a class="anchor" href="#publish-to-and-read-from-cloud-pubsub"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Assumes the artifacts and credentials from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; index, and the imports an IDE resolves from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/api/java/"&gt;Java API reference&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="publish-a-stream-to-a-topic"&gt;Publish a stream to a topic&lt;a class="anchor" href="#publish-a-stream-to-a-topic"&gt;#&lt;/a&gt;&lt;/h2&gt;


&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;getExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;setRuntimeMode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;RuntimeExecutionMode&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;STREAMING&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;enableCheckpointing&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;60_000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;fromData&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;hello&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;world&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;sinkTo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;PubSubSink&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;String&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="n"&gt;builder&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;topic&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TopicDestination&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-project&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;orders&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;serializer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;PubSubSerializationSchema&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;new&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;SimpleStringSchema&lt;/span&gt;&lt;span class="p"&gt;()))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;execute&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;pubsub-sink-quickstart&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Checkpointing is not decoration: the sink is at-least-once &lt;em&gt;only&lt;/em&gt; with it, since the checkpoint is
what makes Flink flush the messages the SDK publishers are still batching.&lt;/p&gt;</description></item><item><title>Cloud Pub/Sub</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/pubsub/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/pubsub/</guid><description>&lt;h1 id="cloud-pubsub-options"&gt;Cloud Pub/Sub options&lt;a class="anchor" href="#cloud-pubsub-options"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Every option the Pub/Sub sink and source take, and the ones the shared
&lt;a href="#pubsubdeadletterqueuebuilder"&gt;dead-letter queue&lt;/a&gt; takes. What each one is &lt;em&gt;for&lt;/em&gt; is on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/"&gt;Cloud Pub/Sub connector&lt;/a&gt; page, linked from
each section; the three forms of the Default column are explained
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/#what-a-default-means"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The &lt;code&gt;WITH&lt;/code&gt; options of the &lt;code&gt;pubsub&lt;/code&gt; table connector are a separate surface, documented on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/pubsub/"&gt;Pub/Sub SQL connector&lt;/a&gt; page.&lt;/p&gt;
&lt;h2 id="pubsubsinkbuilder"&gt;&lt;code&gt;PubSubSink.builder()&lt;/code&gt;&lt;a class="anchor" href="#pubsubsinkbuilder"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;table&gt;
	&lt;thead&gt;
			&lt;tr&gt;
					&lt;th&gt;Option&lt;/th&gt;
					&lt;th&gt;Default&lt;/th&gt;
					&lt;th&gt;What it does&lt;/th&gt;
			&lt;/tr&gt;
	&lt;/thead&gt;
	&lt;tbody&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;topic&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt;, unless &lt;code&gt;destinationResolver&lt;/code&gt; is set&lt;/td&gt;
					&lt;td&gt;Publishes every record to one fixed topic&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;destinationResolver&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;Resolves the topic per record&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;serializer&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;strong&gt;required&lt;/strong&gt;&lt;/td&gt;
					&lt;td&gt;Converts each record into a &lt;code&gt;PubsubMessage&lt;/code&gt;, or into &lt;code&gt;null&lt;/code&gt; to skip it. &lt;code&gt;payload(...)&lt;/code&gt; wraps a payload-only schema; &lt;code&gt;withAttributes(...)&lt;/code&gt; and &lt;code&gt;withOrderingKey(...)&lt;/code&gt; layer onto any of them&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;createDisposition&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;CREATE_IF_NEEDED&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Whether a missing topic is created or fails the job&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;topicCreateOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;Pub/Sub&amp;rsquo;s own defaults&lt;/td&gt;
					&lt;td&gt;&lt;a href="#topiccreateoptions"&gt;Settings&lt;/a&gt; for topics the sink creates. Rejected with &lt;code&gt;CREATE_NEVER&lt;/code&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;publisherOptions&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;a href="#pubsubpublisheroptions"&gt;defaults&lt;/a&gt;&lt;/td&gt;
					&lt;td&gt;Publisher and writer tuning&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;failedMessageHandler&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;code&gt;FailureHandler.failJob()&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;What happens to a message that terminally fails — fail, drop, or dead-letter. Under &lt;code&gt;enableMessageOrdering(true)&lt;/code&gt;, dropping a keyed message leaves a gap in that key&amp;rsquo;s stream&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;serviceAccountKeyFile&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;&lt;em&gt;unset ⇒ application-default credentials&lt;/em&gt;&lt;/td&gt;
					&lt;td&gt;Reads a service-account JSON key on each TaskManager when the writer starts. Every eligible TaskManager must see the same path. Rejected beside &lt;code&gt;emulatorEndpoint&lt;/code&gt;; see the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/#credential-file-deployment"&gt;deployment note&lt;/a&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;emulatorEndpoint&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;—&lt;/td&gt;
					&lt;td&gt;Points the sink at an emulator over a plaintext channel with &lt;strong&gt;no credentials&lt;/strong&gt;. Never production. Given as &lt;code&gt;host:port&lt;/code&gt;, and rejected at the setter if it is not&lt;/td&gt;
			&lt;/tr&gt;
	&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="pubsubpublisheroptions"&gt;&lt;code&gt;PubSubPublisherOptions&lt;/code&gt;&lt;a class="anchor" href="#pubsubpublisheroptions"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Set through &lt;code&gt;publisherOptions(...)&lt;/code&gt;. The batching and retry knobs are handed to the SDK publisher
and left unset by default, so &lt;code&gt;defaults()&lt;/code&gt; is equivalent to passing no options at all; the in-flight
caps and the recovery budget are the connector&amp;rsquo;s own. See
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/#publisher-options"&gt;Publisher options&lt;/a&gt; for why
the SDK&amp;rsquo;s flow controller is deliberately not exposed, and
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/pubsub/#delivery-guarantees-and-state"&gt;Backpressure&lt;/a&gt;
for how the caps are sized.&lt;/p&gt;</description></item><item><title>Contributing</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/contributing/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/development/contributing/</guid><description>&lt;h1 id="contributing"&gt;Contributing&lt;a class="anchor" href="#contributing"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Contributions are welcome, and they start with an issue rather than a pull request — the same
consensus-first shape as &lt;a href="https://flink.apache.org/how-to-contribute/contribute-code/"&gt;Apache Flink&amp;rsquo;s contribution
process&lt;/a&gt;. Agreeing on the problem
and the approach before code exists is what keeps a pull request reviewable and keeps effort
from being spent on a change that would not be accepted.&lt;/p&gt;
&lt;h2 id="before-writing-code"&gt;Before writing code&lt;a class="anchor" href="#before-writing-code"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Open an issue describing the problem or the proposal, or comment on an existing one, and reach
agreement on the approach there. For a typo-level fix a pull request alone is fine; for
anything that changes behavior, a public API, or a settled design, the discussion comes first.&lt;/p&gt;</description></item><item><title>Cloud Tasks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/</guid><description>&lt;h1 id="cloud-tasks-connector"&gt;Cloud Tasks Connector&lt;a class="anchor" href="#cloud-tasks-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Start with the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/"&gt;Quickstart&lt;/a&gt; for the basic dispatch job,
or use the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/cloudtasks/"&gt;Cloud Tasks examples&lt;/a&gt; for dynamic queues,
Table sink requests, cross-connector pipelines, and local development.
The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/cloudtasks/"&gt;Table connector&lt;/a&gt; owns DDL, formats,
writable metadata, and planner restrictions.&lt;/p&gt;
&lt;h2 id="overview-and-setup"&gt;Overview and setup&lt;a class="anchor" href="#overview-and-setup"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Cloud Tasks sink for Apache Flink, provided by the &lt;code&gt;flink-connector-gcp-cloudtasks&lt;/code&gt; module.&lt;/p&gt;
&lt;p&gt;The sink ships in &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/24"&gt;#24&lt;/a&gt;, and App Engine targets join it in
&lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/628"&gt;#628&lt;/a&gt;.
Its emulator integration tests are &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/25"&gt;#25&lt;/a&gt;.
This page doubles as the design record: it explains what the connector does and why each decision
was taken, so the reasoning is settled once rather than re-argued per pull request.&lt;/p&gt;</description></item><item><title>Cloud Tasks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/cloudtasks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/cloudtasks/</guid><description>&lt;h1 id="cloud-tasks-sql-connector"&gt;Cloud Tasks SQL Connector&lt;a class="anchor" href="#cloud-tasks-sql-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Start with the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/"&gt;Quickstart&lt;/a&gt; for the basic DataStream
job, or use the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/cloudtasks/"&gt;Cloud Tasks examples&lt;/a&gt; for complete
Table sink requests and cross-connector pipelines.&lt;/p&gt;
&lt;h2 id="overview-and-setup"&gt;Overview and setup&lt;a class="anchor" href="#overview-and-setup"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The &lt;code&gt;cloud-tasks&lt;/code&gt; table connector is a sink provided by the
&lt;code&gt;flink-connector-gcp-cloudtasks&lt;/code&gt; module.
It maps onto the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/"&gt;DataStream sink&lt;/a&gt;, which
documents checkpoint behavior, retries, task naming and queue pacing.
This page defines how SQL rows become external HTTP or App Engine requests.&lt;/p&gt;
&lt;p&gt;Cloud Tasks is a request dispatch queue rather than an API-specific client.
The target API therefore decides whether a request uses JSON, another body format, a query string,
or no body at all.
SQL represents that split with a Flink format for the body and writable metadata for the rest of
the request.&lt;/p&gt;</description></item><item><title>Cloud Tasks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/cloudtasks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/cloudtasks/</guid><description>&lt;h1 id="cloud-tasks-examples"&gt;Cloud Tasks examples&lt;a class="anchor" href="#cloud-tasks-examples"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Starting from the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/"&gt;Cloud Tasks quickstart&lt;/a&gt; job.&lt;/p&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/"&gt;DataStream connector&lt;/a&gt; explains sink
runtime behavior, while the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/cloudtasks/"&gt;Table connector&lt;/a&gt;
owns DDL, writable metadata, and planner restrictions.&lt;/p&gt;
&lt;p&gt;For checkpointed task creation, the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/#checkpointed-task-creation"&gt;DataStream configuration&lt;/a&gt; and &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/cloudtasks/#checkpointed-task-creation"&gt;SQL example&lt;/a&gt; include retained checkpoints and bounded restart settings.
They share the same creation and recovery protocol; the examples below use eager creation unless explicitly configured otherwise.&lt;/p&gt;
&lt;h2 id="datastream-sink"&gt;DataStream sink&lt;a class="anchor" href="#datastream-sink"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;h3 id="basic-dispatch-job"&gt;Basic dispatch job&lt;a class="anchor" href="#basic-dispatch-job"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/"&gt;Quickstart&lt;/a&gt; is the canonical basic job: it creates
one external HTTP task for each input record and leaves dispatch pacing to the queue.
The examples below change its destination or use the Table API instead of copying that job.&lt;/p&gt;</description></item><item><title>Cloud Tasks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/cloudtasks/</guid><description>&lt;h1 id="dispatch-a-stream-as-cloud-tasks"&gt;Dispatch a stream as Cloud Tasks&lt;a class="anchor" href="#dispatch-a-stream-as-cloud-tasks"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Assumes the artifacts and credentials from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; index, and the imports an IDE resolves from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/api/java/"&gt;Java API reference&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Create the queue first.&lt;/strong&gt; The sink will not create one, and that is deliberate: the queue&amp;rsquo;s rate
limits are the entire reason to use the service, and a queue created with defaults would carry
Cloud Tasks&amp;rsquo; own (500 dispatches/second, 1000 concurrent) rather than the pacing the target
endpoint can absorb.&lt;/p&gt;</description></item><item><title>Cloud Tasks</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/cloudtasks/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/cloudtasks/</guid><description>&lt;h1 id="cloud-tasks-options"&gt;Cloud Tasks options&lt;a class="anchor" href="#cloud-tasks-options"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Every option the Cloud Tasks sink and App Engine target builder take. What each one is &lt;em&gt;for&lt;/em&gt; is on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/"&gt;Cloud Tasks connector&lt;/a&gt; page; the three
forms of the Default column are explained
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/#what-a-default-means"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;There are no rate knobs here.&lt;/strong&gt;
&lt;code&gt;maxDispatchesPerSecond&lt;/code&gt;, &lt;code&gt;maxConcurrentDispatches&lt;/code&gt; and the retry policy are &lt;em&gt;queue&lt;/em&gt; configuration,
applied by whoever creates the queue — the sink writes tasks and the queue decides how fast they
execute. That inversion is the connector&amp;rsquo;s whole reason for existing, and it is set out under
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/#what-this-connector-is-for"&gt;What this connector is for&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Bigtable</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/</guid><description>&lt;h1 id="bigtable-connector"&gt;Bigtable Connector&lt;a class="anchor" href="#bigtable-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Writes a DataStream into Cloud Bigtable, one row mutation per record, at-least-once by default, into a
fixed table or one each record names. Every
option is in the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigtable/"&gt;Bigtable reference&lt;/a&gt;; the runnable job is
the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigtable/"&gt;quickstart&lt;/a&gt;; implementation status is the table in
the module
&lt;a href="https://github.com/flink-gcp/flink-connector-gcp/tree/main/flink-connector-gcp-bigtable"&gt;README&lt;/a&gt;.&lt;/p&gt;


&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;Sink&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;OrderEvent&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;sink&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;BigtableSink&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;OrderEvent&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="n"&gt;builder&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;table&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TableDestination&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-project&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-instance&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;orders&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;serializer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;RowMutationEntry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;setCell&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;cf&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;payload&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;timestampMicros&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;body&lt;/span&gt;&lt;span class="p"&gt;()))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;h2 id="what-this-connector-is-for"&gt;What this connector is for&lt;a class="anchor" href="#what-this-connector-is-for"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Bigtable is a wide-column store keyed by a single row key, and what a streaming pipeline usually
wants from it is a materialized view: the latest state per key, or an append-only history of events
under a key that a serving path reads by prefix. The sink is shaped for that — the record decides
its own row key and cells, and the sink&amp;rsquo;s whole job is to get mutations there in bounded memory and
to make a checkpoint mean something.&lt;/p&gt;</description></item><item><title>Bigtable</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable/</guid><description>&lt;h1 id="bigtable-sql-connector"&gt;Bigtable SQL Connector&lt;a class="anchor" href="#bigtable-sql-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;code&gt;bigtable&lt;/code&gt; connector reads and writes a table in Cloud Bigtable through the module
&lt;code&gt;flink-connector-gcp-bigtable&lt;/code&gt;. It is a mapping onto the DataStream sink and scan source documented
in &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/"&gt;Bigtable&lt;/a&gt; — that page carries the design,
the delivery guarantees and the error handling; this one carries the DDL surface. Per-feature
status is in the module README.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;sink.parallelism&lt;/code&gt; and &lt;code&gt;scan.parallelism&lt;/code&gt; come from Flink&amp;rsquo;s own &lt;code&gt;FactoryUtil&lt;/code&gt; rather than from this
connector.
Bounded scans and sinks have no format option: a Bigtable row is a schema this DDL describes, cell
by cell, and the cell encoding is the HBase ecosystem&amp;rsquo;s rather than a choice.
The selected-cell Change Streams mode is the exception because one cell holds a serialized logical
row and &lt;code&gt;value.format&lt;/code&gt; decodes it.&lt;/p&gt;</description></item><item><title>Bigtable</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/bigtable/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/bigtable/</guid><description>&lt;h1 id="bigtable-examples"&gt;Bigtable examples&lt;a class="anchor" href="#bigtable-examples"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigtable/"&gt;Bigtable quickstart&lt;/a&gt; owns the basic source and sink jobs.
The cases below change one direction or compose it with another connector.&lt;/p&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable-functions/"&gt;async SQL functions&lt;/a&gt; return
conditional outcomes and changed cells to Flink 2.x streaming queries, with SQL-only registration
and named request settings.&lt;/p&gt;
&lt;h2 id="datastream-source"&gt;DataStream source&lt;a class="anchor" href="#datastream-source"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigtable/#read-a-table-back"&gt;Quickstart read job&lt;/a&gt; is the canonical bounded source example.
The worked cases below narrow its rows, filter its cells, or route it through another application profile.&lt;/p&gt;</description></item><item><title>Bigtable</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigtable/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/bigtable/</guid><description>&lt;h1 id="write-to-and-read-from-a-bigtable-table"&gt;Write to and read from a Bigtable table&lt;a class="anchor" href="#write-to-and-read-from-a-bigtable-table"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Assumes the artifacts and credentials from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; index, and the imports an IDE resolves from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/api/java/"&gt;Java API reference&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The examples use application-default credentials.
If a deployment cannot supply the intended identity through ADC, add
&lt;code&gt;serviceAccountKeyFile(&amp;quot;/mounted/path/key.json&amp;quot;)&lt;/code&gt; to either builder.
The path is read when the job&amp;rsquo;s runtime components start and must be mounted at the same absolute
path on every eligible TaskManager and, for either source, the JobManager.
Prefer an attached service account or Workload Identity over a long-lived key; the operational
requirements are in &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/#credential-file-deployment"&gt;Credential file deployment&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Bigtable</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigtable/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigtable/</guid><description>&lt;h1 id="bigtable-options"&gt;Bigtable options&lt;a class="anchor" href="#bigtable-options"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Every option the Bigtable sink and source take. What each one is &lt;em&gt;for&lt;/em&gt; is on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/"&gt;Bigtable connector&lt;/a&gt; page; the three forms of
the Default column are explained &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/#what-a-default-means"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The &lt;code&gt;WITH&lt;/code&gt; options of the &lt;code&gt;bigtable&lt;/code&gt; table connector are a separate surface, documented on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable/"&gt;Bigtable SQL connector&lt;/a&gt; page.&lt;/p&gt;
&lt;p&gt;One thing this reference does not list, because it is not an option here. &lt;strong&gt;There are no retry
knobs&lt;/strong&gt;: the client retries &lt;code&gt;MutateRows&lt;/code&gt; per entry on a schedule of its own, so the sink owns no
retry loop — the opposite of the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/cloudtasks/"&gt;Cloud Tasks&lt;/a&gt; sink, and
the reasoning is under
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/#retries-belong-to-the-client"&gt;Retries&lt;/a&gt;. The
&lt;code&gt;recovery*&lt;/code&gt; knobs below are not an exception: they budget the sink-owned
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/#table-auto-creation"&gt;table auto-creation&lt;/a&gt;
repair, not the client&amp;rsquo;s mutation retries. The source owns no retry loop either: the client
resumes a broken &lt;code&gt;ReadRows&lt;/code&gt; stream from the last key it saw.&lt;/p&gt;</description></item><item><title>Bigtable async SQL functions</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable-functions/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable-functions/</guid><description>&lt;h1 id="bigtable-async-sql-functions"&gt;Bigtable async SQL functions&lt;a class="anchor" href="#bigtable-async-sql-functions"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;These functions return the result of one atomic Bigtable row operation to a SQL query.
&lt;code&gt;BigtableCheckAndMutateFunction&lt;/code&gt; returns whether its predicate matched.
&lt;code&gt;BigtableReadModifyWriteFunction&lt;/code&gt; returns the final cells changed by ordered append and increment rules.
Both are available in &lt;strong&gt;Flink 2.x streaming mode&lt;/strong&gt;, including bounded streaming queries.
The Flink 1.20 artifacts do not contain these classes; use the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/"&gt;DataStream request APIs&lt;/a&gt; when that version needs results.&lt;/p&gt;
&lt;p&gt;Put the matching &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable/#getting-the-connector-onto-the-classpath"&gt;&lt;code&gt;flink-sql-connector-gcp-bigtable&lt;/code&gt; jar&lt;/a&gt; on the SQL Client or SQL Gateway and cluster classpaths.
Register the function with &lt;code&gt;CREATE TEMPORARY SYSTEM FUNCTION&lt;/code&gt;, configure a named request through &lt;code&gt;SET&lt;/code&gt;, and call it in a query.
The SQL aliases below are chosen at registration.
Create the destination table, its families, and a single-cluster application profile with single-row transactions enabled before running the examples.
Authentication uses application-default credentials unless a key file is configured.&lt;/p&gt;</description></item><item><title>Lineage</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/lineage/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/lineage/</guid><description>&lt;h1 id="lineage"&gt;Lineage&lt;a class="anchor" href="#lineage"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The shared lineage contract describes the physical resources known from a connector&amp;rsquo;s configuration.
It does not discover resources at runtime or infer them by inspecting records.
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigquery/#lineage"&gt;BigQuery DataStream&lt;/a&gt; and &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigquery/#lineage"&gt;Table/SQL&lt;/a&gt; implement this contract for configured table inputs and fixed outputs, including explicitly named view materialization and default-stream CDC.
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/bigtable/#lineage"&gt;Bigtable DataStream&lt;/a&gt; and &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/bigtable/#lineage"&gt;Table/SQL&lt;/a&gt; implement configured-table lineage for scans, Change Streams and all sink write modes.
Connector adoption remains tracked separately for &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/1271"&gt;Pub/Sub&lt;/a&gt;, &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/1273"&gt;Spanner&lt;/a&gt;, and &lt;a href="https://github.com/flink-gcp/flink-connector-gcp/issues/1274"&gt;Cloud Tasks&lt;/a&gt;.
The common graph and listener tests establish the shared contract.
Pub/Sub and Bigtable also test extraction against their builder-returned Source/Sink objects and SQL planners.
Pub/Sub covers multiple subscriptions and ordering-key routing; Bigtable covers scans, bounded and unbounded Change Streams, and every Table write mode.
Spanner implements the contract for the paths documented in its &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/"&gt;DataStream&lt;/a&gt; and &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/spanner/"&gt;Table&lt;/a&gt; references.
The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/cloudtasks/#lineage"&gt;Cloud Tasks guide&lt;/a&gt; describes its fixed-queue coverage for DataStream and Table/SQL; its connector tests exercise the builder-returned sink, listener delivery and planner facets.&lt;/p&gt;</description></item><item><title>Spanner</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/</guid><description>&lt;h1 id="spanner-connector"&gt;Spanner connector&lt;a class="anchor" href="#spanner-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;An at-least-once sink applies one Spanner &lt;code&gt;Mutation&lt;/code&gt; per record.
The module also provides a bounded snapshot source and an unbounded Change Streams source.
Both dialects, GoogleSQL and PostgreSQL, are supported from the same code; the dialect is a property of the database rather than a builder option.&lt;/p&gt;
&lt;p&gt;Every option is listed on the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/spanner/"&gt;Spanner options&lt;/a&gt; page.&lt;/p&gt;
&lt;h2 id="credentials"&gt;Credentials&lt;a class="anchor" href="#credentials"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The bounded source, Change Streams source, and sink use Application Default Credentials when neither &lt;code&gt;serviceAccountKeyFile(...)&lt;/code&gt; nor &lt;code&gt;emulatorEndpoint(...)&lt;/code&gt; is set.
Set it only when the job must select a service-account JSON key that the runtime environment cannot supply through ADC.&lt;/p&gt;</description></item><item><title>Spanner</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/spanner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/table/spanner/</guid><description>&lt;h1 id="spanner-sql-connector"&gt;Spanner SQL connector&lt;a class="anchor" href="#spanner-sql-connector"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The &lt;code&gt;spanner&lt;/code&gt; connector reads bounded Table API and SQL scans, emits unbounded Change Streams changelogs, serves primary-key lookup joins, and writes rows through &lt;code&gt;flink-connector-gcp-spanner&lt;/code&gt;.
It maps onto the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/"&gt;DataStream source and sink&lt;/a&gt;, so partitioning, snapshot, batching, retry, delivery, metrics, and failure behavior remain the same.&lt;/p&gt;

&lt;span hidden data-sql-snippet-file="flink/SpannerTableReference.sql" data-sql-snippet-tag="overview"&gt;&lt;/span&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;CREATE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;TABLE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;orders&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;order_id&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;BIGINT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;customer&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;STRING&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;total&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;DECIMAL&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;38&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;9&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;updated_at&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;TIMESTAMP_LTZ&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;9&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;PRIMARY&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;KEY&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;order_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;NOT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;ENFORCED&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;WITH&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;connector&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;spanner&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;project&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;my-project&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;instance&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;my-instance&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;database&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;orders-db&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;table&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;orders&amp;#39;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;INSERT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;INTO&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;orders&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;order_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;customer&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;total&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;updated_at&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;staged_orders&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;customer&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;total&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;orders&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Use &lt;code&gt;flink-sql-connector-gcp-spanner&lt;/code&gt;, the relocated SQL uber-jar, for SQL deployments.
Place &lt;code&gt;flink-sql-connector-gcp-spanner-&amp;lt;version&amp;gt;.jar&lt;/code&gt; in Flink&amp;rsquo;s &lt;code&gt;lib/&lt;/code&gt; before starting the cluster,
or load it for one SQL Client session:&lt;/p&gt;</description></item><item><title>Spanner</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/spanner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/examples/spanner/</guid><description>&lt;h1 id="spanner-examples"&gt;Spanner examples&lt;a class="anchor" href="#spanner-examples"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Worked cases beyond the &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/spanner/"&gt;quickstart&lt;/a&gt; follow the shared source-to-sink order.
The &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/spanner/"&gt;Spanner options&lt;/a&gt; page lists every option, while the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/"&gt;Spanner connector&lt;/a&gt; page explains the runtime
contracts behind them.&lt;/p&gt;
&lt;h2 id="datastream-source"&gt;DataStream source&lt;a class="anchor" href="#datastream-source"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The quickstart owns the basic &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/spanner/#read-the-table-back-into-flink"&gt;bounded DataStream read&lt;/a&gt;.
The cases below change its read shape, snapshot, compute placement, or row handling.&lt;/p&gt;
&lt;h3 id="reading-a-key-range-instead-of-a-query"&gt;Reading a key range instead of a query&lt;a class="anchor" href="#reading-a-key-range-instead-of-a-query"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;A table read takes a key set and a column list, and is the cheapest shape when the rows wanted are
a contiguous range of the primary key. There is no SQL to be root-partitionable, so nothing about
the read can be refused for being undistributable.&lt;/p&gt;</description></item><item><title>Spanner</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/spanner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/spanner/</guid><description>&lt;h1 id="write-a-stream-into-a-spanner-table"&gt;Write a stream into a Spanner table&lt;a class="anchor" href="#write-a-stream-into-a-spanner-table"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Assumes the artifacts and credentials from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/quickstart/"&gt;Quickstart&lt;/a&gt; index, and the imports an IDE resolves from the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/api/java/"&gt;Java API reference&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Create the instance, database and table first.&lt;/strong&gt; The sink creates none of them — a missing table
fails every record alike, so it is a configuration error rather than something a sink can repair.&lt;/p&gt;


&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sh" data-lang="sh"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;gcloud spanner instances create my-instance &lt;span class="se"&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt; --config&lt;span class="o"&gt;=&lt;/span&gt;regional-asia-northeast1 --description&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;my-instance&amp;#34;&lt;/span&gt; --nodes&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;gcloud spanner databases create orders-db --instance&lt;span class="o"&gt;=&lt;/span&gt;my-instance &lt;span class="se"&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt; --ddl&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;CREATE TABLE Orders (OrderId STRING(64) NOT NULL, Total INT64) PRIMARY KEY (OrderId)&amp;#39;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;StreamExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;getExecutionEnvironment&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;setRuntimeMode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;RuntimeExecutionMode&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;STREAMING&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="c1"&gt;// Not optional: the sink is at-least-once only with checkpointing, which is what makes&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="c1"&gt;// Flink wait for the batch to be applied before the barrier passes.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;enableCheckpointing&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;60_000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;fromData&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;a-1&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;a-2&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;sinkTo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;SpannerSink&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;String&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="n"&gt;builder&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;database&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;DatabaseDestination&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;of&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-project&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;my-instance&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#34;orders-db&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;serializer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;element&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// insertOrUpdate, not insert: the sink is&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// at-least-once and Spanner&amp;#39;s batch write has no&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// replay protection, so a record can arrive twice.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// An upsert makes that a no-op; an insert makes it&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="c1"&gt;// a routed failure.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Mutation&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;newInsertOrUpdateBuilder&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;Orders&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;set&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;OrderId&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;to&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;order#&amp;#34;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;+&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;element&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;set&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;Total&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;to&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;element&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;length&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="na"&gt;execute&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;&amp;#34;spanner-quickstart&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Read the rows back:&lt;/p&gt;</description></item><item><title>Spanner</title><link>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/spanner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/spanner/</guid><description>&lt;h1 id="spanner-options"&gt;Spanner options&lt;a class="anchor" href="#spanner-options"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Every option the Spanner sink and source take. What each one is &lt;em&gt;for&lt;/em&gt; is on the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/"&gt;Spanner connector&lt;/a&gt; page; the three forms of
the Default column are explained &lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/#what-a-default-means"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;This sink&amp;rsquo;s recovery knobs budget the write retry loop itself, unlike the
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/reference/bigtable/"&gt;Bigtable&lt;/a&gt; recovery knobs, which budget only table
auto-creation repair.
They are not decoration: the Spanner client library does not retry the batch write RPC at all, so
the sink owns the whole retry loop.
See
&lt;a href="https://flink-gcp.github.io/flink-connector-gcp/1.1/docs/connectors/datastream/spanner/#retries-belong-to-the-sink"&gt;Retries&lt;/a&gt;.&lt;/p&gt;</description></item></channel></rss>