BizTalk Pipeline Components Extensions Utility Pack: Local Archive Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Local Archive Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016, once again, got a new update and it now has a new component that you can use in your custom BizTalk Server pipelines: Local Archive Pipeline Component.

Local Archive Pipeline
Component

BizTalk Server Local Archive pipeline component it’s a
pipeline component that can be used for archiving incoming/outgoing message
from any adapters. It will provide the following capabilities:

  • It can be used in any stage of a receive pipeline or send pipeline;
  • It can be used in multiple stages of a receive pipeline or send pipeline;
  • It provides an option for you to specify the location path for where you want to save the message: local folder, shared folder, network folder.
  • It can be used from any adapter:
    • If the adapter provides the ReceivedFileName property promoted like the File adapter or FTP adapter the component will take this value in consideration and save the message with the same name;
    • Otherwise, it will use the MessageID, saving the file with the MessageID has its name without extension.
public Microsoft.BizTalk.Message.Interop.IBaseMessage Execute(Microsoft.BizTalk.Component.Interop.IPipelineContext pc, Microsoft.BizTalk.Message.Interop.IBaseMessage inmsg)
{
	// 
	// TODO: implement component logic
	// 
	// this way, it's a passthrough pipeline component

	if (this.PerformBackup)
	{
		try
		{
			//Get Message Id
			Guid msgId = inmsg.MessageID;

			//Get Filename by FileAdapter NS
			string fileName = inmsg.Context.Read("ReceivedFileName", "http://schemas.microsoft.com/BizTalk/2003/file-properties").ToString();
			if (string.IsNullOrEmpty(fileName))
			{
				fileName = inmsg.Context.Read("ReceivedFileName", "http://schemas.microsoft.com/BizTalk/2003/ftp-properties").ToString();
				if (string.IsNullOrEmpty(fileName))
				{
					fileName = msgId.ToString();
				}
			}

			if (!new DirectoryInfo(this.Folder).Exists)
			{
				try
				{
					Directory.CreateDirectory(this.Folder);
				}
				catch
				{
					throw;
				}
			}

			SaveStreamToFile(inmsg.BodyPart.Data, fileName, true);

			inmsg.BodyPart.Data.Position = 0;
		}
		catch
		{
			throw;
		}
	}

	return inmsg;
}

What is BizTalk Pipeline Components Extensions Utility
Pack?

BizTalk Pipeline Components Extensions Utility Pack is
a set of custom pipeline components (libraries) with several custom pipeline
components that can be used in received and sent pipelines, which will provide
an extension of BizTalk out-of-the-box pipeline capabilities.

The project is
available on the BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity), and everyone can contribute with new
pipeline components that can be extended or improve the existing BizTalk Server
capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Local Archive Pipeline Component

At the moment it is only available for BizTalk Server
2016, but it will soon be compiled and available for previous versions of the
product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from
GitHub here:

BizTalk Pipeline Components Extensions Utility Pack
GitHub

The post BizTalk Pipeline Components Extensions Utility Pack: Local Archive Pipeline Component appeared first on SANDRO PEREIRA BIZTALK BLOG.

BizTalk Pipeline Components Extensions Utility Pack: JSON Encoder Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: JSON Encoder Pipeline Component

At the beginning of this week I ask on twitter what should be the topic of my next blog posts: BizTalk Server and JSON support or Azure Logic Apps. And the majority of the replies was: BizTalk Server and better JSON support.

For that reason, I will respect my reader’s decision and I will be releasing today a new addition to my BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016: Custom JSON Encoder Pipeline Component.

You may be asking yourself: this component already exists by default in BizTalk Server 2016, so why we need another?

Yes, Microsoft provides out-of-the-box a JSON Encoder to transform the XML messages into a JSON message and sends it out. But, unfortunately, in some cases, it doesn’t work as you should expect to work and it will fail, in my case with this error:

Reason: Value cannot be null.
Parameter name: key

