eclipse-hono / hono

Eclipse Hono™ Project
https://eclipse.dev/hono
Eclipse Public License 2.0
450 stars 137 forks source link

[Feature] Support RabbitMQ messaging #2511

Closed rpahli closed 1 year ago

rpahli commented 3 years ago

Hello guys,

I currently use hono in version 1.0 and have replaced the AMQP messaging infrastucture with rabbitMQ and AMQP 0.9.1. I currently work on migrating to the newest hono version and want to ask if you are intrested in the rabbitmq integration. If so I would be happy to prepare the PR for the integration.

sophokles73 commented 3 years ago

Hi, thanks a lot for the offer :-) I am no expert in AMQP 0.9.1, so I wonder if the north bound interface for clients is identical to the one for using AMQP 1.0?

rpahli commented 3 years ago

Hello @sophokles73 ,

no both protocols are different on client and server and therefore incompatible.

sophokles73 commented 3 years ago

I see. I guess you needed to add a new Rabbit based implementation of the clients module's interfaces then in order for the protocol adapters to be able to connect to RabbitMQ, right?

rpahli commented 3 years ago

Yes I started using the kafka adapters as a base. I already have a first working solution.

sophokles73 commented 3 years ago

You mean the code under clients/adapter-kafka? Do you also intend to support the Command & Control direction via RabbitMQ?

rpahli commented 3 years ago

Yes that's the code. Yes the plan is to support also Command & Control. But I'll provide this in a separate PR.

sophokles73 commented 3 years ago

Ok, in general, I think we could support using RabbitMQ in the same (configurable) way that we now support AMQP 1.0 and Kafka, i.e. as a third option to be set on the tenant or by means of configuration of the downstream messaging. I am (currently) not aware of anybody else who wants to use RabbitMQ for this but that might simply be due to my ignorance ;-)

In any case, I believe that we can only add the code to the repository if there is some kind of commitment from your side to maintain that code in the foreseeable future in order to keep it up to date and in shape. If that is not possible for you, we could also think about adding the code to the hono-extras repository instead, which does not have the same requirements regarding code maturity and quality as our main repo does. WDYT?

@calohmn @dejanb @ctron @kaniyan any additional thoughts from your side?

rpahli commented 3 years ago

Yes I'm able to maintain the code for the RabbitMQ part. So if the initial integration is finished you can add me as a maintainer for this part of the code. :-)

kaniyan commented 3 years ago

Currently we support AMQP 1.0 and Kafka support is in progress. In the process to support Kafka, we have refactored our APIs to be protocol agnostic and also configurable at tenant level to choose protocols for downstream messaging, thereby providing more flexibility for Hono to support more messaging systems/protocols. Considering this, I find it good also to have AMQP 0.9.1 support in Hono.

I am not an expert in AMQP 0.9.1 and from what I read, it seems that AMQP 0.9.1 has more client implementations than AMQP 1.0. Also there is a Vert.x based RabbitMQ client and @rpahli I think you are already using it for your implementation.

rpahli commented 3 years ago

Also there is a Vert.x based RabbitMQ client and @rpahli I think you are already using it for your implementation.

Yes this is the client I'm using.

sophokles73 commented 3 years ago

Looks like we all agree.

@rpahli we look forward to your contribution :-)

b-abel commented 3 years ago

@rpahli Please notice my PR #2525 where I tried to make the addition of a new messaging system easier.

sophokles73 commented 2 years ago

@rpahli is this still an issue, i.e. are you working on this or can we close this?

mscheibler commented 2 years ago

@sophokles73 Greetings! This is still an issue, but we had to postpone our work on it as we had other more pressing issues. We are currently evaluating whether it is possible to switch to AMQP1.0 in our infrastructure. Depending on the outcome we will either start working on this issue or it becomes obsolete.

sophokles73 commented 2 years ago

As you may have noticed, we have put the focus on using Kafka as the messaging infrastructure during the last year. Maybe that is an option for you as well?

sophokles73 commented 1 year ago

@mscheibler @rpahli can we close this issue?

rpahli commented 1 year ago

@sophokles73 we switched to kafka so I think you can close the issue for now.