Author |
Message
|
angka |
Posted: Tue Oct 18, 2005 9:39 pm Post subject: Receive Exit for MQSeries clients |
|
|
Chevalier
Joined: 20 Sep 2005 Posts: 406
|
Hi all,
Receive Exit is invoked each time a transmission is received. Which byte of the AgentBuffer shows the sequence number of the messages? Is there any flags to indicate whether it is the last packet through TCP? Can anyone help. Thanks in advance. =)
Angka |
|
Back to top |
|
 |
Nigelg |
Posted: Tue Oct 18, 2005 11:54 pm Post subject: |
|
|
Grand Master
Joined: 02 Aug 2004 Posts: 1046
|
The format of the TSH flow is IBM Confidential, so the information you want is not easily available.
It should be possible for you to deduce the positions of the data you want by inspecting the data flows. _________________ MQSeries.net helps those who help themselves.. |
|
Back to top |
|
 |
wschutz |
Posted: Wed Oct 19, 2005 1:49 am Post subject: |
|
|
 Jedi Knight
Joined: 02 Jun 2005 Posts: 3316 Location: IBM (retired)
|
What are you trying to do? Your post topic mentions MQ clients, yet you want a message sequence number (which doesn't apply toMQI channels). _________________ -wayne |
|
Back to top |
|
 |
RogerLacroix |
Posted: Wed Oct 19, 2005 8:48 pm Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
Hi,
<RANT_ON>
My comments are a little off topic but kind of relevant. Lately, I've had a few bright ideas that would use send & receive exits. But IBM will not publish the structure layouts. The channel security exits have the structures published but not send & receive exits.
This is like a drive-thru ATM (bank machine) having Braille on the keypad. You can only look at it and say 'you cannot be serious'.
I could write more products for MQ but I don't have time to reverse engineer send & receive exits.
Come on, IBM makes the exit available but says guess at the contents.
Every developer has to re-invent the wheel (reverse engineer the data flow).
What, did someone at IBM say it is a security risk to publish the structures? This is just silly and no way prevents / closes a security exposure. The guys/gals over at Ethereal have most of it documented.
Someone at Hursley needs to put down their tea and make a proper / executive decision and publish those structures.
</RANT_ON>
Anyway, my 2 cents.
Regards,
Roger Lacroix
Capitalware Inc. _________________ Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter |
|
Back to top |
|
 |
angka |
Posted: Fri Oct 21, 2005 9:35 am Post subject: |
|
|
Chevalier
Joined: 20 Sep 2005 Posts: 406
|
Hi all,
Thanks alot for replying.
I tested on the data flow. I looked at the first 8 bytes and cant really deduced much from it.
Nigelg, do you have any suggestions which ranges of bytes should I look at?
Wschutz, I mentioned about MQ Clients because I think that the data structure of receiver exit for MQ Clients and Server may be different. "In the case of MQI channels for clients, byte 10 of the agent buffer identifies the API call in use when the send or receive exit is called."
Actually what my receiver exit program wants is just to log all incoming messages once. So I need to know whether the message is segmented for TCP transmission. Think there should be a bit to indicate that the message is segmented and a bit to indicate whether it is the last packet or not and maybe a byte to indicate the sequence number of the packets received.
Thanks all in advance
Regards,
Kian Ann |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Oct 21, 2005 9:36 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Maybe you want to use a Message Exit instead of a Receiver exit. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
angka |
Posted: Fri Oct 21, 2005 9:45 am Post subject: |
|
|
Chevalier
Joined: 20 Sep 2005 Posts: 406
|
Hi Jefflowrey,
Thanks. I cant use Message Exit because it is not supported for MQ Clients
Regards |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Oct 21, 2005 10:06 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
angka wrote: |
I cant use Message Exit because it is not supported for MQ Clients |
 _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
hopsala |
Posted: Fri Oct 21, 2005 10:58 am Post subject: |
|
|
 Guardian
Joined: 24 Sep 2004 Posts: 960
|
angka wrote: |
Actually what my receiver exit program wants is just to log all incoming messages once. So I need to know whether the message is segmented for TCP transmission. |
A good question here would be - Why? Why do you need to log all traffic, and why not do it in the application log? I think you might be able to save yourself some work by going about this in a different way, so let's hear more details. |
|
Back to top |
|
 |
wschutz |
Posted: Fri Oct 21, 2005 11:03 am Post subject: |
|
|
 Jedi Knight
Joined: 02 Jun 2005 Posts: 3316 Location: IBM (retired)
|
|
Back to top |
|
 |
hopsala |
Posted: Fri Oct 21, 2005 11:11 am Post subject: |
|
|
 Guardian
Joined: 24 Sep 2004 Posts: 960
|
RogerLacroix wrote: |
<RANT_ON>...</RANT_ON> |
So I gather your default is OFF?
Anyway, what are the reasons you found to backwards engineer these exits? I would think that these exits were designed for code that is "packet independant" - you don't need to know who the previous or next packet is, or where you are - could you describe a buisness need in which this is required?
What angka described is a good example, but IBMs mistake here wasn't not supplying the RCVexit mechanism, it was that they didn't supply Message exits for channels. Don't get me wrong, I agree with you - hiding protocols nowadays is darn right stupid - but why do you care? |
|
Back to top |
|
 |
RogerLacroix |
Posted: Fri Oct 21, 2005 9:38 pm Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
Hi,
Quote: |
I would think that these exits were designed for code that is "packet independant" - you don't need to know who the previous or next packet is, or where you are - could you describe a buisness need in which this is required? |
Ah yes, I have been misunderstood. Yes, this is true and what one would expect.
In case you haven't look at a receive exit, each time the receive exit is call / invoked, all you get is an undocumented TSH structure. This is what I am ranting about.
Regards,
Roger Lacroix _________________ Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter |
|
Back to top |
|
 |
hopsala |
Posted: Sat Oct 22, 2005 2:45 am Post subject: |
|
|
 Guardian
Joined: 24 Sep 2004 Posts: 960
|
RogerLacroix wrote: |
In case you haven't look at a receive exit, each time the receive exit is call / invoked, all you get is an undocumented TSH structure. This is what I am ranting about. |
Gotcha, you were referring to the data structure, not the protocol, pardon. |
|
Back to top |
|
 |
angka |
Posted: Sun Oct 23, 2005 6:08 pm Post subject: |
|
|
Chevalier
Joined: 20 Sep 2005 Posts: 406
|
Hi all,
Thanks all,
Hopsala, I logged the messages in the Receiver Exit for standardising. I logged my messages with Message Exit for Server connection.
Wschutz, I can't use the API Exit because the server Version of MQ I using is only 5.1.
Besides, logging the messages, I need to filter off those unauthorised access to local queue. Is there anyway I can get the TSH structure?
Regards. |
|
Back to top |
|
 |
harry_hotdog |
Posted: Sun Oct 23, 2005 11:35 pm Post subject: |
|
|
Novice
Joined: 19 Oct 2005 Posts: 10 Location: England
|
I think nigelg already answered that...
[quote]The format of the TSH flow is IBM Confidential[/quote] |
|
Back to top |
|
 |
|