You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by James Peach <jp...@apache.org> on 2017/08/09 20:19:26 UTC

Re: Review Request 60495: Added network ports isolator listen socket utilities.

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

(Updated Aug. 9, 2017, 8:19 p.m.)


Review request for mesos, Qian Zhang and Jiang Yan Xu.


Changes
-------

Rebased and addressed review feedback.


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

Added network ports isolator listen socket utilities.


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


Repository: mesos


Description
-------

Implemented network ports isolator socket utilities to find the
inode numbers of all the listening sockets, and the inodes of the
open sockets for a process. Together, these utilities can tell us
which sockets a process is listening on.


Diffs (updated)
-----

  src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 


Diff: https://reviews.apache.org/r/60495/diff/8/

Changes: https://reviews.apache.org/r/60495/diff/7-8/


Testing
-------

make check (Fedora 26)


Thanks,

James Peach


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review182665
-----------------------------------------------------------




src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 181 (patched)
<https://reviews.apache.org/r/60495/#comment258643>

    Remove this blank line.



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 183 (patched)
<https://reviews.apache.org/r/60495/#comment258644>

    Add a newline before.


- Qian Zhang


On Aug. 10, 2017, 4:19 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Aug. 10, 2017, 4:19 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/8/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review184478
-----------------------------------------------------------




src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 118-119 (patched)
<https://reviews.apache.org/r/60495/#comment260627>

    A newline between.



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 120-124 (patched)
<https://reviews.apache.org/r/60495/#comment260632>

    Better to change to:
    ```
        Error error = ErrnoError("Failed to read symbolic link '" + path::join(fdPath, entry->d_name) + "'"");
        closedir(dir);
        return error;
    ```



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 124 (patched)
<https://reviews.apache.org/r/60495/#comment260629>

    s/link/symbolic link/



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 133 (patched)
<https://reviews.apache.org/r/60495/#comment260630>

    I think here we need to add some code to handle the case that `readdir()` fails (i.e., it returns `nullptr`).



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 134 (patched)
<https://reviews.apache.org/r/60495/#comment260631>

    We need to check if `closedir()` succeeds or not.


- Qian Zhang


On Aug. 15, 2017, 7:40 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Aug. 15, 2017, 7:40 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/13/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review184508
-----------------------------------------------------------




src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 96 (patched)
<https://reviews.apache.org/r/60495/#comment260672>

    s/gived/given/


- Qian Zhang


On Aug. 15, 2017, 7:40 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Aug. 15, 2017, 7:40 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/13/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.

> On Sept. 19, 2017, 2:18 a.m., Qian Zhang wrote:
> > src/slave/containerizer/mesos/isolators/network/ports.cpp
> > Line 112 (original), 112-117 (patched)
> > <https://reviews.apache.org/r/60495/diff/15-16/?file=1818171#file1818171line112>
> >
> >     Can we change this to `while ((entry = readdir(dir)) != nullptr) {` and do `errno = 0` in the end of the while loop? There is already a `errno = 0` (line 106) right before the while loop, so I think we may not need to do it again at the beginning of the loop, instead it would be better to do it in the end of the loop.

I removed the extraneous `errno` write, and pulled the code that checks for `readdir` failure up into the loop so the error checking happens near the call site.


- James


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


On Sept. 19, 2017, 12:19 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 19, 2017, 12:19 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/16/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review185635
-----------------------------------------------------------




src/slave/containerizer/mesos/isolators/network/ports.cpp
Line 112 (original), 112-117 (patched)
<https://reviews.apache.org/r/60495/#comment261948>

    Can we change this to `while ((entry = readdir(dir)) != nullptr) {` and do `errno = 0` in the end of the while loop? There is already a `errno = 0` (line 106) right before the while loop, so I think we may not need to do it again at the beginning of the loop, instead it would be better to do it in the end of the loop.


- Qian Zhang


On Sept. 19, 2017, 8:19 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 19, 2017, 8:19 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/16/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review185769
-----------------------------------------------------------


