> On Jan. 19, 2016, 11:29 p.m., Guangya Liu wrote:
> > A unit test also needed, please refer to 
> > https://github.com/apache/mesos/blob/master/src/tests/containerizer/docker_containerizer_tests.cpp#L297
> >  for detail
> 
> Ezra Silvera wrote:
>     Thanks. I'll have a look. We will probably need to add support for 
> "create network" in order to be able to test the created network.

Guangya Liu, I went through the testing functions and I'm not sure we actually 
need to add test for this.  Currently there are 3 possible values that can be 
passed BRIDGE, HOST, NONE. There isn't any test that check the NONE and HOST 
values. In fact there is  not even a functionality test for BRIDGE value but 
simply when creating containers the BRIDGE value is used.
We added a new value "USER" which is identical in terms of code flow to HOST 
and NONE so I'm not sure we should add a special test for USER while all other 
values are not tested.
Further more in order to create a container with USER we will need to create 
the actual user-network on the docker engine - this will require us to add the 
functionality for  "network create" into docker.cpp. This functionality is not 
needed at all for the mesos and will be used only  for this test.
The same is true for port mapping - maybe we had to better clarify it on the 
comments - we didn't change any functionality at all and didn't touch any code 
related to port mapping or network functionality. We are simply passing a new 
value for the  --net parameter to the docker engine, nothing else has changed.
What do you think?


- Ezra


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


On Jan. 20, 2016, 12:25 p.m., Ezra Silvera wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42516/
> -----------------------------------------------------------
> 
> (Updated Jan. 20, 2016, 12:25 p.m.)
> 
> 
> Review request for mesos and TimothyIL TimothyIL.
> 
> 
> Bugs: MESOS-4369
>     https://issues.apache.org/jira/browse/MESOS-4369
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Signed-off-by: Ezra Silvera <e...@il.ibm.com>
> 
> Review: https://reviews.apache.org/r/42549
> 
> 
> Diffs
> -----
> 
>   include/mesos/mesos.proto 0be4bed336e86a5c377e87ac6212c70ac3b4c66b 
>   include/mesos/v1/mesos.proto c3244e87f9351c71312d2eace7a49bcac926fafd 
>   src/docker/docker.cpp 4d2f1fa14f4450b8fa3401081bf52807d2e79a7e 
> 
> Diff: https://reviews.apache.org/r/42516/diff/
> 
> 
> Testing
> -------
> 
> Using Swarm running on Mesos create a network with "docker  network create 
> --driver=bridge myNetwork"   and then create a container on that network:  
> "docker run --net=myNetwork...."
> 
> 
> Thanks,
> 
> Ezra Silvera
> 
>

Reply via email to