views:

29

answers:

2

I have written a sequential workflow in SharePoint on our development environment. After testing, we decided to deploy this workflow as a feature on the staging environment. We did the following:

  1. copied the strongly named assembly to the GAC using gacutil

  2. copied feature.xml and workflow.xml to WebServerExtensions/12/templates/features/someFolder

  3. installed feature (stsadm command)

  4. activated feature (stsadm command)

All worked exactly as planned and the workflow behaved correctly. The problem was, we decided to change something in the code (a message was not very self explanatory), so on the development machine we updated the message as requested and rebuilt the project.
The problem is, we cannot seem to find a way to correctly get rid of the previous version of this workflow/feature.

To deploy the upgrade, we:

  1. deactivated and uninstalled the feature (stsadm commands), removed also from GAC.

  2. increased the version of the assembly

  3. performed steps 1 to 4 from above.

When using the workflow we are still getting the first message, we cannot find a way to get the new message to be displayed.
What are we missing?

A: 

All the workflow logic "lives" inside the code assembly you are running. This means you can delete the old version of DLL (don't change assembly version numbers, use AssemblyFileVersion instead) from the GAC and replace it with the new version.

Be aware, though, that if you have changed the workflow in the designer, running instances of the old workflow version will "freeze" and never finish. Ask your users to finish their running WF-s before you upgrade the code.

naivists
I tried replacing the dll only, (I made sure there were no WF running) but now the WF does not start anymore: "Failed on Start (retrying)".
Laura L
1) what does it say in SharePoint logfiles (\\servername\c$\Program Files\Common Files\Microsoft Shared\web server extensions\12)?2) did you restart the "Sharepoint Timer Service" (Windows service) as well?
naivists
A: 

It seems that the problem was in the Workflow.xml file. Because I incremented the AssemblyFileVersion, and only replacing the dll in GAC did not work, I checked the two xml files: Feature and Workflow to see which one did not recognize the new dll (if the case). The workflow.xml file had a reference to the old version in it. I updated that, installed and activated the feature again, and it is working perfectly now.
Thanks for your support!

Laura L