You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by thzois <gi...@git.apache.org> on 2018/07/10 13:26:39 UTC

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

GitHub user thzois opened a pull request:

    https://github.com/apache/mesos/pull/301

    Document SUPPRESS HTTP call [MESOS-7211]

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/thzois/mesos master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/mesos/pull/301.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #301
    
----
commit 2c9bc7270956c17b055f23b24a24a006748b7725
Author: zois <zo...@...>
Date:   2018-07-10T13:24:37Z

    Document SUPPRESS HTTP call [MESOS-7211]

----


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r204167169
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -479,6 +479,32 @@ HTTP/1.1 202 Accepted
     
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it doesn't need offers for a given set of its roles. When Mesos master receives this request, it will stop sending offers for the given set of roles to the framework. As a special case, if roles are not specified, all subscribed roles of this framework are suppressed.
    +
    +Note that master continues to send offers to other subscribed roles of this framework that are not suppressed. Also, status updates about tasks, executors and agents are not affected by this call and tasks will continue running for `FrameworkInfo.failover_timeout`.
    +
    +If the scheduler wishes to receive offers for the suppressed roles again (e.g., it needs to schedule new workloads), it can send `REVIVE` call.
    +
    +```
    +SUPPRESS Request (JSON):
    +POST /api/v1/scheduler  HTTP/1.1
    +
    +Host: masterhost:5050
    +Content-Type: application/json
    +Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
    +
    +{
    +  "framework_id" : {"value" : "12220-3440-12532-2345"},
    +  "type"         : "SUPPRESS",
    +  "suppress"     : {"role": <one-of-the-subscribed-roles>}
    --- End diff --
    
    This should be `roles` and not `role` since Mesos at least 1.3.0!  And `roles` takes an array of strings (i.e., roles) and not a single role.


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by nfnt <gi...@git.apache.org>.
Github user nfnt commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201402242
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it wants to inform Mesos master to stop sending offers to the framework. When Mesos receives this request it will stop sending offers to framework but the tasks will continue running for `FrameworkInfo.failover_timeout`. Once the framework has work to do, it can send again a `REVIVE` request.
    +
    +```
    +SUPPRESS Request (JSON):
    +POST /api/v1/scheduler  HTTP/1.1
    +
    +Host: masterhost:5050
    +Content-Type: application/json
    +Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
    +
    +{
    +  "framework_id"        : {"value" : "12220-3440-12532-2345"},
    +  "type"                        : "SUPPRESS"
    --- End diff --
    
    Please re-indent. With spaces, even though some other calls in this document use tabs.


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
Github user thzois closed the pull request at:

    https://github.com/apache/mesos/pull/301


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201406612
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it wants to inform Mesos master to stop sending offers to the framework. When Mesos receives this request it will stop sending offers to framework but the tasks will continue running for `FrameworkInfo.failover_timeout`. Once the framework has work to do, it can send again a `REVIVE` request.
    --- End diff --
    
    How about:
    
    Sent by the scheduler when it doesn't need offers for a given set of its roles. When Mesos master receives this request, it will stop sending offers for the given set of roles to the framework. As a special case, if `roles` is not specified, all subscribed roles of this framework are suppressed.
    
    Note that master continues to send offers to other subscribed roles of this framework that are not suppressed. Also, status updates about tasks, executors and agents are not affected by this call. 
    
    If the scheduler wishes to receive offers for the suppressed roles again (e.g., it needs to schedule new workloads), it can send `REVIVE` call.


---

[GitHub] mesos issue #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
Github user thzois commented on the issue:

    https://github.com/apache/mesos/pull/301
  
    Hello, I think that everything is OK now. Can you confirm this? I will also create a new pull request for the "REVIVE" call.


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201406742
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it wants to inform Mesos master to stop sending offers to the framework. When Mesos receives this request it will stop sending offers to framework but the tasks will continue running for `FrameworkInfo.failover_timeout`. Once the framework has work to do, it can send again a `REVIVE` request.
    +
    +```
    +SUPPRESS Request (JSON):
    +POST /api/v1/scheduler  HTTP/1.1
    +
    +Host: masterhost:5050
    +Content-Type: application/json
    +Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
    +
    +{
    +  "framework_id"        : {"value" : "12220-3440-12532-2345"},
    +  "type"                        : "SUPPRESS"
    +}
    --- End diff --
    
    Can you also include `roles` field here for completeness?


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201401610
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    --- End diff --
    
    Can you move this to #500 below #REQUEST section to preserve the call enum order?


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
Github user thzois closed the pull request at:

    https://github.com/apache/mesos/pull/301


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201407700
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it wants to inform Mesos master to stop sending offers to the framework. When Mesos receives this request it will stop sending offers to framework but the tasks will continue running for `FrameworkInfo.failover_timeout`. Once the framework has work to do, it can send again a `REVIVE` request.
    +
    +```
    +SUPPRESS Request (JSON):
    +POST /api/v1/scheduler  HTTP/1.1
    +
    +Host: masterhost:5050
    +Content-Type: application/json
    +Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
    +
    +{
    +  "framework_id"        : {"value" : "12220-3440-12532-2345"},
    +  "type"                        : "SUPPRESS"
    +}
    +
    +SUPPRESS Response:
    +HTTP/1.1 202 Accepted
    +```
    +
    --- End diff --
    
    While you are at it, can you also update the documentation about "REVIVE" call below. I think it's a bit outdated now. Preferably in a different PR.


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
GitHub user thzois reopened a pull request:

    https://github.com/apache/mesos/pull/301

    Document SUPPRESS HTTP call [MESOS-7211]

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/thzois/mesos master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/mesos/pull/301.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #301
    
----
commit 2c9bc7270956c17b055f23b24a24a006748b7725
Author: zois <zo...@...>
Date:   2018-07-10T13:24:37Z

    Document SUPPRESS HTTP call [MESOS-7211]

commit f9725b0c51db2dc49d6437798b798bb1534659e6
Author: Thodoris Zois <zo...@...>
Date:   2018-07-10T23:39:55Z

    Merge branch 'master' of https://github.com/apache/mesos

commit 23c8ec9669549917dc2e4722034446e5b33a9b79
Author: Thodoris Zois <th...@...>
Date:   2018-07-11T00:02:12Z

    Changes to documentation of SUPPRESS HTTP call [MESOS-7211]

----


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
Github user thzois closed the pull request at:

    https://github.com/apache/mesos/pull/301


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/mesos/pull/301


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
GitHub user thzois reopened a pull request:

    https://github.com/apache/mesos/pull/301

    Document SUPPRESS HTTP call [MESOS-7211]

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/thzois/mesos master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/mesos/pull/301.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #301
    
----
commit 5441716bf1d4d3b695574d21f1d50a2b866b0a14
Author: Thodoris Zois <th...@...>
Date:   2018-07-12T13:47:01Z

    Document SUPPRESS HTTP call [MESOS-7211]

----


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by thzois <gi...@git.apache.org>.
GitHub user thzois reopened a pull request:

    https://github.com/apache/mesos/pull/301

    Document SUPPRESS HTTP call [MESOS-7211]

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/thzois/mesos master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/mesos/pull/301.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #301
    
----
commit e4391b6f13ed5a0f333d6dc3bbc5b4ec1fc51cef
Author: Thodoris Zois <th...@...>
Date:   2018-07-12T14:02:12Z

    Document SUPPRESS HTTP call [MESOS-7211]

----


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by vinodkone <gi...@git.apache.org>.
Github user vinodkone commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r204166164
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -479,6 +479,32 @@ HTTP/1.1 202 Accepted
     
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it doesn't need offers for a given set of its roles. When Mesos master receives this request, it will stop sending offers for the given set of roles to the framework. As a special case, if roles are not specified, all subscribed roles of this framework are suppressed.
    +
    +Note that master continues to send offers to other subscribed roles of this framework that are not suppressed. Also, status updates about tasks, executors and agents are not affected by this call and tasks will continue running for `FrameworkInfo.failover_timeout`.
    --- End diff --
    
    I would remove `...and tasks will continue running for `FrameworkInfo.failover_timeout`` part. That timeout doesn't come into play at all during suppression. That will only come into play when a framework disconnects.


---

[GitHub] mesos pull request #301: Document SUPPRESS HTTP call [MESOS-7211]

Posted by nfnt <gi...@git.apache.org>.
Github user nfnt commented on a diff in the pull request:

    https://github.com/apache/mesos/pull/301#discussion_r201402758
  
    --- Diff: docs/scheduler-http-api.md ---
    @@ -128,6 +128,26 @@ TEARDOWN Response:
     HTTP/1.1 202 Accepted
     ```
     
    +### SUPPRESS
    +Sent by the scheduler when it wants to inform Mesos master to stop sending offers to the framework. When Mesos receives this request it will stop sending offers to framework but the tasks will continue running for `FrameworkInfo.failover_timeout`. Once the framework has work to do, it can send again a `REVIVE` request.
    +
    +```
    +SUPPRESS Request (JSON):
    +POST /api/v1/scheduler  HTTP/1.1
    +
    +Host: masterhost:5050
    +Content-Type: application/json
    +Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
    +
    +{
    +  "framework_id"        : {"value" : "12220-3440-12532-2345"},
    +  "type"                        : "SUPPRESS"
    +}
    --- End diff --
    
    The `Supress` call has a `roles` option. Please use an example call that sets a role to suppress offers for.


---