You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Jan Schlicht <ja...@mesosphere.io> on 2017/07/11 12:45:33 UTC
Review Request 60771: Implemented the 'SUBSCRIBE' call in the resource
provider manager.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/
-----------------------------------------------------------
Review request for mesos, Benjamin Bannier and Jie Yu.
Bugs: MESOS-7780
https://issues.apache.org/jira/browse/MESOS-7780
Repository: mesos
Description
-------
Using HTTP, resource providers are expected to subscribe to the resource
provider manager. The resource provider manager will assign a unique ID
to subscribed resource providers and use events to communicate with
them.
Diffs
-----
src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
Diff: https://reviews.apache.org/r/60771/diff/1/
Testing
-------
make check
Thanks,
Jan Schlicht
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Mesos Reviewbot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review180835
-----------------------------------------------------------
Patch looks great!
Reviews applied: [60768, 60769, 60770, 60771]
Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; ./support/docker-build.sh
- Mesos Reviewbot
On July 11, 2017, 2:45 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 11, 2017, 2:45 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/1/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jie Yu <yu...@gmail.com>.
> On July 17, 2017, 9:50 p.m., Jie Yu wrote:
> >
Sorry, I accidentally clicked "publish". I have more comments to come.
- Jie
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review180219
-----------------------------------------------------------
On July 11, 2017, 12:45 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 11, 2017, 12:45 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/1/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jan Schlicht <ja...@mesosphere.io>.
> On July 17, 2017, 11:50 p.m., Jie Yu wrote:
> > src/resource_provider/manager.cpp
> > Lines 134 (patched)
> > <https://reviews.apache.org/r/60771/diff/1/?file=1774138#file1774138line134>
> >
> > Can we use `Owned` pointer here so that you don't need to release them in destructor.
Instead of `Owned` I'm now using `ResourceProvider` instances directly instead of pointers.
- Jan
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review180219
-----------------------------------------------------------
On July 24, 2017, 2:07 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 24, 2017, 2:07 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/2/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review180219
-----------------------------------------------------------
src/resource_provider/manager.cpp
Lines 109 (patched)
<https://reviews.apache.org/r/60771/#comment255272>
2 lines apart
src/resource_provider/manager.cpp
Lines 120 (patched)
<https://reviews.apache.org/r/60771/#comment255271>
2 lines apart.
src/resource_provider/manager.cpp
Lines 134 (patched)
<https://reviews.apache.org/r/60771/#comment255290>
Can we use `Owned` pointer here so that you don't need to release them in destructor.
src/resource_provider/manager.cpp
Lines 147 (patched)
<https://reviews.apache.org/r/60771/#comment255292>
No need for this is ResourceProviderID is UUID
src/resource_provider/manager.cpp
Line 64 (original), 299-305 (patched)
<https://reviews.apache.org/r/60771/#comment255281>
Let's use UUID for resource provider id.
- Jie Yu
On July 11, 2017, 12:45 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 11, 2017, 12:45 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/1/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review180745
-----------------------------------------------------------
src/resource_provider/manager.cpp
Lines 189 (patched)
<https://reviews.apache.org/r/60771/#comment255958>
kill this line
src/resource_provider/manager.cpp
Lines 303 (patched)
<https://reviews.apache.org/r/60771/#comment255969>
`self().id` is not a uuid (unlike the master id).
- Jie Yu
On July 11, 2017, 12:45 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 11, 2017, 12:45 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/1/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Benjamin Bannier <be...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review181218
-----------------------------------------------------------
src/resource_provider/manager.cpp
Lines 224-231 (patched)
<https://reviews.apache.org/r/60771/#comment256704>
Like discussed offline, let's this pull into the `UPDATE` case for now, so that e.g., a `Call` with just `type == UNKNOWN` triggers a `NotImplemented`.
src/tests/resource_provider_http_api_tests.cpp
Line 64 (original), 75 (patched)
<https://reviews.apache.org/r/60771/#comment256702>
I'd suggest we split the testing into two parts. As a unit test we could first test the RP manager w/o involving any agents or master (e.g., by directly `POST`ing a request to `ResourceProviderManager::api`); having a unit test should make sure we do not entable the RP manager with the agent. As a second test we should fix the existing `AgentEndpoint` test to test the now existing data flow from the agent endpoint to the RP manager.
- Benjamin Bannier
On July 24, 2017, 3:24 p.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 24, 2017, 3:24 p.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/3/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/#review181509
-----------------------------------------------------------
Ship it!
Ship It!
- Jie Yu
On July 26, 2017, 9:35 a.m., Jan Schlicht wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60771/
> -----------------------------------------------------------
>
> (Updated July 26, 2017, 9:35 a.m.)
>
>
> Review request for mesos, Benjamin Bannier and Jie Yu.
>
>
> Bugs: MESOS-7780
> https://issues.apache.org/jira/browse/MESOS-7780
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Using HTTP, resource providers are expected to subscribe to the resource
> provider manager. The resource provider manager will assign a unique ID
> to subscribed resource providers and use events to communicate with
> them.
>
>
> Diffs
> -----
>
> src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
> src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
>
>
> Diff: https://reviews.apache.org/r/60771/diff/5/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Jan Schlicht
>
>
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jan Schlicht <ja...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/
-----------------------------------------------------------
(Updated July 26, 2017, 11:35 a.m.)
Review request for mesos, Benjamin Bannier and Jie Yu.
Changes
-------
Re-added the `AgentEndpoint` test case. Added checks for response bodies.
Bugs: MESOS-7780
https://issues.apache.org/jira/browse/MESOS-7780
Repository: mesos
Description
-------
Using HTTP, resource providers are expected to subscribe to the resource
provider manager. The resource provider manager will assign a unique ID
to subscribed resource providers and use events to communicate with
them.
Diffs (updated)
-----
src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
Diff: https://reviews.apache.org/r/60771/diff/5/
Changes: https://reviews.apache.org/r/60771/diff/4-5/
Testing
-------
make check
Thanks,
Jan Schlicht
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jan Schlicht <ja...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/
-----------------------------------------------------------
(Updated July 25, 2017, 4:55 p.m.)
Review request for mesos, Benjamin Bannier and Jie Yu.
Changes
-------
Addressed issues and refactored test cases.
Bugs: MESOS-7780
https://issues.apache.org/jira/browse/MESOS-7780
Repository: mesos
Description
-------
Using HTTP, resource providers are expected to subscribe to the resource
provider manager. The resource provider manager will assign a unique ID
to subscribed resource providers and use events to communicate with
them.
Diffs (updated)
-----
src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
Diff: https://reviews.apache.org/r/60771/diff/4/
Changes: https://reviews.apache.org/r/60771/diff/3-4/
Testing
-------
make check
Thanks,
Jan Schlicht
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jan Schlicht <ja...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/
-----------------------------------------------------------
(Updated July 24, 2017, 3:24 p.m.)
Review request for mesos, Benjamin Bannier and Jie Yu.
Changes
-------
Fixed wrong endpoints in test cases.
Bugs: MESOS-7780
https://issues.apache.org/jira/browse/MESOS-7780
Repository: mesos
Description
-------
Using HTTP, resource providers are expected to subscribe to the resource
provider manager. The resource provider manager will assign a unique ID
to subscribed resource providers and use events to communicate with
them.
Diffs (updated)
-----
src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
Diff: https://reviews.apache.org/r/60771/diff/3/
Changes: https://reviews.apache.org/r/60771/diff/2-3/
Testing
-------
make check
Thanks,
Jan Schlicht
Re: Review Request 60771: Implemented the 'SUBSCRIBE' call in the
resource provider manager.
Posted by Jan Schlicht <ja...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60771/
-----------------------------------------------------------
(Updated July 24, 2017, 2:07 p.m.)
Review request for mesos, Benjamin Bannier and Jie Yu.
Changes
-------
Addressed issues.
Bugs: MESOS-7780
https://issues.apache.org/jira/browse/MESOS-7780
Repository: mesos
Description
-------
Using HTTP, resource providers are expected to subscribe to the resource
provider manager. The resource provider manager will assign a unique ID
to subscribed resource providers and use events to communicate with
them.
Diffs (updated)
-----
src/resource_provider/manager.cpp a9bf258a0896bd519b99a689a0bfab64d665172f
src/tests/resource_provider_http_api_tests.cpp 46a3f37ba046201e9d79e8ba037da2cb37f5c31f
Diff: https://reviews.apache.org/r/60771/diff/2/
Changes: https://reviews.apache.org/r/60771/diff/1-2/
Testing
-------
make check
Thanks,
Jan Schlicht