by community-syndication | Jun 28, 2006 | BizTalk Community Blogs via Syndication
As mentioned previously we recently launched the BizTalk Server 2006 Developer Center. This project constituted a complete rebuild of the previous BizTalk Server 2004 Developer Center. For May and June we featured orchestrations. This included new code samples, an FAQ paper on orchestrations, and in-depth content surfaced from the core documentation. With the re-design of the site it’s easier than ever to learn to develop, deploy, administer, and use BizTalk Server 2006. For July we will be focusing on Adapters
In addition to the Developer Center, we also launched the BizTalk Server 2006 TechCenter. The TechCenter provides easy access to BizTalk Server 2006 technical documentation, downloads, and community, as well as to IT Pro favorites such as the Events & Errors Message Center. Each navigation page within the technical library includes quick access to search BizTalk Server newsgroups and knowledge-base articles as seen, for example, on the Getting Started page. Among many things, the site contains:
- Virtual labs
- The end-to-end tutorial as downloadable Word docs
- New content on Clustering BizTalk Server
- Links to the Installation Instructions
- Links to the Production Documentation published on MSDN
by community-syndication | Jun 28, 2006 | BizTalk Community Blogs via Syndication
I built a sample (you can download it here)
based upon a question asked in the WF forums last night (you can see the post here).
I wanted to post it here so I could point out some of the interesting features it
has in it.
First – there is a CallWorkflowActivity – which creates and executes another workflow
in a synchronous manner. The WF built-in InvokeWorkflowActivity invokes another
workflow – but does it asynchronously. It turns out to do is synchronously
you have to build a custom activity – mostly because synchronously you have to make
some assumptions about the workflow you are calling. In my example – the
assumption I am making is that the “called” workflow will have parameters to pass
in, and parameters that are return – but there is no other communication between the
host and the workflow.
Now – since my CallWorkflowActivity can’t talk to the WorkflowRuntime directly – in
order to make it work I implemented a service to add to the WorkflowRuntime.
Why can’t the activity talk to the WorkflowRuntime? Well that could create some
interesting problems – like what if an Activity could ask the WorkflowRuntime to persist
the WorkflowInstance the Activity is being executed inside of? The Activity
would be executing waiting for persistence, the WorkflowRuntime would be waiting to
persist until the Activity completed – classic deadlock.
InvokeWorkflow uses a service that is installed by default – IStartWorkflow – which
works create in the async case – but doesn’t work in the sync case. So I just
created a custom service. One aspect of WF that I try to emphasize to people
when I do my WF trainings is that even though there are well-known services inside
of the WorkflowRuntime – you can add any number of services which won’t be known to
the WorkflowRuntime – but can be used by your Activities. In fact this is necessary
in some cases (like this one) where the code you want to execute would be “illegal”
inside of Activity.Execute (things like spawning threads or anything that would go
against the model of WF in terms of what Activities should do). Now in this
case I made the Service derive from WorkflowRuntimeService because my service needs
the WorkflowRuntime to do its job, and that is the easiest way to get a reference
to the WorkflowRuntime. But it isn’t a requirement that a service added
via WorkflowRuntime.AddService derive from WorkflowRuntimeService.
So here is how my service executes a workflow:
public class CallWorkflowService
: WorkflowRuntimeService
{
public void StartWorkflow(Type
workflowType,Dictionary<string,object>
inparms,Guid caller,IComparable qn)
{
WorkflowRuntime wr = this.Runtime;
WorkflowInstance wi = wr.CreateWorkflow(workflowType,inparms);
wi.Start();
ManualWorkflowSchedulerService ss = wr.GetService<ManualWorkflowSchedulerService>();
if (ss
!= null)
ss.RunWorkflow(wi.InstanceId);
EventHandler<WorkflowCompletedEventArgs> d = null;
d = delegate(object o,
WorkflowCompletedEventArgs e)
{
if (e.WorkflowInstance.InstanceId
==wi.InstanceId)
{
wr.WorkflowCompleted -= d;
WorkflowInstance c = wr.GetWorkflow(caller);
c.EnqueueItem(qn, e.OutputParameters, null, null);
}
};
EventHandler<WorkflowTerminatedEventArgs> te = null;
te = delegate(object o,
WorkflowTerminatedEventArgs e)
{
if (e.WorkflowInstance.InstanceId
== wi.InstanceId)
{
wr.WorkflowTerminated -= te;
WorkflowInstance c = wr.GetWorkflow(caller);
c.EnqueueItem(qn, new Exception(“Called
Workflow Terminated”, e.Exception), null, null);
}
};
wr.WorkflowCompleted += d;
wr.WorkflowTerminated += te;
}
}
Notice the use of anonymous delegates really helps in this case. No need to
keep state about workflow instances around in the service – the anonymous delegates
get registered and unregistered for each Workflow execution.
To get the data back to the Activity – the WorkflowQueue name that the Activity created
– so the Activity can return ActivityExecutionStatus.Executing from Execute – and
it waits for an item to come back on the Queue.
If the Workflow terminates – the service sends an exception into the WorkflowQueue
– which causes that exception to promolgate to the workflow itself.
Another interesting part of this sample is the use of the WorkflowParameterBindingCollection
– similar to the way that the InvokeWorkflow,CallExternalMethod and other built-in
activities do. Make note of the DependencyProperty declaration and the call
to base.SetReadOnlyProperty in the constructor – both are necessary to get Collections
to serialize correctly into your .designer file.

