|
Home > Archive > BizTalk Server Orchestration > April 2005 > Why can't I catch this exception?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Why can't I catch this exception?
|
|
| biztalker 2005-03-23, 6:01 pm |
| Hello
I need some help in handling exceptions as well as preventing the warnings
and errors that appear towards the end of this post from showing up in the
application log.
I am trying to build an orchestration that sends request to a two-way web
method, receives a response and handles any exceptions that may be thrown
back by the web service. For testing purposes, I have disabled the web
server. The orchestration receives a message, maps it to the web service
request message, and then within a scope shape sends the request and receives
and drops off the response somewhere. The exception handler is catching
exceptions of the type System.Net.WebException (more handlers to be added
later). I write to the event log to indicate that an exception was caught.
However, I end up getting BizTalk messaging errors and an XLANG error in the
event log, with the following error code showing up in HAT:
System.Net.WebException: The underlying connection was closed: Unable to
connect to the remote server.
at System.Net.HttpWebRequest.CheckFinalStatus()
at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult)
at System.Net.HttpWebRequest.GetRequestStream()
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
methodName, Object[] parameters)
at
Why is the exception not being caught when the handler handles
System.Net.WebException type? If I change the exception type to
System.Exception, I end up getting the BizTalk server error messages in the
application log, but at the same time, an exception is caught that has the
Message details of the XLANG error. What am I doing wrong here?
The BizTalk warnings/errors showing up in the application log are as
follows. Can't the orchestration design prevent these from getting written to
the application log? Is there some way?
Event Type: Warning
Event Source: BizTalk Server 2004
Event Category: BizTalk Server 2004
Event ID: 5740
Date: 23/03/2005
Time: 8:43:21 AM
User: N/A
Computer: DEV-BTS2K4
Description:
The adapter "SOAP" raised an error message. Details "Exception has been
thrown by the target of an invocation.".
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Event Type: Warning
Event Source: BizTalk Server 2004
Event Category: BizTalk Server 2004
Event ID: 5740
Date: 23/03/2005
Time: 8:43:21 AM
User: N/A
Computer: DEV-BTS2K4
Description:
The adapter "SOAP" raised an error message. Details "The underlying
connection was closed: Unable to connect to the remote server.".
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Event Type: Error
Event Source: BizTalk Server 2004
Event Category: BizTalk Server 2004
Event ID: 5754
Date: 23/03/2005
Time: 8:43:21 AM
User: N/A
Computer: DEV-BTS2K4
Description:
The "SOAP" adapter is suspending an outbound message going to destination
URL:"http://dvtil-webapp/arsys/services/ARService?server=dvtil-webapp&webService=viaTIL_WS".
Details:"The underlying connection was closed: Unable to connect to the
remote server.".
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Event Type: Error
Event Source: BizTalk Server 2004
Event Category: BizTalk Server 2004
Event ID: 5752
Date: 23/03/2005
Time: 8:43:22 AM
User: N/A
Computer: DEV-BTS2K4
Description:
The Messaging Engine has suspended "1" message(s) from adapter "SOAP" due to
failures in message processing. Please refer to Health and Activity Tracking
tool for more detailed information on this failure.
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
| |
| Scott Colestock 2005-03-23, 6:01 pm |
| The adapter typically deals with errors at this level. To achieve what your
after, I believe you'll want to look at delivery acknolwedgements - see this
post:
http://blogs.msdn.com/kevinsmi/arch.../03/172574.aspx
and this thread:
http://groups-beta.google.com/group...>
2350e377527cd
Scott Colestock
www.traceofthought.net
"biztalker" <biztalker@discussions.microsoft.com> wrote in message
news:822A8934-6E9C-4139-94FC-196AC0BD93A3@microsoft.com...
> Hello
>
> I need some help in handling exceptions as well as preventing the warnings
> and errors that appear towards the end of this post from showing up in the
> application log.
>
> I am trying to build an orchestration that sends request to a two-way web
> method, receives a response and handles any exceptions that may be thrown
> back by the web service. For testing purposes, I have disabled the web
> server. The orchestration receives a message, maps it to the web service
> request message, and then within a scope shape sends the request and
> receives
> and drops off the response somewhere. The exception handler is catching
> exceptions of the type System.Net.WebException (more handlers to be added
> later). I write to the event log to indicate that an exception was caught.
> However, I end up getting BizTalk messaging errors and an XLANG error in
> the
> event log, with the following error code showing up in HAT:
>
> System.Net.WebException: The underlying connection was closed: Unable to
> connect to the remote server.
> at System.Net.HttpWebRequest.CheckFinalStatus()
> at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult
> asyncResult)
> at System.Net.HttpWebRequest.GetRequestStream()
> at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
> methodName, Object[] parameters)
> at
>
> Why is the exception not being caught when the handler handles
> System.Net.WebException type? If I change the exception type to
> System.Exception, I end up getting the BizTalk server error messages in
> the
> application log, but at the same time, an exception is caught that has the
> Message details of the XLANG error. What am I doing wrong here?
>
> The BizTalk warnings/errors showing up in the application log are as
> follows. Can't the orchestration design prevent these from getting written
> to
> the application log? Is there some way?
>
> Event Type: Warning
> Event Source: BizTalk Server 2004
> Event Category: BizTalk Server 2004
> Event ID: 5740
> Date: 23/03/2005
> Time: 8:43:21 AM
> User: N/A
> Computer: DEV-BTS2K4
> Description:
> The adapter "SOAP" raised an error message. Details "Exception has been
> thrown by the target of an invocation.".
>
> For more information, see Help and Support Center at
> http://go.microsoft.com/fwlink/events.asp.
>
> Event Type: Warning
> Event Source: BizTalk Server 2004
> Event Category: BizTalk Server 2004
> Event ID: 5740
> Date: 23/03/2005
> Time: 8:43:21 AM
> User: N/A
> Computer: DEV-BTS2K4
> Description:
> The adapter "SOAP" raised an error message. Details "The underlying
> connection was closed: Unable to connect to the remote server.".
>
> For more information, see Help and Support Center at
> http://go.microsoft.com/fwlink/events.asp.
>
> Event Type: Error
> Event Source: BizTalk Server 2004
> Event Category: BizTalk Server 2004
> Event ID: 5754
> Date: 23/03/2005
> Time: 8:43:21 AM
> User: N/A
> Computer: DEV-BTS2K4
> Description:
> The "SOAP" adapter is suspending an outbound message going to destination
> URL:"http://dvtil-webapp/arsys/services/ARService?server=dvtil-webapp&webService=viaTIL_WS".
> Details:"The underlying connection was closed: Unable to connect to the
> remote server.".
>
> For more information, see Help and Support Center at
> http://go.microsoft.com/fwlink/events.asp.
>
>
> Event Type: Error
> Event Source: BizTalk Server 2004
> Event Category: BizTalk Server 2004
> Event ID: 5752
> Date: 23/03/2005
> Time: 8:43:22 AM
> User: N/A
> Computer: DEV-BTS2K4
> Description:
> The Messaging Engine has suspended "1" message(s) from adapter "SOAP" due
> to
> failures in message processing. Please refer to Health and Activity
> Tracking
> tool for more detailed information on this failure.
>
> For more information, see Help and Support Center at
> http://go.microsoft.com/fwlink/events.asp.
>
>
| |
| biztalker 2005-03-23, 6:01 pm |
| I did test specifying the port binding to 'specify later' and setting the
scope shape to synchronized, as well as catching DeliveryFailureException, I
still get the same error messages as below, the exception still does not seem
to have been dealt with in the orchestration itself. Any ideas as to why this
is happening?
"Scott Colestock" wrote:
> The adapter typically deals with errors at this level. To achieve what your
> after, I believe you'll want to look at delivery acknolwedgements - see this
> post:
>
> http://blogs.msdn.com/kevinsmi/arch.../03/172574.aspx
>
> and this thread:
> http://groups-beta.google.com/group...>
2350e377527cd
>
>
> Scott Colestock
> www.traceofthought.net
>
>
>
> "biztalker" <biztalker@discussions.microsoft.com> wrote in message
> news:822A8934-6E9C-4139-94FC-196AC0BD93A3@microsoft.com...
>
>
>
| |
| biztalker 2005-03-23, 6:01 pm |
| I did test specifying the port binding to 'specify later' and setting the
scope shape to synchronized, as well as catching DeliveryFailureException, I
still get the same error messages as below, the exception still does not seem
to have been dealt with in the orchestration itself.
In HAT, I still find resumable messaging instances, with original error code
listing exception type System.Net.WebException. How do I get rid of these?
"Scott Colestock" wrote:
> The adapter typically deals with errors at this level. To achieve what your
> after, I believe you'll want to look at delivery acknolwedgements - see this
> post:
>
> http://blogs.msdn.com/kevinsmi/arch.../03/172574.aspx
>
> and this thread:
> http://groups-beta.google.com/group...>
2350e377527cd
>
>
> Scott Colestock
> www.traceofthought.net
>
>
>
> "biztalker" <biztalker@discussions.microsoft.com> wrote in message
> news:822A8934-6E9C-4139-94FC-196AC0BD93A3@microsoft.com...
>
>
>
| |
|
| Hi
Did you manage to resolve this as I seem to be getting the same problem.
Regards
Tim
"biztalker" wrote:
[vbcol=seagreen]
> I did test specifying the port binding to 'specify later' and setting the
> scope shape to synchronized, as well as catching DeliveryFailureException, I
> still get the same error messages as below, the exception still does not seem
> to have been dealt with in the orchestration itself.
>
> In HAT, I still find resumable messaging instances, with original error code
> listing exception type System.Net.WebException. How do I get rid of these?
>
> "Scott Colestock" wrote:
>
|
|
|
|
|