Posts tonen met het label BTS2009. Alle posts tonen
Posts tonen met het label BTS2009. Alle posts tonen

dinsdag 14 februari 2012

BizTalk Server: List of Service Packs and Cumulative Updates available

Each BizTalk Server and Biztalk Adpater pack version already has several service packs and cumulative updates available.
To keep track of all available BTS updates Sandro Pereira made a handy overview on his blog.

BizTalk Server: List of Service Packs and Cumulative Updates available « Sandro Pereira BizTalk Blog

dinsdag 22 november 2011

Cumulative update package 4 for BizTalk Server 2009

Microsoft released a new update package for BTS 2009. Cumulative update package 4 is now available here.


Content:
  • BizTalk Server EDI support: FIX: A TA1 interchange acknowledgement is not returned when you use a two-way receive port to receive EDI interchanges in BizTalk Server
  • BizTalk Server Design Tools: FIX: Visual Studio crashes when you build a project in BizTalk Server 2009 if message types are classes from a referenced .NET project
  • Microsoft BizTalk Server Adapters: FIX: "Error encountered while querying virtual server state for URL" error when you configure WSS adapter in BizTalk Server 2009


!! Important Note:
After you apply this cumulative update, the settings for the DTA Purge and Archive Job roll back to default. This may cause backlog in the BizTalk Tracking (BizTalkDTADb) database. It is recommended to re-configure the job. For more information, visit the following Microsoft Web site: How to Configure the DTA Purge and Archive Job

Error 0xC0002A1F in BizTalk installation

During the BizTalk installation I got the error code '0xC0002A1F' when configuring the installation using the Microsoft BizTalk Server Configuration Wizard. There wasn't any error description given, only the code 0xC0002A1F which of course didn't was of much help.

Turned out this error code meant the following:

Error Code: 0xC0002A1F, Cannot perform encryption or decryption because the secret is not available from the master secret server. See the event log for related errors.

This of course was much clearer. It was clear I needed to restore the Master Secret needed of the SSO (Single Sign-on).

After restoring the master secret, all worked well.

dinsdag 27 september 2011

BTS Project build error on string message

Today Is was making an orchestration that contains a Multi-Part message type, with a message part of type System.String. When building the BizTalk Project it returned the error "'System.String' must be Xml serializable to be a message part type". I've tried several things, but it kept giving this same error no matter what I tried. But I was certain I had used System.String parts in an orchestration before, without any problems. So after some debugging, I tried restarting Visual Studio... and this seemed to do the trick! Apparantly all ik took to succesfully build the biztalk project was restarting Visual Studio.

dinsdag 23 augustus 2011

Biztalk Error: The system cannot find the file specified (Exception from HRESULT: 0x80070002)

Each time I tried to test my new mapping using BizTalk I got this error: The system cannot find the file specified (Exception from HRESULT: 0x80070002).


So the full error in the event viewer looked like this:

A message received by adapter "FILE" on receive location "RECEIVE ORDERS PCE FILE" with URI "C:\B2B.TRADCOM.COM\ORDERS\INBOUND\PCE\*.xml" is suspended.
Error details: The system cannot find the file specified. (Exception from HRESULT: 0x80070002)
MessageId: {F83F1E4B-3B09-4F9B-A9D5-F6C1BD5C2698}
InstanceID: {E162E5AB-E621-4EA1-B643-FD843D7F8D44}


I was able to map the message using Visual Studio, so I was quite sure my BizTalk mapping was correct.

Now it turned out that I forgot to sign the assembly. So the system was unable to place the assembly in the GAC. Because I used a deploy script I didn't notice the resulting warning.

dinsdag 9 augustus 2011

BizTalk Server 2009 CU package 3 available

The cumulative update package 3 for BizTalk Server 2009 is available.

included hotfixes:
  • BizTalk Server EDI support
    • The EDI batching orchestration does not release batches on time in BizTalk Server 2006 R2 and in BizTalk Server 2009
    • AS2 messages remain active after they are processed when the "Track Message Bodies - Request message after port processing" option is enabled on a send port in a BizTalk Server 2009 environment
  • BizTalk Server Administration Tools & Configuration Tools
    • "The group BizTalk Isolated Host Users doesn't exist" error message is logged when you configure the Exception Web Services by using the ESB Configuration Tool in a BizTalk Server 2009 environment
    • All the tracking options under "Track Events" are selected unexpectedly after a BizTalk orchestration is created or updated in BizTalk Server 2009
    • Applications stop responding or crash when System Center Operations Manager monitors BizTalk Server 2009 applications
  • BizTalk Server Message Box and Message Agent, Pipelines & Tracking
    • Performance decreases when a server that is running BizTalk Server 2009 processes a large batch of messages after you customize the settings of the "Large Message Threshold" option and of the "Large Message Fragment size" option
    • Error message when you receive a MIME or SMIME document in BizTalk Server: "Item has already been added"
  • BizTalk Server XLANG engine
    • White space is removed if a message is processed by a mapping operation that is included in a Construct Message shape in BizTalk Server
  • BizTalk Server Setup
    • Cumulative update package 2 for BizTalk Server 2009 fails if a BizTalk group uses a database that uses a case-sensitive collation

