Author |
Message
|
cadenza |
Posted: Mon Apr 16, 2007 2:34 am Post subject: Regd: ASBITSTREAM Usage |
|
|
Apprentice
Joined: 01 Jun 2004 Posts: 48
|
Hi,
I am currently associated with a maintenance project in MB 5.0. I have noticed that the existent code is converting the message to a bitstream before sending any message to a publication node.
However I never used to do that in my earlier projects. The pub-sub used to work fine without converting it into bitstream. It is also working fine in the current project.
I believe there must be a specific reason why someone has used the asbitstream functionality before sending it to publication node. Can anyone point me out the advantage of doing it? Is it better to convert because of maybe ... performance related advantages ?
Also your thoughts on some practical utility of using ASBITSTREAM function is highly appreciated.
Thanks. |
|
Back to top |
|
 |
recallsunny |
Posted: Mon Apr 16, 2007 5:39 am Post subject: |
|
|
 Disciple
Joined: 15 Jun 2005 Posts: 163 Location: Massachusetts
|
IMHO there are No performance advantages in creating a Bitstream of the output root. Unless of course some find/replace operations are being performed on the BLOB (bitstream).
Some practical cases where we had to implement this functionality are: A case where we had to persist the entire message (as bitstream - BLOB) into the Db for retrieval at a later stage in a different flow.
In another situation, we needed a simple logic to store the msg headers sent in a request message from a JMS application and repopulate these headers into the response sent to the same app (asynchronous transaction).
There could be numerous other practical uses for this functionality... would like to hear from the other Grand masters ! |
|
Back to top |
|
 |
cadenza |
Posted: Mon Apr 16, 2007 8:50 pm Post subject: |
|
|
Apprentice
Joined: 01 Jun 2004 Posts: 48
|
Hi,
We are not performing any search/replace operations on the bitstream. The bitstream generated is directly sent to the publication node.
Could it be possible that the message being published as bitstream is more "light-weight" as opposed to a non bitstream message? If yes then maybe it would reduce the load on broker as we are using pub-sub extensively and the volume of messages are also high.
Although there is an overhead of converting the entire message to bitstream using the asbitstream function.
Any ideas folks. |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Apr 17, 2007 3:25 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
There's likely no good reason to do this. The publication node is going to call ASBITSTREAM anyway. (perform the equivalent function, at least.) _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
sourdas2 |
Posted: Thu Apr 19, 2007 4:26 am Post subject: |
|
|
 Voyager
Joined: 21 Apr 2006 Posts: 90 Location: Kolkata,India
|
When publication node publishes message, it might invoke message parser and asbitstream function (or similar mechanism) to convert the message from logical format to physical format (bitstream).
So, it may be a good idea to convert the message to bitream before publishing it.
It would be great if somebody could throw some light on the internal algorithm of publication node. _________________ Thanks and Warm Regards
Sourav |
|
Back to top |
|
 |
|