Skip to content

v0.3.0

Compare
Choose a tag to compare
@sixstone-qq sixstone-qq released this 19 Nov 12:02
· 13 commits to master since this release
5423271
  • Fetch from upstream latest changes #36
  • Upgrade dependencies and give support from go v1.15 onwards #41
  • New feature: Produce Avro formatted messages #38 #39 #40

Avro formatted messages production

  1. Using latest version available using TopicNameStrategy to know the schema subject to use:
# subject: "actors-value"
echo '{"value": {"FirstName": "Ryan"}, "key": "id-42"}' | hkt produce -topic actors -registry http://localhost:8081 -valuecodec avro
  1. Using latest version available using TopicRecordNameStrategy to know the schema subject to use:
# subject: "actors-record"
echo '{"value": {"FirstName": "Ryan"}, "key": "id-42"}' | hkt produce -topic actors -registry http://localhost:8081 -valuecodec avro -value-avro-record-name record
  1. Using schema provided in -value-avro-schema-file parameter:
echo '{"value": {"FirstName": "Ryan"}, "key": "id-42"}' | hkt produce -topic actors -registry http://localhost:8081 -valuecodec avro -value-avro-schema-file file.avsc
  1. Using schema unique identifier provided in -value-avro-schema-id parameter:
echo '{"value": {"FirstName": "Ryan"}, "key": "id-42"}' | hkt produce -topic actors -registry http://localhost:8081 -valuecodec avro -value-avro-schema-id 100