You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@aurora.apache.org by Zameer Manji <zm...@gmail.com> on 2013/12/12 20:29:21 UTC

Review Request 16220: Output all states in maintenance endpoint.

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

Review request for Aurora, Kevin Sweeney and Bill Farner.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.

> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 81
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line81>
> >
> >     This and the other IS_* functions can be replaced with:
> >     
> >     private static Function<HostAttributes, MaintenanceMode> GET_MODE =
> >         new Function<HostAttributes, MaintenanceMode>() {
> >           @Override MaintenanceMode apply(HostAttributes attrs) {
> >             return attr.getMode();
> >           }
> >         };
> >     
> >     private static Predicate<HostAttributes> hasMode(MaintenanceMode mode) {
> >       return Predicates.compose(Predicates.equalTo(mode), GET_MODE);
> >     }
> >     
> >     Then inline:
> >     
> >     hasMode(DRAINING), etc

done.


> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 99
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line99>
> >
> >     this should be only live tasks

done


> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 92
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line92>
> >
> >     s/Fluent//

done


> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 145
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line145>
> >
> >     There's a DRY violation on the snippet of code to get host names by maintenance mode.  Consider extracting a function:
> >     
> >     private static FluentIterable<String> getHostsInMode(MaintenanceMode mode) {
> >       ...
> >     }

done.


> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 68
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line68>
> >
> >     While N is not _huge_ here, there is redundant work in multiple calls to getHostAttributes().  I suspect it wouldn't be hard to rework so that's only fetched once.

I don't think it is worth it here. If you disagree I can encapsulate all of the logic into a stateful private class that does not make multiple calls.


- Zameer


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


On Dec. 12, 2013, 12:51 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 12:51 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.

