mesos icon indicating copy to clipboard operation
mesos copied to clipboard

Return early in fetcher if no uris are specified.

Open carlonelong opened this issue 6 years ago • 2 comments

Change-Id: I9e78b0a9a58e6d84885eae768a5d76e13288c7af

carlonelong avatar May 19 '19 10:05 carlonelong

Hey @carlonelong ,

thanks for contributing!

Your patch looks reasonable to me, however when I ran it through our CI it seemed to break a few unit tests, in particular:

Test Name Duration Age
mesos-ec2-ubuntu-16.04-SSL.Mesos.DockerContainerizerTest.ROOT_DOCKER_UNPRIVILEGED_USER_NonRootSandbox 6 sec 1
mesos-ec2-ubuntu-16.04-SSL.Mesos.MesosContainerizerExecuteTest.ROOT_UNPRIVILEGED_USER_SandboxFileOwnership 0.1 sec 1
mesos-ec2-ubuntu-16.04-SSL.Mesos.MesosContainerizerDestroyTest.DestroyWhileFetching 15 sec 1
mesos-ec2-ubuntu-16.04-SSL.Mesos.ProvisionerDockerTest.ROOT_INTER

(and the same for debian9, centos6/7, ubuntu 14.04, etc.)

I did not have the time to investigate what exactly is causing these tests to fail, but I think this will need to be investigated before we can commit the patch.

Best regards, Benno

lava avatar May 23 '19 16:05 lava

@lava Hi. After reading fetcher.cpp more carefully, I find that the reason these tests failed is that we'll call "chown" in FetcherProcess::run. We may move this part ahead to solve this. But it's not elegant enough.

I also checked MESOS-5218/6843/6217. And I agreed with what Jie Yu said:"The fetcher code is a mess. We should try to clean it up if possible IMO."

I think, FIFO and named pipes used in containerd(between a shim and its container) might be good examples.

carlonelong avatar May 28 '19 09:05 carlonelong