0

I'm using RabbitMQ with NServiceBus. I send message to some queue where a third party service reads it.

It turned out that service requires encoding_type property set to utf-8 which I cannot set through NServiceBus (or can I?).

I wonder if there is a possibillity to access IBasicProperties of RabbitMQ client when I sending message.

Getting a property object in Behavior handlers unfortunately doesn't work.

burnsi
  • 6,194
  • 13
  • 17
  • 27

1 Answers1

1

If you're referring to the headers of a message, you can: https://docs.particular.net/nservicebus/messaging/headers

Dennis van der Stelt
  • 2,203
  • 16
  • 22
  • Unfortunatelly setting message header doesn't solve the problem. Encoding_type should be set directly in message properties. – Nikita Kondratev Jul 04 '22 at 13:30
  • What I understand from the code on RabbitMQ website itself, is that we add headers to the message properties like anyone should. So I would not know how to do it any other way? https://www.rabbitmq.com/tutorials/tutorial-two-dotnet.html – Dennis van der Stelt Jul 05 '22 at 15:04