2

I am studying the possibility to use Kafka with Masstransit on our Information System. Masstransit documentation says Kafka may be used but as a Rider; As the usage of a transport is mandatory we must use another tool (as ActiveMQ, RabbitMQ) in addition of Kafka with Masstransit.

What does transport do that can not be done by Kafka, that prevent exclusive usage of Kafka?

  • How is this different from your previous post? – OneCricketeer Aug 25 '21 at 12:40
  • @OneCricketeer, in this post i assume my precedent question was too vague, so i focus on masstransit, not on Saga globally; but if you asked me this question this sounds you understood what was my problem. Sorry for precision lack, but is not easy to deal with a problem that is not clearly identified – user1958187 Aug 25 '21 at 12:53

1 Answers1

3

MassTransit is designed with publish-subscribe with competing consumers in mind, which is the default pattern when using a message broker.

Riders were introduced, as mentioned in the docs, as a gateway between event streaming and pub-sub. So, the main purpose of riders is to support the scenario when you need to consume a message from a rider and publish it to the bus. Even producers are optional for riders, and they are implementation-specific. As event streaming infrastructure like Kafka doesn't even support competing consumers, it makes little sense to make something like Kafka transport, as it introduces a heavy impedance mismatch between MassTransit concepts and what Kafka does.

You can still only use Kafka with MassTransit, but you'd need to use the in-memory transport to configure and start the bus.

Alexey Zimarev
  • 17,944
  • 2
  • 55
  • 83