kafka-jira mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KAFKA-6513) New Connect header support doesn't define `converter.type` property correctly
Date Thu, 01 Feb 2018 23:47:00 GMT

    [ https://issues.apache.org/jira/browse/KAFKA-6513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16349517#comment-16349517
] 

ASF GitHub Bot commented on KAFKA-6513:
---------------------------------------

rhauch opened a new pull request #4512: KAFKA-6513: Corrected how Converters and HeaderConverters
are instantiated and configured
URL: https://github.com/apache/kafka/pull/4512
 
 
   The commits for KIP-145 (KAFKA-5142) changed how the Connect workers instantiate and configure
the Converters, and also added the ability to do the same for the new HeaderConverters. However,
the last few commits removed the default value for the `converter.type` property for Converters
and HeaderConverters, and this broke how the internal converters were being created.
   
   This change corrects the behavior so that the `converter.type` property is always set by
the worker (or by the Plugins class), which means the existing Converter implementations will
not have to do this. The built-in JsonConverter, ByteArrayConverter, and StringConverter also
implement HeaderConverter which implements Configurable, but the Worker and Plugins methods
do not yet use the `Configurable.configure(Map)` method and instead still use the `Converter.configure(Map,boolean)`.
   
   Several tests were modified, and a new PluginsTest was added to verify the new behavior
in Plugins for instantiating and configuring the Converter and HeaderConverter instances.
   
   ### Committer Checklist (excluded from commit message)
   - [ ] Verify design and implementation 
   - [ ] Verify test coverage and CI build status
   - [ ] Verify documentation (including upgrade notes)
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> New Connect header support doesn't define `converter.type` property correctly
> -----------------------------------------------------------------------------
>
>                 Key: KAFKA-6513
>                 URL: https://issues.apache.org/jira/browse/KAFKA-6513
>             Project: Kafka
>          Issue Type: Bug
>          Components: KafkaConnect
>    Affects Versions: 1.1.0
>            Reporter: Randall Hauch
>            Assignee: Randall Hauch
>            Priority: Blocker
>             Fix For: 1.1.0
>
>
> The recent feature (KAFKA-5142) added a new {{converter.type}} to make the {{Converter}}
implementations now implement {{Configurable}}. However, the worker is not correctly setting
these new property types and is instead incorrectly assuming the existing {{Converter}} implementations
will set them. For example:
> {noformat}
> Exception in thread "main" org.apache.kafka.common.config.ConfigException: Missing required
configuration "converter.type" which has no default value.
>         at org.apache.kafka.common.config.ConfigDef.parseValue(ConfigDef.java:472)
>         at org.apache.kafka.common.config.ConfigDef.parse(ConfigDef.java:462)
>         at org.apache.kafka.common.config.AbstractConfig.<init>(AbstractConfig.java:62)
>         at org.apache.kafka.connect.storage.ConverterConfig.<init>(ConverterConfig.java:48)
>         at org.apache.kafka.connect.json.JsonConverterConfig.<init>(JsonConverterConfig.java:59)
>         at org.apache.kafka.connect.json.JsonConverter.configure(JsonConverter.java:284)
>         at org.apache.kafka.connect.runtime.isolation.Plugins.newConfiguredPlugin(Plugins.java:77)
>         at org.apache.kafka.connect.runtime.isolation.Plugins.newConverter(Plugins.java:208)
>         at org.apache.kafka.connect.runtime.Worker.<init>(Worker.java:107)
>         at io.confluent.connect.replicator.ReplicatorApp.config(ReplicatorApp.java:104)
>         at io.confluent.connect.replicator.ReplicatorApp.main(ReplicatorApp.java:60)
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message