Tracking Custom Workflows Problem

Hi!

I'm a newbie to WWF and this question might be stupid but I really can't figure it out and I didn't find answers in the forums or on the internet.
I want to track a custom workflow and so I attached a SqlTrackingService to my WorkflowRuntime. But when I try to view the running workflow in the Workflow Monitor that I found in the WF samples, I get the following exception (I catched it in the code):
Failed deserializing workflow markup. Make sure all necessary types are available.

I copied the dll with my custom activities in the same directory as WorkflowMonitor.exe (as it is described in the docs to WorkflowMonitor) and checked with Fuslogvw.exe that it is loaded. I even wrote a custom deserializer for my activities although I think they shouldn't need one (all data types in the custom activities are strings or other simple collections, no queues etc.). But this deserializer is never called.
So that doesn't seem to be enough to make it work. What else have I to do? How can I tell the SQLTrackingQuery that I want to use these custom activity types?

Thanks for your answers!

Chris

[1129 byte] By [Chris] at [2008-1-1]
# 1

The SqlTrackingQuery loads types via standard fusion - you don't need to tell it about your types. Are the correct versions of your workflow and activity assemblies in one of the paths that the fusion logs says it's looking in?

Thanks,
Joel West
MSFTE - SDE in WF runtime and hosting

This posting is provided "AS IS" with no warranties, and confers no rights

JoelWest at 2007-9-12 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 2
Thanks for your reply!
In my opinion they are. Actually there is only one version of the assembly where the custom activities are located. Is there a way to find out more about the problem that the SqlTrackingQuery has with the markup? I catched the WorkflowMarkupSerializerException and printed the line number property to the console but it just reads "-1".
I can give an example of the markup, which I found in the SQL database, if that helps.

I can also give you the fusion log entry regarding the loading of our custom assembly.

Thanks in advance!

Chris

Chris at 2007-9-12 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 3

If this is in a development environment rebuild your tracking database by re-running Tracking_Schema.sql. It's possible that you have an old version of the workflow in your database and the SqlTrackingQuery is looking for activities that match that version.

Thanks,
Joel West
MSFTE - SDE in WF runtime and hosting

This posting is provided "AS IS" with no warranties, and confers no rights


JoelWest at 2007-9-12 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 4
Sorry for the late answer and thanks for your reply!

I've done as you told me but I still get the same annoying error. Too bad I can't get more information about it. We have now implemented our own workflow monitor but the problem stays the same (although now all required types are in the same VS solution!!).
So we have written our own SqlQuery to get the workflow instance out of the DB and it worked except the fact that we cannot get the rules out of the DB.
Are the rule conditions stored by the SqlTrackingService and if yes, where?
Does anyone have another idea why the WorklfowDefinition property isn't working?

Many thanks for any response!

Chris

Chris at 2007-9-12 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 5
I'm having this exact same problem, fusion logs report that the assembly is loaded, I tried recreating a schema, but I get that same error. Maybe this is a bug if the root activity is a custom activity? That is the case for me, I have a custom subclass of StateMachineWorkflowActivity.
yeshman at 2007-9-12 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...

Software Development for Windows Vista

Site Classified