Biztalk calls map twice
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server > Biztalk calls map twice




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Biztalk calls map twice  
brandonnewsgroup@hotmail.com


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-08-05 10:49 PM

BTS 2002 SP1

We have biztalk setup to accept hipaa x12 incoming messages and return
hipaa x12 outgoing messages.

In normal cases, Biztalk will convert the x12 messages to xml, call the
map, convert the output xml back to x12 and return the x12 message.

However, if there is a processing problem in the map, biztalk will call
it twice.

It can be reproduced when the map is hardcoded to always return
"<test>abc</test>"

Biztalk is following this logic.

IncomingXML=Convert(IncomingX12)
attempt=0
repeat
attempt=attempt+1
Log(IncomingXML)
OutgoingXML=RunMap(incomingXML)
OutgoingX12=Convert(OutgoingXML)
Valid = isValid(OutgoingX12)
Until valid or attempt>=2

If valid then
Log(OutgoingXML)
Else
EventLog("The XML document has failed validation for the following
reason:..")
End if


What I don't understand is why there would be ANY circumstance in
which repeating the RunMap automatically would be desirable.

If the map is stateless, then it will return the same error for both
calls (making the second call harmless but useless).

If the map is stateful, then calling twice causes a transaction to get
submitted twice (this is what is happening for us).

Oddly, if the second call succeeds, biztalk shows no record that the
first call ever failed.

Can anyone shine some light on why biztalk does this?

Is there any way to get biztalk to log the OUTGOING xml even when it
can not be converted (this is when the logs are most needed)?

Is there any way to force biztalk to go with the results of the first
call to the map and not try again?

I don't think this is related to the channel's retry options which are
left at 3 retrys in 5 minute intervals.






[ Post a follow-up to this message ]



    Re: Biztalk calls map twice  
Joerg Fischer


Report This Message To A Moderator Edit/Delete Message


 
03-10-05 12:47 PM

Hi,

If you access anything outside the inbound pipeline, like DBs, here is a
hint: After installing BizTalk SP1, there is a new interface provided
(PipelineContextEx) which allows you to access the DTC transaction of the
pipeline.

That way, you can ensure that if anything fails, things are rolled back.

Sincerely

Joerg Fischer

<brandonnewsgroup@hotmail.com> wrote in message
news:1110305444.449530.305310@z14g2000cwz.googlegroups.com...
> BTS 2002 SP1
>
> We have biztalk setup to accept hipaa x12 incoming messages and return
> hipaa x12 outgoing messages.
>
> In normal cases, Biztalk will convert the x12 messages to xml, call the
> map, convert the output xml back to x12 and return the x12 message.
>
> However, if there is a processing problem in the map, biztalk will call
> it twice.
>
> It can be reproduced when the map is hardcoded to always return
> "<test>abc</test>"
>
> Biztalk is following this logic.
>
> IncomingXML=Convert(IncomingX12)
> attempt=0
> repeat
>   attempt=attempt+1
>   Log(IncomingXML)
>   OutgoingXML=RunMap(incomingXML)
>   OutgoingX12=Convert(OutgoingXML)
>   Valid = isValid(OutgoingX12)
> Until valid or attempt>=2
>
> If valid then
>   Log(OutgoingXML)
> Else
>   EventLog("The XML document has failed validation for the following
> reason:..")
> End if
>
>
> What I don't understand is why there would be ANY circumstance in
> which repeating the RunMap automatically would be desirable.
>
> If the map is stateless, then it will return the same error for both
> calls (making the second call harmless but useless).
>
> If the map is stateful, then calling twice causes a transaction to get
> submitted twice (this is what is happening for us).
>
> Oddly, if the second call succeeds, biztalk shows no record that the
> first call ever failed.
>
> Can anyone shine some light on why biztalk does this?
>
> Is there any way to get biztalk to log the OUTGOING xml even when it
> can not be converted (this is when the logs are most needed)?
>
> Is there any way to force biztalk to go with the results of the first
> call to the map and not try again?
>
> I don't think this is related to the channel's retry options which are
> left at 3 retrys in 5 minute intervals.
>







[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 12:28 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register