Jackdaw
A high-performance Kafka client written in managed C#.
Jackdaw aims to be API-compatible with the official Confluent Kafka library, so that any migration to Jackdaw should be seamless, even down to the config settings used.
Jackdaw aims to be:
- ๐ High-performance with low memory usage
- ๐ง Extensible for use cases such as AWS IAM authentication
- ๐ค Cross-platform using fully managed code
- โ API-compliant to the official Confluent Kafka library
Usage
Install the package from NuGet with dotnet add package Jackdaw.
Create your producer and/or consumer with the correct settings, and publish/subscribe to the topics you need, as below:
var producerConfig = new ProducerConfig
{
BootstrapServers = "localhost:9092"
};
var consumerConfig = new ConsumerConfig
{
BootstrapServers = "localhost:9092",
GroupId = "my-group"
};
using var producer = new ProducerBuilder<string, string>(producerConfig)
.Build();
using var consumer = new ConsumerBuilder<string, string>(consumerConfig)
.Build();
producer.Produce("my-topic", new Message<string, string>
{
Key = "key", Value = "value"
});
consumer.Subscribe("my-topic");
var result = consumer.Consume();Documentation
See the wiki for examples and help using Jackdaw.
Get in touch
Discuss with us on Discussions, or raise an issue.
Contributing
Please read CONTRIBUTING.md for details on how to contribute to this project.
Acknowledgements
With much โค๏ธ to the Confluent Kafka library.
License
Jackdaw is released under the Apache 2.0 License