And in reality what I just want is a simple way, that, I hope, it would work for all scenarios (aka XML messages) in a simple and effective way.

JSON Encoder Pipeline Component

The Custom JSON Encoder is a pipeline component for BizTalk Server which can be used in a Send Pipeline (Encode stage) to encode any XML message into a JSON equivalent in a simple and effective way.

BizTalk Server Custom JSON Encoder pipeline component

Because I would like to have a choice between using the default pipeline component provide by Microsoft, at least the internal behavior, this pipeline component is an extension of the default JSON Encoder pipeline component and fully compatible with it and you will be able from the BizTalk Administration console you will be able to decide if:

  • You want to use
    the behavior of the default JSON Encoder pipeline component provide by
    Microsoft by setting the UseCustomEncoder property to False;
BizTalk Server Custom JSON Encoder pipeline component use custom behavior
  • or use the custom
    behavior to generate the JSON message by setting the UseCustomEncoder property
    to True;

What is BizTalk Pipeline Components
Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline
components (libraries) with several custom pipeline components that can be used
in received and sent pipelines, which will provide an extension of BizTalk
out-of-the-box pipeline capabilities.

The project is available on the BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity), and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Unzip File Pipeline Component

At the moment it is only available for BizTalk Server 2016, but it will
soon be compiled and available for previous versions of the product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from
GitHub here:

BizTalk Pipeline Components Extensions Utility Pack
GitHub

The post BizTalk Pipeline Components Extensions Utility Pack: JSON Encoder Pipeline Component appeared first on SANDRO PEREIRA BIZTALK BLOG.

Guest blog by Peter Vervoorn – Recipe: Calling multiple Disassemblers in a Receive pipeline

Guest blog by Peter Vervoorn – Recipe: Calling multiple Disassemblers in a Receive pipeline

Happy to introduce my first guest blog author: Peter Vervoorn from Virtual Green. Peter is a very experienced integration specialist. He has been working in ICT since 1995 and was a co-founder of Axon Olympus (now part of the Codit Group). Until his sabbatical in 2014 he headed the team of consultants at Axon Olympus as Technical Director. During his sabbatical in Thailand, he lost over 50 kilos and currently, he divides his time between Thailand and The Netherlands. He is a specialist with (Microsoft) Integration Tools and Technologies like BizTalk Server, Windows 10 IoT, Node-RED and is also involved in developing industrial automation prototypes.

Peter reach me with this funny, a bit unusual but quite interesting scenario: Calling multiple Disassemblers in a Receive pipeline, and I challenge him to be my first guest blog author on my blog. Challenge that he gladly accepted.

Situation

You receive a zip file, containing several files to extract. The extracted files should be disassembled too. (Possibly because they are in flat file format, or you want to call the XmlDisassembler to set the message type.)

Problem

Although the disassemble stage in the receive pipeline can contain multiple components, only the first component (matching the message) will be executed.

Solution

Create a new disassembler component, which will handle calling the sequential disassembler components.

The implementation of the Disassemble method is very easy, just call the initial component in the sequence.

The GetNext method is where it becomes a bit more interesting. Here we would have to extract all the messages from the first stage and feed them to the second stage. Note that it is not possible to create a single instance for the second stage and keep feeding it messages; each message requires its own instance of the component.

To do this, we have to create a new instance of the second stage component. Then we set the required properties (e.g., with values from the property bag.) Then we call the Disassemble method on the component. Next, we call GetNext to retrieve all messages and queue them.

The remainder of the implementation is for dequeening the messages.

Code

In the sample code below, all the usual methods (Load, Save, Validate, etc.) are not shown. Only the two relevant methods are shown. Also, all the plumbing has been removed for brevity/clarity.

[ComponentCategory(CategoryTypes.CATID_PipelineComponent)]
[ComponentCategory(CategoryTypes.CATID_DisassemblingParser)]
[System.Runtime.InteropServices.Guid("YOUR-GUID-HERE")]
public class MultiDisassembler : IBaseComponent, IPersistPropertyBag, IComponentUI, IDisassemblerComponent
{
    private ExtractorComp extractPC = new ExtractorComp();
    private Queue<IBaseMessage> messages = null;

    public void Disassemble(IPipelineContext pContext, IBaseMessage pInMsg)
    { extractPC.Disassemble(pContext, pInMsg); }

    public IBaseMessage GetNext(IPipelineContext pContext)
    {
        if (messages == null)
        {
            messages = new Queue<IBaseMessage>();
            IBaseMessage msgS1 = null;
            while ((msgS1 = extractPC.GetNext(pContext)) != null)
            {
                XmlDasmComp  xmlDasmPC = NewXmlDasmWithPropertiesSet();
                xmlDasmPC.Disassemble(pContext, msgS1);
                IBaseMessage msgS2 = null;
                while ((msgS2 = xmlDasmPC.GetNext(pContext)) != null)
                { messages.Enqueue(msgS2); }
            }
        }

        if (messages.Count > 0)
        { return messages.Dequeue(); }
        return null;
    }
    //...
    //Missing Code
}

Tips

  • You can add more stages, as required;
  • If necessary, you can inspect a message and choose to either enqueue it directly or use a different component to disassemble that message.
    (An example would be a zip file containing a mix of XML files and nested zip files)
  • In the above sample, all messages are queued when the GetNext method is called the first time. Another possibility is getting the next message in a just-in-time fashion. This requires a bit of additional work as you have to do additional housekeeping and handle possible empty messages.
  • Often you see a disassembler also implementing IComponent. This is not required if only the DisassemblingParser attribute is set.

THIS SAMPLE CODE  IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND.

BizTalk Server Recipe: Calling multiple Disassemblers in a Receive pipelineBizTalk Server Recipe: Calling multiple Disassemblers in a Receive pipeline (2 KB)
Microsoft | TechNet Gallery

BizTalk Pipeline Components Extensions Utility Pack

The pipeline component is available on BizTalk Pipeline Components Extensions Utility Pack project, that is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity), and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Unzip File Pipeline Component

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack: Unzip File Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Unzip File Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016, once again, got a new update and it now has a new component that you can use in your custom BizTalk Server pipelines: Unzip File Pipeline Component.

Unzip File Pipeline Component

The Unzip File Pipeline Component for BizTalk Server can be used in a Received pipeline (Disassemble stage), and it allows you to receive a compress (zip/gzip) file and extract its contents into different XML messages.

  • The capabilities are like those available in any compression software such as WinZip or 7-zip:
  • This component doesn’t require any configurations.

This was an old component that I had that I now updated and improved to BizTalk Server 2016 with the help with my internal team at DevScope, in particular, Pedro Almeida.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity), and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Unzip File Pipeline Component

At the moment it is only available for BizTalk Server 2016, but it will soon be compiled and available for previous versions of the product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack: Remove XML Namespace Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Remove XML Namespace Pipeline Component

To end these week contributions, tomorrow is national holiday in Portugal, BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016 got a new update. A new component that you can use in your custom BizTalk Server Send pipelines is now available: Remove XML Namespace Pipeline Component.

Remove XML Namespace Pipeline Component

The XML Remove Namespace pipeline component was developed in the old days by Johan Hedberg for BizTalk Server 2006 – you can check the original post here – that I now migrate to BizTalk Server 2016 with his permission and it can be used to remove XML namespaces from XML documents inside custom pipelines.

This has the availability to transform the root of the message from this:

<ns0:Blah xmlns:ns0="http://RemoveXmlNamespace.BTS.BlahMessage">

Into this:

<Blah>

As Johan mention in his original post, you shouldn’t remove the namespace from the messages, however, we don’t leave in a perfect world and we need to deal with legacy systems and sometimes they required, for unknown reasons for me, that we deliver messages without namespace.

To use this pipeline component in your projects you just copy the “RemoveXmlNamespace.PipelineComponents.dll” file into “Pipeline Components“ folder that exists in BizTalk Server Installation directory: “..Program Files (x86)Microsoft BizTalk Server <version>Pipeline Components” on every server.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Zip Pipeline Component

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity) and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

At the moment it is only available for BizTalk Server 2016 but it will soon be compiled and available for previous versions of the product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack: Zip Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Zip Pipeline Component

And once again, BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016 got a new update. A new component that you can use in your custom BizTalk Server Send pipelines is now available: Zip Pipeline Component.

Zip Pipeline Component

The Zip Pipeline Component is a pipeline component for BizTalk Server which can be used in a send pipeline (encode stage) and is intended to compress (zip/gzip) outgoing messages.

  • The capabilities are similar to those available in compression software such as WinZip or 7-zip:
  • This component requires two configurations that are:
    • the “FileExtension” where you can specify if you want for example a .zip or .gz file.
    • and “Enabled” that is a true or false value to activate the compression.

No compression/decompression software needs to be installed in the BizTalk Server machines.

This was an old component that I had that I now updated and improved to BizTalk Server 2016 with the help with my internal team at DevScope, in special, Pedro Almeida.

To use this pipeline component in your projects you just copy the “BizTalk.PipelineComponents.ZipFile.dll” file into “Pipeline Components“ folder that exists in BizTalk Server Installation directory: “..Program Files (x86)Microsoft BizTalk Server <version>Pipeline Components” on every server.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Zip Pipeline Component

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity) and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

At the moment it is only available for BizTalk Server 2016 but it will soon be compiled and available for previous versions of the product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack: Carry SOAPHeader To WCF-BasicHttp Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Carry SOAPHeader To WCF-BasicHttp Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack community project for BizTalk Server 2016 got a new update and now it has another new component that you can use in your custom BizTalk Server pipelines: Carry SOAPHeader To WCF-BasicHttp Pipeline Component.

Carry SOAPHeader To WCF-BasicHttp Pipeline Component

The Carry SOAPHeader To WCF-BasicHttp is a pipeline component for BizTalk Server which can be used in a send pipeline and is intended to carry forward the received custom SOAP Header to the outgoing message, in other words:

  • This component will read the Custom SOAPHeader from the Message Context Properties
    • The custom header name will be defined on the component configuration and we can read it from the target “http://schemas.microsoft.com/BizTalk/2003/SOAPHeader”
  • and will configure this custom header in the OutboundCustomHeaders property used by the WCF-BasicHTTP Adapter.

The OutboundCustomHeaders property is used if you want to specify the custom SOAP headers for outgoing messages. When this property is used, the property must have the <headers> element as the root element. All of the custom SOAP headers must be placed inside the <headers> element

  • If the custom SOAP header value is an empty string, you must assign <headers></headers> or <headers/> to this property

This component is useful if you are implementing CBR operations on legacy service (SOAP – .asmx) using the new WCF-Adapters in BizTalk Server. Notice that the SOAP adapters, still present in BizTalk Server 2016, are obsolete and discontinued.

To use this pipeline component in your projects you just copy the “CarrySOAPHeader.dll” file into “Pipeline Components“ folder that exists in BizTalk Server Installation directory: “..Program Files (x86)Microsoft BizTalk Server <version>Pipeline Components” on every server.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Multi-Part Message Attachments Zipper Pipeline Component

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity) and everyone can contribute with new pipeline components that can be extended or improve the existing BizTalk Server capabilities.

At the moment it is only available for BizTalk Server 2016 but it will soon be compiled and available for previous versions of the product.

Where to download it?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack: Multi-Part Message Attachments Zipper Pipeline Component

BizTalk Pipeline Components Extensions Utility Pack: Multi-Part Message Attachments Zipper Pipeline Component

A few days ago, I publish the first version of the community project BizTalk Pipeline Components Extensions Utility Pack for BizTalk Server 2016. Today I please to announce that a new pipeline component was added to this project: Multi-Part Message Attachments Zipper Pipeline Component.

This was an old component that I had published in the past for BizTalk Server 2006/2006 R2/2009 and 2010 that I now updated and improved to BizTalk Server 2016 with the help with my internal team at DevScope, in special, Pedro Almeida.

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom pipeline components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

BizTalk Pipeline Components Extensions Utility Pack: Multi-Part Message Attachments Zipper Pipeline Component

Multi-Part Message Attachments Zipper Pipeline Component

The BizTalk Multi-Part Message Attachments Zipper is a pipeline component for BizTalk Server which can be used in a send pipeline and is intended to replace all attachments of a multi-part message for its zipped equivalent.

The capabilities are similar to those available in compression software such as WinZip or 7-zip:

  • Attachments Compression – Extracts, in a send pipeline, all message parts include in a multi-part message that is not included in the message body (Message Body Part = False), compresses it and attaches the compressed attachment back to the message.
  • This component requires one configuration that is the FileExtension where you can specify if you want for example a .zip or .gz file.

No compression/decompression software needs to be installed in the BizTalk Server machines.

To use this pipeline component in your projects you just copy the “PipelineComponentMultipartMsgZipAttach.dll” file into “Pipeline Components“ folder that exists in BizTalk Server Installation directory: “..Program Files (x86)Microsoft BizTalk Server <version>Pipeline Components” on every server.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity) and everyone can contribute with new pipeline components that can extend or improve the existing BizTalk Server capabilities.

At the moment it is only available for BizTalk Server 2016 but it will soon be compiled and available for previous versions of the product.

Where to download?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline Components Extensions Utility Pack for BizTalk Server 2016 available on GitHub

BizTalk Pipeline Components Extensions Utility Pack for BizTalk Server 2016 available on GitHub

I finally started and published the first version of the sibling BizTalk project Mapper Extensions UtilityPack for BizTalk Server 2016: BizTalk Pipeline Components Extensions Utility Pack

What is BizTalk Pipeline Components Extensions Utility Pack?

BizTalk Pipeline Components Extensions Utility Pack is a set of custom pipeline components (libraries) with several custom components that can be used in received and sent pipelines, which will provide an extension of BizTalk out-of-the-box pipeline capabilities.

BizTalk Pipeline Components Extensions Utility Pack

What’s to expect in this version?

Content-Based Routing Pipeline Components

CBR IDoc Operation Promotion Encode component (CBRIdocOperationPromotionEncode)

  • Content-Based Routing Component to promote IDOC Operation property.
    • This component requires one configuration that is the MessageType string to be ignored. Then it will take the last string (word) from the MessageType Message Context Property and promote it to the Operation Message Context Property.
    • This component is to be used on the Encode stage of BizTalk Server Send Pipelines and to be used exclusively on Send Ports.

CBR Operation Promotion Encode component (CBROperationPromotionEncode)

  • Content-Based Routing Component to promote Operation property.
    • This component doesn’t require any configuration. Then it will take the value (word) which lies ahead of the cardinal (#) from the MessageType message context property and promote it to the Operation Message Context Property.
    • This component is to be used on the Encode stage of BizTalk Server Send Pipelines and to be used exclusively on Send Ports.

The project is available on BizTalk Server Open Source Community repository on GitHub (https://github.com/BizTalkCommunity) and everyone can contribute with new pipeline components that can extend or improve the existing BizTalk Server capabilities.

At the moment it is only available for BizTalk Server 2016 but it will soon be compiled and available for previous versions of the product.

Special thanks to my team coworker at DevScope: Pedro Almeida for helping me on this project.

Deploying Pipeline Components

All the .NET pipeline component assemblies (native and custom) must be located in the Pipeline Components folder to be executed by the server. If the pipeline with a custom component will be deployed across several servers, the component’s binaries must be present in the specified folder on every server.

You do not need to add a custom pipeline component to be used by the BizTalk Runtime to the Global Assembly Cache (GAC).

To know more about Deploying Pipeline Components, please see: Deploying Pipeline Components

Where to download?

You can download BizTalk Pipeline Components Extensions Utility Pack from GitHub here:
BizTalk Pipeline Components Extensions Utility Pack
GitHub

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community. View all posts by Sandro Pereira

BizTalk Pipeline does not open with BizTalk Pipeline Editor! Instead it opens with the XML (Text) Editor!

BizTalk Pipeline does not open with BizTalk Pipeline Editor! Instead it opens with the XML (Text) Editor!

In the sequence of one of my last blog posts, I notice that in the same project also while trying to open a BizTalk pipeline inside Visual Studio, again, normally a simple and easy double-click operation to open this time the BizTalk Pipeline Editor, the resource didn’t open with the correct editor: BizTalk Pipeline Editor, instead, it opened with the XML (Text) Editor

BizTalk Pipeline does not open with BizTalk Pipeline Editor: Pipeline open with XML Text Editor

I’m used to seeing this behavior ins orchestration but it is the first time, that I can remember, to see the same happening with pipelines. Again, this has a quick workaround but it becomes annoying after a few times.

Cause

Well, again and similar to the orchestrations, I don’t know exactly what can cause this problem but I suspect that this behavior happens more often when we migrate projects, or when we try to open previous BizTalk Server versions projects in recent versions of Visual Studio, special if we skip one or more versions, for example: from BizTalk Server 2010 to 2013 R2.

And may happen because of different configurations inside the structure of the “<BizTalk>.btproj” file.

The cause of this strange behavior is without a doubt related to a mismatched setting inside the structure of the “<BizTalk>.btproj” file in the Pipeline nodes (each pipeline inside your project will reflect one Pipeline node specifying the name of the file, type name, and namespace. Normally it has this aspect in recent versions of BizTalk Server:

<ItemGroup>
   <Pipeline Include="SendOrReceivePipelineName.btp">
      <Namespace>MyProjectName.Pipelines</Namespace>
      <TypeName>SendOrReceivePipelineName</TypeName>
   </Pipeline>
</ItemGroup>

But sometimes we will find an additional element:

<ItemGroup>
   <Pipeline Include="SendOrReceivePipelineName.btp">
      <Namespace>MyProjectName.Pipelines</Namespace>
      <TypeName>SendOrReceivePipelineName</TypeName>
      <SubType>Designer</SubType>
   </Pipeline>
</ItemGroup>

When the SubType element is present, this strange behavior of automatically open the pipeline with the XML (Text) Editor.

Solution

First, once again let’s describe the easy workaround for this annoying problem/behavior:

  • On the solution explorer, right-click on the pipeline name and then select “Open With…” option

BizTalk Pipeline does not open with BizTalk Pipeline Editor: Visual Studio Pipeline open with

  • On the “Open with …” window, select “BizTalk Pipeline Editor” option and click “OK”.

BizTalk Pipeline does not open with BizTalk Pipeline Editor: Open with Pipeline-Editor

Once again, this will force Visual Studio to actually open the pipeline with the Pipeline Editor. But again, this will be a simple workaround because next time you try to open the pipeline inside Visual Studio it will open again with the XML (Text) Editor.

Similar to the orchestration behavior, force to “Set as Default” inside the “Open with …” window:

  • Select “BizTalk Pipeline Editor” option, click “Set as Default”
  • And then click “OK”.

It will not solve the problem, once again, if you notice in the picture above it is actually already configured as the default viewer.

So, to actually solve once and for all this annoying behavior, once again you need to adjust the configurations inside the btproj file, by:

  • Open the “<BizTalk>.btproj” (or project) file(s) that contain the pipeline(s) with this behavior with Notepad, Notepad++ or other text editors of your preference.
  • Remove the <SubType>Designer</SubType> line
  • Save the file and reload the project inside Visual Studio

If you then try to open the pipeline it will now open with the BizTalk Pipeline Editor.

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc.

He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community.

View all posts by Sandro Pereira