You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Milamber <mi...@apache.org> on 2013/09/11 16:19:30 UTC

There is no upgrade path from 4.1.1 to 4.2.0

Hello,

I've try to upgrade my CS test platform from 4.1.1 to 4.2.0
(from Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9ba5d900b02
+  CLVM issue cherry-pick from 4.2-forward with commitId 
f2c5b5fbfe45196dfad2821fca513ddd6efa25c9.)

The path 4.1.1->4.2.0 seems miss?

2013-09-11 14:32:55,619 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) Grabbing lock to check for database upgrade.
2013-09-11 14:32:55,631 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
2013-09-11 14:32:55,632 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
2013-09-11 14:32:55,632 ERROR [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
2013-09-11 14:32:55,639 ERROR [utils.component.ComponentContext] 
(Timer-1:null) System integrity check failed. Refuse to startup
com.cloud.utils.exception.CloudRuntimeException: There is no upgrade 
path from 4.1.1 to 4.2.0
     at 
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:221)
     at 
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:389)
     at 
com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
     at 
com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:54)
     at java.util.TimerThread.mainLoop(Timer.java:534)
     at java.util.TimerThread.run(Timer.java:484)


Milamber

RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Animesh Chaturvedi <an...@citrix.com>.

From: Chip Childers [mailto:chip.childers@sungard.com]
Sent: Wednesday, September 11, 2013 5:54 PM
To: <de...@cloudstack.apache.org>; Animesh Chaturvedi
Subject: Re: There is no upgrade path from 4.1.1 to 4.2.0

Animesh,

I have not checked on this myself.

I believe that you have not yet promoted the bits from dist/dev to dist/release.  If that's the case, we CAN fix this with a re-spin.  Not being able to upgrade from the 4.1.1 release is a MAJOR ISSUE, since we had a security vulnerability announcement where we asked everyone to upgrade to that bug-fix release.
[Animesh>] yes I have not promoted the bits yet, this needs to be taken care of.

I see that this thread has moved onto talking about the technical aspects of "why we do it this way", but I want to make this point.  If we have not promoted the artifacts, we can fix this!  If they are promoted, we're done with 4.2.0...  period, and no going back.  We can't re-release with the same version number per ASF release policy.



On Wed, Sep 11, 2013 at 11:17 AM, Milamber <mi...@apache.org>> wrote:

Le 11/09/2013 15:42, Sudha Ponnaganti a ecrit :

This indicates to me that this is tested already

https://issues.apache.org/jira/browse/CLOUDSTACK-4509

In CS-4509, the management log file show two db upgrade:

2013-08-26 20:56:19,257 INFO  [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:null) DB version = 4.0.0 Code Version = 4.1.0
2013-08-26 20:56:19,258 INFO  [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:null) Database upgrade must be performed from 4.0.0 to 4.1.0
2013-08-26 20:56:19,258 DEBUG [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:null) Running upgrade Upgrade40to41 to upgrade from 4.0.0-4.1.0 to 4.1.0


and

2013-08-26 22:08:43,111 INFO  [cloud.upgrade.DatabaseUpgradeChecker] (Timer-2:null) DB version = 4.1.0 Code Version = 4.2.0
2013-08-26 22:08:43,113 INFO  [cloud.upgrade.DatabaseUpgradeChecker] (Timer-2:null) Database upgrade must be performed from 4.1.0 to 4.2.0
2013-08-26 22:08:43,114 DEBUG [cloud.upgrade.DatabaseUpgradeChecker] (Timer-2:null) Running upgrade Upgrade410to420 to upgrade from 4.1.0-4.2.0 to 4.2.0


Nothing from 4.1.1 to 4.2.0






-----Original Message-----
From: Wei ZHOU [mailto:ustcweizhou@gmail.com<ma...@gmail.com>]
Sent: Wednesday, September 11, 2013 7:37 AM
To: dev@cloudstack.apache.org<ma...@cloudstack.apache.org>
Subject: Re: There is no upgrade path from 4.1.1 to 4.2.0

