dennisylyung commented on pull request #12630:
URL: https://github.com/apache/beam/pull/12630#issuecomment-678101761


   @iemejia I have pushed a new commit implementing your suggestions.
   For the specific test, I edited the mock consumer in KafkaIOTest to generate 
records with a different schema. 
   I have verified the new deserializer provider by running the modified test 
on the original one
   ```java
     @Override
     public Deserializer<T> getDeserializer(Map<String, ?> configs, boolean 
isKey) {
       ImmutableMap<String, Object> csrConfig =
           ImmutableMap.<String, Object>builder()
               .putAll(configs)
               .put(AbstractKafkaAvroSerDeConfig.SCHEMA_REGISTRY_URL_CONFIG, 
schemaRegistryUrl)
               .build();
       Deserializer<T> deserializer =
           (Deserializer<T>) new 
KafkaAvroDeserializer(getSchemaRegistryClient());
   //            new 
ConfluentSchemaRegistryDeserializer(getSchemaRegistryClient(), getAvroSchema());
       deserializer.configure(csrConfig, isKey);
       return deserializer;
     }
   ```
   As expected, this will cause the test to fail


----------------------------------------------------------------
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]


Reply via email to