Re: Review Request 39797: Adding help message in case kerberos auth fails.

2015-11-03 Thread Aurora ReviewBot

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

Ship it!


Master (f41938d) is green with this patch.
  ./build-support/jenkins/build.sh

I will refresh this build result if you post a review containing "@ReviewBot 
retry"

- Aurora ReviewBot


On Nov. 3, 2015, 5:53 p.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/39797/
> ---
> 
> (Updated Nov. 3, 2015, 5:53 p.m.)
> 
> 
> Review request for Aurora, Joshua Cohen and Bill Farner.
> 
> 
> Bugs: AURORA-1364
> https://issues.apache.org/jira/browse/AURORA-1364
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> The only reasonable way to wire it in is via the AuthModule, which is the 
> only entity aware of the auth approach used.
> 
> Also, dropped AuthModule.payload() as it's no longer needed (SessionKey 
> thrift struct is empty now).
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> 8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
>   src/main/python/apache/aurora/client/cli/client.py 
> c17f857dd1fd6289e2b3ca8e3f86211ede1344ad 
>   src/main/python/apache/aurora/common/auth/auth_module.py 
> e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
>   src/main/python/apache/aurora/common/auth/auth_module_manager.py 
> 2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
>   src/main/python/apache/aurora/kerberos/auth_module.py 
> fade00504a3122bc4b93e1cc1b7ebac6415303da 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 
>   src/test/python/apache/aurora/client/cli/test_client.py 
> 49f050cc34e0d07df7b055ac57b561d3c129c0b7 
> 
> Diff: https://reviews.apache.org/r/39797/diff/
> 
> 
> Testing
> ---
> 
> ./pants test.pytest --no-fast src/test/python::
> ./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
> 
> Example error message:
> ```
> ...
>  INFO] Instances to be killed: [0]
> ERROR] Communication with Aurora scheduler is kerberized. Did you forget to 
> run "kinit"?
> 401 Client Error: Authorization Required
> ```
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 39797: Adding help message in case kerberos auth fails.

2015-11-03 Thread Maxim Khutornenko

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

(Updated Nov. 3, 2015, 5:53 p.m.)


Review request for Aurora, Joshua Cohen and Bill Farner.


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


Repository: aurora


Description
---

The only reasonable way to wire it in is via the AuthModule, which is the only 
entity aware of the auth approach used.

Also, dropped AuthModule.payload() as it's no longer needed (SessionKey thrift 
struct is empty now).


Diffs
-

  src/main/python/apache/aurora/client/api/scheduler_client.py 
8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
  src/main/python/apache/aurora/client/cli/client.py 
c17f857dd1fd6289e2b3ca8e3f86211ede1344ad 
  src/main/python/apache/aurora/common/auth/auth_module.py 
e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
  src/main/python/apache/aurora/common/auth/auth_module_manager.py 
2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
  src/main/python/apache/aurora/kerberos/auth_module.py 
fade00504a3122bc4b93e1cc1b7ebac6415303da 
  src/test/python/apache/aurora/client/api/test_scheduler_client.py 
1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 
  src/test/python/apache/aurora/client/cli/test_client.py 
49f050cc34e0d07df7b055ac57b561d3c129c0b7 

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


Testing (updated)
---

./pants test.pytest --no-fast src/test/python::
./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh

Example error message:
```
...
 INFO] Instances to be killed: [0]
ERROR] Communication with Aurora scheduler is kerberized. Did you forget to run 
"kinit"?
401 Client Error: Authorization Required
```


Thanks,

Maxim Khutornenko



Re: Review Request 39797: Adding help message in case kerberos auth fails.

2015-11-03 Thread Maxim Khutornenko

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

(Updated Nov. 3, 2015, 5:53 p.m.)


Review request for Aurora, Joshua Cohen and Bill Farner.


Changes
---

Updated test cases.


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


Repository: aurora


Description
---

