Custom Workflow activity for business failure evaluation–Part 1

Following on from my series about custom WF support for dependency resolution, this series of posts will look at support for business failure evaluation. Every project I have worked on has some kind of requirement to execute data validation and/or business rules when running a business process. Data validation could be a test that a request message contains an email address whereas a business rule may be that the provided email address is unique. Providing a custom WF activity to facilitate va... [More]

Icon support for custom Windows Workflow activities

Creating a custom dependency resolution activity for WF gave me the opportunity to learn a lot about the latest version of Workflow Foundation. Adding support for custom icons is a simple requirement that often came up when creating new activities. There are two places that provide this icon support. The first is in the [VS] toolbox and the second is on the activity design surface. I have been using images from the awesome famfamfam Silk collection for these activities. [VS] toolbox Adding an... [More]

Custom Windows Workflow activity for dependency resolution–Wrap up

I have been writing a series of posts recently about implementing a custom WF activity that will provide dependency resolution support for WF4 workflows. The InstanceResolver activity caters for lazy loading dependencies, multiple resolutions on the one activity, workflow persistence (including support for non-serializable dependencies) and lifetime management of the resolved dependencies. The activity uses Unity as the backend IoC container however this could be modified to support a differ... [More]

Neovolve.Toolkit 1.0 RTW

I have finally marked my Neovolve.Toolkit project as stable for version 1.0. It includes the recent work I have done for WF4. The toolkit comes with the binaries, a chm help file for documentation information and xml comment files for intellisense in [VS]. You can download the toolkit from the project on Codeplex. The following tables outline the types available in the namespaces across the toolkit assemblies. The information here is copied from the compiled help file. Neovolve.Toolkit.dll ... [More]

Custom Windows Workflow activity for dependency resolution–Part 6

The previous post in this series provided a custom updatable generic type argument implementation for the InstanceResolver activity. This post will look at the the XAML designer support for this activity. The designer support for the InstanceResolver intends to display only the number of dependency resolutions that are configured according to the ArgumentCount property. Each dependency resolution shown needs to provide editing functionality for the resolution type, resolution name and the name ... [More]

Custom Windows Workflow activity for dependency resolution–Part 5

The previous post covers the initial background for designer support of custom Windows Workflow activities. This post outlines a customised version of the updatable generic type support outlined in this post that is specific to the InstanceResolver activity. One of my original design goals for this custom activity was to provide adequate designer support. The initial version of this custom activity resolved a single dependency. This was clearly limited as I often have multiple instance resoluti... [More]

Custom Windows Workflow activity for dependency resolution–Part 4

The posts in this series have looked at providing a custom activity for dependency resolution in Windows Workflow. The series will now take a look at providing designer support for this activity. This post will cover the IRegisterMetadata interface and support for custom morphing. Designer Support The first action to take when creating WF4 activity designer support is to create a new [VS] project. The name of this project should be prefixed with the name of the assembly that contains the activ... [More]

Creating updatable generic Windows Workflow activities

This post is a segue from the current series on building a custom activity for supporting dependency resolution in Windows Workflow (here, here, here and here so far). This post will outline how to support updating generic type arguments of generic activities in the designer. This technique is used in the designer support for the InstanceResolver activity that has been discussed throughout the series. The implementation of this is modelled from the support for this functionality in the generic ... [More]

Custom Windows Workflow activity for dependency resolution–Part 3

My previous post provided the base framework for resolving dependencies, handling persistence and tearing down resolved dependencies in Windows Workflow. This post will provide the custom activity for exposing resolved dependencies to a workflow. The original implementation of this activity supported resolving a single dependency. It has slowly evolved into one that can support up to 16 dependencies. The reason for this specific number is that the activity leverages the ScheduleAction method on... [More]

Custom Windows Workflow activity for dependency resolution–Part 2

My previous post described the design goals for creating a custom WF4 activity that provides dependency resolution functionality. This post will look at the underlying support for making this happen. The main issue with dependency resolution/injection in WF is supporting persistence. An exception will be thrown when a workflow is persisted when it holds onto a dependency that is not serializable. The previous post indicated that the solution to this issue is to have the workflow persist the res... [More]