Skip to content

CLI tool for consuming and producing Avro messages on Kafka.

Notifications You must be signed in to change notification settings

fyndiq/avrocat

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Avrocat

CLI tool for consuming and producing Avro messages from Kafka.

Installation

pip install -e .

Usage

Consume all messages

avrocat consume -t <topic> -b <broker> -r <schema_registry>

Consume messages with given key

avrocat consume -t <topic> -b <broker> -r <schema_registry> -k <key> -P <num_partitions>

Produce message

cat << EOF > CreateFoo.json
{
    "class": "CreateFoo",
    "data": {
        "id": "12345",
        "foo": "foo"
    }
}
EOF

cat CreateFoo.json | avrocat produce -t <topic> -n <num_messages>

Validate JSON against schema

avrocat validate -t <topic> -f CreateFoo.json

About

CLI tool for consuming and producing Avro messages on Kafka.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%