You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@oozie.apache.org by Abhishek Bafna <ba...@gmail.com> on 2016/09/17 20:51:23 UTC

Re: Review Request 51459: Add an admin command to run the PurgeXCommand

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Sept. 17, 2016, 8:51 p.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java f1d0f2b 
  client/src/main/java/org/apache/oozie/client/OozieClient.java a882cab 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 40a5fe5 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java a30baaa 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 567e260 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by András Piros <an...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/#review161202
-----------------------------------------------------------


Ship it!




Ship It!

- Andr�s Piros


On Dec. 19, 2016, 5:36 p.m., Abhishek Bafna wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/51459/
> -----------------------------------------------------------
> 
> (Updated Dec. 19, 2016, 5:36 p.m.)
> 
> 
> Review request for oozie.
> 
> 
> Bugs: OOZIE-2041
>     https://issues.apache.org/jira/browse/OOZIE-2041
> 
> 
> Repository: oozie-git
> 
> 
> Description
> -------
> 
> By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.
> 
> # Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
> # If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
> # The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
> # Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
> # In the HA mode, purge command can be executed only on the leader Oozie server.
> # purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.
> 
> 
> Diffs
> -----
> 
>   client/src/main/java/org/apache/oozie/cli/OozieCLI.java e67fae9 
>   client/src/main/java/org/apache/oozie/client/OozieClient.java 12c80cb 
>   client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
>   client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
>   core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
>   core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
>   core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
>   core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
>   core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
>   core/src/main/resources/oozie-default.xml 2d7650a 
>   core/src/test/java/org/apache/oozie/client/TestOozieCLI.java ce95ff3 
>   core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
>   core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
>   docs/src/site/twiki/DG_CommandLineTool.twiki 35eee40 
>   docs/src/site/twiki/WebServicesAPI.twiki b76e934 
> 
> Diff: https://reviews.apache.org/r/51459/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Abhishek Bafna
> 
>


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Jan. 21, 2017, 7:05 a.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java e67fae9 
  client/src/main/java/org/apache/oozie/client/OozieClient.java 12c80cb 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 943f9bc 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java ce95ff3 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 35eee40 
  docs/src/site/twiki/WebServicesAPI.twiki b76e934 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Jan. 12, 2017, 3:27 p.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java e67fae9 
  client/src/main/java/org/apache/oozie/client/OozieClient.java 12c80cb 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 943f9bc 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java ce95ff3 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 35eee40 
  docs/src/site/twiki/WebServicesAPI.twiki b76e934 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Dec. 19, 2016, 5:36 p.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java e67fae9 
  client/src/main/java/org/apache/oozie/client/OozieClient.java 12c80cb 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 2d7650a 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java ce95ff3 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 35eee40 
  docs/src/site/twiki/WebServicesAPI.twiki b76e934 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Dec. 19, 2016, 1:27 p.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java e67fae9 
  client/src/main/java/org/apache/oozie/client/OozieClient.java 12c80cb 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 2d7650a 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java ce95ff3 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 35eee40 
  docs/src/site/twiki/WebServicesAPI.twiki b76e934 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Sept. 23, 2016, 7:59 p.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java f1d0f2b 
  client/src/main/java/org/apache/oozie/client/OozieClient.java a882cab 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml e71ebe3 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java a30baaa 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 567e260 
  docs/src/site/twiki/WebServicesAPI.twiki 13e1691 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Robert Kanter <rk...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/#review149734
-----------------------------------------------------------




docs/src/site/twiki/DG_CommandLineTool.twiki (line 139)
<https://reviews.apache.org/r/51459/#comment217418>

    Don't forget to add the equivalent documentation to the REST API docs.


- Robert Kanter


On Sept. 18, 2016, 6:43 a.m., Abhishek Bafna wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/51459/
> -----------------------------------------------------------
> 
> (Updated Sept. 18, 2016, 6:43 a.m.)
> 
> 
> Review request for oozie.
> 
> 
> Bugs: OOZIE-2041
>     https://issues.apache.org/jira/browse/OOZIE-2041
> 
> 
> Repository: oozie-git
> 
> 
> Description
> -------
> 
> By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.
> 
> # Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
> # If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
> # The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
> # Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
> # In the HA mode, purge command can be executed only on the leader Oozie server.
> # purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.
> 
> 
> Diffs
> -----
> 
>   client/src/main/java/org/apache/oozie/cli/OozieCLI.java f1d0f2b 
>   client/src/main/java/org/apache/oozie/client/OozieClient.java a882cab 
>   client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
>   client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
>   core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
>   core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
>   core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
>   core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
>   core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
>   core/src/main/resources/oozie-default.xml 40a5fe5 
>   core/src/test/java/org/apache/oozie/client/TestOozieCLI.java a30baaa 
>   core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
>   core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
>   docs/src/site/twiki/DG_CommandLineTool.twiki 567e260 
> 
> Diff: https://reviews.apache.org/r/51459/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Abhishek Bafna
> 
>


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Abhishek Bafna <ba...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/
-----------------------------------------------------------

(Updated Sept. 18, 2016, 6:43 a.m.)


Review request for oozie.


