You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Benjamin Bannier <be...@mesosphere.io> on 2017/12/08 00:17:34 UTC

Review Request 64430: Only passed agent's resource version in top-level UpdateSlaveMessage.

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

Review request for mesos, Jie Yu and Jan Schlicht.


Bugs: MESOS-8312
    https://issues.apache.org/jira/browse/MESOS-8312


Repository: mesos


Description
-------

Since we have moved all resource provider-related information like
e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
we now only pass agent information in top-level fields.

To model that we changed the top-level resource versions there from a
repeated field to a single optional field. This will allow us to in
the future pass agent information in the resource provider data
structure as well.


Diffs
-----

  src/master/master.cpp 1d192db8edd36dac99ebecd17edd9a4df53a416e 
  src/messages/messages.proto 7ab07d7a78210f4a6f418458b1484d9301710dd3 
  src/slave/slave.cpp fb077b7a979ebf6b406cd711642dd05f8749f2d0 
  src/tests/slave_tests.cpp 25cfd4730c3d77d1886745204b13ca3cb140620c 


Diff: https://reviews.apache.org/r/64430/diff/1/


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 64430: Only passed agent's resource version in top-level 'UpdateSlaveMessage'.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Dec. 8, 2017, 6:15 a.m., Jie Yu wrote:
> > Let's also follow up with the change to remove `ResourcesCategory`

I posted https://reviews.apache.org/r/64445/ to address this in isolation and on top of the changes here.


- Benjamin


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


On Dec. 8, 2017, 12:32 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/64430/
> -----------------------------------------------------------
> 
> (Updated Dec. 8, 2017, 12:32 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8312
>     https://issues.apache.org/jira/browse/MESOS-8312
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since we have moved all resource provider-related information like
> e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
> we now only pass agent information in top-level fields.
> 
> To model that we changed the top-level resource versions there from a
> repeated field to a single optional field. This will allow us to in
> the future pass agent information in the resource provider data
> structure as well.
> 
> 
> Diffs
> -----
> 
>   src/master/master.cpp 5cba50636a9351d29660c54fad7734fcfea547b9 
>   src/messages/messages.proto f71178438660fa16aad8f290391baba7813fbff0 
>   src/slave/slave.cpp 54d8bcc035227dd6896ffa6e692a91749c0b56a6 
>   src/tests/slave_tests.cpp 07145432c35c85a755b66ba575c2a46db072ce5c 
> 
> 
> Diff: https://reviews.apache.org/r/64430/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 64430: Only passed agent's resource version in top-level UpdateSlaveMessage.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/64430/#review193219
-----------------------------------------------------------



Let's also follow up with the change to remove `ResourcesCategory`

- Jie Yu


On Dec. 8, 2017, 12:17 a.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/64430/
> -----------------------------------------------------------
> 
> (Updated Dec. 8, 2017, 12:17 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8312
>     https://issues.apache.org/jira/browse/MESOS-8312
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since we have moved all resource provider-related information like
> e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
> we now only pass agent information in top-level fields.
> 
> To model that we changed the top-level resource versions there from a
> repeated field to a single optional field. This will allow us to in
> the future pass agent information in the resource provider data
> structure as well.
> 
> 
> Diffs
> -----
> 
>   src/master/master.cpp 1d192db8edd36dac99ebecd17edd9a4df53a416e 
>   src/messages/messages.proto 7ab07d7a78210f4a6f418458b1484d9301710dd3 
>   src/slave/slave.cpp fb077b7a979ebf6b406cd711642dd05f8749f2d0 
>   src/tests/slave_tests.cpp 25cfd4730c3d77d1886745204b13ca3cb140620c 
> 
> 
> Diff: https://reviews.apache.org/r/64430/diff/1/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 64430: Only passed agent's resource version in top-level 'UpdateSlaveMessage'.

Posted by Mesos Reviewbot Windows <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/64430/#review193245
-----------------------------------------------------------



FAIL: Some Mesos libprocess-tests failed.

Reviews applied: `['64422', '64423', '64424', '64430']`

Failed command: `C:\DCOS\mesos\3rdparty\libprocess\src\tests\Debug\libprocess-tests.exe`

All the build artifacts available at: http://dcos-win.westus.cloudapp.azure.com/mesos-build/review/64430

Relevant logs:

- [libprocess-tests-stdout.log](http://dcos-win.westus.cloudapp.azure.com/mesos-build/review/64430/logs/libprocess-tests-stdout.log):

```
C:\DCOS\mesos\mesos\3rdparty\libprocess\src\tests\ssl_tests.cpp(440): error: Failed to wait 15secs for socket
[  FAILED  ] SSLVerifyIPAdd/SSLTest.RequireCertificate/0, where GetParam() = "false" (16525 ms)
[ RUN      ] SSLVerifyIPAdd/SSLTest.RequireCertificate/1
C:\DCOS\mesos\mesos\3rdparty\libprocess\src\tests\ssl_tests.cpp(440): error: Failed to wait 15secs for socket
[  FAILED  ] SSLVerifyIPAdd/SSLTest.RequireCertificate/1, where GetParam() = "true" (16735 ms)
[----------] 4 tests from SSLVerifyIPAdd/SSLTest (33932 ms total)

[----------] Global test environment tear-down
[==========] 223 tests from 35 test cases ran. (262051 ms total)
[  PASSED  ] 209 tests.
[  FAILED  ] 14 tests, listed below:
[  FAILED  ] SSLTest.SSLSocket
[  FAILED  ] SSLTest.NonSSLSocket
[  FAILED  ] SSLTest.NoVerifyBadCA
[  FAILED  ] SSLTest.RequireBadCA
[  FAILED  ] SSLTest.VerifyBadCA
[  FAILED  ] SSLTest.VerifyCertificate
[  FAILED  ] SSLTest.ProtocolMismatch
[  FAILED  ] SSLTest.ECDHESupport
[  FAILED  ] SSLTest.ValidDowngrade
[  FAILED  ] SSLTest.NoValidDowngrade
[  FAILED  ] SSLTest.ValidDowngradeEachProtocol
[  FAILED  ] SSLTest.NoValidDowngradeEachProtocol
[  FAILED  ] SSLVerifyIPAdd/SSLTest.RequireCertificate/0, where GetParam() = "false"
[  FAILED  ] SSLVerifyIPAdd/SSLTest.RequireCertificate/1, where GetParam() = "true"

14 FAILED TESTS
  YOU HAVE 19 DISABLED TESTS

```

- [libprocess-tests-stderr.log](http://dcos-win.westus.cloudapp.azure.com/mesos-build/review/64430/logs/libprocess-tests-stderr.log):

```
I1208 12:34:23.694483  5020 process.cpp:887] Failed to accept socket: future discarded
I1208 12:34:23.893543  6648 process.cpp:887] Failed to accept socket: future discarded
I1208 12:34:24.186502  4348 openssl.cpp:514] Will not verify peer certificate!
NOTE: Set LIBPROCESS_SSL_VERIFY_CERT=1 to enable peer certificate verification
I1208 12:34:24.186502  4348 openssl.cpp:534] LIBPROCESS_SSL_REQUIRE_CERT implies peer certificate verification.
LIBPROCESS_SSL_VERIFY_CERT set to true
I1208 12:34:24.187503  4348 openssl.cpp:563] Using CA file: C:\Users\mesos\AppData\Local\Temp\oaG1iU\cert.pem
I1208 12:34:24.187503  4348 openssl.cpp:566] Using CA dir: C:\Users\mesos\AppData\Local\Temp\oaG1iU
I1208 12:34:24.557680  4348 openssl.cpp:514] Will not verify peer certificate!
NOTE: Set LIBPROCESS_SSL_VERIFY_CERT=1 to enable peer certificate verification
I1208 12:34:24.557680  4348 openssl.cpp:526] Will use IP address verification in subject alternative name certificate extension.
I1208 12:34:24.557680  4348 openssl.cpp:534] LIBPROCESS_SSL_REQUIRE_CERT implies peer certificate verification.
LIBPROCESS_SSL_VERIFY_CERT set to true
I1208 12:34:24.578687  4348 openssl.cpp:563] Using CA file: C:\Users\mesos\AppData\Local\Temp\ObYk7N\cert.pem
I1208 12:34:24.578687  4348 openssl.cpp:566] Using CA dir: C:\Users\mesos\AppData\Local\Temp\ObYk7N
I1208 12:34:25.131894  4348 openssl.cpp:509] CA directory path unspecified! NOTE: Set CA directory path with LIBPROCESS_SSL_CA_DIR=<dirpath>
I1208 12:34:25.131894  4348 openssl.cpp:514] Will not verify peer certificate!
NOTE: Set LIBPROCESS_SSL_VERIFY_CERT=1 to enable peer certificate verification
I1208 12:34:25.131894  4348 openssl.cpp:534] LIBPROCESS_SSL_REQUIRE_CERT implies peer certificate verification.
LIBPROCESS_SSL_VERIFY_CERT set to true
I1208 12:34:25.131894  4348 openssl.cpp:563] Using CA file: C:\Users\mesos\AppData\Local\Temp\qr162j\cert.pem
I1208 12:34:41.873987  4348 openssl.cpp:509] CA directory path unspecified! NOTE: Set CA directory path with LIBPROCESS_SSL_CA_DIR=<dirpath>
I1208 12:34:41.874980  4348 openssl.cpp:514] Will not verify peer certificate!
NOTE: Set LIBPROCESS_SSL_VERIFY_CERT=1 to enable peer certificate verification
I1208 12:34:41.874980  4348 openssl.cpp:526] Will use IP address verification in subject alternative name certificate extension.
I1208 12:34:41.874980  4348 openssl.cpp:534] LIBPROCESS_SSL_REQUIRE_CERT implies peer certificate verification.
LIBPROCESS_SSL_VERIFY_CERT set to true
I1208 12:34:41.874980  4348 openssl.cpp:563] Using CA file: C:\Users\mesos\AppData\Local\Temp\jo9VgC\cert.pem
I1208 12:34:57.975925  9332 process.cpp:887] Failed to accept socket: future discarded
```

- Mesos Reviewbot Windows


On Dec. 8, 2017, 11:32 a.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/64430/
> -----------------------------------------------------------
> 
> (Updated Dec. 8, 2017, 11:32 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8312
>     https://issues.apache.org/jira/browse/MESOS-8312
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since we have moved all resource provider-related information like
> e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
> we now only pass agent information in top-level fields.
> 
> To model that we changed the top-level resource versions there from a
> repeated field to a single optional field. This will allow us to in
> the future pass agent information in the resource provider data
> structure as well.
> 
> 
> Diffs
> -----
> 
>   src/master/master.cpp 5cba50636a9351d29660c54fad7734fcfea547b9 
>   src/messages/messages.proto f71178438660fa16aad8f290391baba7813fbff0 
>   src/slave/slave.cpp 54d8bcc035227dd6896ffa6e692a91749c0b56a6 
>   src/tests/slave_tests.cpp 07145432c35c85a755b66ba575c2a46db072ce5c 
> 
> 
> Diff: https://reviews.apache.org/r/64430/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 64430: Only passed agent's resource version in top-level 'UpdateSlaveMessage'.

Posted by Benjamin Bannier <be...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/64430/
-----------------------------------------------------------

(Updated Dec. 8, 2017, 12:32 p.m.)


Review request for mesos, Jie Yu and Jan Schlicht.


Changes
-------

Rebased.


Summary (updated)
-----------------

Only passed agent's resource version in top-level 'UpdateSlaveMessage'.


Bugs: MESOS-8312
    https://issues.apache.org/jira/browse/MESOS-8312


Repository: mesos


Description
-------

Since we have moved all resource provider-related information like
e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
we now only pass agent information in top-level fields.

To model that we changed the top-level resource versions there from a
repeated field to a single optional field. This will allow us to in
the future pass agent information in the resource provider data
structure as well.


Diffs (updated)
-----

  src/master/master.cpp 5cba50636a9351d29660c54fad7734fcfea547b9 
  src/messages/messages.proto f71178438660fa16aad8f290391baba7813fbff0 
  src/slave/slave.cpp 54d8bcc035227dd6896ffa6e692a91749c0b56a6 
  src/tests/slave_tests.cpp 07145432c35c85a755b66ba575c2a46db072ce5c 


Diff: https://reviews.apache.org/r/64430/diff/2/

Changes: https://reviews.apache.org/r/64430/diff/1-2/


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 64430: Only passed agent's resource version in top-level 'UpdateSlaveMessage'.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Dec. 8, 2017, 6:15 a.m., Jie Yu wrote:
> > src/master/master.cpp
> > Line 7193 (original), 7193 (patched)
> > <https://reviews.apache.org/r/64430/diff/1/?file=1910897#file1910897line7193>
> >
> >     Do we still need this?

I removed this as part of https://reviews.apache.org/r/64424.


> On Dec. 8, 2017, 6:15 a.m., Jie Yu wrote:
> > src/master/master.cpp
> > Line 7274 (original), 7281 (patched)
> > <https://reviews.apache.org/r/64430/diff/1/?file=1910897#file1910897line7281>
> >
> >     This needs to be adjusted? `slave->offerOperations` has all the operations from all providers as well as agent default resources, while message.offer_operations is only for agent default resources?

Good catch, I fixed this as part of https://reviews.apache.org/r/64423 by removing this variable initialization and unconditionally calculating the lists of operations.


- Benjamin


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


On Dec. 8, 2017, 12:32 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/64430/
> -----------------------------------------------------------
> 
> (Updated Dec. 8, 2017, 12:32 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8312
>     https://issues.apache.org/jira/browse/MESOS-8312
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since we have moved all resource provider-related information like
> e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
> we now only pass agent information in top-level fields.
> 
> To model that we changed the top-level resource versions there from a
> repeated field to a single optional field. This will allow us to in
> the future pass agent information in the resource provider data
> structure as well.
> 
> 
> Diffs
> -----
> 
>   src/master/master.cpp 5cba50636a9351d29660c54fad7734fcfea547b9 
>   src/messages/messages.proto f71178438660fa16aad8f290391baba7813fbff0 
>   src/slave/slave.cpp 54d8bcc035227dd6896ffa6e692a91749c0b56a6 
>   src/tests/slave_tests.cpp 07145432c35c85a755b66ba575c2a46db072ce5c 
> 
> 
> Diff: https://reviews.apache.org/r/64430/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 64430: Only passed agent's resource version in top-level UpdateSlaveMessage.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/64430/#review193216
-----------------------------------------------------------


Fix it, then Ship it!





src/master/master.cpp
Line 7193 (original), 7193 (patched)
<https://reviews.apache.org/r/64430/#comment271780>

    Do we still need this?



src/master/master.cpp
Line 7274 (original), 7281 (patched)
<https://reviews.apache.org/r/64430/#comment271781>

    This needs to be adjusted? `slave->offerOperations` has all the operations from all providers as well as agent default resources, while message.offer_operations is only for agent default resources?


- Jie Yu


On Dec. 8, 2017, 12:17 a.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/64430/
> -----------------------------------------------------------
> 
> (Updated Dec. 8, 2017, 12:17 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8312
>     https://issues.apache.org/jira/browse/MESOS-8312
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since we have moved all resource provider-related information like
> e.g., resource versions to an explicit field in 'UpdateSlaveMessage',
> we now only pass agent information in top-level fields.
> 
> To model that we changed the top-level resource versions there from a
> repeated field to a single optional field. This will allow us to in
> the future pass agent information in the resource provider data
> structure as well.
> 
> 
> Diffs
> -----
> 
>   src/master/master.cpp 1d192db8edd36dac99ebecd17edd9a4df53a416e 
>   src/messages/messages.proto 7ab07d7a78210f4a6f418458b1484d9301710dd3 
>   src/slave/slave.cpp fb077b7a979ebf6b406cd711642dd05f8749f2d0 
>   src/tests/slave_tests.cpp 25cfd4730c3d77d1886745204b13ca3cb140620c 
> 
> 
> Diff: https://reviews.apache.org/r/64430/diff/1/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>