I do not find anything related in
./engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java, and no Upgrade411to420.java in ./engine/schema/src/com/cloud/upgrade/dao/ as well.
This should be a blocker issue.


2013/9/11 Milamber <mi...@apache.org>>
Hello,

I've try to upgrade my CS test platform from 4.1.1 to 4.2.0 (from
Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9**ba5d900b02
+  CLVM issue cherry-pick from 4.2-forward with commitId
f2c5b5fbfe45196dfad2821fca513d**dd6efa25c9.)

The path 4.1.1->4.2.0 seems miss?

2013-09-11 14:32:55,619 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
(Timer-1:null) Grabbing lock to check for database upgrade.
2013-09-11 14:32:55,631 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
(Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
2013-09-11 14:32:55,632 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
(Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
2013-09-11 14:32:55,632 ERROR [cloud.upgrade.**DatabaseUpgradeChecker]
(Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
2013-09-11 14:32:55,639 ERROR [utils.component.**ComponentContext]
(Timer-1:null) System integrity check failed. Refuse to startup
com.cloud.utils.exception.**CloudRuntimeException: There is no upgrade
path from 4.1.1 to 4.2.0
     at com.cloud.upgrade.**DatabaseUpgradeChecker.**upgrade(**
DatabaseUpgradeChecker.java:**221)
     at com.cloud.upgrade.**DatabaseUpgradeChecker.check(**
DatabaseUpgradeChecker.java:**389)
     at com.cloud.utils.component.**ComponentContext.**
initComponentsLifeCycle(**ComponentContext.java:90)
     at com.cloud.servlet.**CloudStartupServlet$1.run(**
CloudStartupServlet.java:54)
     at java.util.TimerThread.**mainLoop(Timer.java:534)
     at java.util.TimerThread.run(**Timer.java:484)


Milamber



Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Chip Childers <ch...@sungard.com>.
Animesh,

I have not checked on this myself.

I believe that you have not yet promoted the bits from dist/dev to
dist/release.  If that's the case, we CAN fix this with a re-spin.  Not
being able to upgrade from the 4.1.1 release is a MAJOR ISSUE, since we had
a security vulnerability announcement where we asked everyone to upgrade to
that bug-fix release.

I see that this thread has moved onto talking about the technical aspects
of "why we do it this way", but I want to make this point.  If we have not
promoted the artifacts, we can fix this!  If they are promoted, we're done
with 4.2.0...  period, and no going back.  We can't re-release with the
same version number per ASF release policy.




On Wed, Sep 11, 2013 at 11:17 AM, Milamber <mi...@apache.org> wrote:

>
> Le 11/09/2013 15:42, Sudha Ponnaganti a ecrit :
>
>  This indicates to me that this is tested already
>>
>> https://issues.apache.org/**jira/browse/CLOUDSTACK-4509<https://issues.apache.org/jira/browse/CLOUDSTACK-4509>
>>
>
> In CS-4509, the management log file show two db upgrade:
>
> 2013-08-26 20:56:19,257 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) DB version = 4.0.0 Code Version = 4.1.0
> 2013-08-26 20:56:19,258 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Database upgrade must be performed from 4.0.0 to 4.1.0
> 2013-08-26 20:56:19,258 DEBUG [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Running upgrade Upgrade40to41 to upgrade from 4.0.0-4.1.0 to
> 4.1.0
>
>
> and
>
> 2013-08-26 22:08:43,111 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-2:null) DB version = 4.1.0 Code Version = 4.2.0
> 2013-08-26 22:08:43,113 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-2:null) Database upgrade must be performed from 4.1.0 to 4.2.0
> 2013-08-26 22:08:43,114 DEBUG [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-2:null) Running upgrade Upgrade410to420 to upgrade from 4.1.0-4.2.0
> to 4.2.0
>
>
> Nothing from 4.1.1 to 4.2.0
>
>
>
>
>
>
>>
>> -----Original Message-----
>> From: Wei ZHOU [mailto:ustcweizhou@gmail.com]
>> Sent: Wednesday, September 11, 2013 7:37 AM
>> To: dev@cloudstack.apache.org
>> Subject: Re: There is no upgrade path from 4.1.1 to 4.2.0
>>
>> I do not find anything related in
>> ./engine/schema/src/com/cloud/**upgrade/**DatabaseUpgradeChecker.java,
>> and no Upgrade411to420.java in ./engine/schema/src/com/cloud/**upgrade/dao/
>> as well.
>> This should be a blocker issue.
>>
>>
>> 2013/9/11 Milamber <mi...@apache.org>
>>
>>  Hello,
>>>
>>> I've try to upgrade my CS test platform from 4.1.1 to 4.2.0 (from
>>> Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9****ba5d900b02
>>> +  CLVM issue cherry-pick from 4.2-forward with commitId
>>> f2c5b5fbfe45196dfad2821fca513d****dd6efa25c9.)
>>>
>>> The path 4.1.1->4.2.0 seems miss?
>>>
>>> 2013-09-11 14:32:55,619 INFO  [cloud.upgrade.****DatabaseUpgradeChecker]
>>> (Timer-1:null) Grabbing lock to check for database upgrade.
>>> 2013-09-11 14:32:55,631 INFO  [cloud.upgrade.****DatabaseUpgradeChecker]
>>> (Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
>>> 2013-09-11 14:32:55,632 INFO  [cloud.upgrade.****DatabaseUpgradeChecker]
>>> (Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
>>> 2013-09-11 14:32:55,632 ERROR [cloud.upgrade.****DatabaseUpgradeChecker]
>>> (Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
>>> 2013-09-11 14:32:55,639 ERROR [utils.component.****ComponentContext]
>>> (Timer-1:null) System integrity check failed. Refuse to startup
>>> com.cloud.utils.exception.****CloudRuntimeException: There is no upgrade
>>> path from 4.1.1 to 4.2.0
>>>      at com.cloud.upgrade.****DatabaseUpgradeChecker.****upgrade(**
>>> DatabaseUpgradeChecker.java:****221)
>>>      at com.cloud.upgrade.****DatabaseUpgradeChecker.check(****
>>> DatabaseUpgradeChecker.java:****389)
>>>      at com.cloud.utils.component.****ComponentContext.**
>>> initComponentsLifeCycle(****ComponentContext.java:90)
>>>      at com.cloud.servlet.****CloudStartupServlet$1.run(**
>>> CloudStartupServlet.java:54)
>>>      at java.util.TimerThread.****mainLoop(Timer.java:534)
>>>      at java.util.TimerThread.run(****Timer.java:484)
>>>
>>>
>>> Milamber
>>>
>>>
>
>

Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Milamber <mi...@apache.org>.
Le 11/09/2013 15:42, Sudha Ponnaganti a ecrit :
> This indicates to me that this is tested already
>
> https://issues.apache.org/jira/browse/CLOUDSTACK-4509

In CS-4509, the management log file show two db upgrade:

2013-08-26 20:56:19,257 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) DB version = 4.0.0 Code Version = 4.1.0
2013-08-26 20:56:19,258 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) Database upgrade must be performed from 4.0.0 to 4.1.0
2013-08-26 20:56:19,258 DEBUG [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-1:null) Running upgrade Upgrade40to41 to upgrade from 4.0.0-4.1.0 
to 4.1.0


and

2013-08-26 22:08:43,111 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-2:null) DB version = 4.1.0 Code Version = 4.2.0
2013-08-26 22:08:43,113 INFO  [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-2:null) Database upgrade must be performed from 4.1.0 to 4.2.0
2013-08-26 22:08:43,114 DEBUG [cloud.upgrade.DatabaseUpgradeChecker] 
(Timer-2:null) Running upgrade Upgrade410to420 to upgrade from 
4.1.0-4.2.0 to 4.2.0


Nothing from 4.1.1 to 4.2.0




>
>
> -----Original Message-----
> From: Wei ZHOU [mailto:ustcweizhou@gmail.com]
> Sent: Wednesday, September 11, 2013 7:37 AM
> To: dev@cloudstack.apache.org
> Subject: Re: There is no upgrade path from 4.1.1 to 4.2.0
>
> I do not find anything related in
> ./engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java, and no Upgrade411to420.java in ./engine/schema/src/com/cloud/upgrade/dao/ as well.
> This should be a blocker issue.
>
>
> 2013/9/11 Milamber <mi...@apache.org>
>
>> Hello,
>>
>> I've try to upgrade my CS test platform from 4.1.1 to 4.2.0 (from
>> Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9**ba5d900b02
>> +  CLVM issue cherry-pick from 4.2-forward with commitId
>> f2c5b5fbfe45196dfad2821fca513d**dd6efa25c9.)
>>
>> The path 4.1.1->4.2.0 seems miss?
>>
>> 2013-09-11 14:32:55,619 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) Grabbing lock to check for database upgrade.
>> 2013-09-11 14:32:55,631 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
>> 2013-09-11 14:32:55,632 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
>> 2013-09-11 14:32:55,632 ERROR [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
>> 2013-09-11 14:32:55,639 ERROR [utils.component.**ComponentContext]
>> (Timer-1:null) System integrity check failed. Refuse to startup
>> com.cloud.utils.exception.**CloudRuntimeException: There is no upgrade
>> path from 4.1.1 to 4.2.0
>>      at com.cloud.upgrade.**DatabaseUpgradeChecker.**upgrade(**
>> DatabaseUpgradeChecker.java:**221)
>>      at com.cloud.upgrade.**DatabaseUpgradeChecker.check(**
>> DatabaseUpgradeChecker.java:**389)
>>      at com.cloud.utils.component.**ComponentContext.**
>> initComponentsLifeCycle(**ComponentContext.java:90)
>>      at com.cloud.servlet.**CloudStartupServlet$1.run(**
>> CloudStartupServlet.java:54)
>>      at java.util.TimerThread.**mainLoop(Timer.java:534)
>>      at java.util.TimerThread.run(**Timer.java:484)
>>
>>
>> Milamber
>>


RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Sudha Ponnaganti <su...@citrix.com>.
This indicates to me that this is tested already

https://issues.apache.org/jira/browse/CLOUDSTACK-4509


-----Original Message-----
From: Wei ZHOU [mailto:ustcweizhou@gmail.com] 
Sent: Wednesday, September 11, 2013 7:37 AM
To: dev@cloudstack.apache.org
Subject: Re: There is no upgrade path from 4.1.1 to 4.2.0

I do not find anything related in
./engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java, and no Upgrade411to420.java in ./engine/schema/src/com/cloud/upgrade/dao/ as well.
This should be a blocker issue.


2013/9/11 Milamber <mi...@apache.org>

> Hello,
>
> I've try to upgrade my CS test platform from 4.1.1 to 4.2.0 (from 
> Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9**ba5d900b02
> +  CLVM issue cherry-pick from 4.2-forward with commitId
> f2c5b5fbfe45196dfad2821fca513d**dd6efa25c9.)
>
> The path 4.1.1->4.2.0 seems miss?
>
> 2013-09-11 14:32:55,619 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Grabbing lock to check for database upgrade.
> 2013-09-11 14:32:55,631 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
> 2013-09-11 14:32:55,632 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
> 2013-09-11 14:32:55,632 ERROR [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
> 2013-09-11 14:32:55,639 ERROR [utils.component.**ComponentContext]
> (Timer-1:null) System integrity check failed. Refuse to startup
> com.cloud.utils.exception.**CloudRuntimeException: There is no upgrade 
> path from 4.1.1 to 4.2.0
>     at com.cloud.upgrade.**DatabaseUpgradeChecker.**upgrade(**
> DatabaseUpgradeChecker.java:**221)
>     at com.cloud.upgrade.**DatabaseUpgradeChecker.check(**
> DatabaseUpgradeChecker.java:**389)
>     at com.cloud.utils.component.**ComponentContext.**
> initComponentsLifeCycle(**ComponentContext.java:90)
>     at com.cloud.servlet.**CloudStartupServlet$1.run(**
> CloudStartupServlet.java:54)
>     at java.util.TimerThread.**mainLoop(Timer.java:534)
>     at java.util.TimerThread.run(**Timer.java:484)
>
>
> Milamber
>

Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Milamber <mi...@apache.org>.
Le 11/09/2013 15:36, Wei ZHOU a ecrit :
> I do not find anything related in
> ./engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java, and no
> Upgrade411to420.java in ./engine/schema/src/com/cloud/upgrade/dao/ as well.
> This should be a blocker issue.

Thanks for checks.

I've open an issue:
https://issues.apache.org/jira/browse/CLOUDSTACK-4645


>
>
> 2013/9/11 Milamber <mi...@apache.org>
>
>> Hello,
>>
>> I've try to upgrade my CS test platform from 4.1.1 to 4.2.0
>> (from Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9**ba5d900b02
>> +  CLVM issue cherry-pick from 4.2-forward with commitId
>> f2c5b5fbfe45196dfad2821fca513d**dd6efa25c9.)
>>
>> The path 4.1.1->4.2.0 seems miss?
>>
>> 2013-09-11 14:32:55,619 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) Grabbing lock to check for database upgrade.
>> 2013-09-11 14:32:55,631 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
>> 2013-09-11 14:32:55,632 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
>> 2013-09-11 14:32:55,632 ERROR [cloud.upgrade.**DatabaseUpgradeChecker]
>> (Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
>> 2013-09-11 14:32:55,639 ERROR [utils.component.**ComponentContext]
>> (Timer-1:null) System integrity check failed. Refuse to startup
>> com.cloud.utils.exception.**CloudRuntimeException: There is no upgrade
>> path from 4.1.1 to 4.2.0
>>      at com.cloud.upgrade.**DatabaseUpgradeChecker.**upgrade(**
>> DatabaseUpgradeChecker.java:**221)
>>      at com.cloud.upgrade.**DatabaseUpgradeChecker.check(**
>> DatabaseUpgradeChecker.java:**389)
>>      at com.cloud.utils.component.**ComponentContext.**
>> initComponentsLifeCycle(**ComponentContext.java:90)
>>      at com.cloud.servlet.**CloudStartupServlet$1.run(**
>> CloudStartupServlet.java:54)
>>      at java.util.TimerThread.**mainLoop(Timer.java:534)
>>      at java.util.TimerThread.run(**Timer.java:484)
>>
>>
>> Milamber
>>


Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Wei ZHOU <us...@gmail.com>.
I do not find anything related in
./engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java, and no
Upgrade411to420.java in ./engine/schema/src/com/cloud/upgrade/dao/ as well.
This should be a blocker issue.


2013/9/11 Milamber <mi...@apache.org>

> Hello,
>
> I've try to upgrade my CS test platform from 4.1.1 to 4.2.0
> (from Commit: e39a7d8e0d3f2fd3e326b1bdf4aaf9**ba5d900b02
> +  CLVM issue cherry-pick from 4.2-forward with commitId
> f2c5b5fbfe45196dfad2821fca513d**dd6efa25c9.)
>
> The path 4.1.1->4.2.0 seems miss?
>
> 2013-09-11 14:32:55,619 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Grabbing lock to check for database upgrade.
> 2013-09-11 14:32:55,631 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) DB version = 4.1.1 Code Version = 4.2.0
> 2013-09-11 14:32:55,632 INFO  [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) Database upgrade must be performed from 4.1.1 to 4.2.0
> 2013-09-11 14:32:55,632 ERROR [cloud.upgrade.**DatabaseUpgradeChecker]
> (Timer-1:null) There is no upgrade path from 4.1.1 to 4.2.0
> 2013-09-11 14:32:55,639 ERROR [utils.component.**ComponentContext]
> (Timer-1:null) System integrity check failed. Refuse to startup
> com.cloud.utils.exception.**CloudRuntimeException: There is no upgrade
> path from 4.1.1 to 4.2.0
>     at com.cloud.upgrade.**DatabaseUpgradeChecker.**upgrade(**
> DatabaseUpgradeChecker.java:**221)
>     at com.cloud.upgrade.**DatabaseUpgradeChecker.check(**
> DatabaseUpgradeChecker.java:**389)
>     at com.cloud.utils.component.**ComponentContext.**
> initComponentsLifeCycle(**ComponentContext.java:90)
>     at com.cloud.servlet.**CloudStartupServlet$1.run(**
> CloudStartupServlet.java:54)
>     at java.util.TimerThread.**mainLoop(Timer.java:534)
>     at java.util.TimerThread.run(**Timer.java:484)
>
>
> Milamber
>

Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Travis Graham <tg...@tgraham.us>.
Is there a problem with applying the sql changes as micro timestamped updates and keeping a schema version in the db based on the timestamp?

In Ruby on Rails that's how migrations are created, as timestamped ruby file that defines the changes, for example 20130818033029_add_user_roles.rb. When a migration is ran all migrations timestamped before the last schema_migration entry are skipped and only the unapplied migration files are applied to the db.

There's an up and down method that allows for things to be rolled back if something doesn't apply correctly so all changes are reversible, as long as there isn't data corruption or one way trapdoor type data changes that happen.

This also allows for partial migrations, you can migrate up to a specified migration based on it's timestamp, and the reverse is also true, you can rollback to a specific version if needed.

The likelihood of a timestamp collision is so astronomically impossible that it isn't a concern. This works well for large code bases being worked on by countless developers adding features and doing what devs do.

The version table could track the timestamps and there wouldn't be any fuss over patch releases with hot fixes vs point releases or major releases that get pushed out causing any problems.

Travis

On Sep 11, 2013, at 6:48 PM, Darren Shepherd <da...@gmail.com> wrote:

> On 09/11/2013 09:12 AM, Alex Huang wrote:
>> 
>> As for separating db version from release version.  In general I agree with that.  Again, it's a practical thing.  Currently, cloudstack db changes with every release so even if you separate them basically they just advance in a parallel path anyways.  I don't see any time soon where cloudstack db schema will stabilize to a point where there's just code changes without schema changes.  When we see that happening, we should break apart the schema from the release version.
>> 
> 
> I'd have to disagree.  First, in a maintenance release, why are you changing the scheme to begin with?  But, if you do, you can do the following.  Say 4.1 was schema 42 and 4.2 in now schema version 50.  If you do a 4.1.1 release that needs a schema change you change the schema in version 51.  And then you install schema 51 on 4.1.
> 
> Schemas should always be backwards compatible in that old code should run on new schema.  I don't think it is the case today as the presence of "clean up" SQL files seems to indicate you are breaking that approach (but I don't really know).
> 
> There's other approaches too.  I really don't think we should do too much to continue to enhance our current approach.  I'd really prefer we just move to flyway.  Regarding hotfixes, here's how flyway can handle it http://flywaydb.org/documentation/faq.html#hot-fixes
> 
> I don't have the time at the moment to help move to flyway, so if somebody else does, great.  Otherwise I'll get to it eventually.
> 
> Darren
> 
> 


Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Darren Shepherd <da...@gmail.com>.
On 09/11/2013 09:12 AM, Alex Huang wrote:
>
> As for separating db version from release version.  In general I agree with that.  Again, it's a practical thing.  Currently, cloudstack db changes with every release so even if you separate them basically they just advance in a parallel path anyways.  I don't see any time soon where cloudstack db schema will stabilize to a point where there's just code changes without schema changes.  When we see that happening, we should break apart the schema from the release version.
>

I'd have to disagree.  First, in a maintenance release, why are you 
changing the scheme to begin with?  But, if you do, you can do the 
following.  Say 4.1 was schema 42 and 4.2 in now schema version 50.  If 
you do a 4.1.1 release that needs a schema change you change the schema 
in version 51.  And then you install schema 51 on 4.1.

Schemas should always be backwards compatible in that old code should 
run on new schema.  I don't think it is the case today as the presence 
of "clean up" SQL files seems to indicate you are breaking that approach 
(but I don't really know).

There's other approaches too.  I really don't think we should do too 
much to continue to enhance our current approach.  I'd really prefer we 
just move to flyway.  Regarding hotfixes, here's how flyway can handle 
it http://flywaydb.org/documentation/faq.html#hot-fixes

I don't have the time at the moment to help move to flyway, so if 
somebody else does, great.  Otherwise I'll get to it eventually.

Darren



RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Alex Huang <Al...@citrix.com>.
> Why do we even maintain such a thing?  DB migration version should not be
> related to the release version.  So DB just goes forward in one continuous
> stream, version 42, 43, 44, 45, 46, etc.
> 

I also meant to reply about this part.  DB upgrade as a continuous stream is nice in theory but really not achievable in practice.  

Consider release timing as follows, each with its own db upgrades.

4.1
4.2
4.1.1 --- where it is branched from 4.1 and is based on 4.1 but was released after 4.2
4.3

Db upgrades, therefore, is not linear.

As for separating db version from release version.  In general I agree with that.  Again, it's a practical thing.  Currently, cloudstack db changes with every release so even if you separate them basically they just advance in a parallel path anyways.  I don't see any time soon where cloudstack db schema will stabilize to a point where there's just code changes without schema changes.  When we see that happening, we should break apart the schema from the release version.

--Alex

RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Alex Huang <Al...@citrix.com>.
I like it as well, especially with the number of dev on the project now.  I think by feature is a good idea.  I do think there are a number of miscellaneous updates like an index to an existing table that having its own sql file is too much.  Maybe we should define when something should be in it's own sql file.  For example, if a feature makes this many changes or certain types of changes on the db schema, then it must define its own sql file.  One obvious one would be if you introduce a new table, it should be in its own sql file.

As I was saying in a previous email, the current upgrade code does support this way of specifying upgrades.  Each upgrade class actually returns an array of sql files, not just one.  It's just our current practice that puts all upgrades into one single file.  It's not due to the upgrade code.

--Alex 

> -----Original Message-----
> From: Soheil Eizadi [mailto:seizadi@infoblox.com]
> Sent: Wednesday, September 11, 2013 9:09 AM
> To: dev@cloudstack.apache.org
> Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0
> 
> Forgot to comment, I like the idea of having smaller sql files rather than one
> large file. -Soheil ________________________________________
> From: Soheil Eizadi [seizadi@infoblox.com]
> Sent: Wednesday, September 11, 2013 9:02 AM
> To: dev@cloudstack.apache.org
> Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0
> 
> Ordering and dependency needs to be handled with multiple sql files not an
> issue with single file.
> -Soheil
> ________________________________________
> From: Alex Huang [Alex.Huang@citrix.com]
> Sent: Wednesday, September 11, 2013 8:29 AM
> To: dev@cloudstack.apache.org
> Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0
> 
> >
> > Why do we even maintain such a thing?  DB migration version should not
> > be related to the release version.  So DB just goes forward in one
> > continuous stream, version 42, 43, 44, 45, 46, etc.
> >
> > So why do we have specific from release to release upgrades?
> > Additionally, there shouldn't be a big olde 41to42.sql.  There should
> > be something 0042-add-important-feature-x.sql,
> > 0043-i-added-something-else- splendid.sql.
> >
> 
> The multiple sql files upgrade is supported.  It was actually the original intent
> with db upgrade but, back when we were a small team, it was easier to just
> edit one single file.  Now, we can definitely change to that type of
> convention.  It does mean a lot more sql files but if we add a directory
> structure, then it shouldn't be a problem.
> 
> --Alex

RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Soheil Eizadi <se...@infoblox.com>.
Forgot to comment, I like the idea of having smaller sql files rather than one large file. -Soheil
________________________________________
From: Soheil Eizadi [seizadi@infoblox.com]
Sent: Wednesday, September 11, 2013 9:02 AM
To: dev@cloudstack.apache.org
Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0

Ordering and dependency needs to be handled with multiple sql files not an issue with single file.
-Soheil
________________________________________
From: Alex Huang [Alex.Huang@citrix.com]
Sent: Wednesday, September 11, 2013 8:29 AM
To: dev@cloudstack.apache.org
Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0

>
> Why do we even maintain such a thing?  DB migration version should not be
> related to the release version.  So DB just goes forward in one continuous
> stream, version 42, 43, 44, 45, 46, etc.
>
> So why do we have specific from release to release upgrades?
> Additionally, there shouldn't be a big olde 41to42.sql.  There should be
> something 0042-add-important-feature-x.sql, 0043-i-added-something-else-
> splendid.sql.
>

The multiple sql files upgrade is supported.  It was actually the original intent with db upgrade but, back when we were a small team, it was easier to just edit one single file.  Now, we can definitely change to that type of convention.  It does mean a lot more sql files but if we add a directory structure, then it shouldn't be a problem.

--Alex

RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Soheil Eizadi <se...@infoblox.com>.
Ordering and dependency needs to be handled with multiple sql files not an issue with single file.
-Soheil
________________________________________
From: Alex Huang [Alex.Huang@citrix.com]
Sent: Wednesday, September 11, 2013 8:29 AM
To: dev@cloudstack.apache.org
Subject: RE: There is no upgrade path from 4.1.1 to 4.2.0

>
> Why do we even maintain such a thing?  DB migration version should not be
> related to the release version.  So DB just goes forward in one continuous
> stream, version 42, 43, 44, 45, 46, etc.
>
> So why do we have specific from release to release upgrades?
> Additionally, there shouldn't be a big olde 41to42.sql.  There should be
> something 0042-add-important-feature-x.sql, 0043-i-added-something-else-
> splendid.sql.
>

The multiple sql files upgrade is supported.  It was actually the original intent with db upgrade but, back when we were a small team, it was easier to just edit one single file.  Now, we can definitely change to that type of convention.  It does mean a lot more sql files but if we add a directory structure, then it shouldn't be a problem.

--Alex

RE: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Alex Huang <Al...@citrix.com>.
> 
> Why do we even maintain such a thing?  DB migration version should not be
> related to the release version.  So DB just goes forward in one continuous
> stream, version 42, 43, 44, 45, 46, etc.
> 
> So why do we have specific from release to release upgrades?
> Additionally, there shouldn't be a big olde 41to42.sql.  There should be
> something 0042-add-important-feature-x.sql, 0043-i-added-something-else-
> splendid.sql.
> 

The multiple sql files upgrade is supported.  It was actually the original intent with db upgrade but, back when we were a small team, it was easier to just edit one single file.  Now, we can definitely change to that type of convention.  It does mean a lot more sql files but if we add a directory structure, then it shouldn't be a problem.

--Alex

Re: There is no upgrade path from 4.1.1 to 4.2.0

Posted by Darren Shepherd <da...@gmail.com>.
On 09/11/2013 07:19 AM, Milamber wrote:
>
> The path 4.1.1->4.2.0 seems miss?
>

Why do we even maintain such a thing?  DB migration version should not 
be related to the release version.  So DB just goes forward in one 
continuous stream, version 42, 43, 44, 45, 46, etc.

So why do we have specific from release to release upgrades? 
Additionally, there shouldn't be a big olde 41to42.sql.  There should be 
something 0042-add-important-feature-x.sql, 
0043-i-added-something-else-splendid.sql.

Darren