ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum IndexUser ExitsMessage Exits - Can we strip out part of xml message

Post new topicReply to topic
Message Exits - Can we strip out part of xml message View previous topic :: View next topic
Author Message
mk15
PostPosted: Wed Sep 19, 2018 4:05 pm Post subject: Message Exits - Can we strip out part of xml message Reply with quote

Newbie

Joined: 03 Aug 2011
Posts: 1

Hello All,

I'm new to exit development. I would like to know whether it's possible to remove some elements of XML messages before placing them into a Queue using message exits.
Back to top
View user's profile Send private message
Vitor
PostPosted: Thu Sep 20, 2018 4:58 am Post subject: Re: Message Exits - Can we strip out part of xml message Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 25250
Location: Ohio, USA

mk15 wrote:
I would like to know whether it's possible to remove some elements of XML messages before placing them into a Queue using message exits.


It's possible to code anything in an exit. Best practice is to never write an exit at all.

Seriously. The problems and dangers of exits have been discussed many times in here, and a search on your part will be more profitable than a repetition on my part. I will stick with my trusty soundbite:

"If the answer is an exit, you have the wrong question"

If you're bound and determined on the near-suicidal course of using an exit, it's critical that the exit be fast, efficient and unable to throw any kind of error. None of these attributes are ones I associate with an XML parser.

One last illustrative soundbite (sort of); I've worked with MQ since 1996 and in all that time I've written 3 exits because there was no alternative. I urge you to think really carefully about this solution, especially the longer term costs of maintaining this code.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
gbaddeley
PostPosted: Thu Sep 20, 2018 4:20 pm Post subject: Re: Message Exits - Can we strip out part of xml message Reply with quote

Padawan

Joined: 25 Mar 2003
Posts: 1886
Location: Melbourne, Australia

mk15 wrote:
..I would like to know whether it's possible to remove some elements of XML messages before placing them into a Queue..

It seems a bit obvious, but the app code could do this before putting the msg.
_________________
Glenn
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Sep 21, 2018 6:22 am Post subject: Re: Message Exits - Can we strip out part of xml message Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 25250
Location: Ohio, USA

gbaddeley wrote:
mk15 wrote:
..I would like to know whether it's possible to remove some elements of XML messages before placing them into a Queue..

It seems a bit obvious, but the app code could do this before putting the msg.






It would be my preferred choice for sure.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexUser ExitsMessage Exits - Can we strip out part of xml message
Jump to:



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
Protected by Anti-Spam ACP


Theme by Dustin Baccetti
Powered by phpBB 2001, 2002 phpBB Group

Copyright MQSeries.net. All rights reserved.