Re: Review Request 22457: Improve aurora "job diff" command.

2014-10-27 Thread Mark Chu-Carroll


> On Oct. 24, 2014, 11:58 a.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 311
> > <https://reviews.apache.org/r/22457/diff/10/?file=732192#file732192line311>
> >
> > This is no longer true. The `populated` field reprsents a single 
> > TaskConfig now. You'd need to inflate a task config list according to the 
> > local instance count.
> 
> Mark Chu-Carroll wrote:
> So you changed the semantics of the API call without changing its type 
> signature to reflect that? Really?
> 
> Maxim Khutornenko wrote:
> We can't change type signatures without breaking backward compatibility. 
> This deprecation was a long overdue change as there is no reason to return a 
> set of completely identical structs over the wire now that all TaskConfigs 
> are identical.

Backward compatibility is only backward compatibility if existing code is 
unbroken by a change. That is *not* the case here. This is a breaking change - 
it will break the comparisons of any client code that isn't explicitly updated 
to reflect the change. Semantic changes break backward compatibility - as this 
change shows!

The right way to handle something like this is to be explicit about the 
deprecation, not to sloppily overload an existing structure so that the change 
will slip by unnoticed because you kept the type signature, but changed the 
semantics.


- Mark


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


On Oct. 24, 2014, 10:50 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/22457/
> ---
> 
> (Updated Oct. 24, 2014, 10:50 a.m.)
> 
> 
> Review request for Aurora, Maxim Khutornenko and Brian Wickman.
> 
> 
> Bugs: aurora-520
> https://issues.apache.org/jira/browse/aurora-520
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Add a new diff method, which uses field-by-field comparison of JSON trees for 
> comparing running job configurations to potentially updated configs.
> 
> - Allow exclusion of semantically irrelevant fields.
> - Provide a clearer list of the differences between configs.
> - Provide a scripting-friendly alternative JSON syntax for diffs.
> 
> The old diff behavior is still available under the "--use-shell-diff" option.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/BUILD 
> 995570325bbb09ecbcc2ace5d223760c5d49367f 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 625cb80a33ae565b403fc71bb9795e4700e1aeb7 
>   src/main/python/apache/aurora/client/cli/json_tree_diff.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/BUILD 
> 4692d31a9c128664273f71d15ee217dc060e66f0 
>   src/test/python/apache/aurora/client/cli/test_diff.py 
> 78694d7559f2041f27cd2a7e4cb81ca467f63ac2 
>   src/test/python/apache/aurora/client/cli/test_json_diff.py PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/22457/diff/
> 
> 
> Testing
> ---
> 
> New unit tests of the JSON tree diff code, plus a bunch of new "job diff" 
> tests of the new functionality.
> All tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 22457: Improve aurora "job diff" command.

2014-10-27 Thread Mark Chu-Carroll


> On Oct. 24, 2014, 11:58 a.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 311
> > <https://reviews.apache.org/r/22457/diff/10/?file=732192#file732192line311>
> >
> > This is no longer true. The `populated` field reprsents a single 
> > TaskConfig now. You'd need to inflate a task config list according to the 
> > local instance count.

So you changed the semantics of the API call without changing its type 
signature to reflect that? Really?


- Mark


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


On Oct. 24, 2014, 10:50 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/22457/
> ---
> 
> (Updated Oct. 24, 2014, 10:50 a.m.)
> 
> 
> Review request for Aurora, Maxim Khutornenko and Brian Wickman.
> 
> 
> Bugs: aurora-520
> https://issues.apache.org/jira/browse/aurora-520
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Add a new diff method, which uses field-by-field comparison of JSON trees for 
> comparing running job configurations to potentially updated configs.
> 
> - Allow exclusion of semantically irrelevant fields.
> - Provide a clearer list of the differences between configs.
> - Provide a scripting-friendly alternative JSON syntax for diffs.
> 
> The old diff behavior is still available under the "--use-shell-diff" option.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/BUILD 
> 995570325bbb09ecbcc2ace5d223760c5d49367f 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 625cb80a33ae565b403fc71bb9795e4700e1aeb7 
>   src/main/python/apache/aurora/client/cli/json_tree_diff.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/BUILD 
> 4692d31a9c128664273f71d15ee217dc060e66f0 
>   src/test/python/apache/aurora/client/cli/test_diff.py 
> 78694d7559f2041f27cd2a7e4cb81ca467f63ac2 
>   src/test/python/apache/aurora/client/cli/test_json_diff.py PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/22457/diff/
> 
> 
> Testing
> ---
> 
> New unit tests of the JSON tree diff code, plus a bunch of new "job diff" 
> tests of the new functionality.
> All tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 27084: Fix error when "job create" is called with "--open-browser".

2014-10-27 Thread Mark Chu-Carroll

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

(Updated Oct. 27, 2014, 11:07 a.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

rebase


Bugs: aurora-886
https://issues.apache.org/jira/browse/aurora-886


Repository: aurora


Description
---

Fix error when "job create" is called with "--open-browser".


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/jobs.py 
625cb80a33ae565b403fc71bb9795e4700e1aeb7 
  src/test/python/apache/aurora/client/cli/test_create.py 
8a5aef8d866f69e124951dd43bf98396f0bd1ef1 

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


Testing
---

Added new test; all unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 22457: Improve aurora "job diff" command.

2014-10-24 Thread Mark Chu-Carroll

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

(Updated Oct. 24, 2014, 10:50 a.m.)


Review request for Aurora, Maxim Khutornenko and Brian Wickman.


Changes
---

I think I finally found the problem that was causing the jenkins failures. 
Since this rebase was a bit messy, can reviewers please take another look 
before I try pushing it?


Bugs: aurora-520
https://issues.apache.org/jira/browse/aurora-520


Repository: aurora


Description
---

Add a new diff method, which uses field-by-field comparison of JSON trees for 
comparing running job configurations to potentially updated configs.

- Allow exclusion of semantically irrelevant fields.
- Provide a clearer list of the differences between configs.
- Provide a scripting-friendly alternative JSON syntax for diffs.

The old diff behavior is still available under the "--use-shell-diff" option.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/BUILD 
995570325bbb09ecbcc2ace5d223760c5d49367f 
  src/main/python/apache/aurora/client/cli/jobs.py 
625cb80a33ae565b403fc71bb9795e4700e1aeb7 
  src/main/python/apache/aurora/client/cli/json_tree_diff.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/BUILD 
4692d31a9c128664273f71d15ee217dc060e66f0 
  src/test/python/apache/aurora/client/cli/test_diff.py 
78694d7559f2041f27cd2a7e4cb81ca467f63ac2 
  src/test/python/apache/aurora/client/cli/test_json_diff.py PRE-CREATION 

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


Testing
---

New unit tests of the JSON tree diff code, plus a bunch of new "job diff" tests 
of the new functionality.
All tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 27047: Improve status command output ordering.

2014-10-22 Thread Mark Chu-Carroll

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

(Updated Oct. 22, 2014, 4:55 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Use keyword parameters in thrift constructors instead of assignment.


Bugs: aurora-879
https://issues.apache.org/jira/browse/aurora-879


Repository: aurora


Description
---

- Sort tasks by instance number.
- Sort events by timestamp.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/jobs.py 
10f8e0d331ca607e55e3aa6f96014caea744ed9f 
  src/test/python/apache/aurora/client/cli/test_status.py 
4f62cf0c52e5837309cf7ad702df6d907df8f510 

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


Testing
---

./pants src/test/python/apache/aurora/client/cli:job
Build operating on top level addresses: 
set([BuildFileAddress(/Users/mchucarroll/Code/incubator-aurora/src/test/python/apache/aurora/client/cli/BUILD,
 job)])
= test session starts ==
platform darwin -- Python 2.7.5 -- py-1.4.25 -- pytest-2.6.3
plugins: cov, timeout
collected 58 items

src/test/python/apache/aurora/client/cli/test_cancel_update.py ..
src/test/python/apache/aurora/client/cli/test_create.py ...
src/test/python/apache/aurora/client/cli/test_diff.py ...
src/test/python/apache/aurora/client/cli/test_kill.py 
src/test/python/apache/aurora/client/cli/test_open.py .
src/test/python/apache/aurora/client/cli/test_restart.py 
src/test/python/apache/aurora/client/cli/test_status.py .

== 58 passed in 3.65 seconds ===
src.test.python.apache.aurora.client.cli.job
.   SUCCESS


Thanks,

Mark Chu-Carroll



Re: Review Request 27047: Improve status command output ordering.

2014-10-22 Thread Mark Chu-Carroll


> On Oct. 22, 2014, 2:41 p.m., Joshua Cohen wrote:
> > src/test/python/apache/aurora/client/cli/test_status.py, line 81
> > <https://reviews.apache.org/r/27047/diff/1/?file=728832#file728832line81>
> >
> > spec?

I'll do better than spec: there's no reason for that to be a mock at all.


- Mark


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


On Oct. 22, 2014, 1:57 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/27047/
> ---
> 
> (Updated Oct. 22, 2014, 1:57 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-879
> https://issues.apache.org/jira/browse/aurora-879
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Sort tasks by instance number.
> - Sort events by timestamp.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 10f8e0d331ca607e55e3aa6f96014caea744ed9f 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> 4f62cf0c52e5837309cf7ad702df6d907df8f510 
> 
> Diff: https://reviews.apache.org/r/27047/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python/apache/aurora/client/cli:job
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/mchucarroll/Code/incubator-aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  job)])
> = test session starts 
> ==
> platform darwin -- Python 2.7.5 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 58 items
> 
> src/test/python/apache/aurora/client/cli/test_cancel_update.py ..
> src/test/python/apache/aurora/client/cli/test_create.py ...
> src/test/python/apache/aurora/client/cli/test_diff.py ...
> src/test/python/apache/aurora/client/cli/test_kill.py 
> src/test/python/apache/aurora/client/cli/test_open.py .
> src/test/python/apache/aurora/client/cli/test_restart.py 
> src/test/python/apache/aurora/client/cli/test_status.py .....
> 
> == 58 passed in 3.65 seconds 
> ===
> src.test.python.apache.aurora.client.cli.job  
>   .   SUCCESS
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26753: Start removing clientv1.

2014-10-21 Thread Mark Chu-Carroll

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

(Updated Oct. 21, 2014, 2:34 p.m.)


Review request for Aurora, Bill Farner and Zameer Manji.


Changes
---

Rebase, now that 26982 was pushed.


Bugs: aurora-131
https://issues.apache.org/jira/browse/aurora-131


Repository: aurora


Description
---

- Make the "aurora2" main target be the standalone clientv2;
- Don't build the bridged client by default; but allow forced build using 
"aurora2_bridge".
- Modify cli tests so that they only depend on the standalone clientv2.
- Modify vagrant config to make clientv2 the primary client.
- Modify end-to-end tests to match the vagrant changes.

(Note: end-to-end tests are failing, but in the same way as they fail without 
this change. I'm working on debugging that, but it should be its own 
change/review, and I don't want to delay reviewing this.)


Diffs (updated)
-

  docs/developing-aurora-client.md b9912bce44d65ddd7f1e35f0ea9356a89d5fe767 
  examples/vagrant/aurorabuild.sh 8659bffb8fb6170c02aef0edce92349540d4366a 
  examples/vagrant/provision-dev-cluster.sh 
1d4fd77a83dbfc6724a3a3b5f44301dc54b3085c 
  examples/vagrant/test_tutorial.sh a5557cb57010cd541cc753e8c74c7a3a99425477 
  src/main/python/apache/aurora/client/cli/BUILD 
995570325bbb09ecbcc2ace5d223760c5d49367f 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
95aa649cfff9166dd10aa432c4d470739e8f06c5 
  src/test/python/apache/aurora/client/cli/test_cancel_update.py 
e7052465411165acb3d5145664f2f166ac052500 
  src/test/python/apache/aurora/client/cli/test_command_hooks.py 
9fc6fe2c2063cda494437d83044557b345acacea 
  src/test/python/apache/aurora/client/cli/test_config_noun.py 
dfcbd7217b1d51609fa01c4d9cefed5471c91718 
  src/test/python/apache/aurora/client/cli/test_create.py 
328297ab1d29efb0adce8f4931a13929a04dcd9c 
  src/test/python/apache/aurora/client/cli/test_cron.py 
c7b71c29d44150162fec8066947623fa91815424 
  src/test/python/apache/aurora/client/cli/test_diff.py 
10817695352687cdb5b0c3ed9720e3091b230e68 
  src/test/python/apache/aurora/client/cli/test_help.py 
551c9f949cda3971a370cb696216ec9584584336 
  src/test/python/apache/aurora/client/cli/test_inspect.py 
e997b9743b63d71f8624ecf5ca1dcae0227be70d 
  src/test/python/apache/aurora/client/cli/test_kill.py 
f7601d82dbb45900bec2939dca2b921bf147961d 
  src/test/python/apache/aurora/client/cli/test_logging.py 
9ca4dceeaa87d5fb2e38fe0d83fdcdf1ee597a0e 
  src/test/python/apache/aurora/client/cli/test_open.py 
c20649f5cada241d0f6e9ae5f88d300eac073517 
  src/test/python/apache/aurora/client/cli/test_plugins.py 
dc5edd4f03cee062673231a04908193480c8071c 
  src/test/python/apache/aurora/client/cli/test_quota.py 
88fb9aec4d1eae6ad05da01752a670f902bafb1b 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a753ab4aead7e2560cae77c441562811924f8f1b 
  src/test/python/apache/aurora/client/cli/test_sla.py 
a1a3d8161ba747aa23a5e614e9ae31473d2058c1 
  src/test/python/apache/aurora/client/cli/test_status.py 
4f62cf0c52e5837309cf7ad702df6d907df8f510 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
f3fa6cf6e9e080689593c40e787018eff46f8ede 
  src/test/python/apache/aurora/client/cli/test_task_run.py 
16fde14c03f6fd2c000e76625fad174835763f1b 
  src/test/python/apache/aurora/client/cli/test_update.py 
cff1b6578aec6f5bcc1e610e58b47af233f32b41 
  src/test/sh/org/apache/aurora/e2e/test_common.sh 
43d2516133c6d6cdb4236358f942396f057f739c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh 
324aa4dbeff00e673fe73b87e3a0766856cd213c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
bbbf90b95e91bcdf8aaf8b2a7b577dee70a7c8a7 

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


Testing
---

- Ran all unit tests, confirmed they continue to pass.
- Ran end-to-end tests (both v1 and v2 variants) with the updated setup, and 
verified that they fail in exactly the same way as before this change.


Thanks,

Mark Chu-Carroll



Re: Review Request 26753: Start removing clientv1.

2014-10-21 Thread Mark Chu-Carroll

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

(Updated Oct. 21, 2014, 2:05 p.m.)


Review request for Aurora, Bill Farner and Zameer Manji.


Changes
---

Address reviews. (Note that this builds on https://reviews.apache.org/r/26982/, 
which will need to be pushed before this.)


Bugs: aurora-131
https://issues.apache.org/jira/browse/aurora-131


Repository: aurora


Description
---

- Make the "aurora2" main target be the standalone clientv2;
- Don't build the bridged client by default; but allow forced build using 
"aurora2_bridge".
- Modify cli tests so that they only depend on the standalone clientv2.
- Modify vagrant config to make clientv2 the primary client.
- Modify end-to-end tests to match the vagrant changes.

(Note: end-to-end tests are failing, but in the same way as they fail without 
this change. I'm working on debugging that, but it should be its own 
change/review, and I don't want to delay reviewing this.)


Diffs (updated)
-

  docs/developing-aurora-client.md b9912bce44d65ddd7f1e35f0ea9356a89d5fe767 
  examples/vagrant/aurorabuild.sh 8659bffb8fb6170c02aef0edce92349540d4366a 
  examples/vagrant/provision-dev-cluster.sh 
1d4fd77a83dbfc6724a3a3b5f44301dc54b3085c 
  examples/vagrant/test_tutorial.sh a5557cb57010cd541cc753e8c74c7a3a99425477 
  src/main/python/apache/aurora/client/cli/BUILD 
995570325bbb09ecbcc2ace5d223760c5d49367f 
  src/main/python/apache/aurora/client/cli/jobs.py 
7bbde156e64e969c6d402a04aaf7c038b919693a 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
95aa649cfff9166dd10aa432c4d470739e8f06c5 
  src/test/python/apache/aurora/client/cli/test_cancel_update.py 
e7052465411165acb3d5145664f2f166ac052500 
  src/test/python/apache/aurora/client/cli/test_command_hooks.py 
9fc6fe2c2063cda494437d83044557b345acacea 
  src/test/python/apache/aurora/client/cli/test_config_noun.py 
dfcbd7217b1d51609fa01c4d9cefed5471c91718 
  src/test/python/apache/aurora/client/cli/test_create.py 
328297ab1d29efb0adce8f4931a13929a04dcd9c 
  src/test/python/apache/aurora/client/cli/test_cron.py 
c7b71c29d44150162fec8066947623fa91815424 
  src/test/python/apache/aurora/client/cli/test_diff.py 
10817695352687cdb5b0c3ed9720e3091b230e68 
  src/test/python/apache/aurora/client/cli/test_help.py 
551c9f949cda3971a370cb696216ec9584584336 
  src/test/python/apache/aurora/client/cli/test_inspect.py 
e997b9743b63d71f8624ecf5ca1dcae0227be70d 
  src/test/python/apache/aurora/client/cli/test_kill.py 
f7601d82dbb45900bec2939dca2b921bf147961d 
  src/test/python/apache/aurora/client/cli/test_logging.py 
9ca4dceeaa87d5fb2e38fe0d83fdcdf1ee597a0e 
  src/test/python/apache/aurora/client/cli/test_open.py 
c20649f5cada241d0f6e9ae5f88d300eac073517 
  src/test/python/apache/aurora/client/cli/test_plugins.py 
dc5edd4f03cee062673231a04908193480c8071c 
  src/test/python/apache/aurora/client/cli/test_quota.py 
88fb9aec4d1eae6ad05da01752a670f902bafb1b 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a753ab4aead7e2560cae77c441562811924f8f1b 
  src/test/python/apache/aurora/client/cli/test_sla.py 
a1a3d8161ba747aa23a5e614e9ae31473d2058c1 
  src/test/python/apache/aurora/client/cli/test_status.py 
c704daec5a6eee73c7092a201b168881853908e8 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
f3fa6cf6e9e080689593c40e787018eff46f8ede 
  src/test/python/apache/aurora/client/cli/test_task_run.py 
16fde14c03f6fd2c000e76625fad174835763f1b 
  src/test/python/apache/aurora/client/cli/test_update.py 
cff1b6578aec6f5bcc1e610e58b47af233f32b41 
  src/test/sh/org/apache/aurora/e2e/test_common.sh 
43d2516133c6d6cdb4236358f942396f057f739c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh 
324aa4dbeff00e673fe73b87e3a0766856cd213c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
bbbf90b95e91bcdf8aaf8b2a7b577dee70a7c8a7 

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


Testing
---

- Ran all unit tests, confirmed they continue to pass.
- Ran end-to-end tests (both v1 and v2 variants) with the updated setup, and 
verified that they fail in exactly the same way as before this change.


Thanks,

Mark Chu-Carroll



Re: Review Request 26982: Make v2 job status look more like v1.

2014-10-21 Thread Mark Chu-Carroll


> On Oct. 21, 2014, 1:57 p.m., David McLaughlin wrote:
> > Is there an end to end test for this that needs updated?

No. The end-to-end doesn't check the output from the status command.


- Mark


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


On Oct. 21, 2014, 12:19 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26982/
> ---
> 
> (Updated Oct. 21, 2014, 12:19 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: AURORA-874
> https://issues.apache.org/jira/browse/AURORA-874
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adds a header line to each task in a task status line specifying
> the instance number, host, etc., the way v1 did. (We had originally planned
> not to display that information in v2, but we also have tests that depend on 
> it being present.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 7bbde156e64e969c6d402a04aaf7c038b919693a 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> c704daec5a6eee73c7092a201b168881853908e8 
> 
> Diff: https://reviews.apache.org/r/26982/diff/
> 
> 
> Testing
> ---
> 
> $ ./pants src/test/python/apache/aurora/client/cli:job
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/mchucarroll/Code/incubator-aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  job)])
> = test session starts 
> ==
> platform darwin -- Python 2.7.5 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 62 items
> 
> src/test/python/apache/aurora/client/cli/test_cancel_update.py ..
> src/test/python/apache/aurora/client/cli/test_create.py ...
> src/test/python/apache/aurora/client/cli/test_diff.py ...
> src/test/python/apache/aurora/client/cli/test_kill.py 
> src/test/python/apache/aurora/client/cli/test_open.py .
> src/test/python/apache/aurora/client/cli/test_restart.py 
> src/test/python/apache/aurora/client/cli/test_status.py 
> src/test/python/apache/aurora/client/cli/test_update.py .
> 
> ========== 62 passed in 6.42 seconds 
> ===
> src.test.python.apache.aurora.client.cli.job  
>   .   SUCCESS
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26753: Start removing clientv1.

2014-10-21 Thread Mark Chu-Carroll


> On Oct. 15, 2014, 2:24 p.m., Bill Farner wrote:
> > Should `docs/clientv2.md` be rehashed/removed to wipe traces of v1, or in a 
> > separte diff?
> > 
> > Can you also update `examples/vagrant/test_tutorial.sh`?  I suspect it's 
> > broken by this patch.

I'd prefer to leave that doc - it's a historical which will be useful for 
understanding the code. I think just adding a header to it saying that it's a 
historical document is enough.

But you're right that the docs in general need update - in particular, the 
"developing-aurora-client" doc should remove references to v1. I would prefer 
to make that a separate change.


> On Oct. 15, 2014, 2:24 p.m., Bill Farner wrote:
> > src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh, line 38
> > <https://reviews.apache.org/r/26753/diff/1/?file=722233#file722233line38>
> >
> > Looks like leftover debugging, and the actual test is commented out?

Was a temporary workaround for part of the end-to-end test problem that Kevin 
has now fixed.


- Mark


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


On Oct. 15, 2014, 12:20 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26753/
> ---
> 
> (Updated Oct. 15, 2014, 12:20 p.m.)
> 
> 
> Review request for Aurora, Bill Farner and Zameer Manji.
> 
> 
> Bugs: aurora-131
> https://issues.apache.org/jira/browse/aurora-131
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Make the "aurora2" main target be the standalone clientv2;
> - Don't build the bridged client by default; but allow forced build using 
> "aurora2_bridge".
> - Modify cli tests so that they only depend on the standalone clientv2.
> - Modify vagrant config to make clientv2 the primary client.
> - Modify end-to-end tests to match the vagrant changes.
> 
> (Note: end-to-end tests are failing, but in the same way as they fail without 
> this change. I'm working on debugging that, but it should be its own 
> change/review, and I don't want to delay reviewing this.)
> 
> 
> Diffs
> -
> 
>   docs/developing-aurora-client.md e1b2ccd7504f983169118a288721894184d67c97 
>   examples/vagrant/aurorabuild.sh a27636655d722ca79f66b377fd847954d52e8feb 
>   examples/vagrant/provision-dev-cluster.sh 
> 740bc212ba604b2c64af92eba1be41e8ed3fdbde 
>   src/main/python/apache/aurora/client/cli/BUILD 
> 995570325bbb09ecbcc2ace5d223760c5d49367f 
>   src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
> a2b28ba23961284ba60358af54726e0386dd69b6 
>   src/test/python/apache/aurora/client/cli/test_cancel_update.py 
> e7052465411165acb3d5145664f2f166ac052500 
>   src/test/python/apache/aurora/client/cli/test_command_hooks.py 
> 9fc6fe2c2063cda494437d83044557b345acacea 
>   src/test/python/apache/aurora/client/cli/test_config_noun.py 
> dfcbd7217b1d51609fa01c4d9cefed5471c91718 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 427f7ce4476b48d407b8bd2bf2c54c52e6e63079 
>   src/test/python/apache/aurora/client/cli/test_cron.py 
> c7b71c29d44150162fec8066947623fa91815424 
>   src/test/python/apache/aurora/client/cli/test_diff.py 
> 10817695352687cdb5b0c3ed9720e3091b230e68 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> f73c8a3778b7d118ea2865f213b442a607fb4a7d 
>   src/test/python/apache/aurora/client/cli/test_inspect.py 
> e997b9743b63d71f8624ecf5ca1dcae0227be70d 
>   src/test/python/apache/aurora/client/cli/test_kill.py 
> bac4485fa105848d96e2505c4a2ea2eee45dc968 
>   src/test/python/apache/aurora/client/cli/test_logging.py 
> 9ca4dceeaa87d5fb2e38fe0d83fdcdf1ee597a0e 
>   src/test/python/apache/aurora/client/cli/test_open.py 
> c20649f5cada241d0f6e9ae5f88d300eac073517 
>   src/test/python/apache/aurora/client/cli/test_plugins.py 
> dc5edd4f03cee062673231a04908193480c8071c 
>   src/test/python/apache/aurora/client/cli/test_quota.py 
> 88fb9aec4d1eae6ad05da01752a670f902bafb1b 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a5f94484b30ecb8417116db9ce12c015957357c5 
>   src/test/python/apache/aurora/client/cli/test_sla.py 
> a1a3d8161ba747aa23a5e614e9ae31473d2058c1 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> c704daec5a6eee73c7092a201b168881853908e8 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 6775c389cb1a0b80dd17fe179e8b98d4e9d

Review Request 26982: Make v2 job status look more like v1.

2014-10-21 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


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


Repository: aurora


Description
---

Adds a header line to each task in a task status line specifying
the instance number, host, etc., the way v1 did. (We had originally planned
not to display that information in v2, but we also have tests that depend on it 
being present.)


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
7bbde156e64e969c6d402a04aaf7c038b919693a 
  src/test/python/apache/aurora/client/cli/test_status.py 
c704daec5a6eee73c7092a201b168881853908e8 

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


Testing
---

$ ./pants src/test/python/apache/aurora/client/cli:job
Build operating on top level addresses: 
set([BuildFileAddress(/Users/mchucarroll/Code/incubator-aurora/src/test/python/apache/aurora/client/cli/BUILD,
 job)])
= test session starts ==
platform darwin -- Python 2.7.5 -- py-1.4.25 -- pytest-2.6.3
plugins: cov, timeout
collected 62 items

src/test/python/apache/aurora/client/cli/test_cancel_update.py ..
src/test/python/apache/aurora/client/cli/test_create.py ...
src/test/python/apache/aurora/client/cli/test_diff.py ...
src/test/python/apache/aurora/client/cli/test_kill.py 
src/test/python/apache/aurora/client/cli/test_open.py .
src/test/python/apache/aurora/client/cli/test_restart.py 
src/test/python/apache/aurora/client/cli/test_status.py 
src/test/python/apache/aurora/client/cli/test_update.py .

== 62 passed in 6.42 seconds ===
src.test.python.apache.aurora.client.cli.job
.   SUCCESS


Thanks,

Mark Chu-Carroll



Re: Review Request 26881: Improve error messages in client commands.

2014-10-20 Thread Mark Chu-Carroll

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

(Updated Oct. 20, 2014, 3:36 p.m.)


Review request for Aurora, Bill Farner and Zameer Manji.


Changes
---

Make error messages more concise.


Bugs: aurora-771
https://issues.apache.org/jira/browse/aurora-771


Repository: aurora


Description
---

When a client command fails due to an error in an API call,
it used to log whatever messages came back in the reply from the server,
and then generate a message saying "... see log for details".

This change improves that behavior. Now, an error message is generated
saying something like "Command failed due to error reported by server",
followed by a group of indented lines containing the messages from the
server. For example, a new error message would look like:

Server reported error restarting job west/bozo/test/hello
Job 'west/bozo/test/hello' not found.


Diffs (updated)
-

  examples/vagrant/aurorabuild.sh a27636655d722ca79f66b377fd847954d52e8feb 
  src/main/python/apache/aurora/client/cli/context.py 
4e94a4e3017f3b2ace38d6d8ce68c3c778c8cd0e 
  src/main/python/apache/aurora/client/cli/cron.py 
061b1d4f768f299d6db72c66f6bb75fdb68bc0d7 
  src/main/python/apache/aurora/client/cli/jobs.py 
0277cbed4b7eb927d6e5823b4b41d90b366f81d0 
  src/main/python/apache/aurora/client/cli/quota.py 
137aab1285a9732a3b65aee65948e836df3c7cac 
  src/main/python/apache/aurora/client/cli/update.py 
8a02b8a8b0bb531248949213da97cbc1a380bf64 
  src/test/python/apache/aurora/client/cli/test_create.py 
427f7ce4476b48d407b8bd2bf2c54c52e6e63079 
  src/test/python/apache/aurora/client/cli/test_kill.py 
bac4485fa105848d96e2505c4a2ea2eee45dc968 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a5f94484b30ecb8417116db9ce12c015957357c5 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
6775c389cb1a0b80dd17fe179e8b98d4e9db0332 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
8f4d2b01c9fa5a6ec9e8885a2d4fa0e9c3abb8a1 

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


Testing
---


Thanks,

Mark Chu-Carroll



Re: Review Request 26881: Improve error messages in client commands.

2014-10-20 Thread Mark Chu-Carroll


> On Oct. 20, 2014, 1:17 p.m., Bill Farner wrote:
> > src/main/python/apache/aurora/client/cli/cron.py, line 48
> > <https://reviews.apache.org/r/26881/diff/1/?file=724475#file724475line48>
> >
> > I don't think the "reported by server" part is a useful detail, 
> > consider dropping.  Ditto for alternative wordings "reported by scheduler".

I think it's worth distinguishing between a local error detected by the client, 
and an error detected by the scheduler. Maybe "Server error schedulering cron 
job", to make it more concise, but still include the information.


- Mark


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


On Oct. 17, 2014, 1:58 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26881/
> ---
> 
> (Updated Oct. 17, 2014, 1:58 p.m.)
> 
> 
> Review request for Aurora, Bill Farner and Zameer Manji.
> 
> 
> Bugs: aurora-771
> https://issues.apache.org/jira/browse/aurora-771
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> When a client command fails due to an error in an API call,
> it used to log whatever messages came back in the reply from the server,
> and then generate a message saying "... see log for details".
> 
> This change improves that behavior. Now, an error message is generated
> saying something like "Command failed due to error reported by server",
> followed by a group of indented lines containing the messages from the
> server. For example, a new error message would look like:
> 
>   Server reported error restarting job west/bozo/test/hello
>   Job 'west/bozo/test/hello' not found.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 4e94a4e3017f3b2ace38d6d8ce68c3c778c8cd0e 
>   src/main/python/apache/aurora/client/cli/cron.py 
> 061b1d4f768f299d6db72c66f6bb75fdb68bc0d7 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 0277cbed4b7eb927d6e5823b4b41d90b366f81d0 
>   src/main/python/apache/aurora/client/cli/quota.py 
> 137aab1285a9732a3b65aee65948e836df3c7cac 
>   src/main/python/apache/aurora/client/cli/update.py 
> 8a02b8a8b0bb531248949213da97cbc1a380bf64 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 427f7ce4476b48d407b8bd2bf2c54c52e6e63079 
>   src/test/python/apache/aurora/client/cli/test_kill.py 
> bac4485fa105848d96e2505c4a2ea2eee45dc968 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a5f94484b30ecb8417116db9ce12c015957357c5 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 6775c389cb1a0b80dd17fe179e8b98d4e9db0332 
> 
> Diff: https://reviews.apache.org/r/26881/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26881: Improve error messages in client commands.

2014-10-17 Thread Mark Chu-Carroll

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

Review request for Aurora, Bill Farner and Zameer Manji.


Bugs: aurora-771
https://issues.apache.org/jira/browse/aurora-771


Repository: aurora


Description
---

When a client command fails due to an error in an API call,
it used to log whatever messages came back in the reply from the server,
and then generate a message saying "... see log for details".

This change improves that behavior. Now, an error message is generated
saying something like "Command failed due to error reported by server",
followed by a group of indented lines containing the messages from the
server. For example, a new error message would look like:

Server reported error restarting job west/bozo/test/hello
Job 'west/bozo/test/hello' not found.


Diffs
-

  src/main/python/apache/aurora/client/cli/context.py 
4e94a4e3017f3b2ace38d6d8ce68c3c778c8cd0e 
  src/main/python/apache/aurora/client/cli/cron.py 
061b1d4f768f299d6db72c66f6bb75fdb68bc0d7 
  src/main/python/apache/aurora/client/cli/jobs.py 
0277cbed4b7eb927d6e5823b4b41d90b366f81d0 
  src/main/python/apache/aurora/client/cli/quota.py 
137aab1285a9732a3b65aee65948e836df3c7cac 
  src/main/python/apache/aurora/client/cli/update.py 
8a02b8a8b0bb531248949213da97cbc1a380bf64 
  src/test/python/apache/aurora/client/cli/test_create.py 
427f7ce4476b48d407b8bd2bf2c54c52e6e63079 
  src/test/python/apache/aurora/client/cli/test_kill.py 
bac4485fa105848d96e2505c4a2ea2eee45dc968 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a5f94484b30ecb8417116db9ce12c015957357c5 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
6775c389cb1a0b80dd17fe179e8b98d4e9db0332 

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


Testing
---


Thanks,

Mark Chu-Carroll



Re: Review Request 26431: Moving post_drain script execution into host_maintenance.py

2014-10-17 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Oct. 8, 2014, 7:46 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26431/
> ---
> 
> (Updated Oct. 8, 2014, 7:46 p.m.)
> 
> 
> Review request for Aurora, Joe Smith and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-806
> https://issues.apache.org/jira/browse/AURORA-806
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Moving post_drain script functionality into host_maintenance.py to support 
> per batch execution.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/admin/host_maintenance.py 
> 9c2a9f77109791da574e1624d27b6b7096a2678e 
>   src/main/python/apache/aurora/client/commands/maintenance.py 
> e465d973e9f764076e18491e1691d44303c0f388 
>   src/test/python/apache/aurora/admin/test_host_maintenance.py 
> 40228df59e43bc6034f2dc651c166a0c4b78aea8 
> 
> Diff: https://reviews.apache.org/r/26431/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 26688: Fix errors in help rendering:

2014-10-15 Thread Mark Chu-Carroll

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

(Updated Oct. 15, 2014, 1:57 p.m.)


Review request for Aurora, Joshua Cohen and Zameer Manji.


Changes
---

Update description of the logging level parameter.


Bugs: aurora-831
https://issues.apache.org/jira/browse/aurora-831


Repository: aurora


Description
---

- Put plugin-generated options into the correct order.
- Include the option-name in the detailed help list.
- Add missing metavars.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/__init__.py 
da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
  src/main/python/apache/aurora/client/cli/options.py 
dc76c25b90acb9610e40b939e65c3cabf032649f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
  src/test/python/apache/aurora/client/cli/test_help.py 
f73c8a3778b7d118ea2865f213b442a607fb4a7d 

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


Testing
---

New help output:
{noformat}
[sun-wukong incubator-aurora (deprecate)]$ ./dist/aurora2.pex help cron 
deschedule
Usage for verb "cron deschedule":
  deschedule   [--verbose-logging]   [--logging-level=numeric_level]   
[--error-log-dir=error-log-dir] [--bind=var=value] CLUSTER/ROLE/ENV/NAME
Options:
  --bind=var=value
Bind a pystachio variable name to a value. Multiple flags may be used 
to specify multiple values.
  CLUSTER/ROLE/ENV/NAME
Fully specified job key, in CLUSTER/ROLE/ENV/NAME format
  --verbose-logging
Show verbose logging, including all logs up to level INFO (equivalent 
to --logging-level=20)
  --logging-level=numeric_level
Set logging to a specific numeric level.
  --error-log-dir=error-log-dir
Directory location where error files containing stack traces should be 
written. If the directory doesn't exist, it will be created

Remove the cron schedule for a job.
{noformat}


Thanks,

Mark Chu-Carroll



Re: Review Request 26688: Fix errors in help rendering:

2014-10-15 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/cli/standalone_client.py
<https://reviews.apache.org/r/26688/#comment97119>

It's the standard python loglevels. The number is basically any positive 
integer from 0 to 50. 

The underlying assumption here is that this is an option that's only going 
to be used by someone who knows what they're doing, most likely someone 
debugging the client. Users will generally use "--verbose-logging" instead of 
setting a specific value.

Since this is an option that's going to show up in *every* command's help, 
I'd really like to keep it's helpline as concise as possible.

How about adding "numeric level as defined by python standard logging"?


- Mark Chu-Carroll


On Oct. 15, 2014, 12:46 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26688/
> ---
> 
> (Updated Oct. 15, 2014, 12:46 p.m.)
> 
> 
> Review request for Aurora, Joshua Cohen and Zameer Manji.
> 
> 
> Bugs: aurora-831
> https://issues.apache.org/jira/browse/aurora-831
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Put plugin-generated options into the correct order.
> - Include the option-name in the detailed help list.
> - Add missing metavars.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
>   src/main/python/apache/aurora/client/cli/options.py 
> dc76c25b90acb9610e40b939e65c3cabf032649f 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> f73c8a3778b7d118ea2865f213b442a607fb4a7d 
> 
> Diff: https://reviews.apache.org/r/26688/diff/
> 
> 
> Testing
> ---
> 
> New help output:
> {noformat}
> [sun-wukong incubator-aurora (deprecate)]$ ./dist/aurora2.pex help cron 
> deschedule
> Usage for verb "cron deschedule":
>   deschedule   [--verbose-logging]   [--logging-level=numeric_level]   
> [--error-log-dir=error-log-dir] [--bind=var=value] CLUSTER/ROLE/ENV/NAME
> Options:
>   --bind=var=value
>   Bind a pystachio variable name to a value. Multiple flags may be used 
> to specify multiple values.
>   CLUSTER/ROLE/ENV/NAME
>   Fully specified job key, in CLUSTER/ROLE/ENV/NAME format
>   --verbose-logging
>   Show verbose logging, including all logs up to level INFO (equivalent 
> to --logging-level=20)
>   --logging-level=numeric_level
>   Set logging to a specific numeric level.
>   --error-log-dir=error-log-dir
>   Directory location where error files containing stack traces should be 
> written. If the directory doesn't exist, it will be created
> 
> Remove the cron schedule for a job.
> {noformat}
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26688: Fix errors in help rendering:

2014-10-15 Thread Mark Chu-Carroll


> On Oct. 14, 2014, 12:46 p.m., Joshua Cohen wrote:
> > src/test/python/apache/aurora/client/cli/test_help.py, line 75
> > <https://reviews.apache.org/r/26688/diff/1/?file=720844#file720844line75>
> >
> > Are option names guaranteed to be unique? If not this test could 
> > potentially pass if any help output contains a plugin option name, not 
> > necessarily the help output for the command to which the plugin was 
> > registered.
> > 
> > It's also possible for a plugin option name to appear in the help for 
> > another option, and not on its own, which would cause this test to succeed 
> > even if the plugin options themselves are not properly displayed?
> > 
> > I guess what I'm getting at is would it be better to test for more than 
> > just the appearance of a string at any point in the output?
> > 
> > (This may be based on incomplete understanding of how the client 
> > registers commands/options).

I'm trying to keep the test from being overly sensitive to changes. The problem 
with a lot of output testing is that it's incredibly brittle - even tiny 
changes to the output require the test to get rewritten.  So when possible, I'd 
prefer to have tightly focused tests, which look for specific problems.

We know that we had a rendering bug that was causing plugin options to get 
omitted from usage strings - so this test tries to specifically check that 
that's not happening anymore. If it fails, we know exactly what the problem is.


- Mark


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


On Oct. 15, 2014, 12:41 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26688/
> ---
> 
> (Updated Oct. 15, 2014, 12:41 p.m.)
> 
> 
> Review request for Aurora, Joshua Cohen and Zameer Manji.
> 
> 
> Bugs: aurora-831
> https://issues.apache.org/jira/browse/aurora-831
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Put plugin-generated options into the correct order.
> - Include the option-name in the detailed help list.
> - Add missing metavars.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
>   src/main/python/apache/aurora/client/cli/options.py 
> dc76c25b90acb9610e40b939e65c3cabf032649f 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> f73c8a3778b7d118ea2865f213b442a607fb4a7d 
> 
> Diff: https://reviews.apache.org/r/26688/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26688: Fix errors in help rendering:

2014-10-15 Thread Mark Chu-Carroll

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

(Updated Oct. 15, 2014, 12:46 p.m.)


Review request for Aurora, Joshua Cohen and Zameer Manji.


Bugs: aurora-831
https://issues.apache.org/jira/browse/aurora-831


Repository: aurora


Description (updated)
---

- Put plugin-generated options into the correct order.
- Include the option-name in the detailed help list.
- Add missing metavars.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
  src/main/python/apache/aurora/client/cli/options.py 
dc76c25b90acb9610e40b939e65c3cabf032649f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
  src/test/python/apache/aurora/client/cli/test_help.py 
f73c8a3778b7d118ea2865f213b442a607fb4a7d 

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


Testing (updated)
---

New help output:
{noformat}
[sun-wukong incubator-aurora (deprecate)]$ ./dist/aurora2.pex help cron 
deschedule
Usage for verb "cron deschedule":
  deschedule   [--verbose-logging]   [--logging-level=numeric_level]   
[--error-log-dir=error-log-dir] [--bind=var=value] CLUSTER/ROLE/ENV/NAME
Options:
  --bind=var=value
Bind a pystachio variable name to a value. Multiple flags may be used 
to specify multiple values.
  CLUSTER/ROLE/ENV/NAME
Fully specified job key, in CLUSTER/ROLE/ENV/NAME format
  --verbose-logging
Show verbose logging, including all logs up to level INFO (equivalent 
to --logging-level=20)
  --logging-level=numeric_level
Set logging to a specific numeric level.
  --error-log-dir=error-log-dir
Directory location where error files containing stack traces should be 
written. If the directory doesn't exist, it will be created

Remove the cron schedule for a job.
{noformat}


Thanks,

Mark Chu-Carroll



Re: Review Request 26688: Fix errors in help rendering:

2014-10-15 Thread Mark Chu-Carroll

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

(Updated Oct. 15, 2014, 12:41 p.m.)


Review request for Aurora, Joshua Cohen and Zameer Manji.


Bugs: aurora-831
https://issues.apache.org/jira/browse/aurora-831


Repository: aurora


Description
---

- Put plugin-generated options into the correct order.
- Include the option-name in the detailed help list.
- Add missing metavars.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
  src/main/python/apache/aurora/client/cli/options.py 
dc76c25b90acb9610e40b939e65c3cabf032649f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
  src/test/python/apache/aurora/client/cli/test_help.py 
f73c8a3778b7d118ea2865f213b442a607fb4a7d 

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


Testing
---


Thanks,

Mark Chu-Carroll



Review Request 26753: Start removing clientv1.

2014-10-15 Thread Mark Chu-Carroll

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

Review request for Aurora, Bill Farner and Zameer Manji.


Bugs: aurora-131
https://issues.apache.org/jira/browse/aurora-131


Repository: aurora


Description
---

- Make the "aurora2" main target be the standalone clientv2;
- Don't build the bridged client by default; but allow forced build using 
"aurora2_bridge".
- Modify cli tests so that they only depend on the standalone clientv2.
- Modify vagrant config to make clientv2 the primary client.
- Modify end-to-end tests to match the vagrant changes.

(Note: end-to-end tests are failing, but in the same way as they fail without 
this change. I'm working on debugging that, but it should be its own 
change/review, and I don't want to delay reviewing this.)


Diffs
-

  docs/developing-aurora-client.md e1b2ccd7504f983169118a288721894184d67c97 
  examples/vagrant/aurorabuild.sh a27636655d722ca79f66b377fd847954d52e8feb 
  examples/vagrant/provision-dev-cluster.sh 
740bc212ba604b2c64af92eba1be41e8ed3fdbde 
  src/main/python/apache/aurora/client/cli/BUILD 
995570325bbb09ecbcc2ace5d223760c5d49367f 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
a2b28ba23961284ba60358af54726e0386dd69b6 
  src/test/python/apache/aurora/client/cli/test_cancel_update.py 
e7052465411165acb3d5145664f2f166ac052500 
  src/test/python/apache/aurora/client/cli/test_command_hooks.py 
9fc6fe2c2063cda494437d83044557b345acacea 
  src/test/python/apache/aurora/client/cli/test_config_noun.py 
dfcbd7217b1d51609fa01c4d9cefed5471c91718 
  src/test/python/apache/aurora/client/cli/test_create.py 
427f7ce4476b48d407b8bd2bf2c54c52e6e63079 
  src/test/python/apache/aurora/client/cli/test_cron.py 
c7b71c29d44150162fec8066947623fa91815424 
  src/test/python/apache/aurora/client/cli/test_diff.py 
10817695352687cdb5b0c3ed9720e3091b230e68 
  src/test/python/apache/aurora/client/cli/test_help.py 
f73c8a3778b7d118ea2865f213b442a607fb4a7d 
  src/test/python/apache/aurora/client/cli/test_inspect.py 
e997b9743b63d71f8624ecf5ca1dcae0227be70d 
  src/test/python/apache/aurora/client/cli/test_kill.py 
bac4485fa105848d96e2505c4a2ea2eee45dc968 
  src/test/python/apache/aurora/client/cli/test_logging.py 
9ca4dceeaa87d5fb2e38fe0d83fdcdf1ee597a0e 
  src/test/python/apache/aurora/client/cli/test_open.py 
c20649f5cada241d0f6e9ae5f88d300eac073517 
  src/test/python/apache/aurora/client/cli/test_plugins.py 
dc5edd4f03cee062673231a04908193480c8071c 
  src/test/python/apache/aurora/client/cli/test_quota.py 
88fb9aec4d1eae6ad05da01752a670f902bafb1b 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a5f94484b30ecb8417116db9ce12c015957357c5 
  src/test/python/apache/aurora/client/cli/test_sla.py 
a1a3d8161ba747aa23a5e614e9ae31473d2058c1 
  src/test/python/apache/aurora/client/cli/test_status.py 
c704daec5a6eee73c7092a201b168881853908e8 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
6775c389cb1a0b80dd17fe179e8b98d4e9db0332 
  src/test/python/apache/aurora/client/cli/test_task_run.py 
16fde14c03f6fd2c000e76625fad174835763f1b 
  src/test/python/apache/aurora/client/cli/test_update.py 
cff1b6578aec6f5bcc1e610e58b47af233f32b41 
  src/test/sh/org/apache/aurora/e2e/test_common.sh 
43d2516133c6d6cdb4236358f942396f057f739c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh 
324aa4dbeff00e673fe73b87e3a0766856cd213c 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
8f4d2b01c9fa5a6ec9e8885a2d4fa0e9c3abb8a1 

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


Testing
---

- Ran all unit tests, confirmed they continue to pass.
- Ran end-to-end tests (both v1 and v2 variants) with the updated setup, and 
verified that they fail in exactly the same way as before this change.


Thanks,

Mark Chu-Carroll



Re: Review Request 26688: Fix errors in help rendering:

2014-10-14 Thread Mark Chu-Carroll


> On Oct. 14, 2014, 1 p.m., Mark Chu-Carroll wrote:
> > src/test/python/apache/aurora/client/cli/test_help.py, line 75
> > <https://reviews.apache.org/r/26688/diff/1/?file=720844#file720844line75>
> >
> > Yes, they are guaranteed to be unique. The argparse framework that this 
> > is built on checks uniqueness, and raises an exception if there's any 
> > ambiguity.
> 
> Joshua Cohen wrote:
> What about the second question (could an option name appearing elsewhere 
> in the help output cause this test to improperly pass)?

I don't think so - that would require *every* command to have option names that 
were superstrings of every option in the plugins.


- Mark


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


On Oct. 14, 2014, 11:07 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26688/
> ---
> 
> (Updated Oct. 14, 2014, 11:07 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Joshua Cohen.
> 
> 
> Bugs: aurora-831
> https://issues.apache.org/jira/browse/aurora-831
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Put plugin-generated options into the correct order.
> - Include the option-name in the detailed help list.
> - Add missing metavars.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
>   src/main/python/apache/aurora/client/cli/options.py 
> dc76c25b90acb9610e40b939e65c3cabf032649f 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> f73c8a3778b7d118ea2865f213b442a607fb4a7d 
> 
> Diff: https://reviews.apache.org/r/26688/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26688: Fix errors in help rendering:

2014-10-14 Thread Mark Chu-Carroll

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



src/test/python/apache/aurora/client/cli/test_help.py
<https://reviews.apache.org/r/26688/#comment96900>

Yes, they are guaranteed to be unique. The argparse framework that this is 
built on checks uniqueness, and raises an exception if there's any ambiguity.



src/test/python/apache/aurora/client/cli/test_help.py
<https://reviews.apache.org/r/26688/#comment96902>

Anything can have an unset metavar, but most of the time, that isn't a 
problem. The default metavar for an int is "int" - but in help strings, that 
works well.

For example, you'll often see [--port=int]. That's good, and I don't think 
we want that to be an error. Saying that the value is expected to be "int" is 
telling you something essential about the value expected for the parameter.

str is different, because it's the default type value for any structured 
input - pathnames, config names, tunnel descriptors, instance lists, usernames, 
etc. Saying "str" doesn't tell you anything meaningful about what's expected.


- Mark Chu-Carroll


On Oct. 14, 2014, 11:07 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26688/
> ---
> 
> (Updated Oct. 14, 2014, 11:07 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Joshua Cohen.
> 
> 
> Bugs: aurora-831
> https://issues.apache.org/jira/browse/aurora-831
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Put plugin-generated options into the correct order.
> - Include the option-name in the detailed help list.
> - Add missing metavars.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
>   src/main/python/apache/aurora/client/cli/options.py 
> dc76c25b90acb9610e40b939e65c3cabf032649f 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> f73c8a3778b7d118ea2865f213b442a607fb4a7d 
> 
> Diff: https://reviews.apache.org/r/26688/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26688: Fix errors in help rendering:

2014-10-14 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Joshua Cohen.


Bugs: aurora-831
https://issues.apache.org/jira/browse/aurora-831


Repository: aurora


Description
---

- Put plugin-generated options into the correct order.
- Include the option-name in the detailed help list.
- Add missing metavars.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
da9d5b6ba4d22ba1f444341b97bbcfaf7889a4a8 
  src/main/python/apache/aurora/client/cli/options.py 
dc76c25b90acb9610e40b939e65c3cabf032649f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
20f4d7ef43ba336a2b6d02cbf5656c97bdfa2ea1 
  src/test/python/apache/aurora/client/cli/test_help.py 
f73c8a3778b7d118ea2865f213b442a607fb4a7d 

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


Testing
---


Thanks,

Mark Chu-Carroll



Re: Review Request 26363: Make the large-update check in the client update command consider instance parameters.

2014-10-08 Thread Mark Chu-Carroll

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

(Updated Oct. 8, 2014, 7:56 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

rebase


Bugs: aurora-792
https://issues.apache.org/jira/browse/aurora-792


Repository: aurora


Description
---

Make the large-update check in the client update command consider instance 
parameters.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/context.py 
4e94a4e3017f3b2ace38d6d8ce68c3c778c8cd0e 
  src/main/python/apache/aurora/client/cli/jobs.py 
0277cbed4b7eb927d6e5823b4b41d90b366f81d0 
  src/test/python/apache/aurora/client/cli/BUILD 
d33e86643a59879c115876c98bd1dc19aa7ae61c 
  src/test/python/apache/aurora/client/cli/test_update.py 
cff1b6578aec6f5bcc1e610e58b47af233f32b41 

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


Testing
---

New unit tests added, all test pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26363: Make the large-update check in the client update command consider instance parameters.

2014-10-08 Thread Mark Chu-Carroll

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

(Updated Oct. 8, 2014, 1:40 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Remove debug prints.


Bugs: aurora-792
https://issues.apache.org/jira/browse/aurora-792


Repository: aurora


Description
---

Make the large-update check in the client update command consider instance 
parameters.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/context.py 
301531fcb443297facb78d87a18073c8b7fd4064 
  src/main/python/apache/aurora/client/cli/jobs.py 
103fb53cb5101d3e025d8712e3887bccdfbb6aeb 
  src/test/python/apache/aurora/client/cli/BUILD 
8ce6bd5b7faa1579372fb6935180ea982af64af8 
  src/test/python/apache/aurora/client/cli/test_update.py 
85b1db19d89967a741bfba7964eeb368426f0b61 

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


Testing
---

New unit tests added, all test pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26363: Make the large-update check in the client update command consider instance parameters.

2014-10-08 Thread Mark Chu-Carroll


> On Oct. 6, 2014, 12:44 p.m., Joshua Cohen wrote:
> > src/test/python/apache/aurora/client/cli/test_update.py, lines 342-353
> > <https://reviews.apache.org/r/26363/diff/1/?file=714123#file714123line342>
> >
> > This sequence of mocks and writing config to a file is repeated in... 
> > many (all?) of these tests. Can you refactor to remove the repetition?

I really think that that should not be done.

For tests, I really like to be able to see, in an instant, exactly what mocks 
are being used by a particular test.  I don't want to have to look somewhere 
else; I don't want to have to mentally combine the stuff that's mocked in a 
common frame and the different stuff that's mocked and/or reconfigured in a 
particular test. The test should be as clear as it can be, and anything from 
the environment that it's mucking with should be done explicitly in the most 
local-possible context.


- Mark


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


On Oct. 6, 2014, 10:57 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26363/
> ---
> 
> (Updated Oct. 6, 2014, 10:57 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-792
> https://issues.apache.org/jira/browse/aurora-792
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Make the large-update check in the client update command consider instance 
> parameters.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 301531fcb443297facb78d87a18073c8b7fd4064 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 103fb53cb5101d3e025d8712e3887bccdfbb6aeb 
>   src/test/python/apache/aurora/client/cli/BUILD 
> 8ce6bd5b7faa1579372fb6935180ea982af64af8 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> 85b1db19d89967a741bfba7964eeb368426f0b61 
> 
> Diff: https://reviews.apache.org/r/26363/diff/
> 
> 
> Testing
> ---
> 
> New unit tests added, all test pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26448: Move the error-log seed file to a user specified directory.

2014-10-08 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description
---

Instead of dumping error traces into the users current directory,
dump them into a user specified directory, with a benign default.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
5c0688f5ea184e2c0b1f8e1b54a109d8260a12fa 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
4fdcf6df493f63aae672e0834214dad208cf4110 
  src/test/python/apache/aurora/client/cli/test_create.py 
8dc0ccb78539f8b0c7829ec2927da93d4afa9ada 
  src/test/python/apache/aurora/client/cli/test_inspect.py 
fd35fe0185c1850910bd18d6a1e5831cd3effa6f 
  src/test/python/apache/aurora/client/cli/test_plugins.py 
7a0a31818cbc57de952d7817f8e7c8fa1e84b25a 
  src/test/python/apache/aurora/client/cli/util.py 
ff7eda20dbba073c8b24fbe3f4389292aab2d128 

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


Testing
---

Added new unit test; verified all tests pass.


Thanks,

Mark Chu-Carroll



Review Request 26445: Fix error in incorrect deprecation warning on v1 "ssh" command.

2014-10-08 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-804
https://issues.apache.org/jira/browse/aurora-804


Repository: aurora


Description
---

The error message incorrectly displayed a list-value for the
"--tunnels" parameter, when in fact it should expand the list
into multiple instances of "--tunnels".


Diffs
-

  src/main/python/apache/aurora/client/commands/ssh.py 
9ee94a0bdfd8bbc030ae978e2ac3fe39571b4ce2 
  src/test/python/apache/aurora/client/commands/test_ssh.py 
c5ca66e378bfc97c40a406a758ae4dfaef8ab2c8 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26328: Improve handling of unknown errors in the aurora client.

2014-10-08 Thread Mark Chu-Carroll

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

(Updated Oct. 8, 2014, 10:42 a.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Rebase.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description
---

Improve handling of unknown errors in the aurora client.

Instead of dumping the stack on the user's terminal, or
absorbing the error and generating a brief error
message, the client now writes detailed information about
the error is written into an error log file, and the
user is given a clean error message referring them to that
file for details.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/__init__.py 
e0c3050151bca1128ed7e476ec5133407a20f6c2 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
7c0975ce9d415b19b6704b9a772ee2619ac9a2af 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
78f21d2f20cf71fa2dfe0614885d44d2948decd2 
  src/test/python/apache/aurora/client/cli/test_create.py 
6e55188bdfc576506848605debb391288e696fe3 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26328: Improve handling of unknown errors in the aurora client.

2014-10-08 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/cli/__init__.py
<https://reviews.apache.org/r/26328/#comment96178>

It writes into the current directory where the user is executing the client.


- Mark Chu-Carroll


On Oct. 6, 2014, 2:55 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26328/
> ---
> 
> (Updated Oct. 6, 2014, 2:55 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-779
> https://issues.apache.org/jira/browse/aurora-779
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Improve handling of unknown errors in the aurora client.
> 
> Instead of dumping the stack on the user's terminal, or
> absorbing the error and generating a brief error
> message, the client now writes detailed information about
> the error is written into an error log file, and the
> user is given a clean error message referring them to that
> file for details.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> e0c3050151bca1128ed7e476ec5133407a20f6c2 
>   src/main/python/apache/aurora/client/cli/context.py 
> 301531fcb443297facb78d87a18073c8b7fd4064 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 7c0975ce9d415b19b6704b9a772ee2619ac9a2af 
>   src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
> 78f21d2f20cf71fa2dfe0614885d44d2948decd2 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 6e55188bdfc576506848605debb391288e696fe3 
>   src/test/python/apache/aurora/client/cli/util.py 
> e1ee884c06f3bc22bcd9e908ff61af9459a0b535 
> 
> Diff: https://reviews.apache.org/r/26328/diff/
> 
> 
> Testing
> ---
> 
> New unit test.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26308: Fix exit condition for RPC loop, fix test_status_api_failure test.

2014-10-07 Thread Mark Chu-Carroll

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


Looks good.

One note on the change description: I'm willing to bet that there is a way to 
get that branch active in a test. Every single time that I've ever said that 
something couldn't be tested, or that some branch couldn't be exercised in a 
test, I've always been wrong. There's a way.

- Mark Chu-Carroll


On Oct. 4, 2014, 1:55 p.m., Bill Farner wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26308/
> ---
> 
> (Updated Oct. 4, 2014, 1:55 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Mark Chu-Carroll.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fixes two problems:
> 
> - mocking was incorrect in `test_status_api_failure`.  Turns out that Mock 
> objects were being passed around and somehow resulted in the test case 
> passing.
> - use of `threading.Event()` was broken in scheduler_client.py.  I don't 
> think it's possible to enter those branches.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 26300792594e4005dacc139a9f89711b8a66ab61 
>   src/main/python/apache/aurora/client/api/command_runner.py 
> a1fed5fc75dde3a79c840515e6daa4741156ef97 
>   src/main/python/apache/aurora/client/api/job_monitor.py 
> 18d5c0381d43fc7b24bae4b2e5e6fdc774a74b52 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> 311c954f1db245b75192d00c6aca0721085fbf32 
>   src/main/python/apache/aurora/client/api/updater.py 
> bf608981c2f2e7960b68c3fbda144277a59a3d40 
>   src/main/python/apache/aurora/common/aurora_job_key.py 
> a7ca7b6df6b9566b3ce617283ccac948deb2eb83 
>   src/test/python/apache/aurora/client/api/test_job_monitor.py 
> 5b26539f86a0a82f72753a803a769eda77cbc332 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 1835843f1795b0530874ec561582df17acfbce65 
>   src/test/python/apache/aurora/client/api/test_updater.py 
> 6905831b23a84320e7f41843efd62b86da366c0b 
>   src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
> 78f21d2f20cf71fa2dfe0614885d44d2948decd2 
>   src/test/python/apache/aurora/client/cli/test_cancel_update.py 
> c15e142930c9474c7873dd931261b6ab4eb5967f 
>   src/test/python/apache/aurora/client/cli/test_command_hooks.py 
> 3acd2ba0d8bd8c71d4c0a9d71a035fc974fa20c3 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 6e55188bdfc576506848605debb391288e696fe3 
>   src/test/python/apache/aurora/client/cli/test_diff.py 
> e1a6f764830e06c73d0bc10a3b5da67219da836c 
>   src/test/python/apache/aurora/client/cli/test_kill.py 
> e3a366bf67074e50787394cad58d5e01359b641e 
>   src/test/python/apache/aurora/client/cli/test_logging.py 
> 6285fbb07442291c2dc4096e68eb285c98994097 
>   src/test/python/apache/aurora/client/cli/test_plugins.py 
> 7a0a31818cbc57de952d7817f8e7c8fa1e84b25a 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> bd30b11022ee0d1fb38da9f6efd4d9c5923b7d13 
>   src/test/python/apache/aurora/client/cli/test_task_run.py 
> 1ce9a632874e818eee71573cd481842affae3615 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> 85b1db19d89967a741bfba7964eeb368426f0b61 
>   src/test/python/apache/aurora/client/commands/test_admin.py 
> 1192556c027dc3adf16bb37adeac7798cf9ef93d 
>   src/test/python/apache/aurora/client/commands/test_cancel_update.py 
> 5f05ef7c0643d189de3de38c75aae58c2a3814a4 
>   src/test/python/apache/aurora/client/commands/test_create.py 
> 7503345ea1c0f224a894ce02cc2c2d8719574e32 
>   src/test/python/apache/aurora/client/commands/test_diff.py 
> 8f5da7d2bca9b0486b635afe49d3885151624e12 
>   src/test/python/apache/aurora/client/commands/test_hooks.py 
> 0861f13b13a8406950ba953efba0ffae186a8253 
>   src/test/python/apache/aurora/client/commands/test_kill.py 
> c0a6fd44c5691cde50746ffdec325bb11a33469a 
>   src/test/python/apache/aurora/client/commands/test_run.py 
> e97b5156609f80a4170028e780bcd891e56983ff 
>   src/test/python/apache/aurora/client/commands/test_ssh.py 
> c5ca66e378bfc97c40a406a758ae4dfaef8ab2c8 
>   src/test/python/apache/aurora/client/commands/test_status.py 
> bda1f28d544ae48428129f8167d8632ef27f5fba 
>   src/test/python/apache/aurora/client/commands/test_update.py 
> af2cbc7f88287201a472ba36902b00d90bc77d3b 
> 
> Diff: https://reviews.apache.org/r/26308/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python:all -vxs
> 
> 
> Thanks,
> 
> Bill Farner
> 
>



Re: Review Request 26308: Fix exit condition for RPC loop, fix test_status_api_failure test.

2014-10-07 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Oct. 4, 2014, 1:55 p.m., Bill Farner wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26308/
> ---
> 
> (Updated Oct. 4, 2014, 1:55 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney and Mark Chu-Carroll.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fixes two problems:
> 
> - mocking was incorrect in `test_status_api_failure`.  Turns out that Mock 
> objects were being passed around and somehow resulted in the test case 
> passing.
> - use of `threading.Event()` was broken in scheduler_client.py.  I don't 
> think it's possible to enter those branches.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 26300792594e4005dacc139a9f89711b8a66ab61 
>   src/main/python/apache/aurora/client/api/command_runner.py 
> a1fed5fc75dde3a79c840515e6daa4741156ef97 
>   src/main/python/apache/aurora/client/api/job_monitor.py 
> 18d5c0381d43fc7b24bae4b2e5e6fdc774a74b52 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> 311c954f1db245b75192d00c6aca0721085fbf32 
>   src/main/python/apache/aurora/client/api/updater.py 
> bf608981c2f2e7960b68c3fbda144277a59a3d40 
>   src/main/python/apache/aurora/common/aurora_job_key.py 
> a7ca7b6df6b9566b3ce617283ccac948deb2eb83 
>   src/test/python/apache/aurora/client/api/test_job_monitor.py 
> 5b26539f86a0a82f72753a803a769eda77cbc332 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 1835843f1795b0530874ec561582df17acfbce65 
>   src/test/python/apache/aurora/client/api/test_updater.py 
> 6905831b23a84320e7f41843efd62b86da366c0b 
>   src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
> 78f21d2f20cf71fa2dfe0614885d44d2948decd2 
>   src/test/python/apache/aurora/client/cli/test_cancel_update.py 
> c15e142930c9474c7873dd931261b6ab4eb5967f 
>   src/test/python/apache/aurora/client/cli/test_command_hooks.py 
> 3acd2ba0d8bd8c71d4c0a9d71a035fc974fa20c3 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 6e55188bdfc576506848605debb391288e696fe3 
>   src/test/python/apache/aurora/client/cli/test_diff.py 
> e1a6f764830e06c73d0bc10a3b5da67219da836c 
>   src/test/python/apache/aurora/client/cli/test_kill.py 
> e3a366bf67074e50787394cad58d5e01359b641e 
>   src/test/python/apache/aurora/client/cli/test_logging.py 
> 6285fbb07442291c2dc4096e68eb285c98994097 
>   src/test/python/apache/aurora/client/cli/test_plugins.py 
> 7a0a31818cbc57de952d7817f8e7c8fa1e84b25a 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> bd30b11022ee0d1fb38da9f6efd4d9c5923b7d13 
>   src/test/python/apache/aurora/client/cli/test_task_run.py 
> 1ce9a632874e818eee71573cd481842affae3615 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> 85b1db19d89967a741bfba7964eeb368426f0b61 
>   src/test/python/apache/aurora/client/commands/test_admin.py 
> 1192556c027dc3adf16bb37adeac7798cf9ef93d 
>   src/test/python/apache/aurora/client/commands/test_cancel_update.py 
> 5f05ef7c0643d189de3de38c75aae58c2a3814a4 
>   src/test/python/apache/aurora/client/commands/test_create.py 
> 7503345ea1c0f224a894ce02cc2c2d8719574e32 
>   src/test/python/apache/aurora/client/commands/test_diff.py 
> 8f5da7d2bca9b0486b635afe49d3885151624e12 
>   src/test/python/apache/aurora/client/commands/test_hooks.py 
> 0861f13b13a8406950ba953efba0ffae186a8253 
>   src/test/python/apache/aurora/client/commands/test_kill.py 
> c0a6fd44c5691cde50746ffdec325bb11a33469a 
>   src/test/python/apache/aurora/client/commands/test_run.py 
> e97b5156609f80a4170028e780bcd891e56983ff 
>   src/test/python/apache/aurora/client/commands/test_ssh.py 
> c5ca66e378bfc97c40a406a758ae4dfaef8ab2c8 
>   src/test/python/apache/aurora/client/commands/test_status.py 
> bda1f28d544ae48428129f8167d8632ef27f5fba 
>   src/test/python/apache/aurora/client/commands/test_update.py 
> af2cbc7f88287201a472ba36902b00d90bc77d3b 
> 
> Diff: https://reviews.apache.org/r/26308/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python:all -vxs
> 
> 
> Thanks,
> 
> Bill Farner
> 
>



Review Request 26417: Change JSON result of "job status" when job isn't found.

2014-10-07 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-803
https://issues.apache.org/jira/browse/aurora-803


Repository: aurora


Description
---

Instead of just exiting with an error code, return a valid JSON
structure when a user calls "aurora job status", and no job matching
the jobspec is running.

Also, remove a bunch of "pants" labels from build files, which generated
warnings while building the tests.


Diffs
-

  src/main/python/apache/aurora/client/cli/context.py 
0816ac02846c30e0beab5c0339aca38f15c4ae10 
  src/main/python/apache/aurora/client/cli/jobs.py 
103fb53cb5101d3e025d8712e3887bccdfbb6aeb 
  src/test/python/apache/aurora/client/cli/BUILD 
8ce6bd5b7faa1579372fb6935180ea982af64af8 
  src/test/python/apache/aurora/client/cli/test_status.py 
bd30b11022ee0d1fb38da9f6efd4d9c5923b7d13 

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


Testing
---

Ran all unit tests; added new test for the empty job list json case.


Thanks,

Mark Chu-Carroll



Re: Review Request 26288: Fixing log_response in context.py

2014-10-07 Thread Mark Chu-Carroll

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

Ship it!


Looks good, thanks for changing the approach.

Can you update the review title, just so that when we look at reviews, we know 
what this one actually changed?

- Mark Chu-Carroll


On Oct. 6, 2014, 7:40 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26288/
> ---
> 
> (Updated Oct. 6, 2014, 7:40 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-786
> https://issues.apache.org/jira/browse/AURORA-786
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fixing log_response in context.py
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/updater.py 
> bf608981c2f2e7960b68c3fbda144277a59a3d40 
>   src/test/python/apache/aurora/client/api/test_updater.py 
> 6905831b23a84320e7f41843efd62b86da366c0b 
> 
> Diff: https://reviews.apache.org/r/26288/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/tests/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 26388: Build break fix.

2014-10-06 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Oct. 6, 2014, 6:01 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26388/
> ---
> 
> (Updated Oct. 6, 2014, 6:01 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> The https://reviews.apache.org/r/26004/ broke tests added in 
> https://reviews.apache.org/r/26372.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/update.py 
> 9debc91cd244c015ae2d925829d05d7de67bc3b5 
> 
> Diff: https://reviews.apache.org/r/26388/diff/
> 
> 
> Testing
> ---
> 
> $ ./pants src/test/python/apache/aurora/client/cli:help
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/mkhutornenko/workspace3/aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  help)])
>  
> test session starts 
> 
> platform darwin -- Python 2.6.7 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 6 items 
> 
> src/test/python/apache/aurora/client/cli/test_help.py ..
> 
> = 6 
> passed in 0.67 seconds 
> ==
> src.test.python.apache.aurora.client.cli.help 
>   .   SUCCESS
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-10-06 Thread Mark Chu-Carroll

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

(Updated Oct. 6, 2014, 3:30 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Add ids to the status command.


Bugs: aurora-742
https://issues.apache.org/jira/browse/aurora-742


Repository: aurora


Description
---

Add support for commands to query and display active updates being
managed by the scheduler. Two commands are added:

* "aurora update list", which shows all active updates that are being processed 
by the server.
* "aurora update status", which shows detailed status information about an 
update in-progress on the server.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/context.py 
301531fcb443297facb78d87a18073c8b7fd4064 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-10-06 Thread Mark Chu-Carroll


> On Sept. 24, 2014, 6:28 p.m., David McLaughlin wrote:
> > What was the rationale for hiding update IDs from the user and making job 
> > key the parameter for update status? It's nice you can quickly see if a job 
> > key has an update in progress.. but what happens if you're wanting to see a 
> > recent deploy that is already finished or see further back?  
> > 
> > I think update list should return the update ids and update status should 
> > accept an update id. Well maybe not update status.. but update show or 
> > something? Something which is consistent with the job verbs would be great.
> 
> Mark Chu-Carroll wrote:
> I was following the pattern that I saw in the API implementation. In 
> early iterations, it exposed updated ids; in later ones, the IDs were removed 
> from the user-level API. We don't use those identifiers for pausing or 
> resuming an active update; why would we use them for checking on the status 
> of an update? That would become a very awkward interface for users: start an 
> update? use the jobkey. Pause an update? User the jobkey. Abort an update? 
> Use the jobkey. Check the status of an update? Use some other identifier that 
> you don't know without running another command.
> 
> I can certainly add the updateID to the list command, and add a command 
> (or alternative parameter) for checking on a job by update-ID, but I don't 
> think that making it the normal parameter to status is a good design for the 
> command-line.
> 
> Mark Chu-Carroll wrote:
> ping?
> 
> David McLaughlin wrote:
> Can we add updateID to the list command? Then this looks ready to ship.

ping?


- Mark


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


On Oct. 6, 2014, 9:16 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26004/
> ---
> 
> (Updated Oct. 6, 2014, 9:16 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-742
> https://issues.apache.org/jira/browse/aurora-742
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Add support for commands to query and display active updates being
> managed by the scheduler. Two commands are added:
> 
> * "aurora update list", which shows all active updates that are being 
> processed by the server.
> * "aurora update status", which shows detailed status information about an 
> update in-progress on the server.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> f639af7de93a069b278dc494b6f92a2f6b10de9c 
>   src/main/python/apache/aurora/client/cli/options.py 
> 9a81a1d7d04c6648e94ff117429278317a9dbed8 
>   src/main/python/apache/aurora/client/cli/update.py 
> b4dd792dc12f19424c620f4d91748113e272f0c9 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 2782fee2867c6ef79349240299de082f07f7967a 
>   src/test/python/apache/aurora/client/cli/util.py 
> e1ee884c06f3bc22bcd9e908ff61af9459a0b535 
> 
> Diff: https://reviews.apache.org/r/26004/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests; all tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26328: Improve handling of unknown errors in the aurora client.

2014-10-06 Thread Mark Chu-Carroll

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

(Updated Oct. 6, 2014, 2:55 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Rebase the changes against the correct branch.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description
---

Improve handling of unknown errors in the aurora client.

Instead of dumping the stack on the user's terminal, or
absorbing the error and generating a brief error
message, the client now writes detailed information about
the error is written into an error log file, and the
user is given a clean error message referring them to that
file for details.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/__init__.py 
e0c3050151bca1128ed7e476ec5133407a20f6c2 
  src/main/python/apache/aurora/client/cli/context.py 
301531fcb443297facb78d87a18073c8b7fd4064 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
7c0975ce9d415b19b6704b9a772ee2619ac9a2af 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
78f21d2f20cf71fa2dfe0614885d44d2948decd2 
  src/test/python/apache/aurora/client/cli/test_create.py 
6e55188bdfc576506848605debb391288e696fe3 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26328: Improve handling of unknown errors in the aurora client.

2014-10-06 Thread Mark Chu-Carroll

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

(Updated Oct. 6, 2014, 2:54 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Apologies - I've got 5 different changes open in RB, and I accidentally based 
this diff against the wrong one. I'll have the correct diff uploaded in a 
couple of minutes.


Summary (updated)
-

Improve handling of unknown errors in the aurora client.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description
---

Improve handling of unknown errors in the aurora client.

Instead of dumping the stack on the user's terminal, or
absorbing the error and generating a brief error
message, the client now writes detailed information about
the error is written into an error log file, and the
user is given a clean error message referring them to that
file for details.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
e0c3050151bca1128ed7e476ec5133407a20f6c2 
  src/main/python/apache/aurora/client/cli/context.py 
f639af7de93a069b278dc494b6f92a2f6b10de9c 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
fd2232bc8b7e5caf487291f657a50184391a8c69 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
78f21d2f20cf71fa2dfe0614885d44d2948decd2 
  src/test/python/apache/aurora/client/cli/test_create.py 
6e55188bdfc576506848605debb391288e696fe3 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26288: Fixing log_response in context.py

2014-10-06 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/cli/context.py
<https://reviews.apache.org/r/26288/#comment95906>

If the client-side API is using a deprecated field of this structure, then 
that should be fixed. We shouldn't be patching this to prevent the need to 
remove deprecations from the client-side API.


- Mark Chu-Carroll


On Oct. 2, 2014, 6:28 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26288/
> ---
> 
> (Updated Oct. 2, 2014, 6:28 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-786
> https://issues.apache.org/jira/browse/AURORA-786
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fixing log_response in context.py
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> f639af7de93a069b278dc494b6f92a2f6b10de9c 
>   src/test/python/apache/aurora/client/cli/BUILD 
> 8ce6bd5b7faa1579372fb6935180ea982af64af8 
>   src/test/python/apache/aurora/client/cli/test_context.py PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/26288/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/tests/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 26372: Test all the nouns and verbs within the Aurora Command Line for help output

2014-10-06 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Oct. 6, 2014, 12:58 p.m., Joe Smith wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26372/
> ---
> 
> (Updated Oct. 6, 2014, 12:58 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin, Mark Chu-Carroll, and Zameer 
> Manji.
> 
> 
> Bugs: AURORA-748
> https://issues.apache.org/jira/browse/AURORA-748
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This steps through each noun within the commandline, and each verb attached 
> to those nouns to validate help output appears as expected.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/update.py 
> b4dd792dc12f19424c620f4d91748113e272f0c9 
>   src/test/python/apache/aurora/client/cli/test_help.py 
> e1602b145a6b100efca8663104a7d44cc119c5a5 
> 
> Diff: https://reviews.apache.org/r/26372/diff/
> 
> 
> Testing
> ---
> 
> [tw-172-25-132-201 aurora (yasumoto/test_update_help)]$ ./pants 
> ./src/test/python/apache/aurora/client/cli:help
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/jsmith/workspace/aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  help)])
> 
>  test session starts 
> =
> platform darwin -- Python 2.6.8 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 6 items 
> 
> src/test/python/apache/aurora/client/cli/test_help.py ..
> 
> ==
>  6 passed in 0.71 seconds 
> ==
> src.test.python.apache.aurora.client.cli.help 
>   .   SUCCESS
> 
> 
> And confirmed via:
> 
> 
> [tw-172-25-132-201 aurora (yasumoto/test_update_help)]$ git diff
> diff --git a/src/main/python/apache/aurora/client/cli/update.py 
> b/src/main/python/apache/aurora/client/cli/update.py
> index 41475a7..142ba5e 100644
> --- a/src/main/python/apache/aurora/client/cli/update.py
> +++ b/src/main/python/apache/aurora/client/cli/update.py
> @@ -42,7 +42,7 @@ class StartUpdate(Verb):
>INSTANCES_SPEC_ARGUMENT, CONFIG_ARGUMENT
>  ]
>  
> -  @property
> +  #@property
>def help(self):
>  return textwrap.dedent("""\
>  Start a scheduler-driven rolling upgrade on a running job, using the 
> update
> [tw-172-25-132-201 aurora (yasumoto/test_update_help)]$ ./pants 
> ./src/test/python/apache/aurora/client/cli:help
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/jsmith/workspace/aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  help)])
> 
>  test session starts 
> =
> platform darwin -- Python 2.6.8 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 6 items 
> 
> src/test/python/apache/aurora/client/cli/test_help.py F.
> 
> ==
>  FAILURES 
> ==
> ___
>  TestHelp.test_all_help 
> ___
> 
> self = 
> 
> def test_all_help(self):
>   for noun in self.cmd.registered_nouns:
> 

Re: Review Request 26288: Fixing log_response in context.py

2014-10-06 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/cli/context.py
<https://reviews.apache.org/r/26288/#comment95901>

When I wrote code that did that check, Bill specifically told me to remove 
it, because anything in the deprecated field would *always* also be in the 
details list. 

So unless we're moving backwards, this is the wrong approach. If there's a 
place where the scheduler is sending things via the deprecated field but not 
via the details list, then that should be changed.


- Mark Chu-Carroll


On Oct. 2, 2014, 6:28 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26288/
> ---
> 
> (Updated Oct. 2, 2014, 6:28 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-786
> https://issues.apache.org/jira/browse/AURORA-786
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fixing log_response in context.py
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> f639af7de93a069b278dc494b6f92a2f6b10de9c 
>   src/test/python/apache/aurora/client/cli/BUILD 
> 8ce6bd5b7faa1579372fb6935180ea982af64af8 
>   src/test/python/apache/aurora/client/cli/test_context.py PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/26288/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/tests/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Review Request 26363: Make the large-update check in the client update command consider instance parameters.

2014-10-06 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-792
https://issues.apache.org/jira/browse/aurora-792


Repository: aurora


Description
---

Make the large-update check in the client update command consider instance 
parameters.


Diffs
-

  src/main/python/apache/aurora/client/cli/context.py 
301531fcb443297facb78d87a18073c8b7fd4064 
  src/main/python/apache/aurora/client/cli/jobs.py 
103fb53cb5101d3e025d8712e3887bccdfbb6aeb 
  src/test/python/apache/aurora/client/cli/BUILD 
8ce6bd5b7faa1579372fb6935180ea982af64af8 
  src/test/python/apache/aurora/client/cli/test_update.py 
85b1db19d89967a741bfba7964eeb368426f0b61 

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


Testing
---

New unit tests added, all test pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-10-06 Thread Mark Chu-Carroll

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

(Updated Oct. 6, 2014, 9:16 a.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-742
https://issues.apache.org/jira/browse/aurora-742


Repository: aurora


Description
---

Add support for commands to query and display active updates being
managed by the scheduler. Two commands are added:

* "aurora update list", which shows all active updates that are being processed 
by the server.
* "aurora update status", which shows detailed status information about an 
update in-progress on the server.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/context.py 
f639af7de93a069b278dc494b6f92a2f6b10de9c 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26328: Add "aurora update list" and "aurora update status" commands.

2014-10-06 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/cli/__init__.py
<https://reviews.apache.org/r/26328/#comment95880>

This is a filename, not a print statement. The only reason that I'm using a 
time there is to ensure that it's unique. Creating filenames in the users 
workspace with spaces in it causes lots of unpleasantness for the user. It's 
just obnoxious to do that.


- Mark Chu-Carroll


On Oct. 3, 2014, 4:47 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26328/
> ---
> 
> (Updated Oct. 3, 2014, 4:47 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-779
> https://issues.apache.org/jira/browse/aurora-779
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Improve handling of unknown errors in the aurora client.
> 
> Instead of dumping the stack on the user's terminal, or
> absorbing the error and generating a brief error
> message, the client now writes detailed information about
> the error is written into an error log file, and the
> user is given a clean error message referring them to that
> file for details.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/__init__.py 
> e0c3050151bca1128ed7e476ec5133407a20f6c2 
>   src/main/python/apache/aurora/client/cli/context.py 
> f639af7de93a069b278dc494b6f92a2f6b10de9c 
>   src/main/python/apache/aurora/client/cli/options.py 
> 9a81a1d7d04c6648e94ff117429278317a9dbed8 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> fd2232bc8b7e5caf487291f657a50184391a8c69 
>   src/main/python/apache/aurora/client/cli/update.py 
> b4dd792dc12f19424c620f4d91748113e272f0c9 
>   src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
> 78f21d2f20cf71fa2dfe0614885d44d2948decd2 
>   src/test/python/apache/aurora/client/cli/test_create.py 
> 6e55188bdfc576506848605debb391288e696fe3 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 2782fee2867c6ef79349240299de082f07f7967a 
>   src/test/python/apache/aurora/client/cli/util.py 
> e1ee884c06f3bc22bcd9e908ff61af9459a0b535 
> 
> Diff: https://reviews.apache.org/r/26328/diff/
> 
> 
> Testing
> ---
> 
> New unit test.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26328: Add "aurora update list" and "aurora update status" commands.

2014-10-03 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description
---

Add support for commands to query and display active updates being
managed by the scheduler.

Add the IDs.


Improve handling of unknown errors in the aurora client.

Instead of dumping the stack on the user's terminal, or
absorbing the error and generating a brief error
message, the client now writes detailed information about
the error is written into an error log file, and the
user is given a clean error message referring them to that
file for details.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
e0c3050151bca1128ed7e476ec5133407a20f6c2 
  src/main/python/apache/aurora/client/cli/context.py 
f639af7de93a069b278dc494b6f92a2f6b10de9c 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
fd2232bc8b7e5caf487291f657a50184391a8c69 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
78f21d2f20cf71fa2dfe0614885d44d2948decd2 
  src/test/python/apache/aurora/client/cli/test_create.py 
6e55188bdfc576506848605debb391288e696fe3 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26328: Add "aurora update list" and "aurora update status" commands.

2014-10-03 Thread Mark Chu-Carroll

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

(Updated Oct. 3, 2014, 4:47 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-779
https://issues.apache.org/jira/browse/aurora-779


Repository: aurora


Description (updated)
---

Improve handling of unknown errors in the aurora client.

Instead of dumping the stack on the user's terminal, or
absorbing the error and generating a brief error
message, the client now writes detailed information about
the error is written into an error log file, and the
user is given a clean error message referring them to that
file for details.


Diffs
-

  src/main/python/apache/aurora/client/cli/__init__.py 
e0c3050151bca1128ed7e476ec5133407a20f6c2 
  src/main/python/apache/aurora/client/cli/context.py 
f639af7de93a069b278dc494b6f92a2f6b10de9c 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
fd2232bc8b7e5caf487291f657a50184391a8c69 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_api_from_cli.py 
78f21d2f20cf71fa2dfe0614885d44d2948decd2 
  src/test/python/apache/aurora/client/cli/test_create.py 
6e55188bdfc576506848605debb391288e696fe3 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

New unit test.


Thanks,

Mark Chu-Carroll



Re: Review Request 26137: Fix help for new update command.

2014-10-03 Thread Mark Chu-Carroll


> On Sept. 30, 2014, 2:32 a.m., Joe Smith wrote:
> > src/main/python/apache/aurora/client/cli/update.py, line 45
> > <https://reviews.apache.org/r/26137/diff/1/?file=708198#file708198line45>
> >
> > Could you update a test case to catch accessing these as properties to 
> > catch accidental regressions?
> 
> David McLaughlin wrote:
> Piggy backing this issue to add that my ship it is pending a test for 
> this command at least?
> 
> Mark Chu-Carroll wrote:
> I don't know of any way to write a single test that would always catch 
> this.
> 
> Joe Smith wrote:
> Rebased off your diff:
> 
> [tw-172-25-132-201 aurora (yasumoto/test_update_help)]$ git diff
> diff --git a/src/main/python/apache/aurora/client/cli/update.py 
> b/src/main/python/apache/aurora/client/cli/update.py
> index 41475a7..ef07a11 100644
> --- a/src/main/python/apache/aurora/client/cli/update.py
> +++ b/src/main/python/apache/aurora/client/cli/update.py
> @@ -42,7 +42,6 @@ class StartUpdate(Verb):
>INSTANCES_SPEC_ARGUMENT, CONFIG_ARGUMENT
>  ]
>  
> -  @property
>def help(self):
>  return textwrap.dedent("""\
>  Start a scheduler-driven rolling upgrade on a running job, using 
> the update
> diff --git a/src/test/python/apache/aurora/client/cli/test_update.py 
> b/src/test/python/apache/aurora/client/cli/test_update.py
> index eeed774..1a38ffe 100644
> --- a/src/test/python/apache/aurora/client/cli/test_update.py
> +++ b/src/test/python/apache/aurora/client/cli/test_update.py
> @@ -23,6 +23,7 @@ from apache.aurora.client.api.quota_check import 
> QuotaCheck
>  from apache.aurora.client.api.scheduler_mux import SchedulerMux
>  from apache.aurora.client.cli import EXIT_INVALID_CONFIGURATION, EXIT_OK
>  from apache.aurora.client.cli.client import AuroraCommandLine
> +from apache.aurora.client.cli.update import StartUpdate
>  from apache.aurora.client.cli.util import AuroraClientCommandTest, 
> FakeAuroraCommandContext, IOMock
>  from apache.aurora.config import AuroraConfig
>  
> @@ -301,6 +302,10 @@ class TestUpdateCommand(AuroraClientCommandTest):
>'Update completed successfully']
>assert mock_err.get() == []
>  
> +  def test_update_start_help(self):
> +start = StartUpdate()
> +assert 'Start a scheduler-driven rolling' in start.help
> +
>@classmethod
>def assert_correct_addinstance_calls(cls, api):
>  assert api.addInstances.call_count == 20
> [tw-172-25-132-201 aurora (yasumoto/test_update_help)]$ ./pants 
> ./src/test/python/apache/aurora/client/cli:job
> Build operating on top level addresses: 
> set([BuildFileAddress(/Users/jsmith/workspace/aurora/src/test/python/apache/aurora/client/cli/BUILD,
>  job)])
> 
> 
>  test session starts 
> =
> platform darwin -- Python 2.6.8 -- py-1.4.25 -- pytest-2.6.3
> plugins: cov, timeout
> collected 61 items 
> 
> src/test/python/apache/aurora/client/cli/test_cancel_update.py ..
> src/test/python/apache/aurora/client/cli/test_create.py ..
> src/test/python/apache/aurora/client/cli/test_diff.py ...
> src/test/python/apache/aurora/client/cli/test_kill.py 
> src/test/python/apache/aurora/client/cli/test_open.py .
> src/test/python/apache/aurora/client/cli/test_restart.py 
> src/test/python/apache/aurora/client/cli/test_status.py ...
> src/test/python/apache/aurora/client/cli/test_update.py ..F...
> 
> 
> ==
>  FAILURES 
> ==
> 
> __
>  TestUpdateCommand.test_update_start_help 
> __
&g

Re: Review Request 26098: Fix checkstyle and add checkstyle back to jenkins.

2014-10-03 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Sept. 26, 2014, 5:35 p.m., Brian Wickman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26098/
> ---
> 
> (Updated Sept. 26, 2014, 5:35 p.m.)
> 
> 
> Review request for Aurora, Mark Chu-Carroll and Bill Farner.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fix checkstyle and add checkstyle back to jenkins.
> 
> 
> Diffs
> -
> 
>   build-support/jenkins/build.sh 602b0bcd050cc8270b1f2c2ff3765f8e9319dd22 
>   src/main/python/apache/aurora/admin/host_maintenance.py 
> b7b339706e29b111459505e160209d3ad5d375e3 
>   src/main/python/apache/aurora/client/api/__init__.py 
> e1dfee7571b19f93fe4edfc0b7a81a3d496a09ba 
>   src/main/python/apache/aurora/client/api/instance_watcher.py 
> fe2f551fa81c32c9345a1552807f7726bf14977e 
>   src/main/python/apache/aurora/client/api/job_monitor.py 
> 756093dff8cf101158f2be803cc31f43ceabe654 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> b400cb2dbdb35077fc2c4a6e161c2959a9217317 
>   src/main/python/apache/aurora/client/api/updater_util.py 
> 06eaf3d6b067bd6dd491d1cb6ffdebd5e905a649 
>   src/main/python/apache/aurora/client/cli/context.py 
> 102d20797816788361dfdac450aac9fb8e6fbc28 
>   src/main/python/apache/aurora/client/cli/cron.py 
> 33a6f91d0d4e4917980db2c79dba0142231fcfb5 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 6605485566c07b3e2c1f65b9372bb38e65af6ff9 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> 30d8f750559b7811d66760741905fa8adf80fd1f 
>   src/main/python/apache/aurora/client/cli/task.py 
> 492dec101e500bb4d552f1fc0f06a953921f1ab1 
>   src/main/python/apache/aurora/client/commands/core.py 
> 5e6cedf1771411201b61f0108bee2e8cb19297b5 
>   src/main/python/apache/aurora/client/commands/maintenance.py 
> c83b96af2a2e6e47767d16ad9737c0fe3e0158eb 
>   src/main/python/apache/aurora/client/commands/run.py 
> 7ed22d35ec91dc95dc134960404071fdc6299b8c 
>   src/main/python/apache/aurora/client/commands/ssh.py 
> afd5ab767fbe8e7b1fbbdb7a3cdefa7bfe6a 
>   src/main/python/apache/aurora/executor/common/health_checker.py 
> bed9aeeb982642b361a9c6477e95c255e41c5ff9 
>   src/main/python/apache/aurora/tools/java/thrift_wrapper_codegen.py 
> c4ca3a26820562cb1c4ca94ad2b67ecb8c2a9d19 
>   src/test/python/apache/aurora/client/api/test_api.py 
> e1885f8f5a89104bd83a7ec717db399856563fd9 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 1cbfbf86e903d890baac7d34461109f9beaff442 
>   src/test/python/apache/aurora/client/api/test_updater.py 
> e4c9ad026323fc51ff8b9a2960abf9efdee6c898 
>   src/test/python/apache/aurora/client/cli/test_cron.py 
> 56f0bd4ba93cb9c1b94e58f549dad9d6b1894b22 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> eeed774c170cbb8deacd533d33002aac4b2323cb 
>   src/test/python/apache/aurora/client/commands/test_admin.py 
> f2bf7b552f8de6feacc5548c792eea73a7560bef 
>   src/test/python/apache/aurora/client/commands/test_kill.py 
> 3e6d048590b07603540b3dab026c8fde3c3c4ba4 
>   src/test/python/apache/aurora/client/commands/test_maintenance.py 
> 004033bc82db503589b2b7bd815f651f4e3e844f 
> 
> Diff: https://reviews.apache.org/r/26098/diff/
> 
> 
> Testing
> ---
> 
> Running build.sh now.
> 
> 
> Thanks,
> 
> Brian Wickman
> 
>



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-10-02 Thread Mark Chu-Carroll

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

(Updated Oct. 2, 2014, 4:41 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Add the IDs to "update list".


Bugs: aurora-742
https://issues.apache.org/jira/browse/aurora-742


Repository: aurora


Description
---

Add support for commands to query and display active updates being
managed by the scheduler. Two commands are added:

* "aurora update list", which shows all active updates that are being processed 
by the server.
* "aurora update status", which shows detailed status information about an 
update in-progress on the server.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/context.py 
f639af7de93a069b278dc494b6f92a2f6b10de9c 
  src/main/python/apache/aurora/client/cli/options.py 
9a81a1d7d04c6648e94ff117429278317a9dbed8 
  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
2782fee2867c6ef79349240299de082f07f7967a 
  src/test/python/apache/aurora/client/cli/util.py 
e1ee884c06f3bc22bcd9e908ff61af9459a0b535 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 26137: Fix help for new update command.

2014-10-02 Thread Mark Chu-Carroll


> On Sept. 30, 2014, 2:32 a.m., Joe Smith wrote:
> > src/main/python/apache/aurora/client/cli/update.py, line 45
> > <https://reviews.apache.org/r/26137/diff/1/?file=708198#file708198line45>
> >
> > Could you update a test case to catch accessing these as properties to 
> > catch accidental regressions?
> 
> David McLaughlin wrote:
> Piggy backing this issue to add that my ship it is pending a test for 
> this command at least?

I don't know of any way to write a single test that would always catch this.


- Mark


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


On Sept. 29, 2014, 11:05 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26137/
> ---
> 
> (Updated Sept. 29, 2014, 11:05 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-748
> https://issues.apache.org/jira/browse/aurora-748
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fix help for new update command.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/update.py 
> b4dd792dc12f19424c620f4d91748113e272f0c9 
> 
> Diff: https://reviews.apache.org/r/26137/diff/
> 
> 
> Testing
> ---
> 
> manual testing.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 26270: Fix multiple errors involving bindings, and fix result codes.

2014-10-02 Thread Mark Chu-Carroll

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

(Updated Oct. 2, 2014, 2:24 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Summary (updated)
-

Fix multiple errors involving bindings, and fix result codes.


Bugs: aurora-781
https://issues.apache.org/jira/browse/aurora-781


Repository: aurora


Description
---

Fix multiple errors involving bindings, and fix result codes.

- Cause an error to be raised by an unresolved binding in a configuration file.
- Fix incorrect structuring of processed bindings.
- Add a test to confirm that unbound parameters generate errors.

While I'm in the code, also fix a problem where result codes aren't returned 
correctly
to the shell.


Diffs
-

  src/main/python/apache/aurora/client/cli/client.py 
0cb69448cd24372067ac845eca5862bc3d3a46a9 
  src/main/python/apache/aurora/client/cli/context.py 
102d20797816788361dfdac450aac9fb8e6fbc28 
  src/main/python/apache/aurora/client/cli/options.py 
c2d422ac2bc82fc387596e93040b49f722f8310f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
30d8f750559b7811d66760741905fa8adf80fd1f 
  src/test/python/apache/aurora/client/cli/test_create.py 
31fa56f5edcfc97903725ab27ccc12c6a8f39ffc 
  src/test/python/apache/aurora/client/cli/util.py 
a50b83c571390374975accf75e31f392dbdaaa04 

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


Testing
---

Unit tests:
- verified that tests fail if the binding code is disabled, but pass with in on.
- added a new unit test to check that unresolved bindings generate an error.


Thanks,

Mark Chu-Carroll



Re: Review Request 26270: Make the client invocation code actually use the exit codes returned by the client.

2014-10-02 Thread Mark Chu-Carroll

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

(Updated Oct. 2, 2014, 12:07 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Improve error messages, and add output testing.


Bugs: aurora-781
https://issues.apache.org/jira/browse/aurora-781


Repository: aurora


Description
---

Fix multiple errors involving bindings, and fix result codes.

- Cause an error to be raised by an unresolved binding in a configuration file.
- Fix incorrect structuring of processed bindings.
- Add a test to confirm that unbound parameters generate errors.

While I'm in the code, also fix a problem where result codes aren't returned 
correctly
to the shell.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/client.py 
0cb69448cd24372067ac845eca5862bc3d3a46a9 
  src/main/python/apache/aurora/client/cli/context.py 
102d20797816788361dfdac450aac9fb8e6fbc28 
  src/main/python/apache/aurora/client/cli/options.py 
c2d422ac2bc82fc387596e93040b49f722f8310f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
30d8f750559b7811d66760741905fa8adf80fd1f 
  src/test/python/apache/aurora/client/cli/test_create.py 
31fa56f5edcfc97903725ab27ccc12c6a8f39ffc 
  src/test/python/apache/aurora/client/cli/util.py 
a50b83c571390374975accf75e31f392dbdaaa04 

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


Testing
---

Unit tests:
- verified that tests fail if the binding code is disabled, but pass with in on.
- added a new unit test to check that unresolved bindings generate an error.


Thanks,

Mark Chu-Carroll



Review Request 26270: Make the client invocation code actually use the exit codes returned by the client.

2014-10-02 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-781
https://issues.apache.org/jira/browse/aurora-781


Repository: aurora


Description
---

Fix multiple errors involving bindings, and fix result codes.

- Cause an error to be raised by an unresolved binding in a configuration file.
- Fix incorrect structuring of processed bindings.
- Add a test to confirm that unbound parameters generate errors.

While I'm in the code, also fix a problem where result codes aren't returned 
correctly
to the shell.


Diffs
-

  src/main/python/apache/aurora/client/cli/client.py 
0cb69448cd24372067ac845eca5862bc3d3a46a9 
  src/main/python/apache/aurora/client/cli/context.py 
102d20797816788361dfdac450aac9fb8e6fbc28 
  src/main/python/apache/aurora/client/cli/options.py 
c2d422ac2bc82fc387596e93040b49f722f8310f 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
30d8f750559b7811d66760741905fa8adf80fd1f 
  src/test/python/apache/aurora/client/cli/test_create.py 
31fa56f5edcfc97903725ab27ccc12c6a8f39ffc 
  src/test/python/apache/aurora/client/cli/util.py 
a50b83c571390374975accf75e31f392dbdaaa04 

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


Testing
---

Unit tests:
- verified that tests fail if the binding code is disabled, but pass with in on.
- added a new unit test to check that unresolved bindings generate an error.


Thanks,

Mark Chu-Carroll



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-10-01 Thread Mark Chu-Carroll


> On Sept. 24, 2014, 6:28 p.m., David McLaughlin wrote:
> > What was the rationale for hiding update IDs from the user and making job 
> > key the parameter for update status? It's nice you can quickly see if a job 
> > key has an update in progress.. but what happens if you're wanting to see a 
> > recent deploy that is already finished or see further back?  
> > 
> > I think update list should return the update ids and update status should 
> > accept an update id. Well maybe not update status.. but update show or 
> > something? Something which is consistent with the job verbs would be great.
> 
> Mark Chu-Carroll wrote:
> I was following the pattern that I saw in the API implementation. In 
> early iterations, it exposed updated ids; in later ones, the IDs were removed 
> from the user-level API. We don't use those identifiers for pausing or 
> resuming an active update; why would we use them for checking on the status 
> of an update? That would become a very awkward interface for users: start an 
> update? use the jobkey. Pause an update? User the jobkey. Abort an update? 
> Use the jobkey. Check the status of an update? Use some other identifier that 
> you don't know without running another command.
> 
> I can certainly add the updateID to the list command, and add a command 
> (or alternative parameter) for checking on a job by update-ID, but I don't 
> think that making it the normal parameter to status is a good design for the 
> command-line.

ping?


- Mark


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


On Sept. 24, 2014, 4:24 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26004/
> ---
> 
> (Updated Sept. 24, 2014, 4:24 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-742
> https://issues.apache.org/jira/browse/aurora-742
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Add support for commands to query and display active updates being
> managed by the scheduler. Two commands are added:
> 
> * "aurora update list", which shows all active updates that are being 
> processed by the server.
> * "aurora update status", which shows detailed status information about an 
> update in-progress on the server.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 102d20797816788361dfdac450aac9fb8e6fbc28 
>   src/main/python/apache/aurora/client/cli/options.py 
> c2d422ac2bc82fc387596e93040b49f722f8310f 
>   src/main/python/apache/aurora/client/cli/update.py 
> c6cb98fe6aa42310090167796c971856d3dc177f 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 4fb1623e497b9741ae2a350deb20030dd4036506 
>   src/test/python/apache/aurora/client/cli/util.py 
> a50b83c571390374975accf75e31f392dbdaaa04 
> 
> Diff: https://reviews.apache.org/r/26004/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests; all tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26137: Fix help for new update command.

2014-09-29 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-748
https://issues.apache.org/jira/browse/aurora-748


Repository: aurora


Description
---

Fix help for new update command.


Diffs
-

  src/main/python/apache/aurora/client/cli/update.py 
b4dd792dc12f19424c620f4d91748113e272f0c9 

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


Testing
---

manual testing.


Thanks,

Mark Chu-Carroll



Re: Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-09-29 Thread Mark Chu-Carroll


> On Sept. 24, 2014, 6:28 p.m., David McLaughlin wrote:
> > What was the rationale for hiding update IDs from the user and making job 
> > key the parameter for update status? It's nice you can quickly see if a job 
> > key has an update in progress.. but what happens if you're wanting to see a 
> > recent deploy that is already finished or see further back?  
> > 
> > I think update list should return the update ids and update status should 
> > accept an update id. Well maybe not update status.. but update show or 
> > something? Something which is consistent with the job verbs would be great.

I was following the pattern that I saw in the API implementation. In early 
iterations, it exposed updated ids; in later ones, the IDs were removed from 
the user-level API. We don't use those identifiers for pausing or resuming an 
active update; why would we use them for checking on the status of an update? 
That would become a very awkward interface for users: start an update? use the 
jobkey. Pause an update? User the jobkey. Abort an update? Use the jobkey. 
Check the status of an update? Use some other identifier that you don't know 
without running another command.

I can certainly add the updateID to the list command, and add a command (or 
alternative parameter) for checking on a job by update-ID, but I don't think 
that making it the normal parameter to status is a good design for the 
command-line.


- Mark


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


On Sept. 24, 2014, 4:24 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26004/
> ---
> 
> (Updated Sept. 24, 2014, 4:24 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Zameer Manji.
> 
> 
> Bugs: aurora-742
> https://issues.apache.org/jira/browse/aurora-742
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Add support for commands to query and display active updates being
> managed by the scheduler. Two commands are added:
> 
> * "aurora update list", which shows all active updates that are being 
> processed by the server.
> * "aurora update status", which shows detailed status information about an 
> update in-progress on the server.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 102d20797816788361dfdac450aac9fb8e6fbc28 
>   src/main/python/apache/aurora/client/cli/options.py 
> c2d422ac2bc82fc387596e93040b49f722f8310f 
>   src/main/python/apache/aurora/client/cli/update.py 
> c6cb98fe6aa42310090167796c971856d3dc177f 
>   src/test/python/apache/aurora/client/cli/test_supdate.py 
> 4fb1623e497b9741ae2a350deb20030dd4036506 
>   src/test/python/apache/aurora/client/cli/util.py 
> a50b83c571390374975accf75e31f392dbdaaa04 
> 
> Diff: https://reviews.apache.org/r/26004/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests; all tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 26014: Quick fix for cron error.

2014-09-24 Thread Mark Chu-Carroll

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

Review request for Aurora, Bill Farner and Zameer Manji.


Bugs: aurora-753
https://issues.apache.org/jira/browse/aurora-753


Repository: aurora


Description
---

Damned python indent-syntax - else clause attached to "if" rather than "for".


Diffs
-

  src/main/python/apache/aurora/client/cli/cron.py 
3416c8e1932056725880f2007b60d77112759428 

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


Testing
---

Quick fix: no additional test. I'll add a regression test when rosh hashanah is 
over.


Thanks,

Mark Chu-Carroll



Review Request 26004: Add "aurora update list" and "aurora update status" commands.

2014-09-24 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-742
https://issues.apache.org/jira/browse/aurora-742


Repository: aurora


Description
---

Add support for commands to query and display active updates being
managed by the scheduler. Two commands are added:

* "aurora update list", which shows all active updates that are being processed 
by the server.
* "aurora update status", which shows detailed status information about an 
update in-progress on the server.


Diffs
-

  src/main/python/apache/aurora/client/cli/context.py 
102d20797816788361dfdac450aac9fb8e6fbc28 
  src/main/python/apache/aurora/client/cli/options.py 
c2d422ac2bc82fc387596e93040b49f722f8310f 
  src/main/python/apache/aurora/client/cli/update.py 
c6cb98fe6aa42310090167796c971856d3dc177f 
  src/test/python/apache/aurora/client/cli/test_supdate.py 
4fb1623e497b9741ae2a350deb20030dd4036506 
  src/test/python/apache/aurora/client/cli/util.py 
a50b83c571390374975accf75e31f392dbdaaa04 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Review Request 25918: Improve aurora command-line help using metavars.

2014-09-22 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-737
https://issues.apache.org/jira/browse/aurora-737


Repository: aurora


Description
---

Improve aurora command-line help using metavars.


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
383c59143ae87d1f059644fdc3433e4c2075d02e 
  src/main/python/apache/aurora/client/cli/options.py 
36f80aa175beaf8f2dc6b6f962394643313d6405 
  src/main/python/apache/aurora/client/cli/task.py 
5b5710ae9005664e17be1053c63b282364ae0300 

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


Testing
---

All unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-17 Thread Mark Chu-Carroll

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

(Updated Sept. 17, 2014, 2:44 p.m.)


Review request for Aurora.


Changes
---

rebase to master.


Repository: aurora


Description
---

This change contains the basic commands needed to work with the
scheduler-driven updater. (It does not yet cover querying for the status
of the update; that will come in a subsequent change.)


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/BUILD 
4ed8f8a3e29010282c5cb0cc461980bcfc6ae478 
  src/main/python/apache/aurora/client/cli/context.py 
51c7d24dca664e476e62f1864d095416dfab70e4 
  src/main/python/apache/aurora/client/cli/jobs.py 
aeb78303fc2071ccad848b1de4512e8ca585bf06 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
b7c8de66d6e4664b536911f826e36a984e8d0fef 
  src/main/python/apache/aurora/client/cli/update.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/BUILD 
70e704d2a3c334eaa8ba905eb3c75c2e9ee152bc 
  src/test/python/apache/aurora/client/cli/test_restart.py 
377ecfe6180785e57a389f6e1bc8b184bca0dd6c 
  src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/util.py 
ebabe529966cea503f11404f37961c5d577f00b7 

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


Testing
---

New suite of tests for the new command; all unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-17 Thread Mark Chu-Carroll

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

(Updated Sept. 17, 2014, 1:06 p.m.)


Review request for Aurora.


Repository: aurora


Description
---

This change contains the basic commands needed to work with the
scheduler-driven updater. (It does not yet cover querying for the status
of the update; that will come in a subsequent change.)


Diffs
-

  src/main/python/apache/aurora/client/cli/BUILD 
ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
  src/main/python/apache/aurora/client/cli/context.py 
51c7d24dca664e476e62f1864d095416dfab70e4 
  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
b7c8de66d6e4664b536911f826e36a984e8d0fef 
  src/main/python/apache/aurora/client/cli/update.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/BUILD 
e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/util.py 
95a2123e127c9811fd2305e71cfc5c7c4376f904 

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


Testing
---

New suite of tests for the new command; all unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-15 Thread Mark Chu-Carroll
As I said - the version with the sub-actions fouls up parameter checking.
(That's the "action" parameter option. It doesn't matter whether it's
"--action=start" or "--start"; in fact, the --action at least lets the
parameter parser do a little bit of checking.)

It's possible to add another layer of dispatch to the framework, but it's a
fair bit of work. But that's not a problem. The problem there is that for
users, "noun/verb" is a very natural idea. When you start going to extra
layers of dispatch, the complexity of the command to users changes pretty
significantly. It's no longer "what do I want to interact with, and what do
I want to do to it", but "How many layers of commands do I need for this?"

I think that adding layers changes the cognitive load of working with the
system in a very unfortunate way.

I still think that of the options, the "update" noun is still the best.

The distinction between nouns is always going to be somewhat arbitrary -
why is "ssh" part of task instead of job? Why is quota a noun and user a
parameter, instead of user a noun and quota a parameter?

There is a sensible distinction in update. The fundamental question behind
nouns is always "what kind of thing do I want to interact with?" And
there's a reasonable answer: "an update process on a server". It can be
explained to users in the one-line usage message, and it's easy to remember.






On Mon, Sep 15, 2014 at 5:16 PM, Maxim Khutornenko  wrote:

> I guess there is also the option you originally proposed: "aurora job
> update --start|--pause|--resume|--abort".
>
> If you don't like the option syntax, would it be too much work to
> support double "verb" (or rather double "noun") syntax, like "aurora
> job update start"?
>
> On Mon, Sep 15, 2014 at 2:07 PM, Mark Chu-Carroll
>  wrote:
> > The choices are:
> >
> > (1) Action parameter: "aurora job update
> --action=start/pause/resume/abort".
> > Pros: it's part of the "job" noun and the familiar "update" verb.
> > Cons:
> > - the action parameter is ugly,
> > - we lose automatic parameter checking, since the different actions take
> > different parameters.
> > - it's difficult to prevent it from interfering with existing users while
> > the server-driven update is under
> >   development and not working. (I see this as an extremely serious
> blocking
> > problem.)
> >
> > (2) Multiple verbs on job: "aurora job update_start", "aurora job
> > update_pause", ...
> > Pros:
> > - it's part of the "job" noun,
> > - parameter checking works.
> > - it's reasonably easy to keep this separated so that it doesn't show up
> > until we're ready.
> > Cons:
> > - it's hideous.
> >
> > (3) Update noun: "aurora update start/pause/resume/abort".
> > Pros:
> > - parameter checking works.
> > - easy to keep under wraps without annoying users.
> > - (arguable) I think it makes sense, because it represents a command that
> > interacts with a different service.
> > Cons:
> > - It's not part of the job noun.
> >
> >
> > I strongly prefer option 3. But I don't want to waste time bikesheding.
> So
> > if you guys strongly disagree with me, fine, just tell me which one
> you're
> > willing to agree on.
> >
> > -Mark
> >
> > On Mon, Sep 15, 2014 at 2:28 PM, Bill Farner  wrote:
> >>
> >> In the world of 'nouns' and 'verbs', i imagine a user would think "i
> want
> >> to update my job", not "i want to start an update".  So if the goal of
> >> organizing commands by nouns is to make it intuitive, i think "update
> start"
> >> is less natural than "job update".
> >>
> >> -=Bill
> >>
> >> On Mon, Sep 15, 2014 at 10:25 AM, Mark Chu-Carroll
> >>  wrote:
> >>>
> >>>
> >>>
> >>> > On Sept. 15, 2014, 12:04 p.m., Maxim Khutornenko wrote:
> >>> > > src/main/python/apache/aurora/client/cli/standalone_client.py, line
> >>> > > 121
> >>> > >
> >>> > > <
> https://reviews.apache.org/r/25255/diff/2/?file=685554#file685554line121>
> >>> > >
> >>> > > I am still not sure why we are going with the top level noun
> for
> >>> > > job updates. It's quite strange to see create/restart un

Re: Review Request 25255: Implement server-driven update commands.

2014-09-15 Thread Mark Chu-Carroll
The choices are:

(1) Action parameter: "aurora job update
--action=start/pause/resume/abort".
Pros: it's part of the "job" noun and the familiar "update" verb.
Cons:
- the action parameter is ugly,
- we lose automatic parameter checking, since the different actions take
different parameters.
- it's difficult to prevent it from interfering with existing users while
the server-driven update is under
  development and not working. (I see this as an *extremely* serious
blocking problem.)

(2) Multiple verbs on job: "aurora job update_start", "aurora job
update_pause", ...
Pros:
- it's part of the "job" noun,
- parameter checking works.
- it's reasonably easy to keep this separated so that it doesn't show up
until we're ready.
Cons:
- it's hideous.

(3) Update noun: "aurora update start/pause/resume/abort".
Pros:
- parameter checking works.
- easy to keep under wraps without annoying users.
- (arguable) I think it makes sense, because it represents a command that
interacts with a different service.
Cons:
- It's not part of the job noun.


I strongly prefer option 3. But I don't want to waste time bikesheding. So
if you guys strongly disagree with me, fine, just tell me which one you're
willing to agree on.

-Mark

On Mon, Sep 15, 2014 at 2:28 PM, Bill Farner  wrote:

> In the world of 'nouns' and 'verbs', i imagine a user would think "i want
> to update my job", not "i want to start an update".  So if the goal of
> organizing commands by nouns is to make it intuitive, i think "update
> start" is less natural than "job update".
>
> -=Bill
>
> On Mon, Sep 15, 2014 at 10:25 AM, Mark Chu-Carroll <
> mchucarr...@twopensource.com> wrote:
>
>>
>>
>> > On Sept. 15, 2014, 12:04 p.m., Maxim Khutornenko wrote:
>> > > src/main/python/apache/aurora/client/cli/standalone_client.py, line
>> 121
>> > > <
>> https://reviews.apache.org/r/25255/diff/2/?file=685554#file685554line121>
>> > >
>> > > I am still not sure why we are going with the top level noun for
>> job updates. It's quite strange to see create/restart under "job" but
>> "update" living on its own. Is this only to avoid collision with the
>> existing client update? If so, it's only there until we iron out the async
>> updates. We could clearly mark new server side update options as "BETA" in
>> command help to avoid any confusion. I think the long term consistency here
>> is more important than temporary ambiguity.
>>
>> I thought that it made sense to be a separate noun.
>>
>> There's two main reasons why I think it makes sense for this to be a
>> distinct noun.
>>
>> (1) All of the "job" commands on the client are client-driven logic. This
>> isn't. This is server-side logic,
>>   but not truly scheduler logic. It's creating an update process on a
>> server somewhere, and then allowing
>>   you to interact with it. You're not using these commands to interact
>> with a job - you're interacting with
>>   an update process.  You're interacting with a different kind of
>> *thing*, and each kind of thing is
>>   handled as a different noun.  (Think about the "task" noun. A task is a
>> piece of a job, but we handle
>>   it differently. We still use jobkeys to specify them - but for
>> operations that work on the running
>>   task in a mesos slave, we put them in a different noun than the
>> operations that talk to the scheduler
>>   about the job itself. I think this is a similar case.)
>>
>> (2) There's a collection of sub-commands, and the subcommands are
>> behaviorally very much the kinds of
>>   operations you find on nouns elsewhere in the client. Putting all of
>> this under the "update" verb
>>   on jobs results in a lot of ugliness - you end up with the "action"
>> parameter from the earlier version
>>   of this review, and you lose hte ability to have the option parser do
>> parameter checking for the
>>   different actions. You end up with a better syntax, and clearer
>> semantics when you treat start/pause/resume/abort/status as verbs on an
>> update noun.
>>
>> Finally, I very strongly disagree that it's OK to introduce the
>> server-driven updates as options to the existing "update" command.
>> Disrupting users with unsupported, non-working test functionality is *not*
>> acceptable in a production tool.
>>
>> One fringe benefit of this approach i

Re: Review Request 25255: Implement server-driven update commands.

2014-09-15 Thread Mark Chu-Carroll


> On Sept. 15, 2014, 12:04 p.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/standalone_client.py, line 121
> > <https://reviews.apache.org/r/25255/diff/2/?file=685554#file685554line121>
> >
> > I am still not sure why we are going with the top level noun for job 
> > updates. It's quite strange to see create/restart under "job" but "update" 
> > living on its own. Is this only to avoid collision with the existing client 
> > update? If so, it's only there until we iron out the async updates. We 
> > could clearly mark new server side update options as "BETA" in command help 
> > to avoid any confusion. I think the long term consistency here is more 
> > important than temporary ambiguity.

I thought that it made sense to be a separate noun.

There's two main reasons why I think it makes sense for this to be a distinct 
noun.

(1) All of the "job" commands on the client are client-driven logic. This 
isn't. This is server-side logic,
  but not truly scheduler logic. It's creating an update process on a server 
somewhere, and then allowing
  you to interact with it. You're not using these commands to interact with a 
job - you're interacting with
  an update process.  You're interacting with a different kind of *thing*, and 
each kind of thing is 
  handled as a different noun.  (Think about the "task" noun. A task is a piece 
of a job, but we handle
  it differently. We still use jobkeys to specify them - but for operations 
that work on the running
  task in a mesos slave, we put them in a different noun than the operations 
that talk to the scheduler
  about the job itself. I think this is a similar case.)

(2) There's a collection of sub-commands, and the subcommands are behaviorally 
very much the kinds of
  operations you find on nouns elsewhere in the client. Putting all of this 
under the "update" verb
  on jobs results in a lot of ugliness - you end up with the "action" parameter 
from the earlier version
  of this review, and you lose hte ability to have the option parser do 
parameter checking for the 
  different actions. You end up with a better syntax, and clearer semantics 
when you treat start/pause/resume/abort/status as verbs on an update noun.
  
Finally, I very strongly disagree that it's OK to introduce the server-driven 
updates as options to the existing "update" command. Disrupting users with 
unsupported, non-working test functionality is *not* acceptable in a production 
tool. 

One fringe benefit of this approach is that it's really easy to leave it out of 
the production executable until it's ready to go.

   -Mark


- Mark


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


On Sept. 11, 2014, 10:55 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25255/
> ---
> 
> (Updated Sept. 11, 2014, 10:55 a.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This change contains the basic commands needed to work with the
> scheduler-driven updater. (It does not yet cover querying for the status
> of the update; that will come in a subsequent change.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/BUILD 
> ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
>   src/main/python/apache/aurora/client/cli/context.py 
> 51c7d24dca664e476e62f1864d095416dfab70e4 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> b7c8de66d6e4664b536911f826e36a984e8d0fef 
>   src/main/python/apache/aurora/client/cli/update.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a1e7a5a94a2d336239df98e2600658b97c546901 
>   src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25255/diff/
> 
> 
> Testing
> ---
> 
> New suite of tests for the new command; all unit tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25255: Implement server-driven update commands.

2014-09-15 Thread Mark Chu-Carroll

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


ping? THis is ready for another look.

- Mark Chu-Carroll


On Sept. 11, 2014, 10:55 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25255/
> ---
> 
> (Updated Sept. 11, 2014, 10:55 a.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This change contains the basic commands needed to work with the
> scheduler-driven updater. (It does not yet cover querying for the status
> of the update; that will come in a subsequent change.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/BUILD 
> ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
>   src/main/python/apache/aurora/client/cli/context.py 
> 51c7d24dca664e476e62f1864d095416dfab70e4 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/main/python/apache/aurora/client/cli/standalone_client.py 
> b7c8de66d6e4664b536911f826e36a984e8d0fef 
>   src/main/python/apache/aurora/client/cli/update.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a1e7a5a94a2d336239df98e2600658b97c546901 
>   src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25255/diff/
> 
> 
> Testing
> ---
> 
> New suite of tests for the new command; all unit tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25543: Update to pants 0.0.23.

2014-09-15 Thread Mark Chu-Carroll


> On Sept. 12, 2014, 6:54 p.m., Brian Wickman wrote:
> > I noticed you just commented out some of the timeout= keywords -- do you 
> > plan to remove those or just leave them as annotations?

Leave them as annotations. I'm not really clear on why the timeout was removed, 
but the fact that we believe that these tests should be considered as failed if 
they take longer than that timeout period seems like something worth preserving.


- Mark


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


On Sept. 11, 2014, 12:13 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25543/
> ---
> 
> (Updated Sept. 11, 2014, 12:13 p.m.)
> 
> 
> Review request for Aurora, Joe Smith and Brian Wickman.
> 
> 
> Bugs: aurora-695
> https://issues.apache.org/jira/browse/aurora-695
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> - Update build files for the new syntax, which no longer requires
>   'pants(...)' around target names.
> - Remove no-longer-supported "timeout" from python_tests.
> 
> 
> Diffs
> -
> 
>   pants 4f9c351888afa1a779415730240093c3dee25dfb 
>   src/main/python/apache/aurora/admin/BUILD 
> 7a100d1a4a74aae034082f34db051c9cc31f8540 
>   src/main/python/apache/aurora/client/BUILD 
> bf196bf86b36db0d72f8e096260c9a900f74d07c 
>   src/main/python/apache/aurora/client/api/BUILD 
> 70ad38e34f14c6d54b71c8f4b2138f085658110e 
>   src/main/python/apache/aurora/client/bin/BUILD 
> 43d747956df0611b0880f64df9955d5f5806901c 
>   src/main/python/apache/aurora/client/cli/BUILD 
> ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
>   src/main/python/apache/aurora/client/commands/BUILD 
> cc16923909a7b26b0f3ac0b47bb37dafdbbf502e 
>   src/main/python/apache/aurora/client/hooks/BUILD 
> 9471c4cba5175296030747301e246a65a39aa203 
>   src/main/python/apache/aurora/common/BUILD 
> b879b15127d6691b35880074fd0ceacd866a61ed 
>   src/main/python/apache/aurora/common/auth/BUILD 
> 7e96cb2258711b2e2925d18ad9435fa986e86bca 
>   src/main/python/apache/aurora/config/BUILD 
> 4f8fad80114ddabac8b25f70bba00119228ec675 
>   src/main/python/apache/aurora/config/schema/BUILD 
> 69d60aebd2a9aa353497406ae578a9997323b07e 
>   src/main/python/apache/aurora/executor/BUILD 
> 1ad8f82cdce85cf228c53e088171918e36ed536d 
>   src/main/python/apache/aurora/executor/bin/BUILD 
> aeb8aee6f50a0d89714626e933699c0a13b363d9 
>   src/main/python/apache/aurora/executor/common/BUILD 
> 335ebc4809096c5f128846cd846d33910a777968 
>   src/main/python/apache/thermos/BUILD 
> 0dc035f759dd9949997f0c979b3556a350cf8df7 
>   src/main/python/apache/thermos/bin/BUILD 
> 669f9930a3590184dc0f8b5c15c36168e715eb03 
>   src/main/python/apache/thermos/common/BUILD 
> 6015f9e9a23f71bf6dede1f4698fe63dbb4dcfaa 
>   src/main/python/apache/thermos/config/BUILD 
> 0531f92ea569ffe36817b645a17fab7a712e5897 
>   src/main/python/apache/thermos/core/BUILD 
> 0d1d339d55ee6a569297614ac734661e5caf7ea4 
>   src/main/python/apache/thermos/monitoring/BUILD 
> 79da0d5cef9436d4a3d83075910decfc93e422a6 
>   src/main/python/apache/thermos/observer/BUILD 
> 49b844ffc1b1d5911fc28d14294d088c3d0b6e4b 
>   src/main/python/apache/thermos/observer/bin/BUILD 
> 044ca66b18282daf17a4198ff369d954e14c9b6d 
>   src/main/python/apache/thermos/observer/http/BUILD 
> 901ad9c61e4dd1c61f5fbf4467becb8c881a64ed 
>   src/main/python/apache/thermos/testing/BUILD 
> dc328a63788381307576b5a43ecdc704bb764473 
>   src/main/thrift/org/apache/aurora/gen/BUILD 
> 947504ec1f9582496952b23e66d7f5f20a168ce7 
>   src/test/python/BUILD f01efff2e4982a475221b5739dfe1e8fd1a41d92 
>   src/test/python/apache/aurora/BUILD 
> 6555b984a713ef786aef5688b206ae9d8017c48d 
>   src/test/python/apache/aurora/admin/BUILD 
> 5e170d6c15a95e2511b69e18a255d7364c2e7a4d 
>   src/test/python/apache/aurora/client/BUILD 
> 831a72d39b27ca2aca466a38914bbf40ff94 
>   src/test/python/apache/aurora/client/api/BUILD 
> b4f08c6192e6bf6b38665197e98db7235751ae86 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/commands/BUILD 
> 17933dedfa08c9d12c369087bf801e7c35cdde9b 
>   src/test/python/apache/aurora/client/hooks/BUILD 
> f7856a2d5dc7e5d1edc480f64d5db97d88c71b70 
>   src/test/python/apache/aurora/common/BUILD 
> e949ba8859d5567c62623bec9d5ba86a846

Re: Review Request 25582: Fix error in client "task ssh" command when the job isn't found.

2014-09-12 Thread Mark Chu-Carroll

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

(Updated Sept. 12, 2014, 1:17 p.m.)


Review request for Aurora, David McLaughlin and Zameer Manji.


Changes
---

Address review comments.


Bugs: aurora-706
https://issues.apache.org/jira/browse/aurora-706


Repository: aurora


Description
---

Fix error in client "task ssh" command when the job isn't found.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/task.py 
91175facdc8c9fd59ab66781f86ee8b5940a 
  src/main/python/apache/aurora/client/commands/ssh.py 
37a90089b72b86c82466f1819e7881a36bb2f214 
  src/test/python/apache/aurora/client/cli/test_task_run.py 
8d9ef0543c1ab514d6f039ba63a1d417a4a90a1b 
  src/test/python/apache/aurora/client/commands/test_ssh.py 
4070b710b005c91fe08dd7906cd93bf3a8cdba9e 

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


Testing
---

Added new tests to catch this case;
Ran all client unit tests, all tests pass.


Thanks,

Mark Chu-Carroll



Review Request 25582: Fix error in client "task ssh" command when the job isn't found.

2014-09-12 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Zameer Manji.


Bugs: aurora-706
https://issues.apache.org/jira/browse/aurora-706


Repository: aurora


Description
---

Fix error in client "task ssh" command when the job isn't found.


Diffs
-

  src/main/python/apache/aurora/client/cli/task.py 
91175facdc8c9fd59ab66781f86ee8b5940a 
  src/main/python/apache/aurora/client/commands/ssh.py 
37a90089b72b86c82466f1819e7881a36bb2f214 
  src/test/python/apache/aurora/client/cli/test_task_run.py 
8d9ef0543c1ab514d6f039ba63a1d417a4a90a1b 
  src/test/python/apache/aurora/client/commands/test_ssh.py 
4070b710b005c91fe08dd7906cd93bf3a8cdba9e 

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


Testing
---

Added new tests to catch this case;
Ran all client unit tests, all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25519: Adding "get_scheduler" admin command.

2014-09-11 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Sept. 10, 2014, 6:43 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25519/
> ---
> 
> (Updated Sept. 10, 2014, 6:43 p.m.)
> 
> 
> Review request for Aurora, Mark Chu-Carroll and Zameer Manji.
> 
> 
> Bugs: AURORA-692
> https://issues.apache.org/jira/browse/AURORA-692
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adding "get_scheduler" admin command.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> 0ba07611b1a367f7157b91a1d4b65b1af176 
>   src/main/python/apache/aurora/client/commands/admin.py 
> bc9a9eee9a187f2c895e70a093871f0b795931c4 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 630f662ad2ffb8d192299d98c612ad4892161081 
>   src/test/python/apache/aurora/client/commands/test_admin.py 
> 94e736fb80c3fd7f103437c24f33d7c4451a6969 
>   src/test/python/apache/aurora/client/commands/util.py 
> 21b8830df5a3eccc7d36067369fc16cc5fd9de2a 
>   src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh 
> 989801cfcbd19109ac140b01cd3024d70c78c829 
>   src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
> 0965b5c8cb89eb36c6e15108c702c39dd68268be 
> 
> Diff: https://reviews.apache.org/r/25519/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Review Request 25543: Update to pants 0.0.23.

2014-09-11 Thread Mark Chu-Carroll

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

Review request for Aurora, Joe Smith and Brian Wickman.


Bugs: aurora-695
https://issues.apache.org/jira/browse/aurora-695


Repository: aurora


Description
---

- Update build files for the new syntax, which no longer requires
  'pants(...)' around target names.
- Remove no-longer-supported "timeout" from python_tests.


Diffs
-

  pants 4f9c351888afa1a779415730240093c3dee25dfb 
  src/main/python/apache/aurora/admin/BUILD 
7a100d1a4a74aae034082f34db051c9cc31f8540 
  src/main/python/apache/aurora/client/BUILD 
bf196bf86b36db0d72f8e096260c9a900f74d07c 
  src/main/python/apache/aurora/client/api/BUILD 
70ad38e34f14c6d54b71c8f4b2138f085658110e 
  src/main/python/apache/aurora/client/bin/BUILD 
43d747956df0611b0880f64df9955d5f5806901c 
  src/main/python/apache/aurora/client/cli/BUILD 
ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
  src/main/python/apache/aurora/client/commands/BUILD 
cc16923909a7b26b0f3ac0b47bb37dafdbbf502e 
  src/main/python/apache/aurora/client/hooks/BUILD 
9471c4cba5175296030747301e246a65a39aa203 
  src/main/python/apache/aurora/common/BUILD 
b879b15127d6691b35880074fd0ceacd866a61ed 
  src/main/python/apache/aurora/common/auth/BUILD 
7e96cb2258711b2e2925d18ad9435fa986e86bca 
  src/main/python/apache/aurora/config/BUILD 
4f8fad80114ddabac8b25f70bba00119228ec675 
  src/main/python/apache/aurora/config/schema/BUILD 
69d60aebd2a9aa353497406ae578a9997323b07e 
  src/main/python/apache/aurora/executor/BUILD 
1ad8f82cdce85cf228c53e088171918e36ed536d 
  src/main/python/apache/aurora/executor/bin/BUILD 
aeb8aee6f50a0d89714626e933699c0a13b363d9 
  src/main/python/apache/aurora/executor/common/BUILD 
335ebc4809096c5f128846cd846d33910a777968 
  src/main/python/apache/thermos/BUILD 0dc035f759dd9949997f0c979b3556a350cf8df7 
  src/main/python/apache/thermos/bin/BUILD 
669f9930a3590184dc0f8b5c15c36168e715eb03 
  src/main/python/apache/thermos/common/BUILD 
6015f9e9a23f71bf6dede1f4698fe63dbb4dcfaa 
  src/main/python/apache/thermos/config/BUILD 
0531f92ea569ffe36817b645a17fab7a712e5897 
  src/main/python/apache/thermos/core/BUILD 
0d1d339d55ee6a569297614ac734661e5caf7ea4 
  src/main/python/apache/thermos/monitoring/BUILD 
79da0d5cef9436d4a3d83075910decfc93e422a6 
  src/main/python/apache/thermos/observer/BUILD 
49b844ffc1b1d5911fc28d14294d088c3d0b6e4b 
  src/main/python/apache/thermos/observer/bin/BUILD 
044ca66b18282daf17a4198ff369d954e14c9b6d 
  src/main/python/apache/thermos/observer/http/BUILD 
901ad9c61e4dd1c61f5fbf4467becb8c881a64ed 
  src/main/python/apache/thermos/testing/BUILD 
dc328a63788381307576b5a43ecdc704bb764473 
  src/main/thrift/org/apache/aurora/gen/BUILD 
947504ec1f9582496952b23e66d7f5f20a168ce7 
  src/test/python/BUILD f01efff2e4982a475221b5739dfe1e8fd1a41d92 
  src/test/python/apache/aurora/BUILD 6555b984a713ef786aef5688b206ae9d8017c48d 
  src/test/python/apache/aurora/admin/BUILD 
5e170d6c15a95e2511b69e18a255d7364c2e7a4d 
  src/test/python/apache/aurora/client/BUILD 
831a72d39b27ca2aca466a38914bbf40ff94 
  src/test/python/apache/aurora/client/api/BUILD 
b4f08c6192e6bf6b38665197e98db7235751ae86 
  src/test/python/apache/aurora/client/cli/BUILD 
e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
  src/test/python/apache/aurora/client/commands/BUILD 
17933dedfa08c9d12c369087bf801e7c35cdde9b 
  src/test/python/apache/aurora/client/hooks/BUILD 
f7856a2d5dc7e5d1edc480f64d5db97d88c71b70 
  src/test/python/apache/aurora/common/BUILD 
e949ba8859d5567c62623bec9d5ba86a8463fbaa 
  src/test/python/apache/aurora/config/BUILD 
37bbd27e13a2a3589faff7285f04e3c44ca57eeb 
  src/test/python/apache/aurora/executor/BUILD 
4d43e256ad131223cc1ac36a406d42a979a8a2dd 
  src/test/python/apache/aurora/executor/common/BUILD 
7d8934046b56ac2c0c16440cfc571dc370767a14 
  src/test/python/apache/thermos/BUILD cb93a4622e33ef96855b89a7c138f42033368950 
  src/test/python/apache/thermos/bin/BUILD 
4b59f3879298de9664f168150ea9029e013e7913 
  src/test/python/apache/thermos/common/BUILD 
36fa6a69b5e77a645a65c52fef6ec9343bf541bc 
  src/test/python/apache/thermos/config/BUILD 
42445ceccba8dfe8296a22a174aca6123bdfdb52 
  src/test/python/apache/thermos/core/BUILD 
8f5c626c2e89834dbb4938c3c69ef8c79558e12b 
  src/test/python/apache/thermos/monitoring/BUILD 
ea4005b52be3185e553f7d23fb29b89f68befa50 

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


Testing
---

- Ran all unit tests: several fail, but they also fail under the previous 
version of pants.
- Built all python_binary targets in src/main/python/apache/aurora.
- Verified that resulting pexes executed correctly.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-11 Thread Mark Chu-Carroll

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

(Updated Sept. 11, 2014, 10:55 a.m.)


Review request for Aurora.


Changes
---

Refactor the change to move the service-driven update commands into a new 
"update" noun.


Repository: aurora


Description
---

This change contains the basic commands needed to work with the
scheduler-driven updater. (It does not yet cover querying for the status
of the update; that will come in a subsequent change.)


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/BUILD 
ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
  src/main/python/apache/aurora/client/cli/context.py 
51c7d24dca664e476e62f1864d095416dfab70e4 
  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/main/python/apache/aurora/client/cli/standalone_client.py 
b7c8de66d6e4664b536911f826e36a984e8d0fef 
  src/main/python/apache/aurora/client/cli/update.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/BUILD 
e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/util.py 
95a2123e127c9811fd2305e71cfc5c7c4376f904 

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


Testing
---

New suite of tests for the new command; all unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-11 Thread Mark Chu-Carroll

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


I was about to ping about this, when I discovered that my replies to the 
comments never got sent - guessing chrome timed out, and I didn't notice.

Please don't re-review this yet - I'm reworking some of the code; I'll send an 
update when it's ready.

- Mark Chu-Carroll


On Sept. 2, 2014, 12:36 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25255/
> ---
> 
> (Updated Sept. 2, 2014, 12:36 p.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This change contains the basic commands needed to work with the
> scheduler-driven updater. (It does not yet cover querying for the status
> of the update; that will come in a subsequent change.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 51c7d24dca664e476e62f1864d095416dfab70e4 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a1e7a5a94a2d336239df98e2600658b97c546901 
>   src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25255/diff/
> 
> 
> Testing
> ---
> 
> New suite of tests for the new command; all unit tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25255: Implement server-driven update commands.

2014-09-11 Thread Mark Chu-Carroll


> On Sept. 3, 2014, 3:58 p.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 667
> > <https://reviews.apache.org/r/25255/diff/1/?file=673959#file673959line667>
> >
> > How about a BROWSER_OPTION for all update commands 
> > (start/pause/resume/abort)?

It will, eventually, but we don't have a set URL for it yet. That can be added 
when the UI is more locked down.


> On Sept. 3, 2014, 3:58 p.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, lines 704-706
> > <https://reviews.apache.org/r/25255/diff/1/?file=673959#file673959line704>
> >
> > Is this a result of sharing the verb definition with start_update? Any 
> > chance to avoid sharing the option set here?

With the way that the noun/verb framework works right now, no, there's not 
really any good way. 

There are three choices:
(1) Have an action parameter as a selector (what this change does);
(2) Have a collection of verbs, "update_start", "update_pause", 
"update_resume", "update_abort".
(3) Add a noun for an in-progress update, in which case the commands become 
"aurora update start", "aurora update pause", etc.

I really hate (2), and I've been going back and forth between (1) and (3).


- Mark


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


On Sept. 2, 2014, 12:36 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25255/
> ---
> 
> (Updated Sept. 2, 2014, 12:36 p.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This change contains the basic commands needed to work with the
> scheduler-driven updater. (It does not yet cover querying for the status
> of the update; that will come in a subsequent change.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 51c7d24dca664e476e62f1864d095416dfab70e4 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a1e7a5a94a2d336239df98e2600658b97c546901 
>   src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25255/diff/
> 
> 
> Testing
> ---
> 
> New suite of tests for the new command; all unit tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25505: Make "aurora job status" JSON output more friendly.

2014-09-10 Thread Mark Chu-Carroll

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

(Updated Sept. 10, 2014, 3:34 p.m.)


Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Changes
---

Fix other error in "job status", generating error when no matching job is found.


Bugs: aurora-666
https://issues.apache.org/jira/browse/aurora-666


Repository: aurora


Description
---

Use string names instead of numeric values for ScheduleStatus fields of
records rendered in JSON.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/jobs.py 
38b5f6e306c2c8dd9aa8d98e21c6a628028ad899 
  src/test/python/apache/aurora/client/cli/test_status.py 
721d9764190bdc4b1c5b65e416a039803b7c507c 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25505: Make "aurora job status" JSON output more friendly.

2014-09-10 Thread Mark Chu-Carroll

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

(Updated Sept. 10, 2014, 1:38 p.m.)


Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Changes
---

Fix boolean rendering.


Bugs: aurora-666
https://issues.apache.org/jira/browse/aurora-666


Repository: aurora


Description
---

Use string names instead of numeric values for ScheduleStatus fields of
records rendered in JSON.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/jobs.py 
38b5f6e306c2c8dd9aa8d98e21c6a628028ad899 
  src/test/python/apache/aurora/client/cli/test_status.py 
721d9764190bdc4b1c5b65e416a039803b7c507c 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25505: Make "aurora job status" JSON output more friendly.

2014-09-10 Thread Mark Chu-Carroll

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



src/test/python/apache/aurora/client/cli/test_status.py
<https://reviews.apache.org/r/25505/#comment92095>

Yup, you're right.


- Mark Chu-Carroll


On Sept. 10, 2014, 11:56 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25505/
> ---
> 
> (Updated Sept. 10, 2014, 11:56 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Maxim Khutornenko.
> 
> 
> Bugs: aurora-666
> https://issues.apache.org/jira/browse/aurora-666
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Use string names instead of numeric values for ScheduleStatus fields of
> records rendered in JSON.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 38b5f6e306c2c8dd9aa8d98e21c6a628028ad899 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> 721d9764190bdc4b1c5b65e416a039803b7c507c 
> 
> Diff: https://reviews.apache.org/r/25505/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests; all tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Review Request 25505: Make "aurora job status" JSON output more friendly.

2014-09-10 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Bugs: aurora-666
https://issues.apache.org/jira/browse/aurora-666


Repository: aurora


Description
---

Use string names instead of numeric values for ScheduleStatus fields of
records rendered in JSON.


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
38b5f6e306c2c8dd9aa8d98e21c6a628028ad899 
  src/test/python/apache/aurora/client/cli/test_status.py 
721d9764190bdc4b1c5b65e416a039803b7c507c 

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


Testing
---

Added new unit tests; all tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25450: Fix broken "large update" warning.

2014-09-09 Thread Mark Chu-Carroll

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

(Updated Sept. 9, 2014, 3:43 p.m.)


Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Changes
---

Fixed time delay in test runs;
Adjusted logging output.


Bugs: aurora-5860
https://issues.apache.org/jira/browse/aurora-5860


Repository: aurora


Description
---

At some point, the "large update" warning logic was revised so that the
warning shows whenever you do an update that either:
- the updated config had more than 4x as many instances as the running one; or
- the updated config had less than 4x as many instances as the running one.

(Seriously: either local >= 4 * remote or local <= 4 * remote". And running git 
blame says it's all my fault.)

This fixes it: the correct logic is:
- the updated config has more than 4x as many as running; or
- the updated config has less than 1/4th as many as running.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/__init__.py 
6e553d8af459e575b2d62282a3bc0d1e266203d8 
  src/main/python/apache/aurora/client/cli/jobs.py 
8f349c09637c16e2499e85f2dc96eb7ccffd0aaf 
  src/test/python/apache/aurora/client/cli/test_update.py 
8b7d11202b35deb09a248cfe0a96458fb70c 
  src/test/python/apache/aurora/client/cli/util.py 
95a2123e127c9811fd2305e71cfc5c7c4376f904 

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


Testing
---

Added new unit tests.


Thanks,

Mark Chu-Carroll



Re: Review Request 25450: Fix broken "large update" warning.

2014-09-09 Thread Mark Chu-Carroll


> On Sept. 8, 2014, 4:31 p.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 655
> > <https://reviews.apache.org/r/25450/diff/1/?file=682752#file682752line655>
> >
> > This feels redundant. Current output already has success message(s):
> > 
> > ...
> > log(info): Killed: 8
> > log(info): Instance 0 has been up and healthy for at least 45 seconds
> > log(info): Instance 1 has been up and healthy for at least 45 seconds
> > log(info): Update successful
> > log(info): Command terminated successfully
> 
> Mark Chu-Carroll wrote:
> Current output has those messages on logs - which are optional.  I think 
> that making sure there's some feedback to the user is worthwhile.

(For what it's worth, the "command terminated successfully" was intended to put 
a status line into loggie. I've switched it to TRANSCRIPT level, so it goes to 
loggie, but the user won't see it; that way, the user won't see duplicates, but 
they'll definitely see feedback when the command completes.)


- Mark


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


On Sept. 8, 2014, 2:37 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25450/
> ---
> 
> (Updated Sept. 8, 2014, 2:37 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Maxim Khutornenko.
> 
> 
> Bugs: aurora-5860
> https://issues.apache.org/jira/browse/aurora-5860
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> At some point, the "large update" warning logic was revised so that the
> warning shows whenever you do an update that either:
> - the updated config had more than 4x as many instances as the running one; or
> - the updated config had less than 4x as many instances as the running one.
> 
> (Seriously: either local >= 4 * remote or local <= 4 * remote". And running 
> git blame says it's all my fault.)
> 
> This fixes it: the correct logic is:
> - the updated config has more than 4x as many as running; or
> - the updated config has less than 1/4th as many as running.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 8f349c09637c16e2499e85f2dc96eb7ccffd0aaf 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> 8b7d11202b35deb09a248cfe0a96458fb70c 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25450/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25450: Fix broken "large update" warning.

2014-09-09 Thread Mark Chu-Carroll


> On Sept. 8, 2014, 4:31 p.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 655
> > <https://reviews.apache.org/r/25450/diff/1/?file=682752#file682752line655>
> >
> > This feels redundant. Current output already has success message(s):
> > 
> > ...
> > log(info): Killed: 8
> > log(info): Instance 0 has been up and healthy for at least 45 seconds
> > log(info): Instance 1 has been up and healthy for at least 45 seconds
> > log(info): Update successful
> > log(info): Command terminated successfully

Current output has those messages on logs - which are optional.  I think that 
making sure there's some feedback to the user is worthwhile.


> On Sept. 8, 2014, 4:31 p.m., Maxim Khutornenko wrote:
> > src/test/python/apache/aurora/client/cli/test_update.py, line 251
> > <https://reviews.apache.org/r/25450/diff/1/?file=682753#file682753line251>
> >
> > This patching not appear to work in the current version of tests where 
> > a 5 seconds timeout is always waited on. Any chance it could be fixed 
> > before piling up more test cases like this?

I'll look, and see if I can figure out where that's coming from.


- Mark


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


On Sept. 8, 2014, 2:37 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25450/
> ---
> 
> (Updated Sept. 8, 2014, 2:37 p.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Maxim Khutornenko.
> 
> 
> Bugs: aurora-5860
> https://issues.apache.org/jira/browse/aurora-5860
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> At some point, the "large update" warning logic was revised so that the
> warning shows whenever you do an update that either:
> - the updated config had more than 4x as many instances as the running one; or
> - the updated config had less than 4x as many instances as the running one.
> 
> (Seriously: either local >= 4 * remote or local <= 4 * remote". And running 
> git blame says it's all my fault.)
> 
> This fixes it: the correct logic is:
> - the updated config has more than 4x as many as running; or
> - the updated config has less than 1/4th as many as running.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> 8f349c09637c16e2499e85f2dc96eb7ccffd0aaf 
>   src/test/python/apache/aurora/client/cli/test_update.py 
> 8b7d11202b35deb09a248cfe0a96458fb70c 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25450/diff/
> 
> 
> Testing
> ---
> 
> Added new unit tests.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 22457: Improve aurora "job diff" command.

2014-09-09 Thread Mark Chu-Carroll

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

(Updated Sept. 9, 2014, 10:07 a.m.)


Review request for Aurora, Maxim Khutornenko and Brian Wickman.


Changes
---

Tried modifying the test, to see if that fixes the jenkins build issue.


Bugs: aurora-520
https://issues.apache.org/jira/browse/aurora-520


Repository: aurora


Description (updated)
---

Add a new diff method, which uses field-by-field comparison of JSON trees for 
comparing running job configurations to potentially updated configs.

- Allow exclusion of semantically irrelevant fields.
- Provide a clearer list of the differences between configs.
- Provide a scripting-friendly alternative JSON syntax for diffs.

The old diff behavior is still available under the "--use-shell-diff" option.


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/BUILD 
ebe681a0d1735b7cc695dc3b7a14c4292d87ae32 
  src/main/python/apache/aurora/client/cli/jobs.py 
8f349c09637c16e2499e85f2dc96eb7ccffd0aaf 
  src/main/python/apache/aurora/client/cli/json_tree_diff.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/BUILD 
e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
  src/test/python/apache/aurora/client/cli/test_diff.py 
38629b63c082cf81cb891dace2a70d9e8f418e18 
  src/test/python/apache/aurora/client/cli/test_json_diff.py PRE-CREATION 

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


Testing
---

New unit tests of the JSON tree diff code, plus a bunch of new "job diff" tests 
of the new functionality.
All tests pass.


Thanks,

Mark Chu-Carroll



Review Request 25450: Fix broken "large update" warning.

2014-09-08 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Bugs: aurora-5860
https://issues.apache.org/jira/browse/aurora-5860


Repository: aurora


Description
---

At some point, the "large update" warning logic was revised so that the
warning shows whenever you do an update that either:
- the updated config had more than 4x as many instances as the running one; or
- the updated config had less than 4x as many instances as the running one.

(Seriously: either local >= 4 * remote or local <= 4 * remote". And running git 
blame says it's all my fault.)

This fixes it: the correct logic is:
- the updated config has more than 4x as many as running; or
- the updated config has less than 1/4th as many as running.


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
8f349c09637c16e2499e85f2dc96eb7ccffd0aaf 
  src/test/python/apache/aurora/client/cli/test_update.py 
8b7d11202b35deb09a248cfe0a96458fb70c 
  src/test/python/apache/aurora/client/cli/util.py 
95a2123e127c9811fd2305e71cfc5c7c4376f904 

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


Testing
---

Added new unit tests.


Thanks,

Mark Chu-Carroll



Review Request 25350: Fix build problem.

2014-09-04 Thread Mark Chu-Carroll

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

Review request for Aurora and Bill Farner.


Bugs: aurora-684
https://issues.apache.org/jira/browse/aurora-684


Repository: aurora


Description
---

Timestamps in pretty-printed job status use the local timezone.
Jenkins machines use GMT as their local time; so the time printed
on jenkins differs from times printed elsewhere.

This fix fuzzes out the time in the timestamps, so that it doesn't matter
where the test is run.


Diffs
-

  src/test/python/apache/aurora/client/cli/test_status.py 
2af24fbaa4971819636898df752fa886553d75a3 

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


Testing
---


Thanks,

Mark Chu-Carroll



Re: Review Request 25309: Fix output formatting error in "job status".

2014-09-04 Thread Mark Chu-Carroll


> On Sept. 4, 2014, 11:42 a.m., Maxim Khutornenko wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, line 543
> > <https://reviews.apache.org/r/25309/diff/1-2/?file=675766#file675766line543>
> >
> > Curious, why not using multiple '\t' instead of spacing?

Looking at the output with standard terminal tab settings, it was ugly. The use 
of multiple tabs just ate up too much horizontal space.


- Mark


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


On Sept. 4, 2014, 9:24 a.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25309/
> ---
> 
> (Updated Sept. 4, 2014, 9:24 a.m.)
> 
> 
> Review request for Aurora, David McLaughlin and Maxim Khutornenko.
> 
> 
> Bugs: aurora-672
> https://issues.apache.org/jira/browse/aurora-672
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fix output formatting error in "job status".
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/test/python/apache/aurora/client/cli/test_status.py 
> 311fac02af32e0ed687489a2352164effb4dba96 
> 
> Diff: https://reviews.apache.org/r/25309/diff/
> 
> 
> Testing
> ---
> 
> Ran unit tests; added new test cases.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25309: Fix output formatting error in "job status".

2014-09-04 Thread Mark Chu-Carroll

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

(Updated Sept. 4, 2014, 9:24 a.m.)


Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Changes
---

Poking around, I noticed several more glitches in the output formatting, and 
corrected them. Take another quick look please?


Bugs: aurora-672
https://issues.apache.org/jira/browse/aurora-672


Repository: aurora


Description
---

Fix output formatting error in "job status".


Diffs (updated)
-

  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/test_status.py 
311fac02af32e0ed687489a2352164effb4dba96 

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


Testing
---

Ran unit tests; added new test cases.


Thanks,

Mark Chu-Carroll



Re: Review Request 25255: Implement server-driven update commands.

2014-09-03 Thread Mark Chu-Carroll


> On Sept. 2, 2014, 1:32 p.m., Joshua Cohen wrote:
> > Is the command name "supdate" up for debate? I'm not in love with it ;).

It's a temporary thing. (Came up with it during a discussion with Bill.) 

If we start adding this stuff to the existing update command, then existing 
users are going to see things like "pause", and "resume" that don't make any 
sense, and that are only related to a component/service that they can't use.  
We don't want to screw up or confuse users of the existing command during the 
development of the update service - so for that transition, we're keeping 
update/supdate separate.

I'm not in love with "supdate" as the name, but I didn't want to waste time 
coming up with something better when it's just temporary anyway.


> On Sept. 2, 2014, 1:32 p.m., Joshua Cohen wrote:
> > src/main/python/apache/aurora/client/cli/jobs.py, lines 664-665
> > <https://reviews.apache.org/r/25255/diff/1/?file=673959#file673959line664>
> >
> > This doesn't read very well to me.
> > 
> > Maybe something like:
> > 
> > "Update action to start an update or pause, resume or abort an 
> > in-progress update."

I think that wording is worse... The help should suggest what the value of the 
parameter is. "Update action to start an update or pause..." blurs that. The 
argument specifies the action that the user wants, which can be update, pause, 
resume, or abort.


- Mark


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


On Sept. 2, 2014, 12:36 p.m., Mark Chu-Carroll wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25255/
> ---
> 
> (Updated Sept. 2, 2014, 12:36 p.m.)
> 
> 
> Review request for Aurora.
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> This change contains the basic commands needed to work with the
> scheduler-driven updater. (It does not yet cover querying for the status
> of the update; that will come in a subsequent change.)
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/cli/context.py 
> 51c7d24dca664e476e62f1864d095416dfab70e4 
>   src/main/python/apache/aurora/client/cli/jobs.py 
> ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
>   src/test/python/apache/aurora/client/cli/BUILD 
> e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
>   src/test/python/apache/aurora/client/cli/test_restart.py 
> a1e7a5a94a2d336239df98e2600658b97c546901 
>   src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
>   src/test/python/apache/aurora/client/cli/util.py 
> 95a2123e127c9811fd2305e71cfc5c7c4376f904 
> 
> Diff: https://reviews.apache.org/r/25255/diff/
> 
> 
> Testing
> ---
> 
> New suite of tests for the new command; all unit tests pass.
> 
> 
> Thanks,
> 
> Mark Chu-Carroll
> 
>



Re: Review Request 25204: Adding "get" job update client APIs.

2014-09-03 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Aug. 29, 2014, 6:28 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25204/
> ---
> 
> (Updated Aug. 29, 2014, 6:28 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-615
> https://issues.apache.org/jira/browse/AURORA-615
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adding "get" job update client APIs.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 90462bf5920786ea1316c75a99c8382cf8c803a1 
>   src/test/python/apache/aurora/client/api/test_api.py 
> b47b6db31842fffba797c7f616b5f4deb8d04a86 
> 
> Diff: https://reviews.apache.org/r/25204/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python/apache/aurora/client/api:api -s
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 25204: Adding "get" job update client APIs.

2014-09-03 Thread Mark Chu-Carroll


> On Sept. 2, 2014, 3:35 p.m., Mark Chu-Carroll wrote:
> > src/main/python/apache/aurora/client/api/__init__.py, line 176
> > <https://reviews.apache.org/r/25204/diff/1/?file=672539#file672539line176>
> >
> > Nit - but why are you changing the parameter comment syntax? We don't 
> > use the double-dash anywhere else in the client.
> 
> Maxim Khutornenko wrote:
> This is the style everything under client/api seems to follow. Just 
> making it consistent.

Ick. So client/api doesn't follow the same pattern as a lot of other client 
code. Something for me to fix at some point.


> On Sept. 2, 2014, 3:35 p.m., Mark Chu-Carroll wrote:
> > src/main/python/apache/aurora/client/api/__init__.py, line 232
> > <https://reviews.apache.org/r/25204/diff/1/?file=672539#file672539line232>
> >
> > I think this would be clearer inlined. Right now, it's pretty much an 
> > alternate name for the JobUpdateQuery constructor, but with different 
> > parameter names. It makes the code harder to follow, not easier.
> 
> Maxim Khutornenko wrote:
> The reason for this is mostly consistency (see build_query above) but I 
> personally prefer this approach as it decouples query building from the 
> thrift API call.

In this case, I disagree pretty strongly - but if you must have the separate 
method, at least make the argument names match.


- Mark


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


On Aug. 29, 2014, 6:28 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25204/
> -----------
> 
> (Updated Aug. 29, 2014, 6:28 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-615
> https://issues.apache.org/jira/browse/AURORA-615
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adding "get" job update client APIs.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 90462bf5920786ea1316c75a99c8382cf8c803a1 
>   src/test/python/apache/aurora/client/api/test_api.py 
> b47b6db31842fffba797c7f616b5f4deb8d04a86 
> 
> Diff: https://reviews.apache.org/r/25204/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python/apache/aurora/client/api:api -s
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Review Request 25309: Fix output formatting error in "job status".

2014-09-03 Thread Mark Chu-Carroll

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

Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Bugs: aurora-672
https://issues.apache.org/jira/browse/aurora-672


Repository: aurora


Description
---

Fix output formatting error in "job status".


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/test_status.py 
311fac02af32e0ed687489a2352164effb4dba96 

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


Testing
---

Ran unit tests; added new test cases.


Thanks,

Mark Chu-Carroll



Re: Review Request 25206: Fix aurora run in end to end tests.

2014-09-03 Thread Mark Chu-Carroll
At the moment, there's two end-to-end tests: test_end_to_end.sh, and
test_end_to_end_v2.sh. Since this is the v1 test, it should use v1.

 -Mark


On Wed, Sep 3, 2014 at 2:05 PM, Joe Smith  wrote:

>This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25206/
>
> On September 2nd, 2014, 6:47 p.m. PDT, *Joe Smith* wrote:
>
>   src/test/sh/org/apache/aurora/e2e/test_run.sh
> <https://reviews.apache.org/r/25206/diff/1/?file=672554#file672554line23> 
> (Diff
> revision 1)
>
> 23
>
> aurora_command=${3:-"aurora run"}
>
>   aurora job run?
>
>  On September 2nd, 2014, 8:15 p.m. PDT, *Joe Smith* wrote:
>
> Kevin and Toby, can you two take a look at this ASAP? I'd like to have the 
> e2e tests fixed before I ship https://reviews.apache.org/r/25208/
>
>  On September 3rd, 2014, 9:25 a.m. PDT, *Joshua Cohen* wrote:
>
> It defaults to 'aurora run', for the aurora1 client, but we pass in 'aurora2 
> job run' from the test_end_to_end_v2.sh script. Are you saying to switch the 
> default (or maybe I should just remove the default altogether)?
>
>  I was saying switch the default so it's the new syntax
>
>
> - Joe
>
> On August 29th, 2014, 4:17 p.m. PDT, Joshua Cohen wrote:
>   Review request for Aurora, Kevin Sweeney, Mark Chu-Carroll, and Tobias
> Weingartner.
> By Joshua Cohen.
>
> *Updated Aug. 29, 2014, 4:17 p.m.*
>  *Bugs: * AURORA-676 <https://issues.apache.org/jira/browse/AURORA-676>
>  *Repository: * aurora
> Description
>
> Fix aurora run in end to end tests.
>
>   Testing
>
> $ bash src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
>
> Unfortunately the v2 client end to end tests are currently broken (filed 
> https://issues.apache.org/jira/browse/AURORA-677), but I verified that the 
> test for aurora task run works in that script as well.
>
>   Diffs
>
>- examples/vagrant/upstart/mesos-slave.conf
>(e53d545f3a66383c12ed1e7de6b1eef2dbad1541)
>- src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
>(fa5568e5d34e1a8b2db78b4c9d009ed3d47ed04f)
>- src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh
>(14a0b62c1b06179211d79f35a9c6df162c9a5999)
>- src/test/sh/org/apache/aurora/e2e/test_run.sh (PRE-CREATION)
>
> View Diff <https://reviews.apache.org/r/25206/diff/>
>


Re: Review Request 25297: Make config-file an optional parameter for "job restart."

2014-09-03 Thread Mark Chu-Carroll

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

(Updated Sept. 3, 2014, 10:07 a.m.)


Review request for Aurora, David McLaughlin and Maxim Khutornenko.


Bugs: aurora-673
https://issues.apache.org/jira/browse/aurora-673


Repository: aurora


Description
---

Make config-file an optional parameter for "job restart."


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
14a0b62c1b06179211d79f35a9c6df162c9a5999 

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


Testing
---

- Ran all unit tests successfully.
- Ran end-to-end tests successfully.
- 


Thanks,

Mark Chu-Carroll



Re: Review Request 25297: Make config-file an optional parameter for "job restart."

2014-09-03 Thread Mark Chu-Carroll

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

(Updated Sept. 3, 2014, 10:06 a.m.)


Review request for Aurora.


Bugs: aurora-673
https://issues.apache.org/jira/browse/aurora-673


Repository: aurora


Description
---

Make config-file an optional parameter for "job restart."


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
14a0b62c1b06179211d79f35a9c6df162c9a5999 

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


Testing
---

- Ran all unit tests successfully.
- Ran end-to-end tests successfully.
- 


Thanks,

Mark Chu-Carroll



Review Request 25297: Make config-file an optional parameter for "job restart."

2014-09-03 Thread Mark Chu-Carroll

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

Review request for Aurora.


Repository: aurora


Description
---

Make config-file an optional parameter for "job restart."


Diffs
-

  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
14a0b62c1b06179211d79f35a9c6df162c9a5999 

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


Testing
---

- Ran all unit tests successfully.
- Ran end-to-end tests successfully.
- 


Thanks,

Mark Chu-Carroll



Re: Review Request 25206: Fix aurora run in end to end tests.

2014-09-02 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Aug. 29, 2014, 7:17 p.m., Joshua Cohen wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25206/
> ---
> 
> (Updated Aug. 29, 2014, 7:17 p.m.)
> 
> 
> Review request for Aurora, Kevin Sweeney, Mark Chu-Carroll, and Tobias 
> Weingartner.
> 
> 
> Bugs: AURORA-676
> https://issues.apache.org/jira/browse/AURORA-676
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Fix aurora run in end to end tests.
> 
> 
> Diffs
> -
> 
>   examples/vagrant/upstart/mesos-slave.conf 
> e53d545f3a66383c12ed1e7de6b1eef2dbad1541 
>   src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh 
> fa5568e5d34e1a8b2db78b4c9d009ed3d47ed04f 
>   src/test/sh/org/apache/aurora/e2e/test_end_to_end_v2.sh 
> 14a0b62c1b06179211d79f35a9c6df162c9a5999 
>   src/test/sh/org/apache/aurora/e2e/test_run.sh PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/25206/diff/
> 
> 
> Testing
> ---
> 
> $ bash src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
> 
> Unfortunately the v2 client end to end tests are currently broken (filed 
> https://issues.apache.org/jira/browse/AURORA-677), but I verified that the 
> test for aurora task run works in that script as well.
> 
> 
> Thanks,
> 
> Joshua Cohen
> 
>



Re: Review Request 25204: Adding "get" job update client APIs.

2014-09-02 Thread Mark Chu-Carroll

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



src/main/python/apache/aurora/client/api/__init__.py
<https://reviews.apache.org/r/25204/#comment90799>

Nit - but why are you changing the parameter comment syntax? We don't use 
the double-dash anywhere else in the client.



src/main/python/apache/aurora/client/api/__init__.py
<https://reviews.apache.org/r/25204/#comment90801>

I think this would be clearer inlined. Right now, it's pretty much an 
alternate name for the JobUpdateQuery constructor, but with different parameter 
names. It makes the code harder to follow, not easier.



src/main/python/apache/aurora/client/api/__init__.py
<https://reviews.apache.org/r/25204/#comment90802>

If we're going to the trouble of abstracting away the actual scheduler 
interface, I think we shouldn't be returning the raw Response datatype. This 
should return the updates, not the structure wrapping the updates in two layers 
of indirection.

These kinds of methods should check the result code, raise an exception if 
the API call failed, and then return a meaningful, simple result. 

(Same comment applies to get_job_update_details)


- Mark Chu-Carroll


On Aug. 29, 2014, 6:28 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25204/
> ---
> 
> (Updated Aug. 29, 2014, 6:28 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-615
> https://issues.apache.org/jira/browse/AURORA-615
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adding "get" job update client APIs.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 90462bf5920786ea1316c75a99c8382cf8c803a1 
>   src/test/python/apache/aurora/client/api/test_api.py 
> b47b6db31842fffba797c7f616b5f4deb8d04a86 
> 
> Diff: https://reviews.apache.org/r/25204/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python/apache/aurora/client/api:api -s
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Review Request 25255: Implement server-driven update commands.

2014-09-02 Thread Mark Chu-Carroll

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

Review request for Aurora.


Repository: aurora


Description
---

This change contains the basic commands needed to work with the
scheduler-driven updater. (It does not yet cover querying for the status
of the update; that will come in a subsequent change.)


Diffs
-

  src/main/python/apache/aurora/client/cli/context.py 
51c7d24dca664e476e62f1864d095416dfab70e4 
  src/main/python/apache/aurora/client/cli/jobs.py 
ebc22aaa5a8aed311897b3ce9632b6f7175b6080 
  src/test/python/apache/aurora/client/cli/BUILD 
e1f9ebf96774b8f5c75de8570c6ba87d953ab649 
  src/test/python/apache/aurora/client/cli/test_restart.py 
a1e7a5a94a2d336239df98e2600658b97c546901 
  src/test/python/apache/aurora/client/cli/test_supdate.py PRE-CREATION 
  src/test/python/apache/aurora/client/cli/util.py 
95a2123e127c9811fd2305e71cfc5c7c4376f904 

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


Testing
---

New suite of tests for the new command; all unit tests pass.


Thanks,

Mark Chu-Carroll



Re: Review Request 25159: Adding pause/resume/abort client APIs.

2014-08-28 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Aug. 28, 2014, 2:16 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25159/
> ---
> 
> (Updated Aug. 28, 2014, 2:16 p.m.)
> 
> 
> Review request for Aurora and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-615
> https://issues.apache.org/jira/browse/AURORA-615
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Adding pause/resume/abort client APIs.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/__init__.py 
> 4968738068876b6796ee0ddc0e70192894482ccf 
>   src/test/python/apache/aurora/client/api/test_api.py 
> 237d4abacae78ff9d024f43d777ff6d3328b1dd9 
> 
> Diff: https://reviews.apache.org/r/25159/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python/apache/aurora/client/api:api
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 24871: Converting perform_maintenance_hosts into host_drain.

2014-08-22 Thread Mark Chu-Carroll

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

Ship it!


Ship It!

- Mark Chu-Carroll


On Aug. 22, 2014, 5:26 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/24871/
> ---
> 
> (Updated Aug. 22, 2014, 5:26 p.m.)
> 
> 
> Review request for Aurora, Joe Smith and Mark Chu-Carroll.
> 
> 
> Bugs: AURORA-43
> https://issues.apache.org/jira/browse/AURORA-43
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> Converting perform_maintenance_hosts into host_drain.
> 
> Also, renaming maintenance commands to address AURORA-43.
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/admin/admin_util.py 
> 31ec2b1fb06e1ad5f8c00978b091e7ab01fbb7ab 
>   src/main/python/apache/aurora/admin/host_maintenance.py 
> 162f9afea67e409d784e436c96f55ceed0537ca1 
>   src/main/python/apache/aurora/client/commands/maintenance.py 
> a54f0f663590033989db0d2cf3521453bf87de6a 
>   src/test/python/apache/aurora/admin/test_host_maintenance.py 
> d8aeffb5035a55ced485318444002141dada5bfc 
>   src/test/python/apache/aurora/client/commands/test_maintenance.py 
> a748c0183997a59f1773a2be62ec17f6c11ddd3a 
> 
> Diff: https://reviews.apache.org/r/24871/diff/
> 
> 
> Testing
> ---
> 
> ./pants src/test/python:all
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



  1   2   3   4   5   6   >