CircleCI-Public/cimg-node

cimg slower than old image

Closed this issue · 2 comments

The new image is twice as slow, mainly due to Time to upload agent and config

Compare https://app.circleci.com/pipelines/github/15five/fifteen5/30221/workflows/1d50e294-90ff-4e99-9e42-76c2da7d4c48/jobs/186258 (old image) with https://app.circleci.com/pipelines/github/15five/fifteen5/30228/workflows/252fd8ae-7cc7-4e63-8bc3-1f00e33e027a/jobs/186289

old: (3 seconds)

Build-agent version 1.0.34446-05905e76 (2020-06-16T11:27:30+0000)
Docker Engine Version: 18.09.6
Kernel Version: Linux f0b56ba200d0 4.15.0-1067-aws #71-Ubuntu SMP Thu Apr 30 13:51:43 UTC 2020 x86_64 Linux
Starting container circleci/node:12
  image is cached as circleci/node:12, but refreshing...
12: Pulling from circleci/node
Digest: sha256:25b032177e0c69947a8a31e91370fd6fea100689e63c4ee011bceecd75589de2
Status: Image is up to date for circleci/node:12
  pull stats: N/A
  time to create container: 562ms
  using image circleci/node@sha256:25b032177e0c69947a8a31e91370fd6fea100689e63c4ee011bceecd75589de2
Time to upload agent and config: 953.114164ms
Time to start containers: 1.544365849s

New: (6 seconds)

Build-agent version 1.0.34446-05905e76 (2020-06-16T11:27:30+0000)
Docker Engine Version: 18.09.6
Kernel Version: Linux 2bebb7165f7d 4.15.0-1067-aws #71-Ubuntu SMP Thu Apr 30 13:51:43 UTC 2020 x86_64 Linux
Starting container cimg/node:12.18
  image is cached as cimg/node:12.18, but refreshing...
12.18: Pulling from cimg/node
Digest: sha256:13a99486762328eefc90bf72f897be133176d1cf1117660e69406b44c441537e
Status: Image is up to date for cimg/node:12.18
  pull stats: N/A
  time to create container: 499ms
  using image cimg/node@sha256:13a99486762328eefc90bf72f897be133176d1cf1117660e69406b44c441537e
Time to upload agent and config: 3.51082595s
Time to start containers: 1.891967343s

I tried re-running the workflow but for some reason the image wasn't cached anymore so I couldn't get a accurate comparison. Maybe this was a one-off speed difference or something.

I suspect this is a random spike in latency on the platform side of things, rather than the Docker image itself. More data points are required to confirm this theory though.

This does look like a platform based spike as the difference is in the Time to upload agent and config portion, rather than any of the actual container creation/spin up itself.

If there are any more examples of this, then it may be worth reaching out to support too so they can check whether this is a platform-based issue or not.

I will go ahead and close this issue for now as there have been no further reports here, but please re-open it if there are any further concerns.