mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Schwartzmeyer <and...@schwartzmeyer.com>
Subject Re: Review Request 63862: Windows: Ported docker_tests.cpp.
Date Fri, 01 Dec 2017 02:26:13 GMT


> On Nov. 16, 2017, 11:25 a.m., Andrew Schwartzmeyer wrote:
> > src/tests/containerizer/docker_tests.cpp
> > Lines 67 (patched)
> > <https://reviews.apache.org/r/63862/diff/1/?file=1893974#file1893974line67>
> >
> >     You could declare a `Seconds(30)` and not have to use  `Seconds(DOCKER_WAIT)`
below.
> >     
> >     It'd be nicer if we didn't have to adjust the timeouts at all...
> 
> Akash Gupta wrote:
>     Hopefully it can be removed when the nanoserver image works since boots up way faster...

Glad it worked out!


> On Nov. 16, 2017, 11:25 a.m., Andrew Schwartzmeyer wrote:
> > src/tests/containerizer/docker_tests.cpp
> > Lines 79-82 (patched)
> > <https://reviews.apache.org/r/63862/diff/1/?file=1893974#file1893974line79>
> >
> >     Is this assumed not fail? I don't know, but if it can fail, we should `CHECK_SOME`
it before `get()`.
> 
> Akash Gupta wrote:
>     It can't fail since validate = false, so it just calls a constructor.

Fair enough.


> On Nov. 16, 2017, 11:25 a.m., Andrew Schwartzmeyer wrote:
> > src/tests/containerizer/docker_tests.cpp
> > Lines 231 (patched)
> > <https://reviews.apache.org/r/63862/diff/1/?file=1893974#file1893974line231>
> >
> >     We're not checking the status code?
> 
> Akash Gupta wrote:
>     On Hyper-V isolation, the status code is -1, which causes the `AWAIT_EXPECT_WEXITSTATUS_EQ`
macro to fail since it thinks that the process failed to start. On process isolation, the
status code is `STATUS_CONTROL_C_EXIT`. So, I just decided to check if there was a status
code, and then rely on `docker ps` to determine if the container actually stopped.

Ah, we should at least comment this in.


> On Nov. 16, 2017, 11:25 a.m., Andrew Schwartzmeyer wrote:
> > src/tests/containerizer/docker_tests.cpp
> > Lines 400 (patched)
> > <https://reviews.apache.org/r/63862/diff/1/?file=1893974#file1893974line400>
> >
> >     Should we maybe do `strings::remove(PREFIX, "/", container.name)` for a safer
test? (Otherwise we're just assuming here that `container.name` will always be prefixed with
a slash.)
> 
> Akash Gupta wrote:
>     `docker inspect` will always have a / in front of the container name. This is because
it's more like a path, so /X means container X on the local machine. So, the output would
actually be wrong if it didn't have the slash prefix. The weird part is that Mesos `docker->ps()`
isn't actually `docker ps`, but more like `docker inspect` on all containers returned by `docker
ps (-a)`, so I check for the slash here.

Gotcha. Let's get it in a comment.


> On Nov. 16, 2017, 11:25 a.m., Andrew Schwartzmeyer wrote:
> > src/tests/containerizer/docker_tests.cpp
> > Lines 611 (patched)
> > <https://reviews.apache.org/r/63862/diff/1/?file=1893974#file1893974line611>
> >
> >     Should we get an actual Windows temp directory instead of `C:\tmp`?
> 
> Akash Gupta wrote:
>     It's just an arbitary path in the container, so the specific place doesn't matter.
The container is going to be deleted anyway at the end of the test.

Gotcha.


- Andrew


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


On Nov. 27, 2017, 9:45 a.m., Akash Gupta wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63862/
> -----------------------------------------------------------
> 
> (Updated Nov. 27, 2017, 9:45 a.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer and John Kordich.
> 
> 
> Bugs: MESOS-7342
>     https://issues.apache.org/jira/browse/MESOS-7342
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Ported the disabled tests to run on Windows. The following tests
> could not be ported due to Windows platform limitations and remain
> diabled:
>   - ROOT_DOCKER_MountRelativeContainerPath (can't mount volumes inside
>     sandbox).
>   - ROOT_DOCKER_NVIDIA_GPU_DeviceAllow (no GPU container support).
>   - ROOT_DOCKER_NVIDIA_GPU_InspectDevices (no GPU container support).
> 
> 
> Diffs
> -----
> 
>   src/tests/containerizer/docker_tests.cpp 5cabf5a0b0164f9923008677c58806c8931cbc8d 
> 
> 
> Diff: https://reviews.apache.org/r/63862/diff/2/
> 
> 
> Testing
> -------
> 
> Windows mesos-test:
> [==========] 754 tests from 77 test cases ran. (270586 ms total)
> [  PASSED  ] 754 tests.
> 
> 
> Windows DockerTest only:
> [==========] 11 tests from 1 test case ran. (85617 ms total)
> [  PASSED  ] 11 tests.
> 
> Linux DockerTest (only 12 tests instead of 14, because I don't have Nvidia GPU):
> [==========] 12 tests from 1 test case ran. (12413 ms total)
> [  PASSED  ] 12 tests.
> 
> 
> Thanks,
> 
> Akash Gupta
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message