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

Types and the interface #18

Closed iangregsondev closed 5 years ago

iangregsondev commented 5 years ago

Hey,

I noticed you added types! This is great. I notice the Interface isn't being exported though.

As the constructor returns it, I would like to import the Interface for dependency injection.

iangregsondev commented 5 years ago
  constructor(private loggerFactory: LoggerFactory, @inject(AvroSchemaRegistrySymbol) private registry: any) {

I don't have access to the interface

interface ISchemaRegistry {
  decode: DecodeMessage;
  decodeMessage: DecodeMessage;
  encodeById: (schemaId: string, msg: any, parseOptions?: any) => Promise<any>;
  encodeKey: EncodeMessage;
  encodeMessage: EncodeMessage;
}
bencebalogh commented 5 years ago

I've changed the exports in 1.4.1