-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Node.js payload #14
Comments
There is in fact some weirdness with the content (using node example:
payload:
decoded payload:
i am guessing it's a problem with this method:
but i might be wrong.
but that is pure speculation. maybe you could try to run the sbemu-node docker projects and POST to the cheers |
Hey guys, The problem seems to be related to the message batching not being supported by the emulator atm. When batching is enabled, multiple messages are serialized and wrapped by an outer message. Emulator recognizes only the outer message but does not understand its inner body containing the actual message, and forwards as-is to rabbitmq. A quick workaround is to send a single message, not an array, by changing
to
Note that the example given by @confuser seems to already pass a single message, but since it is typed, might be following a "batched" code path on nodejs sdk side. On the other hand the code snippet given by @rafak works fine after removing Going forward, I will try to find a way to handle this in the emulator. I just need to figure out how to access a MessageFormat field, which indicates that we are dealing with a batch. TBC /Piotr |
ok i will try to work with single messages, thanks |
i can confirm that single messages work and all is good, i will put in the links in case they become somehow useful. |
@piotr-rojek tried the new version and no longer getting the timeout issue described in #9 🥳
However a new issue cropped up. We're sending messages with a JSON payload with nodejs and receiving them with nodejs via the Azure SDK.
Example code:
However, using the emulator the body is in a different format,
Sp�@@@Sr�+�x-opt-partition-key�questionnaire-V1SsESu��{"questionId":"fbf1ccfe-c544-4125-9e42-2e09b0d26a64","answerId":"51abac65-e201-402b-8b5a-09186a0fbdea","value":"","userId":"290c1ead-c95b-4559-969e-851be85689a6","version":"1.0","createdOn":"2023-04-19T13:20:27.718Z"}
as an example.Seems to be the exact problem described in https://www.bfcamara.com/post/84113031238/send-a-message-to-an-azure-service-bus-queue-with
The text was updated successfully, but these errors were encountered: