by stephen-w-thomas | Aug 7, 2006 | Downloads
This sample shows how to use MSBuild (available with Visual Studio 2005) to build, deploy, and undeploy a BizTalk 2006 Solution. This sample does not use an MSI or a binding file and build, binds, and deploys all BizTalk and .Net code using MSBuild Tasks. This sample uses the custom tasks developed by Microsoft UK and available on GotDotNet.
This sample will work with BizTalk 2006 and BizTalk 2006 R2.
Get more information from the original blog post on this topic: http://www.biztalkgurus.com/biztalk_server/biztalk_blogs/b/biztalk/archive/2006/08/07/how-to-build-and-deploy-biztalk-solutions-using-msbuild.aspx
by stephen-w-thomas | Aug 6, 2006 | Stephen's BizTalk and Integration Blog
MSBuild is the new build platform for Visual Studios. It allows great flexibility, customization (through creating custom Tasks), and integration with unit tests.
While MSBuild doesn’t directly support building BizTalk solutions, tasks are available to call the DEVENV executable and Microsoft UK has released a set of custom tasks to support a wide verity of common BizTalk tasks (available on GotDotNet). This provided an easy method for scripting automated or ad-hock BizTalk builds and deployments using MSBuild.
What can MSBuild do for you?
– Allow for automated and scheduled builds of your BizTalk code
– Extract code from Team Foundation Server (or other source control)
– Run unit tests
– Deploy BizTalk code to local or remote servers
– Control your overall BizTalk deployment by removing past solutions, stopping applications, and terminating Orchestrations
I have put together a sample to show the power and flexibility of using MSBuild for you BizTalk Build, Deployment, and Undeployment.
Download: BizTalk 2006 Build and Deployment with MSBuild
(Note the download included the custom BizTalk task binary files from GotDotNet and required license file.)
This solution provides a sample of how to set up a MSBuild script to build, deploy, and undeploy a BizTalk 2006 Solution. This solution has multiple projects and custom .net code. I also use MSBuild to create all required Send and Receive Ports and bind them to the Orchestration.
The whole build and deployment process does not use a MSI or a binding file. Although, I would have used a binding file but I wasn’t able to get the custom task to work correctly. This approach might not be the best solution to your deployment needs, but is intended to show you what can be done and how.
To run the sample, it must be extracted to your C drive unless you manually edit the configuration files. Once extracted, open a Visual Studio 2005 command window, change your path to C:\SampleDeployment, and type: MSBuild Build.proj to build and deploy the code. To undeploy the solution type: MSBuild UnDeploy.proj
The Build.proj will automatically do an undeployment if needed. This sample has only been tested with a local deployment and I was not able to get it to work remotely on my home environment. I need to do some more research on this.
In case you get lost in all the files, the FullBuild.proj is the full undeploy, build, and deploy in one file. All MSBuild files have been commented so it should be easy to follow what is going on.
Key files and what they do:
Build.proj – this is basically a control file. It imports Build.properties, Undeploy.targets, and Deploy.targets.
Undeploy.proj – this is another control file. It imports Build.properties and Deploy.targets. It is used if you just want to undeploy the solution.
Build.properties – this contains solution specific information like the solution name, dll names, application name, and so on. In theory, this should be the only file you need to update (except I hard coded all the port info into the Build.targets file)
Undeploy.targets – this set of targets handles the termination of running Orchestrations, stopping the Application, and removes the items from the GAC.
Deploy.targets – this set of targets builds the BizTalk solution, creates the Application, creates the ports, deploys the BizTalk assemblies, binds ports to the Orchestration, and starts the Application.
FullDeplou.proj – this file is the same as Build.properties, Undeploy.targets, and Deploy.targets except it has all the targets in one file.
One huge time saver I found when working with the custom tasks from GotDotNet is to download the source code. This way you can view the custom tasks, understand input parameters, and see required fields. It’s a huge time saver.
What’s on the horizon? Integration with BizUnit, FTS, multiple deployment options (like Dev, Test, Prod), and testing the remote deployment support. I hope to post more on these topics later on.
by stephen-w-thomas | Mar 21, 2006 | Downloads
This tool can help with importing and exporting policies and vocabularies in BizTalk Server 2004. This tool supports the use of a configuration file to limit what is imported and exported. This should also work for BizTalk 2006.
Get more information from the original blog post on this topic: http://www.biztalkgurus.com/blogs/biztalk/archive/2006/03/21/BizTalk-Server-2004-Rules-Engine-Deployment-Tool.aspx
by stephen-w-thomas | Mar 20, 2006 | Stephen's BizTalk and Integration Blog
Find yourself running the Rules Engine Deployment Wizard over and over again to export and import policies and vocabularies? Looking for a simple push button approach to move a full configuration from one server to another? My simple Rules Engine Deployment Tool will help with these common tasks.
This tool will do the following:
- Export all your policies and vocabularies
- Export your most recent policies with dependant vocabularies
- Export policies based on a configuration file with dependant vocabularies
- Import all policies and vocabularies in the Import folder
- Import polices and vocabularies based on a configuration file
Download: BizTalk Rules Engine Deployment Tool
How to use this tool:
Simply extract to your C drive, build, and run it. Vocabularies that reference other vocabularies are not really supported. That is, you will have to name the files so that the most referenced vocabulary is imported first or use a configuration file. Also note that the process is not transactional. So, if something fails the import will stop in the middle. I have included some sample policies, vocabularies, and a configuration file so you can see how to use them.
The main purpose of this tool is to move one full set of rules from one server to another server although using the configuration file you can do just about anything you like.
I have not tested this with BizTalk 2006, but I would guess it would work.
by stephen-w-thomas | Sep 7, 2005 | Stephen's BizTalk and Integration Blog
A lot can be said about development with Biztalk Server. For someone new to Biztalk it takes a little practice to learn some of the non-intuitive tasks related to assembly redeployment and basic Biztalk Development.
One common error message is:
“Some items in the removed assembly are still being used by items not defined in the same assembly, thus removal of the assembly failed.
Make sure that items in the assembly you are trying to remove fulfill the following conditions:
1. Pipelines, maps, and schemas are not being used by Send Ports or Receive Locations
2. Roles have no enlisted parties.”
The most common problem I see is what is required to redeploy an assembly. To redeploy an assembly the flowing must be true:
- project is marked with redeploy = true
- dependant assemblies but be undeployed
- included maps and pipelines can not still be set on a send or receive port
- Orchestration instances must be terminated
- Orchestrations must be stopped and unenlisted
- hosts must be restarted to release the cache
As the number of Ports, Maps, Orchestation, and Pipelines in your solution increase, tracking down these errors and manually stopping and starting can be difficult and time consuming.
I have put together a simple Windows Application that will perform some of these basic administrative tasks to help speed up the development process. These tasks include:
- Set all pipeline to default and remove all maps from Send and Receive Ports (make sure you have extracted your current settings as a binding file before hand)
- Stop all Orchestrations
- Stop all Send and Receive Ports
- Start all Orchestrations
- Start all Send and Receive Ports
- Restart all in-process hosts (uses WMI)
All this simple form does is it loops around the existing ExplorerOM and WMI provided in Biztalk.
Download: Biztalk Server Development Helper Tool
Setup is easy. Just review the code and run the form. You must have the correct permissions to run the tasks and to access a remote SQL. If you are using a remote SQL Server, put that server name inside the top right text box. It will default to your local computer name. As always, run this code at your own risk.
Biztalk 2006 greatly simplifies this process. In the mean time, if you are looking for something more powerful take a look at Jon Flander’s Biztalk Snapshot Tool
by stephen-w-thomas | Sep 7, 2005 | Downloads
This tool can help with development with Biztalk 2004. This tool will start and stop Orchestration, start and stop Send and Receive Port, remove pipelines and map from Send and Receive Port, and restart all in-process Biztalk Hosts. This tool is a great resource for any Biztalk developer. This should also work with BizTalk 2006.
Get more information from the original blog post on this topic: http://www.biztalkgurus.com/biztalk_server/biztalk_blogs/b/biztalk/archive/2005/09/07/biztalk-2004-development-helper-tool-_2d00_-a-must-have.aspx