You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by timcharper <gi...@git.apache.org> on 2016/07/08 09:06:50 UTC

[GitHub] mesos pull request #133: Output disk resource source information.

GitHub user timcharper opened a pull request:

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

    Output disk resource source information.

    This information is obscured when formatted via `stringify`, leading to confusing error messages such as:
    
    ```
    Task uses more resources
    cpus(*):4; mem(*):4096;     ports(*):[31000-31000]; disk(kafka, kafka)[kafka_0:data]:960679
    than available
    cpus(*):32; mem(*):256819;  ports(*):[31000-32000]; disk(kafka, kafka)[kafka_0:data]:960679;   disk(*):240169;
    ```
    
    (above was formatted and aligned for clarity)
    
    The validation error here is actually complaining that the disk requested didn't have any source information (and therefore defaulted to a root volume), but the available persistent volume was a mount source.


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

    $ git pull https://github.com/vivint-smarthome/mesos 0.28.x

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

    https://github.com/apache/mesos/pull/133.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 #133
    
----
commit bdb533c5de2b44f9dab873b16c3c7e28d53bcca4
Author: Tim Harper <ti...@gmail.com>
Date:   2016-07-08T09:00:32Z

    Output disk resource source information.

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    The travis CI is broken/not-maintained, since we don't (usually) make any code changes via GitHub PRs.  See: http://mesos.apache.org/documentation/latest/submitting-a-patch/
    
    Can you file a JIRA for this change?  We might have to consider backwards compatibility if the resources string changes.  And we'd like that discussion to take place in JIRA.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    Could you please close this PR since there is a review instead now?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos pull request #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133#discussion_r70072622
  
    --- Diff: src/common/resources.cpp ---
    @@ -1475,6 +1475,20 @@ ostream& operator<<(ostream& stream, const Volume& volume)
       return stream;
     }
     
    +ostream& operator<<(ostream& stream, const Resource::DiskInfo::Source& source)
    +{
    +  stream << source.type();
    +
    +  if (source.has_path()) {
    --- End diff --
    
    It looks like the common pattern is to switch on the type. Could you please follow this pattern? You can convert `has_*()` into `CHECK`s.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    Why would we want to back port such change?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    I ran the tests manually and they still pass


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    Not sure why the tests have failed, but @rukletsov - I've updated the PR; it doesn't seem like a good idea to put a `CHECK` call into a string formatter, so I didn't. Do you disagree?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos issue #133: Output disk resource source information.

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

    https://github.com/apache/mesos/pull/133
  
    I've followed the instructions and the JIRA issue is here: https://issues.apache.org/jira/browse/MESOS-5824


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] mesos pull request #133: Output disk resource source information.

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

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


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---