Forum Replies Created
-
AuthorPosts
-
Sure no problem.
I created a Stored Procedure to insert the xml message into a table like this:
CREATE PROCEDURE [dbo].[CreateLogEntry]
@XmlMessage xml = nullI have more parameters there but you get the picture. Then I generated a schema from this procedure(the xml column comes out a string element). Promote that element !! Important step.
Then In my orchestration I have a message of type System.Xml.XmlDocument. And the first thing I do after I receive my incoming message I do this in an expression shape:
MsgXmlLogMessage = MsgSalesOrderRcvd; // Initialize the XmlDocument message
Then you need to Construct a message of the type CreateLogEntry (the schema we generated from the stored procedure). Make sure in this map that you put some value into the Xml element because it is promoted and we set it in an Assignment shape but not in the map. It will fail if you don’t set some dummy value in the map to assignit in an Assignment shape.
Then after the Transform shape put an Assignment shape and type this:
MsgRcvLogRequest.parameters.CreateLogEntry.XmlMessage = MsgXmlLogMessage.OuterXml;
Now you can just send this MsgRcvLogRequest to the SQL Send Adapter to execute the procedure.
Sorry for my english hope you understand if not I’ll try screenshots next 🙂
Actually I tried that first but was unsuccessful in getting the XML to insert into the DB. Can you tell me more about how you handled the message and the send port? I implemented a workaround by changing the column type to ‘text’ and using an updategram, but I’d rather do something with more flexibility. Any info you can provide about your solution would be a great help! Thanks!
December 10, 2008 at 10:59 AM in reply to: The Messaging Engine encountered an error while suspending one or more messages – PRODUCTION #21348BaldurKn,
Not much available after that. All I have is “For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.”
But I did get some errors on my send port but it finally send the messages out to file folder.
There was a failure executing the send pipeline: “Microsoft.BizTalk.DefaultPipelines.XMLTransmit, Microsoft.BizTalk.DefaultPipelines, Version=3.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35” Source: “XML assembler” Send Port: “EDI_Bills_810_4010_Out_1.0.0.0_EDI_Bills_810_4010_Out.ZBOBL_EDIBILLS_810_4010_OUT_Dynamic_Archive_4d2aeeb85dde6a59” URI: “file://E:\EDI\BACKUP_IDocs\EDI_Bills_810\945414530ECP_09_945414530ECP\%MessageID%.xml” Reason: This Assembler cannot retrieve a document specification using this type: “ZBOBL_EDIBILLS”.
I’m thinking this may be related to the performance of the server but I have no idea where to relate. We are using Windows Server 2003 Standard SP1 with 4 gig memory and Intel Xeon 3.2 Gig processor.
December 10, 2008 at 9:05 AM in reply to: The Messaging Engine encountered an error while suspending one or more messages – PRODUCTION #21347Don’t you get some more messages in the error message? Some stacktrace perhaps ?
I once had a similar problem, what we did was create a column of the type ‘xml’ and that way we were able to insert the whole xml message unattached. I think you need MS-SQL 2005 to use that datatype.
Would this work for you ?
I am getting following error while i test that MAP file.
error btml1046: out put validation error the element in namespace ” has incomplete content. list of possible elements expected: ” in namespace ”.
December 10, 2008 at 7:31 AM in reply to: The Messaging Engine encountered an error while suspending one or more messages – PRODUCTION #21342I’m also getting several of “The Messaging Engine encountered an error while deleting one or more messages.” errors.
Great!
Found it! I’ve got a german VS and the translation is just crap, so it’s sometimes hard to find such things.
But there comes an other question:
Could an restart of host instances be done by commandline?
thanks, Daniel
Try
BTS Management Console
-BTS
-BizTalk Group
-Platform
-Host Instances
thehostsinstance (right click Restart)
Sorry,
but how to restart the host instance?
BTS Management Console
-BTS
-BizTalk Group
-Applications
-MyApplikation (rightclick – stop, than choose Fullstop, rightclick Refresh and start)
This is how I restart host instances.
But this either doesn’t work. So may I ask, is there an other way to restart host instances to solve the problem from above?
The current solution I’m trying is to increment the version for the assemblies.
This seems to work.
Thanks Daniel
You should just need to re-GAC the dll and restart the BizTalk Host (the host running the Orchestration process).
Make sure you didn’t change the strong name key of the dll, version number, or that it is set to auto-version. i.e. make sure you have the exact version in the GAC you expect.
Ok, to be more specific, BizTalk 2006 does not have any build-in features to catch the exceptions and display them to you (other than admin tools/HAT). That is the reason Microsoft came up with an exception handling framework in R2. If you are not using ESB then you will have to build your own components similar to that which are available in R2.
You need to possibly
a) develop a .NET component which you can call in all your exception handlers in orchestration, build a fault message and pass it on to the error handler component and persist the message in your required persistence database/logs OR
b) design a fault message schema, build the fault message in every exception handler and publish it to the message box. Have another set of orchestration(s) that will subcribe to the fault message and persrists the message in your persistence database/logs.
In either of the method, you can build a custom UI (web portal) to read the persistence database and display it in the fashion your project needs.
But i strongly recommend, use R2 if possible. It has lot of other features than just exception handling (like edit & resubmit etc.). Taka a look at design and architecture of ESB guidance.
I hope that answers your question. Guys correct me if i am wrong,.
Hi Prasanth,
Thanks for your replay. Please go through my question one more time, I asked how to catch the exceptions, where they
will be stored like EventLog, how to catch the exception message, how to display and how to store in different
locations like Eventlog, Databse..
Can anyone please help me with any example and I would be helpful if you can explain with different scenarios.
Thanks in advance for your help,
Chinnu.
Add your shapes withing a Scope shape and add exception handlers to the scope. If you are not catching the exceptions the messages will be suspended by BizTalk and you will have to debug them using the HAT tool.
If you are using BizTalk R2 then its worth checking out the exception handling framework in the ESB guidance provided by Microsoft.
You need to restart the Host instance that the orchestration is running under when you deploy an updated version of the assembly. BizTalk does not automatically reload assemblies from the GAC.
-
AuthorPosts