Skip to content
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

Receive function of consumer is removing blank spaces at the end of message #45

Closed
thejams opened this issue Feb 2, 2022 · 3 comments
Closed

Comments

@thejams
Copy link

thejams commented Feb 2, 2022

Hello, im currently making a produce / consumer application, and everything works fine except that when the consumer receives the message somehow i don't know why the blank spaces at the end of the message send by the producer are gone, somehow the consumer is making some kind of a trim to the message, it is possible for this not to happen ? because i need those blank strings at the end of the message, those belong to the original message and i need them

@thejams thejams changed the title Receive function of consumer is removing empty spaces at the end of message Receive function of consumer is removing blank spaces at the end of message Feb 2, 2022
@matrober-uk
Copy link
Member

Hi @thejams - I'll take a look at this over the next week too to see if I can resolve the current behaviour.

In the mean time as a (somewhat hacky I admit!) workaround do you have the option to add a non-blank character to the end of the messages when they are sent, and trim that character off when you receive them in your application code - as that approach should honour the blank spaces that exist at the end of the current message text.

@thejams
Copy link
Author

thejams commented Feb 3, 2022

hi @matrober-uk thank you very much for the reply, i did a workaround similar to what you mentioned and it works for now, thanks again for the reply dude

matrober-uk added a commit to matrober-uk/mq-golang-jms20 that referenced this issue Feb 5, 2022
matrober-uk added a commit that referenced this issue Feb 5, 2022
Prevent trimming of whitespace on receive - #45
@matrober-uk
Copy link
Member

Fix merged to main under #48

Fix included in new tag v1.6.0;
https://github.com/ibm-messaging/mq-golang-jms20/releases/tag/v1.6.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants