qingdao81 commented on a change in pull request #15808:
URL: https://github.com/apache/flink/pull/15808#discussion_r645520286
##########
File path:
flink-formats/flink-avro-confluent-registry/src/main/java/org/apache/flink/formats/avro/registry/confluent/RegistryAvroOptions.java
##########
@@ -37,4 +37,40 @@ private RegistryAvroOptions() {}
.noDefaultValue()
.withDescription(
"Subject name to write to the Schema Registry
service, required for sink");
+
+ public static final ConfigOption<String>
SCHEMA_REGISTRY_SSL_KEYSTORE_LOCATION =
+ ConfigOptions.key("schema-registry.keystore.location")
+ .stringType()
+ .noDefaultValue()
+ .withDescription("Location / File of SSL keystore");
+
+ public static final ConfigOption<String>
SCHEMA_REGISTRY_SSL_KEYSTORE_PASSWORD =
+ ConfigOptions.key("schema-registry.keystore.password")
+ .stringType()
+ .noDefaultValue()
+ .withDescription("Password for SSL keystore");
+
+ public static final ConfigOption<String>
SCHEMA_REGISTRY_SSL_TRUSTSTORE_LOCATION =
+ ConfigOptions.key("schema-registry.truststore.location")
+ .stringType()
+ .noDefaultValue()
+ .withDescription("Location / File of SSL truststore");
+
+ public static final ConfigOption<String>
SCHEMA_REGISTRY_SSL_TRUSTSTORE_PASSWORD =
+ ConfigOptions.key("schema-registry.truststore.password")
+ .stringType()
+ .noDefaultValue()
+ .withDescription("Password for SSL truststore");
+
+ public static final ConfigOption<String>
SCHEMA_REGISTRY_BASIC_AUTH_CREDENTIALS_SOURCE =
+ ConfigOptions.key("schema-registry.basic.auth.credentials.source")
Review comment:
These properties are forwarded to the confluent `RestService` which
expects a `.` notation.
[SchemaRegistryClientConfig](https://github.com/confluentinc/schema-registry/blob/master/client/src/main/java/io/confluent/kafka/schemaregistry/client/SchemaRegistryClientConfig.java#L25)
That is even true for `schema-registry`. I think for the 2 already existing
properties `schema-registry.url` and `schema-registry.subject` this doesn't
matter because they are treated in a different way. (they are parsed and then
used for confluent api calls)
To my understanding for the additional properties it will only work if we
forward for example `schema.registry.basic.auth.credentials.source` to the
confluent api. If we use the grouping notation the properties will not match
anymore and will be ignored.
If Flink should work with the dot and slash separation for hierarchies I had
to transform the input back to pure dot notation at some point before
delegating it to the confluent api.
At least this is my understanding but maybe I'm missing something?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]