Description
Summary: Struct value validation in Kafka Connect can be optimized to avoid creating an Iterator when the expectedClasses list is of size 1. This is a meaningful enhancement for high throughput connectors.
Stack Trace from the Couchbase Kafka Connector:
- java.util.Collections.singletonIterator(Object)
- java.util.Collections$SingletonList.iterator()
- org.apache.kafka.connect.data.ConnectSchema.validateValue(String, Schema, Object)
- org.apache.kafka.connect.data.Struct.put(Field, Object)
- org.apache.kafka.connect.data.Struct.put(String, Object)
- com.couchbase.connect.kafka.handler.source.DefaultSchemaSourceHandler.buildValue(SourceHandlerParams, CouchbaseSourceRecord$Builder)
Attachments
Issue Links
- links to