Using RocksDB Merge Operator in FlinkSQL to Improve the Performance of the Join Operator
Scenario
In FlinkSQL jobs that use the RocksDB state backend, the Join operator with NoUniqueKey needs to read the old value and then write the new value when updating the state. This causes a large amount of read amplification overhead, which deteriorates the performance of the Join operator. After this feature is enabled, the Join operator can directly update the state through the merge operation, improving the computing performance of the Join operator.
Notes and Constraints
- This feature works only when the RocksDB state backend is used.
- Snapshots generated before and after this feature is enabled are incompatible.
Usage
You can use either of the following methods to set table.exec.join.use-merge-operator to true to enable the MergeOperator feature:
- Method 1: When configuring a Flink job, add this custom parameter to the flink_config parameter of the job.
- Method 2: Add this custom parameter to the Flink parameters of the endpoint.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot