You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@aurora.apache.org by Suman Karumuri <sk...@twitter.com> on 2013/12/13 01:46:36 UTC
Review Request 16231: Added getJobSummary call to thrift API
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/
-----------------------------------------------------------
Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
Repository: aurora
Description
-------
Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
Diffs
-----
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
Diff: https://reviews.apache.org/r/16231/diff/
Testing
-------
gradle clean build
Thanks,
Suman Karumuri
Re: Review Request 16231: Added getJobSummary call to thrift API
Posted by Suman Karumuri <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/#review30847
-----------------------------------------------------------
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java
<https://reviews.apache.org/r/16231/#comment59049>
Done.
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java
<https://reviews.apache.org/r/16231/#comment59050>
Changed.
- Suman Karumuri
On Dec. 13, 2013, 12:46 a.m., Suman Karumuri wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16231/
> -----------------------------------------------------------
>
> (Updated Dec. 13, 2013, 12:46 a.m.)
>
>
> Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
>
>
> Repository: aurora
>
>
> Description
> -------
>
> Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
>
> Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
>
>
> Diffs
> -----
>
> src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
> src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
> src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
> src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
>
> Diff: https://reviews.apache.org/r/16231/diff/
>
>
> Testing
> -------
>
> gradle clean build
>
>
> Thanks,
>
> Suman Karumuri
>
>
Re: Review Request 16231: Added getJobSummary call to thrift API
Posted by Suman Karumuri <ma...@apache.org>.
> On Dec. 26, 2013, 8:34 p.m., Bill Farner wrote:
> > This looks great!
Thanks queued!
- Suman
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/#review30886
-----------------------------------------------------------
On Dec. 24, 2013, 1:39 a.m., Suman Karumuri wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16231/
> -----------------------------------------------------------
>
> (Updated Dec. 24, 2013, 1:39 a.m.)
>
>
> Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
>
>
> Repository: aurora
>
>
> Description
> -------
>
> Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
>
> Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
>
>
> Diffs
> -----
>
> src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
> src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
> src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
> src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
>
> Diff: https://reviews.apache.org/r/16231/diff/
>
>
> Testing
> -------
>
> gradle clean build
>
>
> Thanks,
>
> Suman Karumuri
>
>
Re: Review Request 16231: Added getJobSummary call to thrift API
Posted by Bill Farner <wf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/#review30886
-----------------------------------------------------------
Ship it!
This looks great!
- Bill Farner
On Dec. 24, 2013, 1:39 a.m., Suman Karumuri wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16231/
> -----------------------------------------------------------
>
> (Updated Dec. 24, 2013, 1:39 a.m.)
>
>
> Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
>
>
> Repository: aurora
>
>
> Description
> -------
>
> Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
>
> Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
>
>
> Diffs
> -----
>
> src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
> src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
> src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
> src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
>
> Diff: https://reviews.apache.org/r/16231/diff/
>
>
> Testing
> -------
>
> gradle clean build
>
>
> Thanks,
>
> Suman Karumuri
>
>
Re: Review Request 16231: Added getJobSummary call to thrift API
Posted by Suman Karumuri <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/
-----------------------------------------------------------
(Updated Dec. 24, 2013, 1:39 a.m.)
Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
Changes
-------
Updated code per Bill's comments.
Repository: aurora
Description
-------
Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
Diffs (updated)
-----
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
Diff: https://reviews.apache.org/r/16231/diff/
Testing
-------
gradle clean build
Thanks,
Suman Karumuri
Re: Review Request 16231: Added getJobSummary call to thrift API
Posted by Bill Farner <wf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16231/#review30402
-----------------------------------------------------------
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java
<https://reviews.apache.org/r/16231/#comment58191>
Please remove — ordering should be a display concern.
src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java
<https://reviews.apache.org/r/16231/#comment58192>
I'd love to do without the mutable state, even if it's short-lived. Can you instead index into two SetMultimaps, and iterate over the union of their key sets?
e.g.
Multimap<String, JobKey> jobsByRole = ...;
Multimap<String, JobKey> cronJobsByRole = ...;
List<JobSummary> jobSummaries = ...;
for (String role : Sets.union(jobsByRole.keySet(), cronJobsByRole.keySet()) {
JobSummary summary = ...;
summary.setJobCount(jobsByRole.get(role).size());
summary.setCronJobCount(cronJobsByRole.get(role).size());
jobSummaries.add(summary);
}
- Bill Farner
On Dec. 13, 2013, 12:46 a.m., Suman Karumuri wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16231/
> -----------------------------------------------------------
>
> (Updated Dec. 13, 2013, 12:46 a.m.)
>
>
> Review request for Aurora, Kevin Sweeney, Maxim Khutornenko, and Bill Farner.
>
>
> Repository: aurora
>
>
> Description
> -------
>
> Added a new Thrift service to host all read only api's. Added a getJobSummary call to the read only service end point. The output of the call will be used to render the home page.
>
> Implemented the getJobSummary API in SchedulerThriftInterface and added a corresponding unit test. To keep it simple, the implementation of getJobSummary is a clone of SchedulerzHome.get().
>
>
> Diffs
> -----
>
> src/main/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterface.java 503ac447c364340dc7072d15fd3c94532779f7c1
> src/main/thrift/com/twitter/aurora/gen/api.thrift 9b3680b7f219e2805bdc37f2e7560cdca41a5913
> src/test/java/com/twitter/aurora/scheduler/thrift/SchedulerThriftInterfaceTest.java 1e1e7b5a9c2805790ed26939e151b727a15ec88d
> src/test/java/com/twitter/aurora/scheduler/thrift/aop/ForwardingThrift.java 7c5100bd043273ca85e3ed9b54f9cd4f4725d83c
>
> Diff: https://reviews.apache.org/r/16231/diff/
>
>
> Testing
> -------
>
> gradle clean build
>
>
> Thanks,
>
> Suman Karumuri
>
>