rabbitmq / rabbitmq-jms-client

RabbitMQ JMS client
Other
63 stars 49 forks source link

Add pluggable conversion strategy on message consumption #71

Open acogoluegnes opened 5 years ago

acogoluegnes commented 5 years ago

Right now the conversion from the native AMQP message to a JMS message is hardcoded, which is not great for interoperability. JMS "AMQP" destinations provide some interoperability, but are limited to JMS queues. So there's currently no way that some JMS subscribers can consume messages published by non-JMS clients.

This could be implemented as chain of responsibility, the current behavior being the default and usually last part when custom steps are added. An application developer should typically only focus on the payload, so helpers e.g. to deal with headers conversion should be provided.

Original mailing-list thread: https://groups.google.com/d/msg/rabbitmq-users/Zbcp9WL-vUM/X_M_UuurAgAJ

dmitry027 commented 5 years ago

Faced the same issue when trying to establish interaction between PHP (php-amqplib) and JMS clients.

NawazAliShaik commented 2 years ago

Could you please let me know how to consume the message from a queue with JMS client and the producer is non-JMS? When we create the JNDI file and consume , we are receiving junk characters in message payload which is causing the erros.

acogoluegnes commented 2 years ago

Can you use the mailing list or start a discussion? GitHub issues are for actionable items, not support. Please provide more information on your problem, like code samples to reproduce.

There's this test that maps to your use case from my understanding.

fallensieg commented 7 months ago

Facing this issue at the moment. Publisher is a .net client and the consumer uses JMS.

michaelklishin commented 7 months ago

@fallensieg you are welcome to contribute a draft (or maybe even a production version) of what such a "pluggable converter" might look like. This is open source software after all.