bencebalogh / avro-schema-registry

Confluent Schema Registry implementation in javascript to easily serialize and deserialize kafka messages
MIT License
28 stars 30 forks source link

FEATURE REQUEST: add getSchemaByTopicRecordName and getSchemaByRecordName #28

Open baileywall opened 4 years ago

baileywall commented 4 years ago

The Confluent Schema Registry supports registering different types of events for one topic (blog post: https://www.confluent.io/blog/put-several-event-types-kafka-topic/ and pull request: confluentinc/schema-registry#680 and https://docs.confluent.io/current/schema-registry/serializer-formatter.html) by supporting three different subject naming strategies (for key and value):

io.confluent.kafka.serializers.subject.TopicNameStrategy io.confluent.kafka.serializers.subject.RecordNameStrategy io.confluent.kafka.serializers.subject.TopicRecordNameStrategy

This library currently has a getSchemaByTopicName function, but that doesn't support either the RecordNameStrategy or the TopicRecordNameStrategy. Are there any plans to add something similar to getSchemaByTopicName, but for these other strategies?

Thanks!

bencebalogh commented 4 years ago

I'll look into this soon, thanks for the suggestion

flqw commented 4 years ago

I started a pull request that adds the necessary functions #31