BizTalk Server General - BizTalk customized error logging

This is Interesting: Free IT Magazines  
Home > Archive > BizTalk Server General > December 2005 > BizTalk customized error logging





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 BizTalk customized error logging
Alex M

2005-12-06, 5:54 pm

Does anybody know documentation about subj?
I need to customize BizTalk error logging - put errors to log files or
database instead of Event Log.
For example - is there any possibilities to customize Flat File
Disassembler / Pipeline error logging w/o creating my own Disassemblers and
etc? Very unlikely that BizTalk users must create second Flat File
Disassembler component only for customized error logging


BizTalk Benjamin

2005-12-06, 5:54 pm

Alex,
There is no customisable logging built in. You can use Enterprise Library,
log4net or other custom solutions. Ent Lib is terribly unreliable in my
experience and frequently has versioning problems and the system complains of
missing config sections.[check out my post on this subject here:
http://dotnetjunkies.com/WebLog/net...TS_Diary_9.aspx]

Also have a look at Scott Colestocks log4net solution.

We also added custom pipeline components to archive messages to a custom DB
and to do some logging of the steps/milestones. We didnt use BAM.

HTH
Benjy

"Alex M" wrote:

> Does anybody know documentation about subj?
> I need to customize BizTalk error logging - put errors to log files or
> database instead of Event Log.
> For example - is there any possibilities to customize Flat File
> Disassembler / Pipeline error logging w/o creating my own Disassemblers and
> etc? Very unlikely that BizTalk users must create second Flat File
> Disassembler component only for customized error logging
>
>
>

Tomas Restrepo \(MVP\)

2005-12-06, 5:54 pm

Alex,

> Does anybody know documentation about subj?
> I need to customize BizTalk error logging - put errors to log files or
> database instead of Event Log.
> For example - is there any possibilities to customize Flat File
> Disassembler / Pipeline error logging w/o creating my own Disassemblers
> and
> etc? Very unlikely that BizTalk users must create second Flat File
> Disassembler component only for customized error logging


As far as I know, no, you can't customize it. You could, however, write a
tool to monitor WMI and the Event log, extract the relevant entries and save
it to a file.

Why would you want to do this?


--
Tomas Restrepo
tomasr@mvps.org
http://www.winterdom.com/


Greg Forsythe

2005-12-06, 5:54 pm

There is a Biztalk Event Log adapter on GotDotNet
http://www.gotdotnet.com/Community/...71-18E64325474B
Haven't used it myself, but it could be what you are looking for.

Greg




"Alex M" <er4forums@mail.ru> wrote in message
news:%23LgkI4n%23FHA.4092@TK2MSFTNGP10.phx.gbl...
> Does anybody know documentation about subj?
> I need to customize BizTalk error logging - put errors to log files or
> database instead of Event Log.
> For example - is there any possibilities to customize Flat File
> Disassembler / Pipeline error logging w/o creating my own Disassemblers
> and
> etc? Very unlikely that BizTalk users must create second Flat File
> Disassembler component only for customized error logging
>
>



Alex M

2005-12-07, 8:00 am


I need to write to log received but failed to disassemble messages (and
store these msgs in archive). Now there is only event log entries about
these fails...
May by it is possible to create my own component-wrapper for Flat File
Dissasembler component with advanced error logging?
Can this component bubble up its errors and exceptions to my code in this
case?
Or should it be separate component for full archiving of all incoming
unparsed interchange and correlation logic with processed/unprocessed logic?

"Tomas Restrepo (MVP)" <tomasr@mvps.org> wrote in message
news:uXoQNXp%23FHA.2812@TK2MSFTNGP09.phx.gbl...
> Alex,
>
>
> As far as I know, no, you can't customize it. You could, however, write a
> tool to monitor WMI and the Event log, extract the relevant entries and

save
> it to a file.
>
> Why would you want to do this?
>
>
> --
> Tomas Restrepo
> tomasr@mvps.org
> http://www.winterdom.com/
>
>



BizTalk Benjamin

2005-12-07, 8:00 am

Alex,
Im not sure what level of exception information you can get in the pipeline.
Usually the messages that fail to disassemble or indeed any other error would
go straight to the event log.

You could use the old EMAB or the EntLib verison and filter the exceptions
and write to a database. But then again, thats quite intrusive on the
business logic.

The GDN tool that Greg Forsythe pointed out looks like a good non intrusive
way to handle the exceptions. You can build whatever filters you want in
another 'error orchestration' and write to the database.

Remember (AFAIK) that you cant actually get the suspended message in BTS
2004. In 2006 you can write the message to an error queue and get the whole
thing.

HTH
Benjy


"Alex M" wrote:

>
> I need to write to log received but failed to disassemble messages (and
> store these msgs in archive). Now there is only event log entries about
> these fails...
> May by it is possible to create my own component-wrapper for Flat File
> Dissasembler component with advanced error logging?
> Can this component bubble up its errors and exceptions to my code in this
> case?
> Or should it be separate component for full archiving of all incoming
> unparsed interchange and correlation logic with processed/unprocessed logic?
>
> "Tomas Restrepo (MVP)" <tomasr@mvps.org> wrote in message
> news:uXoQNXp%23FHA.2812@TK2MSFTNGP09.phx.gbl...
> save
>
>
>

Alex M

2005-12-07, 8:00 am

I think it's the most perspective idea for my objectives - monitor BT for
suspended messages...

Or may be there is possibility to Add Send port with some kind of filter to
catch unparsed (and etc) messages from specified Receive Location and send
them to some storage?

And there are few ways to accomplish simple monitoring of suspended
messages - monitor WMI events (problems with accessing to message body and
context - http://blogs.msdn.com/darrenj/archi.../30/104135.aspx),
mentioned EventLog adapter (what a ridiculous way, I don't believe that
everything is so bad)
Or simple hack - direct query to BTS MesageBox to extract suspended
messages...



"BizTalk Benjamin" <BizTalkBenjamin@discussions.microsoft.com> wrote in
message news:E200281C-9B6F-47C3-92DA-E27D9CEF43F1@microsoft.com...
> Alex,
> Im not sure what level of exception information you can get in the

pipeline.
> Usually the messages that fail to disassemble or indeed any other error

would
> go straight to the event log.
>
> You could use the old EMAB or the EntLib verison and filter the exceptions
> and write to a database. But then again, thats quite intrusive on the
> business logic.
>
> The GDN tool that Greg Forsythe pointed out looks like a good non

intrusive
> way to handle the exceptions. You can build whatever filters you want in
> another 'error orchestration' and write to the database.
>
> Remember (AFAIK) that you cant actually get the suspended message in BTS
> 2004. In 2006 you can write the message to an error queue and get the

whole[vbcol=seagreen]
> thing.
>
> HTH
> Benjy
>
>
> "Alex M" wrote:
>
this[vbcol=seagreen]
logic?[vbcol=seagreen]
or[vbcol=seagreen]
Disassemblers[vbcol=seagreen]
write a[vbcol=seagreen]
and[vbcol=seagreen]


Greg Forsythe

2005-12-07, 5:55 pm

Alex,

I have used a custom pipeline component to provide "recovery" from Xml
Validation errors.
The code can found at
http://msdn.microsoft.com/biztalk/c...es/default.aspx
This Enhanced Validator simply wraps the standard pipeline component and
catches exceptions.
It provides similar functionality to the BTS2006 Error Message
i.e. on error it creates a new message with the contents of the original
with an error description and publishes this to the message box.
You can then have a send port or orchestration handle the errors and log to
file or db.

It should be possible to do the same with FlatFile Disassembler component.

Alternatively, use BTS2006, where this functionality is standard.

Greg




"Alex M" <er4forums@mail.ru> wrote in message
news:OpDSGex%23FHA.1676@TK2MSFTNGP09.phx.gbl...
>
> I need to write to log received but failed to disassemble messages (and
> store these msgs in archive). Now there is only event log entries about
> these fails...
> May by it is possible to create my own component-wrapper for Flat File
> Dissasembler component with advanced error logging?
> Can this component bubble up its errors and exceptions to my code in this
> case?
> Or should it be separate component for full archiving of all incoming
> unparsed interchange and correlation logic with processed/unprocessed
> logic?
>
> "Tomas Restrepo (MVP)" <tomasr@mvps.org> wrote in message
> news:uXoQNXp%23FHA.2812@TK2MSFTNGP09.phx.gbl...
> save
>
>



Alex M

2005-12-08, 7:51 am

Yes, it took 2 minutes to wrap standart FFDisassembler and log his inner
exception catches but I can't run it under BizTalk. I''ve added this
compenet to my receive pipeline from toolbox but it runtime BizTalk throws
FileNotFoundException for this custom pipeline component assembly (or one of
its dependencies, but everything is installed in GAC - I tested in my own
Console application - it successfully loads and runs this compenent with
references "Copy local - false" ie from GAC)

BizTalk eventlog entry:

There was a failure executing the receive pipeline:
"DataGathering.DgToPrima.Pipelines.MS"
Source: "mscorlib"
Receive Location: "f:\MessageIn\ms*.xls"
Reason: File or assembly name FFDisassemblerLogged.dll, or one of its
dependencies, was not found.


"Greg Forsythe" <greg.forsythe@xtraDOTcoDOTnz> wrote in message
news:OYyc3I2%23FHA.3392@TK2MSFTNGP14.phx.gbl...
> Alex,
>
> I have used a custom pipeline component to provide "recovery" from Xml
> Validation errors.
> The code can found at
> http://msdn.microsoft.com/biztalk/c...es/default.aspx
> This Enhanced Validator simply wraps the standard pipeline component and
> catches exceptions.
> It provides similar functionality to the BTS2006 Error Message
> i.e. on error it creates a new message with the contents of the original
> with an error description and publishes this to the message box.
> You can then have a send port or orchestration handle the errors and log

to
> file or db.
>
> It should be possible to do the same with FlatFile Disassembler component.
>
> Alternatively, use BTS2006, where this functionality is standard.
>
> Greg
>
>
>
>
> "Alex M" <er4forums@mail.ru> wrote in message
> news:OpDSGex%23FHA.1676@TK2MSFTNGP09.phx.gbl...
this[vbcol=seagreen]
or[vbcol=seagreen]
Disassemblers[vbcol=seagreen]
a[vbcol=seagreen]
>
>



Tomas Restrepo \(MVP\)

2005-12-08, 7:51 am

Hi Alex,

> Yes, it took 2 minutes to wrap standart FFDisassembler and log his inner
> exception catches but I can't run it under BizTalk. I''ve added this
> compenet to my receive pipeline from toolbox but it runtime BizTalk throws
> FileNotFoundException for this custom pipeline component assembly (or one
> of
> its dependencies, but everything is installed in GAC - I tested in my own
> Console application - it successfully loads and runs this compenent with
> references "Copy local - false" ie from GAC)


You shouldn't install pipeline components in the GAC. Instead, you should
just copy them to the "Pipeline Components" subfolder of your BizTalk
Installation (e.g. "c:\Program Files\Microsoft BizTalk Server 2004\Pipeline
Components")


--
Tomas Restrepo
tomasr@mvps.org
http://www.winterdom.com/


Alex M

2005-12-08, 5:54 pm

OMG!
Thank you very much!
When I saw this in FUSLOGVW.exe right before read your answer I didn't
beleive my eyes! 8)
I thought that GAC is common plase for such things...


"Tomas Restrepo (MVP)" <tomasr@mvps.org> wrote in message
news:O9TZEz$%23FHA.1248@TK2MSFTNGP14.phx.gbl...
> Hi Alex,
>
throws[vbcol=seagreen]
one[vbcol=seagreen]
own[vbcol=seagreen]
>
> You shouldn't install pipeline components in the GAC. Instead, you should
> just copy them to the "Pipeline Components" subfolder of your BizTalk
> Installation (e.g. "c:\Program Files\Microsoft BizTalk Server

2004\Pipeline
> Components")
>
>
> --
> Tomas Restrepo
> tomasr@mvps.org
> http://www.winterdom.com/
>
>



Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com