Prerequisites
To apply this update, you must have BizTalk Server 2009 installed. For detailed information about how to install this update, see the Readme.txt file that is included in the update package.

Notes
  • You have to stop the following services before you apply this update:
    • ENTSSO
    • IISADMIN
    • WINMGMT
    • BTSNTSVC
  • To install this update in a BizTalk group that includes multiple BizTalk servers, install this server update on each server individually instead of concurrently.


Source: http://support.microsoft.com/kb/2557149

dinsdag 26 juli 2011

BizTalk Training Resources

Where to start learning Biztalk?
First of all here's an interesting post that explains the way Biztalk works by Steef-Jan Wiggers.

A more detailed picture of the BizTalk architecture:


Or if you're interested in some more detailed Biztalk architecture posters:
http://www.biztalk247.com/posters.aspx

Here's another great reference, here you can find a list of tutorial video's, books, virtual labs, and more: http://sandroaspbiztalkblog.wordpress.com/2011/07/13/biztalk-training-resources-virtual-labs-tutorials-virtual-machine-and-more/

donderdag 24 maart 2011

woensdag 23 maart 2011

BizTalk monitoring, PART 2: BTS suspended messages

We've written some code to receive an E-mail when a message is suspended in Biztalk. For this code we've created a scheduled task that is triggered when an error is raised by Biztalk.

First of all I'll show how to setup such a triggered event. Just make a new scheduled task in your windows task scheduler. To start the task you add a new trigger, here's a screenshot from how to set up this trigger:


Then click on the 'Edit event filter' button.
Following screenshot shows you how to configure the trigger to the Biztalk 2009 Errors:


Now that the trigger is set, just configure the scheduled task to run the programming code. Just like the BizTalk monitoring tool of my previous post, the configuration is done in an external XML File.

So here is the used code the send us an E-mail with an overview of suspended messages, including the error details and the receiving port. The method will return a boolean to specify if there are no suspended messages.


   1:  public Boolean CheckBTSQueue()
   2:          {
   3:              String tab = "    ";
   4:              //Constant Values
   5:              String ErrorMessage = tab + "<b><i>Suspended message with error at {0}:</i></b><BR>" +
   6:                  tab + tab + "Receive Port: {1}<BR>" +
   7:                  tab + tab + "Error Code: {2}<BR>" + 
   8:                  tab + tab + "Error Description: {3}<BR><BR>";
   9:                  //tab + tab + "Inner Exception: {3}";
  10:              String ErrorSuspendedMsgHeader = "<strong>WARNING: Suspended Message(s) in Biztalk</strong><BR><BR>";
  11:              String MailSubject = "Messages stuck on " + Dns.GetHostName();
  12:   
  13:              StringBuilder suspendedMessages = new StringBuilder();
  14:   
  15:              Boolean allRunning = true;
  16:   
  17:              BizTalkOperations operation = new BizTalkOperations(dBServer, dB);
  18:   
  19:              int count = 10;
  20:              foreach (BizTalkMessage message in operation.GetMessages())
  21:              {
  22:                  if (message.MessageStatus == MessageStatus.Suspended)
  23:                  {
  24:                      suspendedMessages.AppendLine(String.Format(ErrorMessage, message.CreationTime.ToString(),
  25:                          message.Context.Read("PortName", "http://schemas.microsoft.com/BizTalk/2003/messagetracking-properties"), message.ErrorCode, message.ErrorDescription));
  26:                      //message.Context.Read("Name", "NameSpace");
  27:   
  28:                      count--;
  29:   
  30:                      allRunning = false;
  31:                  }
  32:                  if (count <= 0)
  33:                  {
  34:                      count--;
  35:                      break;
  36:                  }
  37:              }
  38:   
  39:              if (!allRunning)
  40:              {
  41:                  if (!String.IsNullOrEmpty(suspendedMessages.ToString()))
  42:                      suspendedMessages.Insert(0, ErrorSuspendedMsgHeader);
  43:   
  44:                  String body = "";
  45:   
  46:                  if (count < 0)
  47:                      body = "Only last 10 messages are given<BR><BR>";
  48:   
  49:                  body += suspendedMessages.ToString();
  50:   
  51:                  Helper.SendMail(body, MailSubject, sendMailAddress, receiveMailAddress, SMTP);
  52:              }
  53:   
  54:              return false;
  55:          }