by community-syndication | Jun 28, 2006 | BizTalk Community Blogs via Syndication
10 more BizTalk samples are live in the MSDN Web site. I wrote four of them as follows:
1) BAM and HAT Correlation
This sample demonstrates how to use the enhanced BAM features, and how to customize BAM and HAT integration. This sample also includes a Windows Forms application customizing BAM and HAT integration for the sample BizTalk solution
2) Using Role Links
This sample demonstrates how to use role links and parties.
3) Using Enterprise Library 2.0 with BizTalk Server
This sample demonstrates how to use Enterprise Library 2.0 with BizTalk Server.
4) Consuming Web Services
This sample demonstrates how to consume Web services in a messaging-only scenario, and without using the Add Web Reference option
If you have any feedbacks about the samples, please leave a message.
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
In the latest BizTalk Server 2006 Help Update, you’ll find the following content:
- Complete documentation for all BizTalk Server Line of Business Adapters, including new tutorials, one for each adapter. See the section “Using Adapters.”
- Troubleshooting guidance for each of the native BizTalk adapters. See the section “Troubleshooting Adapters.”
- Troubleshooting Instructions for how to capture a memory dump. See the section “How to Capture a Memory Dump of a BizTalk Process.”
- Disaster recovery instructions for backing up and restoring your BizTalk Server and databases. See the section “Backing Up and Restoring BizTalk Server”
- Updated Tutorials. See the section, “BizTalk Server 2006 Tutorials”
- Information for improving fault tolerance. See the section “Planning and Architecture”
- Updated Developer’s Reference that now includes the BAM namespaces that were not included in the RTM documentation. See the section “Developer’s Reference”
http://www.microsoft.com/downloads/details.aspx?FamilyID=3294ddaf-9f67-409f-a92d-2f6070dc0d1a&displaylang=en
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
Looks like there are a bunch of new samples posted on the Biztalk Developer center in MSDN. Check out http://msdn.microsoft.com/biztalk/downloads/samples/
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
We have made a number of corrections to the files contained in Tutorial_update.zip (attached). The corrections to these files should alleviate some of the problems you have had with Tutorials 2 and 3. To use the updated files, you must replace the correct existing file with the correct updated file.
- OrderService.odx replaces c:\tutorial\solutions\BAS\OrderProcess\OrderProcess\ OrderService.odx
- B2BOrchestrations_B2BProcess_ReceiveASN_Port.asmx.cs replaces c:\tutorial\solutions\B2BSolution\B2BOrchestrations_webservice\App_Code\B2BOrchestrations_B2BProcess_ReceiveASN_Port.asmx.cs
- B2BOrchestrations_B2BProcess_ReceiveInvoice_Port.asmx.cs replaces c:\tutorial\solutions\B2BSolution\B2BOrchestrations_webservice\App_Code\B2BOrchestrations_B2BProcess_ReceiveInvoice_Port.asmx.cs
- Setup.bat replaces c:\tutorial\solutions\B2BSolution\Setup.bat
- ReplacePKToken.vbs replaces c:\tutorial\solutions\B2BSolution\ReplacePKToken.vbs
Additionally, there are some corrections I will make to the instructions which I will post an update for shortly. Planned changes include the following:
1. In Before You Begin the tutorials
2. In Tutorial 2
3. In Tutorial 3
Rewrite Solution undeploy/redeploy tasks to use the BizTalk Administration console and Windows interface.
Fix some typos.
Add instructions for fixing the embedded tokens. You can find the instructions in this blog post: http://www.dotnetslackers.com/newsgroups/microsoft_public_biztalk_server/ng-86953_Problem_with_Tutorial_3_Lesson_3_failure_executi_.aspx. Note that in the updated files, you replace the placeholder tokens that appear as “xxx…”s instead of an actual token. Make sure you fix all instances of the token placeholder in each file.
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
The BizTalk Server 2006 Installation and Upgrade Guides have been updated since the initial release and include valuable feedback from the community! Check them out here:
http://www.microsoft.com/downloads/details.aspx?FamilyId=B273269C-97E0-411D-8849-5A8070698E4A&displaylang=en
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
Update: Andy pointed out that Tom
Abraham has given this a thorough treatment here.
There appear to be cases where having BizTalk 2004 and the .NET
2.0 framework installed on the same machine may cause you some difficulty. I’ve
seen a few instances where the BizTalk service will not start…or where the BizTalk
2004 process is loading (gulp) the 2.0 runtime (so says Process
Explorer.) This latter behavior will result in the VS2003 debugger not attaching
correctly (among other things…) See this kb.
To fix this, you can modify the BTSNTSvc.exe.config file to include the following
(after ‘configSections’):
<startup>
<supportedRuntime version="v1.1.4322"/>
</startup>
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
Update: Andy pointed out that Tom
Abraham has given this a thorough treatment here.
There appear to be cases where having BizTalk 2004 and the .NET
2.0 framework installed on the same machine may cause you some difficulty. I’ve
seen a few instances where the BizTalk service will not start…or where the BizTalk
2004 process is loading (gulp) the 2.0 runtime (so says Process
Explorer.) This latter behavior will result in the VS2003 debugger not attaching
correctly (among other things…) See this kb.
To fix this, you can modify the BTSNTSvc.exe.config file to include the following
(after ‘configSections’):
<startup>
<supportedRuntime version="v1.1.4322"/>
</startup>
by community-syndication | Jun 27, 2006 | BizTalk Community Blogs via Syndication
In response to recent questions/confusion, I posted an entry with links to the .NET 3.0 Beta 2 downloads — ironically a few days later on Friday (June 23), they released a new version labeled the June CTP.
So, to avoid being the cause of even more confusion, here are the links to the latest June CTP bits:
-
.NET 3.0 (WinFX) Runtime Components June CTP
-
Windows SDK (for June CTP)
-
VS.NET 2005 Extensions (for June CTP)
-
Workflow Foundation RC and Extensions (for June CTP)
As a matter of practice, go to the new .NET 3.0 portal site (http://www.netfx3.com/), and follow the download links to locate the latest bits.