Is Kafka property partition.assignment.strategy works with Flink Table API

44 Views Asked by At

Flink Table API allows us to set and pass arbitrary Kafka configurations (doc). I wanted to test kafka property 'partition.assignment.strategy' but I can't see any difference between the versions with it and without. There is no difference between strategies I set either.

So my question is this property functional in Flink Table API or maybe it's overridden by default value ?

I'm using Flink 1.14.5

My code:

tEnv.executeSql(
  s"""
     |CREATE TABLE $tableName ($schema) WITH (
     | 'connector' = 'kafka',
     | 'topic' = '$topicName',
     | 'properties.bootstrap.servers' = '${jobArgs("bootstrap.servers")}',
     | 'properties.group.id' = '${jobArgs("group.id")}',
     | 'properties.auto.offset.reset' = 'latest',
     | 'properties.partition.assignment.strategy' = 'org.apache.kafka.clients.consumer.CooperativeStickyAssignor',
     | 'scan.startup.mode' = '$offsets',
     | 'format' = 'csv',
     | 'csv.ignore-parse-errors' = 'true',
     | 'csv.field-delimiter' = '$separator'
     |)
     |""".stripMargin
)
0

There are 0 best solutions below