Ship it!




Ship It!

- Qian Zhang


On Sept. 20, 2017, 12:29 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 20, 2017, 12:29 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/18/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/
-----------------------------------------------------------

(Updated Sept. 19, 2017, 4:29 p.m.)


Review request for mesos, Qian Zhang and Jiang Yan Xu.


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


Repository: mesos


Description
-------

Implemented network ports isolator socket utilities to find the
inode numbers of all the listening sockets, and the inodes of the
open sockets for a process. Together, these utilities can tell us
which sockets a process is listening on.


Diffs (updated)
-----

  src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 


Diff: https://reviews.apache.org/r/60495/diff/17/

Changes: https://reviews.apache.org/r/60495/diff/16-17/


Testing
-------

make check (Fedora 26)


Thanks,

James Peach


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/
-----------------------------------------------------------

(Updated Sept. 19, 2017, 12:19 a.m.)


Review request for mesos, Qian Zhang and Jiang Yan Xu.


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


Repository: mesos


Description
-------

Implemented network ports isolator socket utilities to find the
inode numbers of all the listening sockets, and the inodes of the
open sockets for a process. Together, these utilities can tell us
which sockets a process is listening on.


Diffs (updated)
-----

  src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 


Diff: https://reviews.apache.org/r/60495/diff/16/

Changes: https://reviews.apache.org/r/60495/diff/15-16/


Testing
-------

make check (Fedora 26)


Thanks,

James Peach


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.

> On Sept. 8, 2017, 7:43 a.m., Qian Zhang wrote:
> > src/slave/containerizer/mesos/isolators/network/ports.cpp
> > Line 112 (original), 112 (patched)
> > <https://reviews.apache.org/r/60495/diff/13-15/?file=1808218#file1808218line112>
> >
> >     Why do we need a `for` loop like this? I think the previous `while` loop is good enough.

If we want to depend on `errno`, we need to guarantee that it is `0` before we call the `readddir`. Since there is non-trivial logic inside the loop, it is difficult to be confident that nothing we call is going to change it, particularly if this code is ever updated.


> On Sept. 8, 2017, 7:43 a.m., Qian Zhang wrote:
> > src/slave/containerizer/mesos/isolators/network/ports.cpp
> > Line 124 (original), 125 (patched)
> > <https://reviews.apache.org/r/60495/diff/13-15/?file=1808218#file1808218line125>
> >
> >     This seems too strict, since here we are already going to return an error out, I think we can simply ignore the error of `closedir()`.

The only way `closedir` can fail is if we give it a bad pointer, so if we check this I think `CHECK` is appropriate. I don't understand the rationale of wanting to check the `readdir` but not the `closedir` since the error conditions for these are identical.


> On Sept. 8, 2017, 7:43 a.m., Qian Zhang wrote:
> > src/slave/containerizer/mesos/isolators/network/ports.cpp
> > Lines 144 (patched)
> > <https://reviews.apache.org/r/60495/diff/13-15/?file=1808218#file1808218line144>
> >
> >     Better to change this to:
> >     ```
> >       if (closedir(dir) == -1) {
> >         return ErrnoError("Failed to close directory '" + fdPath + "'");
> >       }
> >     ```
> >     This is also aligned with how you handle the error of `opendir()` in the above.

I don't understand why we want to check the error return for this one but not the others. Since the `closedir` can't fail, IMHO we should just either assert or ignore it consistently.


- James


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


On Sept. 7, 2017, 9:50 p.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 7, 2017, 9:50 p.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/15/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.

> On Sept. 8, 2017, 3:43 p.m., Qian Zhang wrote:
> > src/slave/containerizer/mesos/isolators/network/ports.cpp
> > Line 112 (original), 112 (patched)
> > <https://reviews.apache.org/r/60495/diff/13-15/?file=1808218#file1808218line112>
> >
> >     Why do we need a `for` loop like this? I think the previous `while` loop is good enough.
> 
> James Peach wrote:
>     If we want to depend on `errno`, we need to guarantee that it is `0` before we call the `readddir`. Since there is non-trivial logic inside the loop, it is difficult to be confident that nothing we call is going to change it, particularly if this code is ever updated.

