aurora-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maxim Khutornenko <ma...@apache.org>
Subject Re: Review Request 51993: Added the 'reason' to the /pendingTasks endpoint
Date Mon, 19 Sep 2016 16:18:19 GMT

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




src/main/java/org/apache/aurora/scheduler/scheduling/TaskGroups.java (line 138)
<https://reviews.apache.org/r/51993/#comment217136>

    I don't think this is the right approach. `TaskGroups` has no business in accessing the
`NearestFit` functionality. 
    
    Please, consider extracting [this](https://github.com/apache/aurora/blob/795a2728c623c35bd509d582c24684a6921c74ad/src/main/java/org/apache/aurora/scheduler/thrift/ReadOnlySchedulerImpl.java#L194-L208)
and making it a public method of the `NearestFit` itself (e.g.: `getPendingReason(Query.Builder
query)`. You can query that method and marry the results right within the `PendingTasks`.


- Maxim Khutornenko


On Sept. 17, 2016, 9:36 p.m., Pradyumna Kaushik wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/51993/
> -----------------------------------------------------------
> 
> (Updated Sept. 17, 2016, 9:36 p.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Added the 'reason' to the /pendingTasks endpoint
> 
> 
> Diffs
> -----
> 
>   src/main/java/org/apache/aurora/scheduler/http/PendingTasks.java c80e0c8adf80e12082a6952ae79b7d9cc960c5b6

>   src/main/java/org/apache/aurora/scheduler/scheduling/TaskGroup.java 5d319557057e27fd5fc6d3e553e9ca9139399c50

>   src/main/java/org/apache/aurora/scheduler/scheduling/TaskGroups.java d390c07522d22e43d79ce4370985f3643ef021ca

>   src/test/java/org/apache/aurora/scheduler/scheduling/TaskGroupsTest.java 88729626de5fa87b45472792c59cc0ff1ade3e93

> 
> Diff: https://reviews.apache.org/r/51993/diff/
> 
> 
> Testing
> -------
> 
> ./build-support/jenkins/build.sh
> ./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
> 
> 
> Thanks,
> 
> Pradyumna Kaushik
> 
>


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