Bugs: OOZIE-2041
    https://issues.apache.org/jira/browse/OOZIE-2041


Repository: oozie-git


Description
-------

By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.

# Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
# If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
# The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
# Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
# In the HA mode, purge command can be executed only on the leader Oozie server.
# purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.


Diffs (updated)
-----

  client/src/main/java/org/apache/oozie/cli/OozieCLI.java f1d0f2b 
  client/src/main/java/org/apache/oozie/client/OozieClient.java a882cab 
  client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
  client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
  core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
  core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
  core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
  core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
  core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
  core/src/main/resources/oozie-default.xml 40a5fe5 
  core/src/test/java/org/apache/oozie/client/TestOozieCLI.java a30baaa 
  core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
  core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
  docs/src/site/twiki/DG_CommandLineTool.twiki 567e260 

Diff: https://reviews.apache.org/r/51459/diff/


Testing
-------


Thanks,

Abhishek Bafna


Re: Review Request 51459: Add an admin command to run the PurgeXCommand

Posted by Peter Cseh <ge...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/51459/#review149349
-----------------------------------------------------------




client/src/main/java/org/apache/oozie/client/OozieClient.java (line 2166)
<https://reviews.apache.org/r/51459/#comment216899>

    Please add check to avoid AOOBE.



client/src/main/java/org/apache/oozie/client/rest/JsonTags.java (line 250)
<https://reviews.apache.org/r/51459/#comment216898>

    PURGE would fit the pattern of these constants more.



core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java (line 211)
<https://reviews.apache.org/r/51459/#comment216897>

    XServletException can take the cause as an additional parameter. Please pass it over.



docs/src/site/twiki/DG_CommandLineTool.twiki (line 139)
<https://reviews.apache.org/r/51459/#comment216900>

    The CLI output is:
     -purge <arg>        purge old oozie workflow, coordinator and bundle records from DB



docs/src/site/twiki/DG_CommandLineTool.twiki (line 1516)
<https://reviews.apache.org/r/51459/#comment216896>

    Can you add a bit more explanation?
    a) The fact that it has to be ran on the leader
    b) A one-line explanation of the example line like: the command would delete every workflow older than two days (wf=2) and so on.


- Peter Cseh


On Sept. 17, 2016, 8:51 p.m., Abhishek Bafna wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/51459/
> -----------------------------------------------------------
> 
> (Updated Sept. 17, 2016, 8:51 p.m.)
> 
> 
> Review request for oozie.
> 
> 
> Bugs: OOZIE-2041
>     https://issues.apache.org/jira/browse/OOZIE-2041
> 
> 
> Repository: oozie-git
> 
> 
> Description
> -------
> 
> By default {{PurgeService}} executes every hour to clean up old oozie workflows, coordinators and bundles from Oozie DB. With the new {{oozie admin -purge wf=1\;coord=2\;bundle=3\;limit=100\;oldCoordAction=true/false>}} command, users (admin users) can execute {{PurgeService}} on demand.
> 
> # Allow users to specify older than values for (workflow, coordinator and bundle) in {{days}}, limit and turn {{on/off}} for old coordinator actions. At least one parameter needs to be specified.
> # If user does not specify one of parameter than {{PurgeService}} will use the default value of it from {{oozie-default.xml}} or {{oozie-site.xml}}.
> # The execution of the Purge Command will require a lock for execution, so at the same time two {{PurgeXCommand}} will not execute. In the case, when lock is not acquired, it will queue the command.
> # Currently purge command is implemented as blocking command. Users will need to wait until command execution completes.
> # In the HA mode, purge command can be executed only on the leader Oozie server.
> # purge command can be enabled/disabled using {{oozie.service.PurgeService.enable.command.line}} property. By default it is enabled.
> 
> 
> Diffs
> -----
> 
>   client/src/main/java/org/apache/oozie/cli/OozieCLI.java f1d0f2b 
>   client/src/main/java/org/apache/oozie/client/OozieClient.java a882cab 
>   client/src/main/java/org/apache/oozie/client/rest/JsonTags.java 397e9ed 
>   client/src/main/java/org/apache/oozie/client/rest/RestConstants.java 4129364 
>   core/src/main/java/org/apache/oozie/command/PurgeXCommand.java ab06fdf 
>   core/src/main/java/org/apache/oozie/service/PurgeService.java 6e4a8e8 
>   core/src/main/java/org/apache/oozie/servlet/BaseAdminServlet.java 64d3f1f 
>   core/src/main/java/org/apache/oozie/servlet/V0AdminServlet.java fd573d5 
>   core/src/main/java/org/apache/oozie/servlet/V1AdminServlet.java 965a19a 
>   core/src/main/resources/oozie-default.xml 40a5fe5 
>   core/src/test/java/org/apache/oozie/client/TestOozieCLI.java a30baaa 
>   core/src/test/java/org/apache/oozie/servlet/TestAdminServlet.java ffa3dc1 
>   core/src/test/java/org/apache/oozie/servlet/TestV1AdminServlet.java 35568e1 
>   docs/src/site/twiki/DG_CommandLineTool.twiki 567e260 
> 
> Diff: https://reviews.apache.org/r/51459/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Abhishek Bafna
> 
>