Malevich source is in constant flux - the system is gaining new features, bug fixes, and usability improvements very frequently.
There is one important invariant about the state of the development tree that had been true throughout the history of the project, and that is - the tree is always stable. The changes happen in bursts - many multiple check-ins go through in a very short time.
If you are getting the source at least several hours after the last check-in, the tree is in great shape, and you can upgrade without fear: as of this writing, several dozen developers and testers are using Malevich actively, and the bugs - at least the crippling
ones - are discovered - and fixed - within minutes.
So have no fear - upgrade! Get the cool new stuff - and get it often!
Most of the time, the changes are small and amount to simply tweaking or adding a control on the web site. Changes that touch the database - and thus have a ripple effect throughout the whole system - are infrequent, but they do happen. Unless you are a very
active Malevich developer, it is quite hard to say whether the difference is small and large. We suggest that you upgrade all of the system at once - it is really easy.
It goes without saying, but the user (1) MUST be an administrator in SQL server instance that houses Malevich database, and (2) MUST have "Full Control" rights to the directory/share where the web site lives.
First and foremost
If you have made modifications to Malevich, upgrade instructions below may (if you changed source - will!) wipe them out.
Backup the database from SQL Server Management Studio. Backup the web site by saving a copy in a different directory.
Upgrading using MSI installer
Malevich installer tries to transfer setting that it knows about from one version to the next. In most cases, if your modification of the setup is restricted to application settings in web.config, the upgrade will be painless - the installer will move these
settings to the newer version. The contents of the review database will be preserved as well.
To upgrade to the new version:
- If previous installation was from MSI, uninstall the old MSI package from Control Panel.
DO NOT RUN THE CONFIGURATION PROGRAM ("Configure Malevich") Note that the running instance of Malevich is separate from the files being deployed by MSI, and it will continue to run even after the MSI is removed.
- Install the MSI containing the new version.
- Run "Configure Malevich" shortcut. This will detect the running version and offer you to uninstall or upgrade. Type "upgrade" at that prompt, confirm the options that were detected, and watch the installer do all the work. The upgrade
should handle both the versions deployed from an earlier MSI version as well as from Visual Studio.
Upgrading from Visual Studio
You need to have the same flavor of Visual Studio at the same level (SP1 + Database GDR) as was required for installation. See
Installation and configuration
for specific requirements and links to where to install things from, if you are upgrading from a machine that was different from the one used to install Malevich.
To upgrade, go to the Source Code section, and pull down the most recent version of source. Put it in a separate directory postfixed with the date or the change list number, for example: Malevich.022109. Open the solution (cancel out of TFS login prompt if
it shows). Make sure that Solution configuration is set to Release
, and the Platform to
. Build the solution.
Upgrading the database
Visual Studio does a fantastic job for database upgrades. Running through the actions below will bring your database up to date without destroying the data in it (do backup the CodeReivew database just in case, but I have ran many tens of these, and it always
worked, even when I changed column data types).
In Visual Studio, right-click on the database project. Select Properties from the menu. Click on the deploy tab. The Deploy Action should be
Create a deployment script (.sql) and deploy to the database
. Target connection MUST point to where the Malevich database it. Click Edit to set it up, and don't forget to Test the connection. Target database name should be
. After all this has been set, simply right-click on the database project again, and chose Deply from the menu. The action will output a few diagnostic messages to the output window. Make sure that at the end of the output, it said that the
Upgrading the web site
Before deploying the web site, edit the web.config and make sure that
- DataConnectionString points to YOUR instance of SQL server. Replace whatever is in Data Source clause with your SQL instance name.
- diffExe points to where diff.exe is installed on your computer.
- If you have skinned Malevich (Skinning Malevich), make sure that skinDirectory points to where you have the skin files.
- If your project's default maximum line length is something other than 120 characters, update maxLineLength parameter (only do it if you want to use this to enforce the maximum line length; if you don't - leave it as it is: 120 characters is a convenient
If you've made other customizations to Malevich (web.config, style sheets), you will need to integrate them back. Note that it could be the case that the need for the specific customization has been subplanted by a new feature in Malevich that does what
you need out of the box. We recommend running the new version of Malevich without customizations first, and then apply them later if you still need them. Also see
on how to properly customize Malevich.
: the next step will erase everything you had in the web site. If you've made any customizations directly to the site (web.config, style sheets, etc), copy the files out of there before continuing.
In Visual Studio, right-click on the website project, choose Publish. Point it to the directory where the web site is on your server. Click OK twice. Done!
Upgrading the client (review.exe)
This one is easy - get everything from review\bin\x86\Release and copy it over the old bits. You are done.
Upgrading the notifier (reviewnotifier.exe)
Same thing as with review.exe - get everything from notifier\bin\Release, and copy it over the directory where you had reviewnotifier.exe previously. This is it.
YOU ARE DONE! That your upgrade is functional by following instructions here:
Testing Malevich setup