0

I am a beginner with XMS and I am having quite a hard time finding a solution to my problem. I hope you will help me find a solution or at least give me a hand.

So, in my project I am using IBM MQ XMS API to send and receive messages. It works well but there is only one problem. When the users send a message that is superior to the Max Msg Length it triggers a general exception. In that exception there is a treament for various case of errors but it lacks the treatments of that particular exception.

What would be the best way to test if the message length is inferior to Max Msg Length defined on the server before sending it? Or at least how should i catch the trigger of that exception more precisely?

(I am sorry I can't post code because it belongs to the company I am working for)

JoshMc
  • 10,239
  • 2
  • 19
  • 38
Andrea
  • 145
  • 9
  • 1
    Either option is fine. Which is preferable would depend on things like how easy is it to know in advance, etc. The hard question is: what will you do if your message is too long? – Caleth Apr 20 '18 at 16:04
  • If the message is too long i just want to add a warning in the log so the user understand why he lost some messages – Andrea Apr 21 '18 at 16:14
  • What genetic error do you receive and what version of IBM MQ client are you using with the C++ XMS API? – JoshMc Dec 30 '19 at 03:43

0 Answers0