Understanding RosettaNet Message Flow in BizTalk Server 2006

If a picture is worth a thousand words, then these two diagrams (courtesy & copyright Microsoft) are worth millions! At least they are to anyone desperate to understand how the BizTalk Accelerator for RosettaNet (BTARN 3.5) really works.

Initiator Message Flow

Don’t let the complexity of this diagram scare you. The message flow for an outbound RNIF (or PIDX) message consists of four key areas.

  1. The SQL Server BTARN Databases where all “lob” messages (such as a P21 – PIDX Invoice) and any attachments are stored BEFORE the outbound RNIF message flow actually begins, and the SQL Receive Location used to process the message content and attachments into the MessageBox.

    Note: If you’re not sending attachments you may elect not to use SQL for this and can substitute FILE receive locations. The SDK contains sample code and a pretty good explanation of how this may work.

  2. The Initiator Private Process orchestration where the actual messages and attachments are “prepared” (usually transformed into XML) for further processing by the initiator public process.
  3. The Initiator Public Process orchestration where the outbound message is actually formatted to meet the RNIF standard. This includes adding the required RNIF headers and other such tasks. Consider this a “Black Box” since you can’t change how this works without invalidating the RosettaNet certification.
  4. The HTTP/HTTPS Send Ports and the RNIFSend.aspx web application that are CRITICAL to the correct processing of the outbound messages. This is where the real work is done to validate the messages, create the correct MIME headers and add the required RNIF DOCTYPE declarations.

    Just a side note. If you’re really interested in how this all works, you can look at the source code for this web application using Lutz Roeder’s Reflector. I think you’ll be amazed at how much Regex is used to “craft” these RNIF messages.

Responder Message Flow

The message flow for an inbound RNIF message (whether it’s a new message or an asynchronous response to a message you’ve already sent) consists of three key areas.

  1. The RNIFReceive.aspx web application which processes the inbound message, validates it and then removes all the RNIF specific headers and DOCTYPE declarations. This then passes the message along to the HTTP/HTTPS Receive Port and Pipeline which handles the non-repudiation, decodes the message, parses the message and resolves which Party it came from.
  2. The Responder Public Process receive the RNIF message from the MessageBox and extracts the content and attachments and sends them to the responder private process for further processing. Just like the initiator public process, the Responder Public Process should be considered a “Black Box” and left unchanged.
  3. The Responder Private Process then routes the inbound messages and any attachments to the SQL Server BTARN Databases where it can be further processed and sent to some “lob” back-end system.

There are a few other details involved in the message flow (signals) depending upon whether your transmission is synchronous or asynchronous, but the basics are fairly straight-forward. The best thing is that this workflow is almost entirely “configured” using the BTARN Management Console and is “message agnostic”, meaning that you can use any standard RNIF, CIDX or PIDX “PIP” (Partner Interface Process) that you and your trading partner both support.

Best of all, it’s included in the price of BizTalk Server 2006 R2!

Currently listening to Carrie Underwood’s Carnival Ride

This entry was posted in BizTalk Server, Microsoft, PIDX, RosettaNet. Bookmark the permalink. Follow any comments here with the RSS feed for this post.

3 Responses to Understanding RosettaNet Message Flow in BizTalk Server 2006

  1. jlynch says:

    @mike – Glad you found the issue and no, I hadn’t really had a chance to review your issue yet. I’m still working through several of my own. Oh, the joys of RNIF!

  2. mike says:

    Seems that I sort of did know what I was doing, but since I stole the code from the double action tutorial, I confused the source and destination parties. I switched the “FABRIKAM” and “SHI”, and my process worked as expected.

    I hope you did not waste any time looking at this, and thanks for the posts on RN.


  3. mike says:

    I posted a month or so ago about some issues I was having with my RNIF setup (which I can’t even remember). Well things finally got moving with my inbound processing, and that has moved to production. Now it is time to move to setting up outbound invoices (3C3), but I am having a hard time finding any info on starting the outbound flow other than the LOBWebApp in the SDK.

    I see in your outbound posting that you say either put the doc into SQL so the Private Process will pick it up, or use the file drop from SDK. The issue I have with using SQL is that the service content in the MessagesFromLOB table seem to have a header before the RNIF message starts, but I cannot find any documentation on creating this.

    My approach so far which I stole from the DoubleAction Tutorial is to put the following code into an Expression shape, which I thought would add the headers I spoke of above, and drop a message into SQL.


    I am getting an error that “No active TPA exists between XX, YY, for PIP: 3C3 version: V01.01 for home role of initiator”.

    1. Shouldn’t I see the doc in MessagesFromLOB table?
    2. I checked everything, and I think I have my setup correct in BT Admin for RN.

    Thanks in advance, and I hope I made myself clear.


Leave a Reply