|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
|
|
Empty putTime and putDate in Java |
« View previous topic :: View next topic » |
Author |
Message
|
mattfarney2 |
Posted: Thu Nov 12, 2020 3:31 pm Post subject: Empty putTime and putDate in Java |
|
|
Newbie
Joined: 12 Nov 2020 Posts: 2
|
I have received some messages without putTime and putDate that caused my application issues. I'm trying to simulate these transactions, but the current version of the Java MQMD class has a single GregorianCalendar instead of individual char fields.
The MQMD1 header does have the smaller fields, but without better examples, I do not think I'll be able to get that to work. The copyFrom and copyTo operations throw null pointer exceptions - and the documentation does not specify what fields are required for either operation.
I have two questions:
1. Is there an easy way to generate an MQ message in Java with null and/or empty putTime/putDate fields?
2. Has anyone seen any examples of MQMD1 usage in Java?
-mf |
|
Back to top |
|
|
bruce2359 |
Posted: Thu Nov 12, 2020 5:08 pm Post subject: |
|
|
Poobah
Joined: 05 Jan 2008 Posts: 9442 Location: US: west coast, almost. Otherwise, enroute.
|
|
Back to top |
|
|
RogerLacroix |
Posted: Fri Nov 13, 2020 10:12 am Post subject: |
|
|
Jedi Knight
Joined: 15 May 2001 Posts: 3258 Location: London, ON Canada
|
Or you can go the opposite way, set CMQC.MQPMO_SET_ALL_CONTEXT for PMO options and then not set the putDateTime field of the MQMessage class.
Don't forget to set CMQC.MQOO_SET_ALL_CONTEXT for Open Options.
Regards,
Roger Lacroix
Capitalware Inc. _________________ Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter |
|
Back to top |
|
|
mattfarney2 |
Posted: Fri Nov 13, 2020 10:45 am Post subject: |
|
|
Newbie
Joined: 12 Nov 2020 Posts: 2
|
Thanks for the suggestions.
MQPMO_NO_CONTEXT worked perfectly.
-mf |
|
Back to top |
|
|
bruce2359 |
Posted: Fri Nov 13, 2020 1:01 pm Post subject: |
|
|
Poobah
Joined: 05 Jan 2008 Posts: 9442 Location: US: west coast, almost. Otherwise, enroute.
|
MQPMO_SET_ALL requires put and setall permissions
MQPMO_NO_CONTEXT requires only put permission _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
|
|
|
|
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|