• Add a Comment
  • Edit
  • More Actions v
  • Quarantine this Entry

Comments (15)

1 irazabal commented Permalink

Hermann - you are the man! Thanks, I was just looking into this for a customer...thanks so much for making my life easier... :)

2 jwende commented Permalink

Thanks Hermann - great stuff ...

3 HermannSW commented Permalink

I added important new important information on top of the blog entry in <EDIT> section.</EDIT>

4 HermannSW commented Permalink

Hmm, once again.

I added important information on top of the blog posting in <EDIT> section.

5 lenisha commented Permalink

Hi Hermann,

Would implementing MLLP protocol (TCP/IP stream where requests are separated by some delimiter like CRLF) and payload is delimited text be possible using this technique ?
Where rawTCP2HTTP MPGW would convert TCP/IP stream to HTTP? How would it understand delimiters between requests to put them to appropriate HTTP POST?
Thanks a lot

6 HermannSW commented Permalink

MLLP spec just says that the form of a message is:
0x0B "HL7 message" 0x1C 0x0D

So having several messages of this form in a single request is fine, because it can be parsed and seperated later.
rawTCP2HTTP MPGW will just take the terminated(*) request and just forward it to a "normal" HTTP Non-XML service.
(*) As mentioned in the WSTE webcast the ER for a "real" rawTCP Non-XML FSH is still needed, because above technique does not allow for persistent connections. The ER is in state "Planned for Future Release" currently.
If your client does not terminate the connection by sending a FIN, you can workaround this by setting a 1sec FSH timeout. After request has been sent to DataPower, and after a 1sec delay (no CPU usage), DataPower will close the frontside connection and continue processing as if the client would have sent the FIN.

7 echurchm commented Permalink

Hermann, thanks for your great information!! When you say persistent connection, do you mean http persistent connection or some kind of tcp connection? I am having the issue where my tcp client is sending the data but is looks like DataPower just keeps reading the stream and then times out. I tried setting the timeout value but my client is expecting a response which is terminated with ASCII ZERO which I also need to figure how to send. Any suggestions would be greatly appreciated.

8 HermannSW commented Permalink

"... but my client is expecting a response which is terminated with ASCII ZERO which I also need to figure how to send. ..." If you return XML to your client, you first have to &lt;dp:serialize> it and then base64 encode it (as $b64), add &lt;dp:output-mapping href="store:///pkcs7-convert-input.ffd" type="ffd"/> to your stylesheet, make it a xformbin action instead of a xform action, and finally return &lt;object>&lt;message>&lt;xsl:copy-of select="dp:binary-decode(dp:concat-base64($b64,'AA=='))"/>&lt;/message>&lt;/object>

9 sp8888 commented Permalink

Hi Herman,

I am new to data power Admin, I am planning to upgrade firmware from to v6 (XI50 - 9235)but in IBM release notes prerequisites for v6 firmware upgrade is device should be running on either or v5.
Please help me on this.

10 vvidovic commented Permalink

Hi Hermann,

I listened to your non-xml data processing and found this non-xml raw tcp processing very interesting for a feature we are trying to implement for our client but could not manage to implement a desired solution.
We are trying to put one "raw TCP" service which just listens on frontside with Stateless Raw XML Handler and pass TCP to backend service using static TCP backend URL (like: "tcp://hostname:port"). If that works I would like to add functionality to copy each message (or each one resulting in error response) to some ftp or similar for later troubleshooting (to be able to easy solve problems which occurs to clients connecting to backend service).
When I try to test this setup (using curl or SoapUI) it just hangs (it seems that backend service receives data and sends response but client doesn't receive response, it just keeps waiting for response, while if I direct client to connect to backend service directly everything works fine).
We tried to use both request and response type of "Pass through" or "Non-XML" or their combinations.
Do you maybe have any suggestions which could help us to solve this problem?

11 HermannSW commented Permalink

Hi sp888,

just upgrade to first.
Then, after the box booted with, upgrade to v6.

12 HermannSW commented Permalink

Hi Vedran,

DataPower rawTCP XML Front Side Handler (FSH) needs to know where a message ends. If you just send XML, then DataPower parses on the fly while it receives the data and knows message is complete when document node closing tag has been read. This allows to use persistent connections for processing XML rawTCP data!
When "mis"using the rawTCP XML FSH for Non-XMl [I know, I did propose that ;-)] DataPower needs to know when message is complete. This can either be done by client sending a TCP FIN packet (which "netcat" tool (bc) does). If client does not send a FIN, then DataPower has to wait for FSH timeout because it does not know when client is done with sending data. Setting a low FSH timeout value will do what is needed. Minimal value is 1 (second) which add delay of 1 second, but does non-active waiting. After the timeout happened, request rule processing starts.

13 3EW0_Rajeesh_Divakaran commented Permalink


I was trying to test the Datapower service which I created as per your instructions above(statelessRAWXML Front side handler). So when i test using netcat, I am getting a read error in the probe which says unable to read the input.
My requirement is to simulate a text message (SMS) as input. So how should i specify the input in the nc command? The file should be in what format and with what filename extension?
Please advice.
Refer errors below:
0x80e0070e mpgw (SMPPGatewayPOC): Error in stream (101). Local( - Remote( Additional information: Read error (7) Connection reset by peer (104)
0x80c00008 mpgw (SMPPGatewayPOC): rule (default_rule_0): implied action Pass input through without processing failed: Read error

14 HermannSW commented Permalink


> So how should i specify the input in the nc command?
nc ip-addr port < input-file
echo "foobar" | nc ip-addr port
> The file should be in what format and with what filename extension?
Any format, rawTCP2HTTP allows to process arbitrary binary data.

15 HermannSW commented Permalink

Please see <EDIT date="2/3/2015"> section at very top of blog posting, things have become really bad.


Add a Comment Add a Comment