[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["很难理解","hardToUnderstand","thumb-down"],["信息或示例代码不正确","incorrectInformationOrSampleCode","thumb-down"],["没有我需要的信息/示例","missingTheInformationSamplesINeed","thumb-down"],["翻译问题","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-09-04。"],[[["\u003cp\u003eThe Flink Bigtable connector enables real-time streaming, serialization, and writing of data from a specified data source to a Bigtable table using either the Apache Flink Table API or the Datastream API.\u003c/p\u003e\n"],["\u003cp\u003eTo use the connector, a pre-existing Bigtable table with predefined column families is required as the data sink.\u003c/p\u003e\n"],["\u003cp\u003eThe connector offers three built-in serializers for converting data into Bigtable mutation entries: \u003ccode\u003eGenericRecordToRowMutationSerializer\u003c/code\u003e, \u003ccode\u003eRowDataToRowMutationSerializer\u003c/code\u003e, and \u003ccode\u003eFunctionRowMutationSerializer\u003c/code\u003e, with the option for custom serializers as well.\u003c/p\u003e\n"],["\u003cp\u003eThere are two serialization modes available, column family mode, where all data is written to a single column family, and nested-rows mode, where each top-level field represents a column family.\u003c/p\u003e\n"],["\u003cp\u003eWhen using Bigtable as a data sink with the connector, exactly-once processing behavior is achieved automatically due to Bigtable's idempotent \u003ccode\u003emutateRow\u003c/code\u003e mutation, provided timestamps aren't changed on retries and the pipeline satisfies exactly-once semantics.\u003c/p\u003e\n"]]],[],null,["Flink Bigtable connector\n\nApache Flink is a stream-processing framework that lets you manipulate data in\nreal time. If you have a Bigtable table, you can use a *Flink\nBigtable connector* to stream, serialize, and write data from your\nspecified data source to Bigtable. The connector lets you do the\nfollowing, using either the Apache Flink Table API or the Datastream API:\n\n1. Create a pipeline\n2. Serialize the values from your data source into Bigtable mutation entries\n3. Write those entries to your Bigtable table\n\nThis document describes the Flink Bigtable connector and what you\nneed to know before you use it. Before you read this document, you should be\nfamiliar with\n[Apache Flink](https://nightlies.apache.org/flink/flink-docs-master/),\nthe\n[Bigtable storage model](/bigtable/docs/overview#storage-model), and\n[Bigtable writes](/bigtable/docs/writes).\n\nTo use the connector, you must have a pre-existing Bigtable table\nto serve as your data sink. You must create the table's column families before\nyou start the pipeline; column families can't be created on write. For more\ninformation, see\n[Create and manage tables](/bigtable/docs/managing-tables).\n\nThe connector is available on GitHub. For information about installing the\nconnector, see the\n[Flink Bigtable Connector](https://github.com/google/flink-connector-gcp/blob/main/connectors/bigtable/README.md)\nrepository. For code samples that demonstrate how to use the connector, see the\n[flink-examples-gcp-bigtable](https://github.com/google/flink-connector-gcp/tree/main/connectors/bigtable/flink-examples-gcp-bigtable)\ndirectory.\n\nSerializers\n\nThe Flink connector has three built-in serializers that you can use to convert\ndata into Bigtable mutation entries:\n\n- `GenericRecordToRowMutationSerializer`: For AVRO `GenericRecord` objects\n- `RowDataToRowMutationSerializer`: For Flink `RowData` objects\n- `FunctionRowMutationSerializer`: For custom serialization logic using a provided function\n\nYou can also choose to create your own custom serializer inheriting from\n`BaseRowMutationSerializer`.\n\nSerialization modes\n\nWhen you use the Flink connector, you choose one of two serialization modes. The\nmode specifies how your source data is serialized to represent your\nBigtable column families and then written your\nBigtable table. You must use either one mode or the other.\n\nColumn family mode\n\nIn column family mode, all data is written to a single specified column family.\nNested fields are not supported.\n\nNested-rows mode\n\nIn nested-rows mode, each top-level field represents a column family. The value\nof the top-level field (RowKeyField) is another field. The value of that field\nhas a row object for each column in the Bigtable column family. In\nnested rows mode, all fields other than the top-level field must be row objects.\nDouble-nested rows are not supported.\n\nExactly-once processing\n\nIn Apache Flink, *exactly once* means that each data record\nin a stream is processed exactly one time, preventing any duplicate processing\nor data loss, even in the event of system failures.\n\nA Bigtable `mutateRow` mutation is idempotent by default, so a\nwrite request that has the same row key, column family, column, timestamp, and\nvalue doesn't create a new cell, even if it's retried. This means that when you\nuse Bigtable as the data sink for an Apache Flink framework, you\nget exactly-once behavior automatically, as long as you don't change the\ntimestamp in retries and the rest of your pipeline also satisfies exactly-once\nrequirements.\n\nFor more information on exactly-once semantics, see\n[An overview of end-to-end exactly-once processing in Apache Flink](https://flink.apache.org/2018/02/28/an-overview-of-end-to-end-exactly-once-processing-in-apache-flink-with-apache-kafka-too/).\n\nWhat's next\n\n- [Bigtable Beam connector](/bigtable/docs/beam-connector)\n- [Bigtable Kafka Connect sink connector](/bigtable/docs/kafka-sink-connector)\n- [Integrations with Bigtable](/bigtable/docs/integrations)\n- [Datastream API reference](/datastream/docs/use-the-datastream-api)"]]