The only reasonable way to wire it in is via the AuthModule, which is the only 
entity aware of the auth approach used.

Also, dropped AuthModule.payload() as it's no longer needed (SessionKey thrift 
struct is empty now).


Diffs (updated)
-

  src/main/python/apache/aurora/client/api/scheduler_client.py 
8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
  src/main/python/apache/aurora/client/cli/client.py 
c17f857dd1fd6289e2b3ca8e3f86211ede1344ad 
  src/main/python/apache/aurora/common/auth/auth_module.py 
e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
  src/main/python/apache/aurora/common/auth/auth_module_manager.py 
2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
  src/main/python/apache/aurora/kerberos/auth_module.py 
fade00504a3122bc4b93e1cc1b7ebac6415303da 
  src/test/python/apache/aurora/client/api/test_scheduler_client.py 
1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 
  src/test/python/apache/aurora/client/cli/test_client.py 
49f050cc34e0d07df7b055ac57b561d3c129c0b7 

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


Testing
---

./pants test.pytest --no-fast src/test/python::
./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh

Example error message:
```
...
 INFO] Instances to be killed: [0]
ERROR] INTERNAL: Communication with Aurora scheduler is kerberized. Did you 
forget to run "kinit"?
401 Client Error: Authorization Required
```


Thanks,

Maxim Khutornenko



Re: Review Request 39797: Adding help message in case kerberos auth fails.

2015-11-02 Thread Joshua Cohen


> On Oct. 30, 2015, 2:31 p.m., Joshua Cohen wrote:
> > src/main/python/apache/aurora/client/api/scheduler_client.py, lines 305-306
> > 
> >
> > It seems like this friendly error message is going to get buried at the 
> > top of the stack trace?
> > 
> > The output will be something like...
> > 
> > ERROR] Hey! Run kinit!
> > ERROR] GSS Error: (('Unspecified GSS failure...)
> > ...
> > 20 lines of stacktrace follow
> > ...
> > 
> > I'm not sure if there's any way around that, but it would certainly be 
> > nice to have "run kinit" be the last thing the user sees in the cases of 
> > these failures...
> 
> Maxim Khutornenko wrote:
> The stack is logged by requests-kerberos [1] before we get any chance to 
> react to it. I don't see an easy way to disable that logging without hiding 
> other (possibly important for troubleshooting) requests messages.
> 
> [1] - 
> https://github.com/requests/requests-kerberos/blob/master/requests_kerberos/kerberos_.py#L105-L133
> 
> Bill Farner wrote:
> Can you use the verbose flag and squash the logging when we're not 
> verbose?  This could cause us to lose information in rare non-repeatable 
> scenarios, but i'd be willing to risk that to provide a better experience in 
> normal cases.

+1. I'd be ok with asking users to re-run with --verbose for the rare case if 
it means less support requests for failures to kinit.


- Joshua


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


On Oct. 30, 2015, 2:24 a.m., Maxim Khutornenko wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/39797/
> ---
> 
> (Updated Oct. 30, 2015, 2:24 a.m.)
> 
> 
> Review request for Aurora, Joshua Cohen and Bill Farner.
> 
> 
> Bugs: AURORA-1364
> https://issues.apache.org/jira/browse/AURORA-1364
> 
> 
> Repository: aurora
> 
> 
> Description
> ---
> 
> The only reasonable way to wire it in is via the AuthModule, which is the 
> only entity aware of the auth approach used.
> 
> Also, dropped AuthModule.payload() as it's no longer needed (SessionKey 
> thrift struct is empty now).
> 
> 
> Diffs
> -
> 
>   src/main/python/apache/aurora/client/api/scheduler_client.py 
> 8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
>   src/main/python/apache/aurora/common/auth/auth_module.py 
> e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
>   src/main/python/apache/aurora/common/auth/auth_module_manager.py 
> 2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
>   src/main/python/apache/aurora/kerberos/auth_module.py 
> fade00504a3122bc4b93e1cc1b7ebac6415303da 
>   src/test/python/apache/aurora/client/api/test_scheduler_client.py 
> 1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 
> 
> Diff: https://reviews.apache.org/r/39797/diff/
> 
> 
> Testing
> ---
> 
> ./pants test.pytest --no-fast src/test/python::
> ./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh
> 
> Example error message:
> ```
> ...
> GSSError: ((' Miscellaneous failure (see text)', 851968), ('No credentials 
> cache file found', -1765328189))
> ERROR] Communication with Aurora scheduler is kerberized. Did you forget to 
> run "kinit"?
> 401 Client Error: Authorization Required
> ```
> 
> 
> Thanks,
> 
> Maxim Khutornenko
> 
>



Re: Review Request 39797: Adding help message in case kerberos auth fails.

2015-11-02 Thread Maxim Khutornenko

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

(Updated Nov. 3, 2015, 1:13 a.m.)


Review request for Aurora, Joshua Cohen and Bill Farner.


Changes
---

Hiding requests-kerberos output behind the -v flag.


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


Repository: aurora


Description
---

The only reasonable way to wire it in is via the AuthModule, which is the only 
entity aware of the auth approach used.

Also, dropped AuthModule.payload() as it's no longer needed (SessionKey thrift 
struct is empty now).


Diffs (updated)
-

  src/main/python/apache/aurora/client/api/scheduler_client.py 
8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
  src/main/python/apache/aurora/client/cli/client.py 
c17f857dd1fd6289e2b3ca8e3f86211ede1344ad 
  src/main/python/apache/aurora/common/auth/auth_module.py 
e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
  src/main/python/apache/aurora/common/auth/auth_module_manager.py 
2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
  src/main/python/apache/aurora/kerberos/auth_module.py 
fade00504a3122bc4b93e1cc1b7ebac6415303da 
  src/test/python/apache/aurora/client/api/test_scheduler_client.py 
1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 

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


Testing (updated)
---

./pants test.pytest --no-fast src/test/python::
./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh

Example error message:
```
...
 INFO] Instances to be killed: [0]
ERROR] INTERNAL: Communication with Aurora scheduler is kerberized. Did you 
forget to run "kinit"?
401 Client Error: Authorization Required
```


Thanks,

Maxim Khutornenko



Review Request 39797: Adding help message in case kerberos auth fails.

2015-10-29 Thread Maxim Khutornenko

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

Review request for Aurora, Joshua Cohen and Bill Farner.


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


Repository: aurora


Description
---

The only reasonable way to wire it in is via the AuthModule, which is the only 
entity aware of the auth approach used.

Also, dropped AuthModule.payload() as it's no longer needed (SessionKey thrift 
struct is empty now).


Diffs
-

  src/main/python/apache/aurora/client/api/scheduler_client.py 
8ff21bf64c4a2e6678299439af42e9a0eeacbc7e 
  src/main/python/apache/aurora/common/auth/auth_module.py 
e655cad8fbd3d23e3c44cbc38f6b6462d4781d9b 
  src/main/python/apache/aurora/common/auth/auth_module_manager.py 
2d785e7b274cb3be0b96322bc6b65a3c1ef5dfea 
  src/main/python/apache/aurora/kerberos/auth_module.py 
fade00504a3122bc4b93e1cc1b7ebac6415303da 
  src/test/python/apache/aurora/client/api/test_scheduler_client.py 
1b4ff9cef167de1e4051e6aaa6e4fb6961fd20f1 

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


Testing
---

./pants test.pytest --no-fast src/test/python::
./src/test/sh/org/apache/aurora/e2e/test_end_to_end.sh

Example error message:
```
...
GSSError: ((' Miscellaneous failure (see text)', 851968), ('No credentials 
cache file found', -1765328189))
ERROR] Communication with Aurora scheduler is kerberized. Did you forget to run 
"kinit"?
401 Client Error: Authorization Required
```


Thanks,

Maxim Khutornenko