Troubleshooting Workflow Services with diagnostic logging

Sometimes you have a workflow service that is misbehaving in a production environment.  How do you figure out what is going on when you can’t attach a debugger? The solution is to use Workflow Tracking.  There are two alternatives you can try out Tracking using the System.Activities.Tracking.EtwTrackingParticipant see this Zoiner’s blog for a great quick…

4

How To Enable Service Metadata for Workflow Services

Try this… Create a new ASP.NET Web Application (MVC or Web Forms).  Then add a new a WCF Workflow Service to your web project. Now try to add a service reference to your workflow service.  It fails with an error. There was an error downloading metadata from the address. Please verify that you have entered…

0

Troubleshooting Silverlight, WorkflowServices, WCF and Behavior Extensions

In my previous posts I’ve written about my experiences with WorkflowServices and Silverlight. Troubleshooting Workflow Services / Silverlight Using Workflow Services and Silverlight Together WorkflowServices, CanCreateInstance and Silverlight Problem with Extensions This morning I got an email notification that someone had posted a question about my Silverlight / State Machine Workflow Service sample on MSDN…

0

WF4 WorkflowServices Troubleshooting Tip: Browse the XAMLX

I was doing some work on my Contoso HR Workflow Services sample application today when for some strange reason things were not working at all.  I found that when I tried to send a message to the Workflow Service from the ASP.NET code I got this exception. System.ServiceModel.CommunicationException was unhandled by user code   Message=The…

0

Visual Studio 11 Preview and .NET 4 Platform Update 1 Side by Side Bug

If you install the Visual Studio 11 Preview release on a machine that has .NET 4 Platform Update 1 installed you will find that projects targeting .NET 4 Platform Update 1 will fail to build properly.  The error you will get is ‘System.Activities.XamlIntegration.ActivityXamlServices’ does not contain a definition for ‘InitializeComponent’ The bug has been fixed…

3

Using the WCF Test Client to Test Your Workflow Service

If you need a quick and simple way to manually test your WorkflowService the WCF Test Client makes it simple but there are a few tips that will make your life much easier. Tip: Add the WCF Test Client to your Visual Studio Tools menu Select Tools / External Tools Add the WCF Test Client…

0

Troubleshooting Workflow Services / Silverlight

From time to time I’ll hear from somebody who is trying to use a WCF Workflow Service with Silverlight as the client and they are getting this exception. System.ServiceModel.CommunicationException was unhandled by user code Message=An error occurred while trying to make a request to URI http://localhost:49238/SecurityDoorService.xamlx’. This could be due to attempting to access a…

0

XamlInjector–Cannot create unknown type errors

If you are using Microsoft.Activities.UnitTesting.XamlInjector to mock activities you may run into an error like this. Test method XamlInjectorRepro.Test.UnitTest1.TestMethod1 threw exception: System.Xaml.XamlObjectWriterException: Cannot create unknown type ‘{clr-namespace:XamlInjectorRepro}MyCustomActivity’. This error occurs when the XAML loader encounters a type that was declared in the same assembly as the XAML when it was created.  For example, I have…

0

How to create a Custom Activity Designer with Windows Workflow Foundation (WF4)

The Windows Workflow Foundation (WF4) – Custom Activity Designer sample demonstrates how you can build an activity and activity designer.  It includes three projects MyActivityLibrary – The activity library project MyActivityLibrary.Design – The activity designer project TestDesigner – A rehosted designer project useful for testing the activity Step 1: Create the Activity The first step…

0

MSTest [DeploymentItem] and Environment Variables

Today I’ve been fixing up the build system for Microsoft.Activities and Microsoft.Activities.UnitTesting.  Over time I’ve been using a combination of strange tools and batch files to build things but it became such a mess I decided to take the time to finally build a good project file that I can use MSBuild on that will…

3