the method to send an email, the method to read the configuration from XML and the XML itself are the same as in my previous Blog. Here they are again:

the method to send an email is the following:


   1:  public static void SendMail(String body, String subject, String fromAddress, String toAddress, String SMTPAddress)
   2:          {
   3:              MailMessage msg = new MailMessage(fromAddress, toAddress);
   4:              msg.IsBodyHtml = true;
   5:              msg.Body = body;
   6:              //msg.From = new MailAddress(fromAddress);
   7:              msg.Subject = subject;
   8:   
   9:              System.Net.Mail.SmtpClient smtp = new SmtpClient(SMTPAddress);
  10:              smtp.Send(msg);
  11:              //SmtpMail.SmtpServer = SMTPAddress;
  12:              //SmtpMail.Send(msg);
  13:          }

to read the configuration out of the XML file, we've programmed following in the constructor (all is read to private class variables:


   1:  private string dBServer;
   2:          private string dB;
   3:          private string userName;
   4:          private string password;
   5:   
   6:          private List<string> BTSService;
   7:   
   8:          private string sendMailAddress;
   9:          private string receiveMailAddress;
  10:          private string SMTP;
  11:   
  12:          public Monitor()
  13:          {
  14:              XmlDocument config = new XmlDocument();
  15:              config.Load(System.IO.Directory.GetCurrentDirectory() + "/BTSMonitorConfiguration.xml");
  16:   
  17:              try
  18:              {
  19:                  dBServer = config.SelectSingleNode("CONFIGURATION/DBSETTINGS/Server").InnerText;
  20:                  dB = config.SelectSingleNode("CONFIGURATION/DBSETTINGS/DB").InnerText;
  21:                  userName = config.SelectSingleNode("CONFIGURATION/DBSETTINGS/UserName") == null ?
  22:                      "" : config.SelectSingleNode("CONFIGURATION/DBSETTINGS/UserName").InnerText;
  23:                  password = config.SelectSingleNode("CONFIGURATION/DBSETTINGS/Password") == null ?
  24:                      "" : config.SelectSingleNode("CONFIGURATION/DBSETTINGS/Password").InnerText;
  25:   
  26:                  BTSService = new List<string>();
  27:   
  28:                  foreach(XmlNode service in config.SelectNodes("CONFIGURATION/BTSSETTINGS/BTSSERVICES/BTSServiceName"))
  29:                  {
  30:                      BTSService.Add(service.InnerText);
  31:                  }
  32:   
  33:                  sendMailAddress = config.SelectSingleNode("CONFIGURATION/MAILSETTINGS/From").InnerText;
  34:                  receiveMailAddress = config.SelectSingleNode("CONFIGURATION/MAILSETTINGS/To").InnerText;
  35:                  SMTP = config.SelectSingleNode("CONFIGURATION/MAILSETTINGS/SMTP").InnerText;
  36:              }
  37:              catch (Exception e)
  38:              {
  39:                  StringBuilder error = new StringBuilder();
  40:                  error.AppendLine("not all necessary data to perform the action is provided.");
  41:                  error.AppendLine("Make sure these fields are correctly filled in in the XML File:");
  42:                  error.AppendLine("\tDBServer (server name)");
  43:                  error.AppendLine("\tDB (Database)");
  44:                  error.AppendLine("\tBTSServiceName (BTS Service Name)");
  45:                  error.AppendLine("\tFrom (sending mail address)");
  46:                  error.AppendLine("\tTo (receiveing mail address)");
  47:                  error.AppendLine("\tSMTP (SMTP host address)");
  48:                  throw (new Exception(error.ToString()));
  49:              }
  50:          }


and finally the created XML file:


<?xml version="1.0" encoding="utf-8" ?>
<CONFIGURATION>
  <DBSETTINGS>
    <Server>.</Server>    <!-- Server Name -->
    <DB>BizTalkMgmtDb</DB>    <!-- DataBase Name -->
    <!--<UserName>user</UserName>-->    <!-- optional -->
    <!--<Password>password</Password>-->    <!-- optional -->
  </DBSETTINGS>
  <BTSSETTINGS>
    <BTSSERVICES>
      <BTSServiceName>BizTalk Service BizTalk Group : BizTalkServerApplication</BTSServiceName>      <!-- BTS Service Name -->
      <BTSServiceName>BizTalk Service BizTalk Group : BizTalkServerApplication2</BTSServiceName>
      <!-- BTS Service Name -->
    </BTSSERVICES>
  </BTSSETTINGS>
  <MAILSETTINGS>
    <From>from@company.com</From>
    <To>to@company.com</To>
    <SMTP>smtp.company.com</SMTP>
  </MAILSETTINGS>
