Jobs sometimes do not attempt to download artifacts
<!--IssueSummary start--> <details> <summary> Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards. </summary> - [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=364561) </details> <!--IssueSummary end--> ### Summary We see pipelines where jobs that depend on other jobs do not always attempt to grab artifacts when their depends jobs have artifacts. Retries of those failing jobs will attempt to grab artifacts. Perhaps related, but we've seen an alarming number of failures to get artifacts when attempted and when pulling from the registry to setup ephemeral runners. Our GitLab instance is four omnibus instances behind a load balancer. Similarly, we have four runner instances that use docker-machine to create our ephemeral runners. I don't seeing the artifacts issues before we upgraded to 14.10.3. ### Steps to reproduce There's no consistent way to do it. It happens sporadically. The jobs I've seen fail are in child pipelines depending on artifacts of the parent pipeline, but that's about 99% of all our relationships, so I'm not certain it is tied to that. ### Example Project None ### What is the current *bug* behavior? No artifact download is attempted. ``` Fetching changes... Reinitialized existing Git repository in {path} Checking out {git SHA} as master... Skipping Git submodules setup Executing "step_script" stage of the job script Using docker image {SHA} for {image name} with digest {digest} ... ``` Potentially related, we sometimes get 404s that succeed on retries: ``` ERROR: Downloading artifacts from coordinator... not found id={id} responseStatus=404 Not Found token={token} ``` ### What is the expected *correct* behavior? On retries, we see it attempt to download the artifacts: ``` Fetching changes... Reinitialized existing Git repository in {path} Checking out {git SHA} as master... Skipping Git submodules setup Downloading artifacts Using docker image {SHA} for {image name} with digest {digest} ... Downloading artifacts for {job name} ({job ID})... Downloading artifacts from coordinator... ok id={job ID} responseStatus=200 OK token={token} Executing "step_script" stage of the job script Using docker image {SHA} for {image name} with digest {digest} ... ``` ### Relevant logs and/or screenshots See above. ### Output of checks #### Results of GitLab environment info <details> <summary>Expand for output related to GitLab environment info</summary> <pre> System information System: Proxy: no Current User: git Using RVM: no Ruby Version: 2.7.5p203 Gem Version: 3.1.4 Bundler Version:2.2.33 Rake Version: 13.0.6 Redis Version: 6.2.6 Sidekiq Version:6.4.0 Go Version: unknown GitLab information Version: 14.10.3-ee Revision: d118e6c477f Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 12.4 URL: {URL} HTTP Clone URL: {HTTP Clone URL} SSH Clone URL: {SSH Clone URL} Elasticsearch: no Geo: no Using LDAP: no Using Omniauth: yes Omniauth Providers: saml GitLab Shell Version: 13.25.1 Repository storage paths: - default: /nonexistent/repositories GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell </pre> </details> #### Results of GitLab application Check <details> <summary>Expand for output related to the GitLab application check</summary> <pre> Checking GitLab subtasks ... Checking GitLab Shell ... GitLab Shell: ... GitLab Shell version >= 13.25.1 ? ... OK (13.25.1) Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Internal API available: OK Redis available via internal API: OK gitlab-shell self-check successful Checking GitLab Shell ... Finished Checking Gitaly ... Gitaly: ... default ... OK Checking Gitaly ... Finished Checking Sidekiq ... Sidekiq: ... Running? ... yes Number of Sidekiq processes (cluster/worker) ... 1/1 Checking Sidekiq ... Finished Checking Incoming Email ... Incoming Email: ... Reply by email is disabled in config/gitlab.yml Checking Incoming Email ... Finished Checking LDAP ... LDAP: ... LDAP is disabled in config/gitlab.yml Checking LDAP ... Finished Checking GitLab App ... Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Systemd unit files or init script exist? ... skipped (omnibus-gitlab has neither init script nor systemd units) Systemd unit files or init script up-to-date? ... skipped (omnibus-gitlab has neither init script nor systemd units) Projects have namespace: ... 3/4 ... yes 4/5 ... yes 4/6 ... yes 3/7 ... yes 4/8 ... yes 4/10 ... yes 4/11 ... yes 4/12 ... yes 4/13 ... yes 4/14 ... yes 3/15 ... yes 3/16 ... yes 3/17 ... yes 3/18 ... yes 3/19 ... yes 3/20 ... yes 3/21 ... yes 3/22 ... yes 3/23 ... yes 3/24 ... yes 3/25 ... yes 3/26 ... yes 3/27 ... yes 4/28 ... yes 3/29 ... yes 5/30 ... yes 3/31 ... yes 3/33 ... yes 3/34 ... yes 3/35 ... yes 3/36 ... yes 189/38 ... yes 3/40 ... yes 3/42 ... yes 3/43 ... yes 3/44 ... yes 3/47 ... yes 3/48 ... yes 115/49 ... yes 3/50 ... yes 3/51 ... yes 3/52 ... yes 3/53 ... yes 3/54 ... yes 3/55 ... yes 3/56 ... yes 3/57 ... yes 3/58 ... yes 3/62 ... yes 3/63 ... yes 3/64 ... yes 3/67 ... yes 3/68 ... yes 4/69 ... yes 4/70 ... yes 3/71 ... yes 3/72 ... yes 144/74 ... yes 3/75 ... yes 4/76 ... yes 3/77 ... yes 3/78 ... yes 4/79 ... yes 8/80 ... yes 9/81 ... yes 3/82 ... yes 3/83 ... yes 3/84 ... yes 3/85 ... yes 3/86 ... yes 3/87 ... yes 3/88 ... yes 189/89 ... yes 189/90 ... yes 3/91 ... yes 3/92 ... yes 4/93 ... yes 3/94 ... yes 189/95 ... yes 3/96 ... yes 4/97 ... yes 189/98 ... yes 189/99 ... yes 4/100 ... yes 3/101 ... yes 3/102 ... yes 4/103 ... yes 3/104 ... yes 3/105 ... yes 3/106 ... yes 4/107 ... yes 3/108 ... yes 3/109 ... yes 3/110 ... yes 3/112 ... yes 3/113 ... yes 3/114 ... yes 3/115 ... yes 3/116 ... yes 3/117 ... yes 3/118 ... yes 3/119 ... yes 3/120 ... yes 3/122 ... yes 3/123 ... yes 3/124 ... yes 3/125 ... yes 3/126 ... yes 3/127 ... yes 4/128 ... yes 3/129 ... yes 3/130 ... yes 3/131 ... yes 189/133 ... yes 3/134 ... yes 3/135 ... yes 3/136 ... yes 3/137 ... yes 3/138 ... yes 3/139 ... yes 3/140 ... yes 3/142 ... yes 3/143 ... yes 3/144 ... yes 3/145 ... yes 606/146 ... yes Redis version >= 5.0.0? ... yes Ruby version >= 2.7.2 ? ... yes (2.7.5) Git user has default SSH configuration? ... yes Active users: ... 267 Is authorized keys file accessible? ... yes GitLab configured to store new projects in hashed storage? ... yes All projects are in hashed storage? ... yes Elasticsearch version 7.x (6.4 - 6.x deprecated to be removed in 13.8)? ... skipped (elasticsearch is disabled) Checking GitLab App ... Finished Checking GitLab subtasks ... Finished </pre> </details> ### Possible fixes No idea.
issue