> On Dec. 12, 2013, 3:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 68
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line68>
> >
> >     While N is not _huge_ here, there is redundant work in multiple calls to getHostAttributes().  I suspect it wouldn't be hard to rework so that's only fetched once.
> 
> Zameer Manji wrote:
>     I don't think it is worth it here. If you disagree I can encapsulate all of the logic into a stateful private class that does not make multiple calls.
> 
> Bill Farner wrote:
>     The class doesn't have to be stateful, you just need to store the result of getHostAttributes() in the calling method:
>     
>       Multimap<MaintenanceMode, String> hostsByMode =
>           Multimaps.index(storeProvider.getAttributeStore().getHostAttributes(), GET_MODE);
>       Map<MaintenanceMode, Object> hosts = Maps.newHashMap();
>       hosts.put(DRAINING, getDrainingTasks(storeProvider, hostsByMode.get(DRAINING));
>       hosts.put(DRAINED, ImmutableSet.copyOf(hostsByMode.get(DRAINED)));
>       hosts.put(SCHEDULED, ImmutableSet.copyOf(hostsByMode.get(SCHEDULED)));

done.


- Zameer


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


On Dec. 12, 2013, 4:53 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 4:53 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Bill Farner <wf...@apache.org>.

> On Dec. 12, 2013, 11:08 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 68
> > <https://reviews.apache.org/r/16220/diff/3/?file=396978#file396978line68>
> >
> >     While N is not _huge_ here, there is redundant work in multiple calls to getHostAttributes().  I suspect it wouldn't be hard to rework so that's only fetched once.
> 
> Zameer Manji wrote:
>     I don't think it is worth it here. If you disagree I can encapsulate all of the logic into a stateful private class that does not make multiple calls.

The class doesn't have to be stateful, you just need to store the result of getHostAttributes() in the calling method:

  Multimap<MaintenanceMode, String> hostsByMode =
      Multimaps.index(storeProvider.getAttributeStore().getHostAttributes(), GET_MODE);
  Map<MaintenanceMode, Object> hosts = Maps.newHashMap();
  hosts.put(DRAINING, getDrainingTasks(storeProvider, hostsByMode.get(DRAINING));
  hosts.put(DRAINED, ImmutableSet.copyOf(hostsByMode.get(DRAINED)));
  hosts.put(SCHEDULED, ImmutableSet.copyOf(hostsByMode.get(SCHEDULED)));


- Bill


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


On Dec. 13, 2013, 12:02 a.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 13, 2013, 12:02 a.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Bill Farner <wf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/#review30294
-----------------------------------------------------------



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment57997>

    While N is not _huge_ here, there is redundant work in multiple calls to getHostAttributes().  I suspect it wouldn't be hard to rework so that's only fetched once.



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment57990>

    This and the other IS_* functions can be replaced with:
    
    private static Function<HostAttributes, MaintenanceMode> GET_MODE =
        new Function<HostAttributes, MaintenanceMode>() {
          @Override MaintenanceMode apply(HostAttributes attrs) {
            return attr.getMode();
          }
        };
    
    private static Predicate<HostAttributes> hasMode(MaintenanceMode mode) {
      return Predicates.compose(Predicates.equalTo(mode), GET_MODE);
    }
    
    Then inline:
    
    hasMode(DRAINING), etc



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment57992>

    s/Fluent//



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment57991>

    this should be only live tasks



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment57994>

    There's a DRY violation on the snippet of code to get host names by maintenance mode.  Consider extracting a function:
    
    private static FluentIterable<String> getHostsInMode(MaintenanceMode mode) {
      ...
    }


- Bill Farner


On Dec. 12, 2013, 8:51 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 8:51 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.

> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 64
> > <https://reviews.apache.org/r/16220/diff/6/?file=397095#file397095line64>
> >
> >     At this point, you might as well just return Response from the storage op

done.


> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 84
> > <https://reviews.apache.org/r/16220/diff/6/?file=397095#file397095line84>
> >
> >     This is probably more appropriately-named getTasksByHosts()

done.


> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 87
> > <https://reviews.apache.org/r/16220/diff/6/?file=397095#file397095line87>
> >
> >     (1) please leave a blank line between a wrapped method signature and the method body
> >     (2) indentation is funky in this method

done.


> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java, line 213
> > <https://reviews.apache.org/r/16220/diff/6/?file=397096#file397096line213>
> >
> >     I would find this more concise and more readable:
> >     
> >       if (attributes.isPresent() && (DRAINING == attributes.getMode())) {
> >         ...
> >       }

done.


> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java, line 217
> > <https://reviews.apache.org/r/16220/diff/6/?file=397096#file397096line217>
> >
> >     inline below

done.


> On Dec. 12, 2013, 5:07 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java, line 291
> > <https://reviews.apache.org/r/16220/diff/6/?file=397096#file397096line291>
> >
> >     please kindly give intellij a smack and revert

done.


- Zameer


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


On Dec. 12, 2013, 4:56 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 4:56 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Bill Farner <wf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/#review30316
-----------------------------------------------------------


Looking much better, i suspect this is the last round-trip before a ship.


src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment58025>

    At this point, you might as well just return Response from the storage op



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment58032>

    This is probably more appropriately-named getTasksByHosts()



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment58031>

    (1) please leave a blank line between a wrapped method signature and the method body
    (2) indentation is funky in this method



src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java
<https://reviews.apache.org/r/16220/#comment58027>

    I generally dislike embedding the type in the variable name.  IMHO, 'attributes' is sufficient, and the type explains that it might be absent.



src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java
<https://reviews.apache.org/r/16220/#comment58029>

    I would find this more concise and more readable:
    
      if (attributes.isPresent() && (DRAINING == attributes.getMode())) {
        ...
      }



src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java
<https://reviews.apache.org/r/16220/#comment58026>

    inline below



src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java
<https://reviews.apache.org/r/16220/#comment58030>

    please kindly give intellij a smack and revert


- Bill Farner


On Dec. 13, 2013, 12:56 a.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 13, 2013, 12:56 a.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.

> On Dec. 12, 2013, 5:41 p.m., Bill Farner wrote:
> > src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java, line 66
> > <https://reviews.apache.org/r/16220/diff/7/?file=397337#file397337line66>
> >
> >     feel free to pull this up to the previous line

done.


- Zameer


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


On Dec. 12, 2013, 5:49 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 5:49 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Bill Farner <wf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/#review30324
-----------------------------------------------------------

Ship it!



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment58055>

    feel free to pull this up to the previous line



src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java
<https://reviews.apache.org/r/16220/#comment58056>

    space on both sides of the colon:
    
      for (String host : hosts) {


- Bill Farner


On Dec. 13, 2013, 1:34 a.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 13, 2013, 1:34 a.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Bill Farner <wf...@apache.org>.

> On Dec. 13, 2013, 1:50 a.m., Zameer Manji wrote:
> > Please commit my code.

Done, feel free to close the review.


- Bill


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


On Dec. 13, 2013, 1:49 a.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 13, 2013, 1:49 a.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/#review30329
-----------------------------------------------------------


Please commit my code.

- Zameer Manji


On Dec. 12, 2013, 5:49 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16220/
> -----------------------------------------------------------
> 
> (Updated Dec. 12, 2013, 5:49 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Bill Farner.
> 
> 
> Bugs: AURORA-9
>     https://issues.apache.org/jira/browse/AURORA-9
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.
> 
> 
> Diffs
> -----
> 
>   src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
>   src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
>   src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 
> 
> Diff: https://reviews.apache.org/r/16220/diff/
> 
> 
> Testing
> -------
> 
> ./gradlew clean build
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 5:49 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Minor style nits.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 5:34 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Bill's Feedback.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 4:56 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Checkstyle fixes


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 4:53 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Bill's feedback.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 4:02 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Bill's feedback.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 12:51 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Checkstyle fixes.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji


Re: Review Request 16220: Output all states in maintenance endpoint.

Posted by Zameer Manji <zm...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16220/
-----------------------------------------------------------

(Updated Dec. 12, 2013, 12:46 p.m.)


Review request for Aurora, Kevin Sweeney and Bill Farner.


Changes
-------

Rebased on top of latest master.


Bugs: AURORA-9
    https://issues.apache.org/jira/browse/AURORA-9


Repository: aurora


Description
-------

Improve the /maintenance endpoint to print out hosts affected by SCHEDULED and DRAINED states.


Diffs (updated)
-----

  src/main/java/com/twitter/aurora/scheduler/http/Maintenance.java 30afce37d6c108a5a8c1c3c8a8094030ad12ce72 
  src/main/java/com/twitter/aurora/scheduler/state/MaintenanceController.java fb12d38858b260d1d9ce318d3022cd93413a3e68 
  src/test/java/com/twitter/aurora/scheduler/state/MaintenanceControllerImplTest.java 8acb716c733ec9d3cc3b1ec74c85f958082ae139 

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


Testing
-------

./gradlew clean build


Thanks,

Zameer Manji