i've been plagued error resuming workflows in rather complex system , far had little luck finding solution it.
the error happens when resume workflow. workflow , activities have changed there versioning in place shouldn't affect that. resume operation brings out old version of xaml file , calls old version of activities , has been working year now.
started testing new version of system , error: the instance 'some guid' found in instance store, instance not workflow instance
this happens in resume method of worklfow , in particular in line :
application.load(resumecontext.workflowinstanceid); in database can find instance guid , looks okay can't understand why wouldn't load.
i found one page in entire google error , there's no answer it, it's desert out there.
the stack trace useless:
exception: system.exception: exception of type 'system.exception' thrown. @ system.activities.workflowapplication.extractruntimestate(idictionary`2 values, guid instanceid) @ system.activities.workflowapplication.processinstancevalues(idictionary`2 values, object& deserializedruntimestate) @ system.activities.workflowapplication.loadcore(dynamicupdatemap updatemap, timeouthelper timeouthelper, boolean loadany, idictionary`2 values) @ system.activities.workflowapplication.load(guid instanceid, timespan timeout) @ system.activities.workflowapplication.load(guid instanceid) @ project.ts.services.workflows.hosting.activityinvoker.resume[tresponse](workflowapplication application, instancestore instancestore, resumebookmarkcontext`1 resumecontext, idictionary`2& outarguments) in c:\projects\ts\trunk\services\workflows\hosting\activityinvoker.cs:line 186 some more info. way works operation object contains workflow version, name , actual xaml , gets loaded workflow application , gets invoked:
var workflowdefinition = activityresolver.resolve(new workflowidentity(operation.workflowversion, operation.workflowname, operation.workflowxaml)); var application = new workflowapplication(workflowdefinition.implementation); response = activityinvoker.resume<resumeoperationresponse>(application, instancestoreprovider.create(), resumecontext, out outarguments); inside invoker resume method , fails:
public tresponse resume<tresponse>(workflowapplication application, instancestore instancestore, resumebookmarkcontext<resumeoperationrequest> resumecontext, out idictionary<string, object> outarguments) tresponse : resumeoperationresponse, new() { var response = new tresponse(); outarguments = new dictionary<string, object>(); idictionary<string, object> wfoutarguments = new dictionary<string, object>(); application.instancestore = instancestore; try { application.load(resumecontext.workflowinstanceid); } catch (exception exp) { //exception happens here } } at point i'm interested in pointers in causing this.
there seems no way debug , actual cause of problem.
many thanks
the workflow application throws error when put load method in try catch. in application, if put load method call in try/catch, change guid right before calls method , throw exception. fix take out try catch method , add on caller calling method.
Comments
Post a Comment