OK, then what about a `while` loop and setting `errno` to 0 in the end of each iteration? Setting `errno` to 0 in the `for` loop seems a bit strange to me.


- Qian


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


On Sept. 8, 2017, 5:50 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 8, 2017, 5:50 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/15/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/#review184953
-----------------------------------------------------------




src/slave/containerizer/mesos/isolators/network/ports.cpp
Line 112 (original), 112 (patched)
<https://reviews.apache.org/r/60495/#comment261177>

    Why do we need a `for` loop like this? I think the previous `while` loop is good enough.



src/slave/containerizer/mesos/isolators/network/ports.cpp
Line 124 (original), 125 (patched)
<https://reviews.apache.org/r/60495/#comment261178>

    This seems too strict, since here we are already going to return an error out, I think we can simply ignore the error of `closedir()`.



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 140 (patched)
<https://reviews.apache.org/r/60495/#comment261179>

    Ditto.



src/slave/containerizer/mesos/isolators/network/ports.cpp
Lines 144 (patched)
<https://reviews.apache.org/r/60495/#comment261180>

    Better to change this to:
    ```
      if (closedir(dir) == -1) {
        return ErrnoError("Failed to close directory '" + fdPath + "'");
      }
    ```
    This is also aligned with how you handle the error of `opendir()` in the above.


- Qian Zhang


On Sept. 8, 2017, 5:50 a.m., James Peach wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60495/
> -----------------------------------------------------------
> 
> (Updated Sept. 8, 2017, 5:50 a.m.)
> 
> 
> Review request for mesos, Qian Zhang and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-7675
>     https://issues.apache.org/jira/browse/MESOS-7675
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented network ports isolator socket utilities to find the
> inode numbers of all the listening sockets, and the inodes of the
> open sockets for a process. Together, these utilities can tell us
> which sockets a process is listening on.
> 
> 
> Diffs
> -----
> 
>   src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 
> 
> 
> Diff: https://reviews.apache.org/r/60495/diff/15/
> 
> 
> Testing
> -------
> 
> make check (Fedora 26)
> 
> 
> Thanks,
> 
> James Peach
> 
>


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/
-----------------------------------------------------------

(Updated Sept. 7, 2017, 9:50 p.m.)


Review request for mesos, Qian Zhang and Jiang Yan Xu.


Changes
-------

Addressed review feedback.


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


Repository: mesos


Description
-------

Implemented network ports isolator socket utilities to find the
inode numbers of all the listening sockets, and the inodes of the
open sockets for a process. Together, these utilities can tell us
which sockets a process is listening on.


Diffs (updated)
-----

  src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 


Diff: https://reviews.apache.org/r/60495/diff/14/

Changes: https://reviews.apache.org/r/60495/diff/13-14/


Testing
-------

make check (Fedora 26)


Thanks,

James Peach


Re: Review Request 60495: Added network ports isolator listen socket utilities.

Posted by James Peach <jp...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60495/
-----------------------------------------------------------

(Updated Aug. 14, 2017, 11:40 p.m.)


Review request for mesos, Qian Zhang and Jiang Yan Xu.


Changes
-------

Rebased and addressed review feedback.


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


Repository: mesos


Description
-------

Implemented network ports isolator socket utilities to find the
inode numbers of all the listening sockets, and the inodes of the
open sockets for a process. Together, these utilities can tell us
which sockets a process is listening on.


Diffs (updated)
-----

  src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION 


Diff: https://reviews.apache.org/r/60495/diff/9/

Changes: https://reviews.apache.org/r/60495/diff/8-9/


Testing
-------

make check (Fedora 26)


Thanks,

James Peach