Upgrading EPiServer Commerce 1 R2 SP1 to EPiServer Commerce 7.5, part 3

Happy New Year!

So the next step. Upgrade to EPiServer Commerce 7.5.

The upgrade script failed, with an unclear message. When the changes are reverted, the upgrade script does not roll back deleted files, so I needed to copy "tools.zip" back to it’s location.
"Mediachase.Cms.Website.dll" was also deleted already, so you can either copy it back, or adjust the script by adding a Try Catch on line 374.

#Remove Mediachase.Cms.Website.dll
Set-EPiProgressStatus -status "Removing Mediachase.Cms.Website.dll"
echo "Removing Mediachase.Cms.Website.dll"
 try{
		$mediachaseCmsWebsiteDllPath = Join-Path $commerceManagerBinPath 'Mediachase.Cms.Website.dll'
		Remove-Item $mediachaseCmsWebsiteDllPath -force
        }
        catch{
        echo "Could not remove Mediachase.Cms.Website.dll because it does not exist."
        }

On the next run the script creates a folder {manager}\b  in which it copies the new manager files, when it tries updating that web.config it crashes, as the web.config is not found in that folder. So, I copied the web.config to this directory.  And of course the tools.zip.

Now the upgrade succeeded.

Analysing the errors I got when starting the manager, I found out that I needed to copy the contents of {manager}\b over the root of the website. Also old/not used from v6 dll’s were not removed.

Next was upgrading my solution. Alas. Again the NuGet packages are newer than the packages from the latest installer. So again version conflicts. But I only needed to update my code to get promotions, so that was a breeze.

Finally I got the frontend to work, well, not crash. So I logged in to EPiServer. No Commerce Tab. This, because the modules settings were not updated. After changing them to the correct locations and adding the appropriate dll’s to the modules bin. I had my Commerce Manager tab. No content though.

When checking the database, i saw that all content was available. After some digging I discovered that the application was assigned a different id during the upgrade process. After replacing it with the old one in the Application table, I had my catalogue, users, etc. back in the Commerce Manager. The only location it was changed.

No catalogue in EPiServer though. After replacing all handlers with the ones from a newly created site … Finally, a working Frontend and a working Commerce Manager.

Conclusion, for now

I think the upgrade scripts are a bit lacking in robustness for an easy upgrade.

What worries me most though  is the change of the application id in the Database.

But I hope that the things I ran into, and my solutions for them, although not pretty, will help you perform an upgrade a little bit smoother.

Next steps

Next up will, of course, be extensive testing, and as Unit Testing is a lot easier with 7.5, I will be going that way.

I will also need to create the strongly typed classes for the catalogue. Pity there is no tool that can create them for you. Not that I know of anyway. Maybe a nice pet project for a rainy day.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s