You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@ambari.apache.org by Di Li <di...@ca.ibm.com> on 2017/11/02 15:12:26 UTC
Review Request 63513: AMBARI-22337 each service should be able to
implement
server actions, package them add a jar to be loaded during EU
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63513/
-----------------------------------------------------------
Review request for Ambari, Jonathan Hurley and Tim Thorpe.
Bugs: AMBARI-22337
https://issues.apache.org/jira/browse/AMBARI-22337
Repository: ambari
Description
-------
xsi:type="server_action" tasks defined in EU/RU upgrade pack xml files currently can only classes from Ambari source code. This limites the server action that custom services / services from mpacks can perform. This JIRA proposes a way to allow each service to implement server action classes, package them in a jar to be loaded during EU
1. Each service can have a server_actions (support stack inheritance) such as /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions.
a) The dir contains jar for the server action classes.
/var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions
[root@~ server_actions]# ll
total 8
rw-rr- 1 root root 7510 Oct 30 10:49 test_full.jar
2. upgrade pack can then invoke the server action as shown below
<!-- server action test without specifying a service in the execution stage-->
<group xsi:type="cluster" name="TEST_A" title="Test abc">
<execute-stage title="aaaa">
<task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithoutService"/>
</execute-stage>
</group>
<!-- server action test with a service specified in the execution stage-->
<execute-stage service="ZOOKEEPER" component="ZOOKEEPER_SERVER" title="Parame
terizing Zookeeper Log4J Properties">
<task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithService">
<summary>zkpr test</summary>
</task>
</execute-stage>
Diffs
-----
ambari-server/pom.xml a86acf5
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java 50e3cfe
ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceDirectory.java 119163e
ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceModule.java 3b3d52c
ambari-server/src/main/java/org/apache/ambari/server/state/ServiceInfo.java 8fe6583
ambari-server/src/test/java/org/apache/ambari/server/stack/ServiceModuleTest.java dbdd043
ambari-server/src/test/java/org/apache/ambari/server/stack/StackManagerExtensionTest.java 6617b33
Diff: https://reviews.apache.org/r/63513/diff/1/
Testing
-------
unit tests, patch a trunk cluster with upgrade.xml changes and java changes, run EU, verify the external server action classes ran and were able to provide response back to EU.
Thanks,
Di Li
Re: Review Request 63513: AMBARI-22337 each service should be able to
implement server actions,
package them add a jar to be loaded during EU
Posted by Di Li <di...@ca.ibm.com>.
> On Nov. 2, 2017, 4:02 p.m., Tim Thorpe wrote:
> > Remove whitespace
all whitespaces will be fixed when I apply the patch for the final commit where git will remove them all.
- Di
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63513/#review189923
-----------------------------------------------------------
On Nov. 2, 2017, 7:30 p.m., Di Li wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63513/
> -----------------------------------------------------------
>
> (Updated Nov. 2, 2017, 7:30 p.m.)
>
>
> Review request for Ambari, Jonathan Hurley and Tim Thorpe.
>
>
> Bugs: AMBARI-22337
> https://issues.apache.org/jira/browse/AMBARI-22337
>
>
> Repository: ambari
>
>
> Description
> -------
>
> xsi:type="server_action" tasks defined in EU/RU upgrade pack xml files currently can only classes from Ambari source code. This limites the server action that custom services / services from mpacks can perform. This JIRA proposes a way to allow each service to implement server action classes, package them in a jar to be loaded during EU
> 1. Each service can have a server_actions (support stack inheritance) such as /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions.
> a) The dir contains jar for the server action classes.
> /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions
> [root@~ server_actions]# ll
> total 8
> rw-rr- 1 root root 7510 Oct 30 10:49 test_full.jar
> 2. upgrade pack can then invoke the server action as shown below
> <!-- server action test without specifying a service in the execution stage-->
> <group xsi:type="cluster" name="TEST_A" title="Test abc">
> <execute-stage title="aaaa">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithoutService"/>
> </execute-stage>
> </group>
> <!-- server action test with a service specified in the execution stage-->
> <execute-stage service="ZOOKEEPER" component="ZOOKEEPER_SERVER" title="Parame
> terizing Zookeeper Log4J Properties">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithService">
> <summary>zkpr test</summary>
> </task>
> </execute-stage>
>
>
> Diffs
> -----
>
> ambari-server/pom.xml a86acf5
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java 50e3cfe
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceDirectory.java 119163e
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceModule.java 3b3d52c
> ambari-server/src/main/java/org/apache/ambari/server/state/ServiceInfo.java 8fe6583
> ambari-server/src/test/java/org/apache/ambari/server/stack/ServiceModuleTest.java dbdd043
> ambari-server/src/test/java/org/apache/ambari/server/stack/StackManagerExtensionTest.java 6617b33
>
>
> Diff: https://reviews.apache.org/r/63513/diff/2/
>
>
> Testing
> -------
>
> unit tests, patch a trunk cluster with upgrade.xml changes and java changes, run EU, verify the external server action classes ran and were able to provide response back to EU.
>
>
> Thanks,
>
> Di Li
>
>
Re: Review Request 63513: AMBARI-22337 each service should be able to
implement server actions,
package them add a jar to be loaded during EU
Posted by Tim Thorpe <tt...@ca.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63513/#review189923
-----------------------------------------------------------
Fix it, then Ship it!
Remove whitespace
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 593 (patched)
<https://reviews.apache.org/r/63513/#comment267149>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 600 (patched)
<https://reviews.apache.org/r/63513/#comment267148>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 616 (patched)
<https://reviews.apache.org/r/63513/#comment267150>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 619 (patched)
<https://reviews.apache.org/r/63513/#comment267151>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 623 (patched)
<https://reviews.apache.org/r/63513/#comment267152>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 646 (patched)
<https://reviews.apache.org/r/63513/#comment267153>
Should this be moved to a debug message?
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java
Lines 664 (patched)
<https://reviews.apache.org/r/63513/#comment267154>
Should this be moved to a debug message?
- Tim Thorpe
On Nov. 2, 2017, 3:12 p.m., Di Li wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63513/
> -----------------------------------------------------------
>
> (Updated Nov. 2, 2017, 3:12 p.m.)
>
>
> Review request for Ambari, Jonathan Hurley and Tim Thorpe.
>
>
> Bugs: AMBARI-22337
> https://issues.apache.org/jira/browse/AMBARI-22337
>
>
> Repository: ambari
>
>
> Description
> -------
>
> xsi:type="server_action" tasks defined in EU/RU upgrade pack xml files currently can only classes from Ambari source code. This limites the server action that custom services / services from mpacks can perform. This JIRA proposes a way to allow each service to implement server action classes, package them in a jar to be loaded during EU
> 1. Each service can have a server_actions (support stack inheritance) such as /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions.
> a) The dir contains jar for the server action classes.
> /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions
> [root@~ server_actions]# ll
> total 8
> rw-rr- 1 root root 7510 Oct 30 10:49 test_full.jar
> 2. upgrade pack can then invoke the server action as shown below
> <!-- server action test without specifying a service in the execution stage-->
> <group xsi:type="cluster" name="TEST_A" title="Test abc">
> <execute-stage title="aaaa">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithoutService"/>
> </execute-stage>
> </group>
> <!-- server action test with a service specified in the execution stage-->
> <execute-stage service="ZOOKEEPER" component="ZOOKEEPER_SERVER" title="Parame
> terizing Zookeeper Log4J Properties">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithService">
> <summary>zkpr test</summary>
> </task>
> </execute-stage>
>
>
> Diffs
> -----
>
> ambari-server/pom.xml a86acf5
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java 50e3cfe
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceDirectory.java 119163e
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceModule.java 3b3d52c
> ambari-server/src/main/java/org/apache/ambari/server/state/ServiceInfo.java 8fe6583
> ambari-server/src/test/java/org/apache/ambari/server/stack/ServiceModuleTest.java dbdd043
> ambari-server/src/test/java/org/apache/ambari/server/stack/StackManagerExtensionTest.java 6617b33
>
>
> Diff: https://reviews.apache.org/r/63513/diff/1/
>
>
> Testing
> -------
>
> unit tests, patch a trunk cluster with upgrade.xml changes and java changes, run EU, verify the external server action classes ran and were able to provide response back to EU.
>
>
> Thanks,
>
> Di Li
>
>
Re: Review Request 63513: AMBARI-22337 each service should be able to
implement server actions,
package them add a jar to be loaded during EU
Posted by Tim Thorpe <tt...@ca.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63513/#review189951
-----------------------------------------------------------
Ship it!
Ship It!
- Tim Thorpe
On Nov. 2, 2017, 7:30 p.m., Di Li wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63513/
> -----------------------------------------------------------
>
> (Updated Nov. 2, 2017, 7:30 p.m.)
>
>
> Review request for Ambari, Jonathan Hurley and Tim Thorpe.
>
>
> Bugs: AMBARI-22337
> https://issues.apache.org/jira/browse/AMBARI-22337
>
>
> Repository: ambari
>
>
> Description
> -------
>
> xsi:type="server_action" tasks defined in EU/RU upgrade pack xml files currently can only classes from Ambari source code. This limites the server action that custom services / services from mpacks can perform. This JIRA proposes a way to allow each service to implement server action classes, package them in a jar to be loaded during EU
> 1. Each service can have a server_actions (support stack inheritance) such as /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions.
> a) The dir contains jar for the server action classes.
> /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions
> [root@~ server_actions]# ll
> total 8
> rw-rr- 1 root root 7510 Oct 30 10:49 test_full.jar
> 2. upgrade pack can then invoke the server action as shown below
> <!-- server action test without specifying a service in the execution stage-->
> <group xsi:type="cluster" name="TEST_A" title="Test abc">
> <execute-stage title="aaaa">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithoutService"/>
> </execute-stage>
> </group>
> <!-- server action test with a service specified in the execution stage-->
> <execute-stage service="ZOOKEEPER" component="ZOOKEEPER_SERVER" title="Parame
> terizing Zookeeper Log4J Properties">
> <task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithService">
> <summary>zkpr test</summary>
> </task>
> </execute-stage>
>
>
> Diffs
> -----
>
> ambari-server/pom.xml a86acf5
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java 50e3cfe
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceDirectory.java 119163e
> ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceModule.java 3b3d52c
> ambari-server/src/main/java/org/apache/ambari/server/state/ServiceInfo.java 8fe6583
> ambari-server/src/test/java/org/apache/ambari/server/stack/ServiceModuleTest.java dbdd043
> ambari-server/src/test/java/org/apache/ambari/server/stack/StackManagerExtensionTest.java 6617b33
>
>
> Diff: https://reviews.apache.org/r/63513/diff/2/
>
>
> Testing
> -------
>
> unit tests, patch a trunk cluster with upgrade.xml changes and java changes, run EU, verify the external server action classes ran and were able to provide response back to EU.
>
>
> Thanks,
>
> Di Li
>
>
Re: Review Request 63513: AMBARI-22337 each service should be able to
implement server actions,
package them add a jar to be loaded during EU
Posted by Di Li <di...@ca.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63513/
-----------------------------------------------------------
(Updated Nov. 2, 2017, 7:30 p.m.)
Review request for Ambari, Jonathan Hurley and Tim Thorpe.
Bugs: AMBARI-22337
https://issues.apache.org/jira/browse/AMBARI-22337
Repository: ambari
Description
-------
xsi:type="server_action" tasks defined in EU/RU upgrade pack xml files currently can only classes from Ambari source code. This limites the server action that custom services / services from mpacks can perform. This JIRA proposes a way to allow each service to implement server action classes, package them in a jar to be loaded during EU
1. Each service can have a server_actions (support stack inheritance) such as /var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions.
a) The dir contains jar for the server action classes.
/var/lib/ambari-server/resources/stacks/HDP/2.5/services/ZOOKEEPER/server_actions
[root@~ server_actions]# ll
total 8
rw-rr- 1 root root 7510 Oct 30 10:49 test_full.jar
2. upgrade pack can then invoke the server action as shown below
<!-- server action test without specifying a service in the execution stage-->
<group xsi:type="cluster" name="TEST_A" title="Test abc">
<execute-stage title="aaaa">
<task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithoutService"/>
</execute-stage>
</group>
<!-- server action test with a service specified in the execution stage-->
<execute-stage service="ZOOKEEPER" component="ZOOKEEPER_SERVER" title="Parame
terizing Zookeeper Log4J Properties">
<task xsi:type="server_action" class="org.apache.ambari.server.serveraction.upgrades.SATestWithService">
<summary>zkpr test</summary>
</task>
</execute-stage>
Diffs (updated)
-----
ambari-server/pom.xml a86acf5
ambari-server/src/main/java/org/apache/ambari/server/serveraction/ServerActionExecutor.java 50e3cfe
ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceDirectory.java 119163e
ambari-server/src/main/java/org/apache/ambari/server/stack/ServiceModule.java 3b3d52c
ambari-server/src/main/java/org/apache/ambari/server/state/ServiceInfo.java 8fe6583
ambari-server/src/test/java/org/apache/ambari/server/stack/ServiceModuleTest.java dbdd043
ambari-server/src/test/java/org/apache/ambari/server/stack/StackManagerExtensionTest.java 6617b33
Diff: https://reviews.apache.org/r/63513/diff/2/
Changes: https://reviews.apache.org/r/63513/diff/1-2/
Testing
-------
unit tests, patch a trunk cluster with upgrade.xml changes and java changes, run EU, verify the external server action classes ran and were able to provide response back to EU.
Thanks,
Di Li