Giter Site home page Giter Site logo

lulzzz / hello-kafka-on-eventhubs-cs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from syedhassaanahmed/hello-kafka-on-eventhubs-cs

0.0 1.0 0.0 125 KB

Connecting to a Kafka-enabled Azure Event Hubs using Confluent's .NET Client

License: MIT License

C# 100.00%

hello-kafka-on-eventhubs-cs's Introduction

hello-kafka-on-eventhubs-cs

This repo demonstrates how to connect to a Kafka-enabled Azure Event Hubs using Confluent's .NET Client.

Caveat

This doc describes how to provide auth config for connecting a Java-based Kafka Producer/Consumer. However the setting sasl.jaas.config won't work with Confluent's .NET Client and will throw an exception:

Unhandled Exception: System.ArgumentException: Java JAAS configuration is not supported, see https://github.com/edenhill/librdkafka/wiki/Using-SASL-with-librdkafka for more information.

Solution

Instead of using sasl.jaas.config, use sasl.username and sasl.password. Furthermore on Windows, default trusted root CA certs are stored in Windows Registry. They're not automatically discovered by Confluent client. You'll need to obtain these from somewhere else, hence I've used the cacert.pem file distributed with curl, set its build setting to "Always copy to output directory" and reference it in the ssl.ca.location.

Reference

ConfluentCloud's C# example

hello-kafka-on-eventhubs-cs's People

Contributors

syedhassaanahmed avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.