</CONFIGURATION>



In this example, only the last 10 suspended messages are mailed to us.

These monitoring mails have proven to be very valuable to us.
Hope you enjoyed my post.

donderdag 6 januari 2011

Not able to add a BizTalk Project in Visual Studio 2008

It's possible that you're not able to add a biztalk project in your visual studio 2008.
The likely cause is a new visual studio 2008 installation, or it's updated in any way.

The solution to this problem is quite simple.You could just do a repair of your BizTalk with the setup, this should do the trick.

Or another way to accomplish this is by changing the registry key [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Projects\{FAE04EC0-301F-11d3-BF4B-00C04F79EFBC}] from ‘csproj’ to ‘csproj;btproj’.
For a 64 bit version of visual studio this would be as follows:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\9.0\Projects\{FAE04EC0-301F-11d3-BF4B-00C04F79EFBC}
Somehow this key gets reset every time the Visual Studio installation is changed...

RESOURCES:
http://ronaldlokers.blogspot.com/2010/12/visual-studio-2008-doesnt-know-biztalk.html
http://blogs.msdn.com/b/biztalkcrt/archive/2009/08/21/visual-studio-2008-fails-to-create-open-biztalk-projects.aspx

vrijdag 17 december 2010

Cumulative update package for BizTalk Server 2009

Recently Microsoft released a cumulative update package 1 for BTS 2009.
This package contains 60 fixes with 55 applying to BizTalk Server 2009 and 5 to UDDI as well as added support to HIPAA 5010. The release has 32 and 64bit downloads and can be obtained either by contacting Customer Services or by requesting the download via the online self-service feature.


link: http://support.microsoft.com/kb/2429050

another update package recently released by microsoft is the cumulative update package 1 for BizTalk adapter pack 2.0.  It includes 11 fixes that apply to the SAP Adapter, Oracle Adapter and the baseline framework itself. It applies to any system using the BizTalk Adapter Pack 2.0 (and .NET solutions consuming the adapters, BizTalk Server 2006 R2 SP1, and BizTalk Server 2009).


link: http://support.microsoft.com/kb/2444952

maandag 13 december 2010

BTS 2009: Remove Byte Order Mark from messages

Some of our recipients where complaining that they received a '?' in front of the messages we send with BizTalk.
Now, when we view the messages we send to them from the tracked messages, nothing seems to be wrong at first.
As you can see in the below image, the sent message just starts with "<?xml version="1.0" encoding="utf-8"?>" like it should be.




When you look at the same message in the binary mode however, you'll see that there are several extra characters added in front of the actual message. These extra characters are called Byte Order Marks (BOM). These characters indicate which of the several unicode representations the text is encoded in. In my case, the message is encoded in UTF-8.
For UTF-8 the BOM is "
EF BB BF" (in hexadecimal), or "" (in ISO-8859-1), like shown in the below picture.


Although there's actually nothing wrong with the sent message, some client applications might have a problem reading your message.

I'll show you how easy it is to remove these extra characters. The solution for this problem is to just correctly configure your send port. I'm not sure of the older BizTalk versions, but in BizTalk 2009 there is a setting on the XML Assembler component called 'PreserveBOM'. When you change this setting to False, the Byte Order Mark characters will be omitted in the sent message.




When I now reprocess the same message with this setting, the resulting message will be without a BOM. The picture shows that, even in binary view, the message starts with "<?xml version="1.0" encoding="utf-8"?>".



donderdag 9 december 2010

BTS 2009: "Failed to update binding information"

We were redeploying one of our mappings to Biztalk 2009 by just adding the assembly to the resources in the BizTalk Admin Console. By doing this we got a strange looking error as shown in below figure.







The error detail is : 'Receive Location 'Receive Order Port' has no Transport Type specified.


The actual error is quite clear, the strange thing however is that the receive location that is mentioned didn't exist anymore in our application.

After doing some research I found out that BizTalk stores info about the last deployments in a local folder, namely 'C:\Documents and Settings\[user name]\Application Data\Microsoft\BizTalk Server\Deployment\BindingFiles' (Or for windows Vista / windows 7 in 'C:\Users\[user name]\AppData\Roaming\Microsoft\BizTalk Server\Deployment\BindingFiles').
And when doing a redeploy of some resources, BizTalk will still use this locally stored information. When this information then is wrong, you'll get a 'failed to update binding information' error.

The solution to this problem is quite easy, just remove all binding info files. After this you shouldn't get any more errors, at least not of this kind :).