You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Yurii Shylov <yu...@gmail.com> on 2015/01/16 19:25:38 UTC
Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/
-----------------------------------------------------------
Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
Bugs: AMBARI-9183
https://issues.apache.org/jira/browse/AMBARI-9183
Repository: ambari
Description
-------
Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java 9b17b33
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
Diff: https://reviews.apache.org/r/29969/diff/
Testing
-------
In progress
Thanks,
Yurii Shylov
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Yurii Shylov <yu...@gmail.com>.
> On Янв. 16, 2015, 6:46 п.п., Alejandro Fernandez wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java, line 1377
> > <https://reviews.apache.org/r/29969/diff/1/?file=823592#file823592line1377>
> >
> > We should not allow creating a new cluster_version in an installing state.
These two issues are basically the same. When we get the first successfully installed service, we should update the host version state and the cluster version, so at that moment there should be only one cluster_version in INSTALLING state. This is not supported right now and causes some side effects, so I've decided to make it CURRENT from the very beginning and treat it as technical debt. Previously cluster version was assumed as CURRENT even before the first component was upgraded.
- Yurii
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68445
-----------------------------------------------------------
On Янв. 16, 2015, 6:26 п.п., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Янв. 16, 2015, 6:26 п.п.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java 9b17b33
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> In progress
>
> Manual testing was performed on 3-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Alejandro Fernandez <af...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68445
-----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java
<https://reviews.apache.org/r/29969/#comment112678>
We need to be careful with the implications of this, because it forces the cluster_version to be created when agents heartbeat with a component. I'll need to go through it more carefully, so hold off for now.
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java
<https://reviews.apache.org/r/29969/#comment112683>
We should not allow creating a new cluster_version in an installing state.
- Alejandro Fernandez
On Jan. 16, 2015, 6:26 p.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 16, 2015, 6:26 p.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java 9b17b33
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> In progress
>
> Manual testing was performed on 3-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Yurii Shylov <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/
-----------------------------------------------------------
(Updated Янв. 19, 2015, 7:14 п.п.)
Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
Bugs: AMBARI-9183
https://issues.apache.org/jira/browse/AMBARI-9183
Repository: ambari
Description (updated)
-------
Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
The logic behind these changes:
when we are doing clean install, the first thing to do is to download all repositories to all hosts, installing won't start without it. So somewhere during this process we can say that repository_version is in INSTALLING/INSTALLED state, but we don't track this as for now. When the installation starts, it means that repo version is INSTALLED. At the time of first response from any of the service we get its version and set to hostcomponentstate table. It propagates changes to host_version and cluster_version. The initial state of the cluster is assumed as UPGRADING because at that moment we have a transition from INSTALLED to CURRENT. After every component reports its version a transition of UPGRADING->CURRENT is made as we don't actually have any finalize step and thus we can skip UPGRADED.
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
Diff: https://reviews.apache.org/r/29969/diff/
Testing
-------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 55:35.812s
Tested clean install and rolling upgrade manually on 2-node cluster
Thanks,
Yurii Shylov
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Alejandro Fernandez <af...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68648
-----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java
<https://reviews.apache.org/r/29969/#comment112995>
Should perhaps also check for not empty
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java
<https://reviews.apache.org/r/29969/#comment112996>
I agree the logic of checking that findByCluster(...).isEmpty() is correct. However, why is the initial state UPGRADING instead of CURRENT?
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java
<https://reviews.apache.org/r/29969/#comment113001>
We should only allow creating a cluster_version in a CURRENT state.
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java
<https://reviews.apache.org/r/29969/#comment113002>
Why is this needed? I thought UPGRADED->CURRENT is the only transition that ends in CURRENT.
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
<https://reviews.apache.org/r/29969/#comment112999>
We should allow initializing to a CURRENT state if the host has no other host_version records.
We should only initialize in an UPGRADING state if we know that we are in the middle of an upgrade because the cluster has a version whose state is UPGRADING or UPGRADED.
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
<https://reviews.apache.org/r/29969/#comment113000>
I will remove this logic that checks for ZKFC in a future patch.
- Alejandro Fernandez
On Jan. 17, 2015, 1:01 a.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 17, 2015, 1:01 a.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
> ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 55:35.812s
>
>
> Tested clean install and rolling upgrade manually on 2-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Dmitro Lisnichenko <dl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68599
-----------------------------------------------------------
Ship it!
Ship It!
- Dmitro Lisnichenko
On Jan. 17, 2015, 1:01 a.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 17, 2015, 1:01 a.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
> ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 55:35.812s
>
>
> Tested clean install and rolling upgrade manually on 2-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Alejandro Fernandez <af...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68658
-----------------------------------------------------------
Ship it!
Ship It!
- Alejandro Fernandez
On Jan. 17, 2015, 1:01 a.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 17, 2015, 1:01 a.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
> ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 55:35.812s
>
>
> Tested clean install and rolling upgrade manually on 2-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Nate Cole <nc...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68610
-----------------------------------------------------------
Ship it!
Let's also get Alejandro's review before pushing
- Nate Cole
On Jan. 16, 2015, 8:01 p.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 16, 2015, 8:01 p.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
> ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 55:35.812s
>
>
> Tested clean install and rolling upgrade manually on 2-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Alejandro Fernandez <af...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/#review68657
-----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java
<https://reviews.apache.org/r/29969/#comment113004>
Yurii just explained to me that even during a new install, the initial state will be UPGRADING, which will transition directly into CURRENT once the install finishes.
- Alejandro Fernandez
On Jan. 17, 2015, 1:01 a.m., Yurii Shylov wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29969/
> -----------------------------------------------------------
>
> (Updated Jan. 17, 2015, 1:01 a.m.)
>
>
> Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
>
>
> Bugs: AMBARI-9183
> https://issues.apache.org/jira/browse/AMBARI-9183
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
> Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
> ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
> ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
> ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
> ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
> ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
> ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
>
> Diff: https://reviews.apache.org/r/29969/diff/
>
>
> Testing
> -------
>
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 55:35.812s
>
>
> Tested clean install and rolling upgrade manually on 2-node cluster
>
>
> Thanks,
>
> Yurii Shylov
>
>
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Yurii Shylov <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/
-----------------------------------------------------------
(Updated Янв. 17, 2015, 1:01 д.п.)
Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
Bugs: AMBARI-9183
https://issues.apache.org/jira/browse/AMBARI-9183
Repository: ambari
Description
-------
Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
Diff: https://reviews.apache.org/r/29969/diff/
Testing (updated)
-------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 55:35.812s
Tested clean install and rolling upgrade manually on 2-node cluster
Thanks,
Yurii Shylov
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Yurii Shylov <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/
-----------------------------------------------------------
(Updated Янв. 17, 2015, 1 д.п.)
Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
Changes
-------
On clean install cluster version is now having UPGRADING state till install is finished; second cluster version won't be created in case of wrong version in heartbit, exception will be thrown instead; added version check for state transfer
Bugs: AMBARI-9183
https://issues.apache.org/jira/browse/AMBARI-9183
Repository: ambari
Description
-------
Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java befd014
ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostVersionDAO.java ed9fa24
ambari-server/src/main/java/org/apache/ambari/server/state/Cluster.java fd0188c
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
Diff: https://reviews.apache.org/r/29969/diff/
Testing
-------
In progress
Manual testing was performed on 3-node cluster
Thanks,
Yurii Shylov
Re: Review Request 29969: Rollling Upgrade - Server bootstrap creates
incorrect repo version
Posted by Yurii Shylov <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29969/
-----------------------------------------------------------
(Updated Янв. 16, 2015, 6:26 п.п.)
Review request for Ambari, Alejandro Fernandez, Dmitro Lisnichenko, and Nate Cole.
Bugs: AMBARI-9183
https://issues.apache.org/jira/browse/AMBARI-9183
Repository: ambari
Description
-------
Currently on clean install Ambari creates cluster entity and its repository version with version taken from selected stack. I.e. for stack HDP-2.2, version 2.2 is written to database, without any information about the actual minor version of that stack. Besides that we can't assume that cluster has some version until it has at least one of components of that version.
Repository version creation should be detached from cluster creation; instead of that versions should be created after receiving the first actual version from service responses during install.
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b5fda49
ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 6dabcbb
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java 9b17b33
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java 19a5f9f
ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClustersImpl.java 9ec8c36
ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java 31606ca
ambari-server/src/test/java/org/apache/ambari/server/state/cluster/ClusterTest.java 57c0223
Diff: https://reviews.apache.org/r/29969/diff/
Testing (updated)
-------
In progress
Manual testing was performed on 3-node cluster
Thanks,
Yurii Shylov