ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sid Wagle" <swa...@hortonworks.com>
Subject Re: Review Request 16925: Request Schedule status not updated for Point in time execution request
Date Thu, 16 Jan 2014 01:50:33 GMT

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

(Updated Jan. 16, 2014, 1:50 a.m.)


Review request for Ambari, Myroslav Papirkovskyy and Sumit Mohanty.


Bugs: AMBARI-4306
    https://issues.apache.org/jira/browse/AMBARI-4306


Repository: ambari


Description (updated)
-------

*API call*:
{code}
curl -u admin:admin -H "X-Requested-By:ambari" -i -X POST -d '[{"RequestSchedule":{"batch":[{"requests":[{"order_id"
: "1","type":"POST","uri":"/api/v1/clusters/c1/requests","RequestBodyInfo":{"RequestInfo":{"context":"Restart
Nagios","command":"RESTART","service_name":"NAGIOS","component_name":"NAGIOS_SERVER","hosts":"c6401.ambari.apache.org"}}}]},{"batch_settings":{"batch_separation_in_seconds":120,"task_failure_tolerance":1}}]}}]'
http://c6401.ambari.apache.org:8080/api/v1/clusters/c1/request_schedules
{code}

The Request Schedule status will be updated based on following rules:
- Check if any trigger exists for the first job
- Check if trigger exists, then will it fire in the future

If both of the above are untrue, mark RequestSchedule status as COMPLETED


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/scheduler/AbstractLinearExecutionJob.java
9203aac 
  ambari-server/src/main/java/org/apache/ambari/server/scheduler/ExecutionScheduleManager.java
3898441 
  ambari-server/src/main/java/org/apache/ambari/server/scheduler/ExecutionScheduler.java 6644e1b

  ambari-server/src/main/java/org/apache/ambari/server/scheduler/ExecutionSchedulerImpl.java
7e1381d 
  ambari-server/src/main/java/org/apache/ambari/server/state/scheduler/BatchRequestJob.java
88142ac 
  ambari-server/src/main/java/org/apache/ambari/server/state/scheduler/RequestExecution.java
44e8ece 
  ambari-server/src/main/java/org/apache/ambari/server/state/scheduler/RequestExecutionImpl.java
5f43b52 
  ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java 3444988 
  ambari-server/src/test/java/org/apache/ambari/server/scheduler/ExecutionScheduleManagerTest.java
11a0d51 
  ambari-server/src/test/java/org/apache/ambari/server/state/RequestExecutionTest.java 9d29ebf


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


Testing
-------


Thanks,

Sid Wagle


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message