Particular / ServiceControl

Backend for ServiceInsight and ServicePulse
https://docs.particular.net/servicecontrol/
Other
53 stars 47 forks source link

Detect schema version at start to prevent downgrades #686

Open ramonsmits opened 8 years ago

ramonsmits commented 8 years ago

Based on:

Do not downgrade releases of ServiceControl. ServiceControl uses an embedded database and changes to the internal data structures can occur between releases. Rolling back may cause index corruption or data loss. Perform testing in a lower environment before upgrading in production environments.

If that is really an issue then we should set a version in the DB and compare this at start.

gbiellem commented 8 years ago

@ramonsmits :+1:

petersgiles commented 8 years ago

@ramonsmits :+1:

gbiellem commented 8 years ago

I'm not sure what downgrade/upgrade logic exists in the SC Management util but we should make sure it doesn't allow downgrades.

Also we need to add a license check when initiating an upgrade. If the maintenance protection has expired then a newly installed version is will appear unlicensed. This could be a trigger for a user to attempt a downgrade.