You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by qi...@apache.org on 2019/08/06 02:37:40 UTC

[mesos] branch 1.8.x updated (6ecaa51 -> 0a73465)

This is an automated email from the ASF dual-hosted git repository.

qianzhang pushed a change to branch 1.8.x
in repository https://gitbox.apache.org/repos/asf/mesos.git.


    from 6ecaa51  Update version numbers and CHANGELOG after 1.8.1 release.
     new de8e872  Looked up parent's IP for the non-checkpointed nested containers.
     new 0a73465  Added MESOS-9868 to the 1.8.2 CHANGELOG.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 CHANGELOG                                             |  1 +
 .../containerizer/mesos/isolators/network/cni/cni.cpp | 19 +++++++++++++++++--
 2 files changed, 18 insertions(+), 2 deletions(-)


[mesos] 01/02: Looked up parent's IP for the non-checkpointed nested containers.

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qianzhang pushed a commit to branch 1.8.x
in repository https://gitbox.apache.org/repos/asf/mesos.git

commit de8e872ac464189fc3b6df4ff3313432342ef081
Author: Qian Zhang <zh...@gmail.com>
AuthorDate: Sat Jul 27 15:34:23 2019 +0800

    Looked up parent's IP for the non-checkpointed nested containers.
    
    Review: https://reviews.apache.org/r/71172
---
 .../containerizer/mesos/isolators/network/cni/cni.cpp | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff --git a/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp b/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
index d941ee7..0975e51 100644
--- a/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
+++ b/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
@@ -1437,12 +1437,29 @@ Future<Nothing> NetworkCniIsolatorProcess::_attach(
 Future<ContainerStatus> NetworkCniIsolatorProcess::status(
     const ContainerID& containerId)
 {
+  const bool isNestedContainer = containerId.has_parent();
+
   // TODO(jieyu): We don't create 'Info' struct for containers that
   // want to join the host network and have no image. Currently, we
   // rely on the slave/containerizer to set the IP addresses in
   // ContainerStatus.  Consider returning the IP address of the slave
   // here.
   if (!infos.contains(containerId)) {
+    if (isNestedContainer) {
+      // There are two cases that `infos` does not contain a nested container:
+      //   1. The nested container has no image and joins host network (i.e.,
+      //      it does not specify `NetworkInfo.name` and its parent joins host
+      //      network). In this case, we do not create `Info` struct for this
+      //      nested container.
+      //   2. The nested container joins the CNI network that its parent joins,
+      //      and then agent is restarted. After recovery `infos` will not
+      //      contain the nested container since we do not checkpoint it in the
+      //      runtime directory.
+      // For both of these two cases, to obtain the network info of the nested
+      // container, we should look up its parent.
+      return status(containerId.parent());
+    }
+
     return ContainerStatus();
   }
 
@@ -1450,8 +1467,6 @@ Future<ContainerStatus> NetworkCniIsolatorProcess::status(
   // wants to joins the parent's network, we should look up the IP
   // address of the root container of the hierarchy to which this
   // container belongs.
-  const bool isNestedContainer = containerId.has_parent();
-
   if (isNestedContainer && infos[containerId]->joinsParentsNetwork) {
     return status(containerId.parent());
   }


[mesos] 02/02: Added MESOS-9868 to the 1.8.2 CHANGELOG.

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qianzhang pushed a commit to branch 1.8.x
in repository https://gitbox.apache.org/repos/asf/mesos.git

commit 0a7346530e663443b861bef39eb19d2ac475e835
Author: Qian Zhang <zh...@gmail.com>
AuthorDate: Tue Aug 6 10:20:36 2019 +0800

    Added MESOS-9868 to the 1.8.2 CHANGELOG.
---
 CHANGELOG | 1 +
 1 file changed, 1 insertion(+)

diff --git a/CHANGELOG b/CHANGELOG
index 248e382..a2c2000 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -4,6 +4,7 @@ Release Notes - Mesos - Version 1.8.2 (WIP)
 
 ** Bug
   * [MESOS-9785] - Frameworks recovered from reregistered agents are not reported to master `/api/v1` subscribers.
+  * [MESOS-9868] - NetworkInfo from the agent /state endpoint is not correct.
 
 
 Release Notes - Mesos - Version 1.8.1