Add job_name field to job log lines

What does this MR do?

Adds the job name to the structured log fields on per-job runner log lines. The completion lines (Job succeeded, Job failed) and everything else logged with the job's field set now carry job_name alongside the existing job ID, and so does the "Checking for jobs... received" line that logs before the build starts.

Why was this MR needed?

Runner logs identify jobs only by numeric ID. When scanning logs for a fleet, the ID alone doesn't tell you which job in a pipeline it was. You have to look each one up in GitLab. The name makes the lines readable and filterable on their own.

The job update and trace patch requests still log only the ID. They don't have the job name available, and the ID is enough to correlate them with the lines that do.

Example log output

Job received:

time="2026-07-30T11:36:51+02:00" level=info msg="Checking for jobs... received" correlation_id=01K1EXAMPLE7Q2M9W4R8T3V6X0 job=11559296127 job_name="rspec unit pg16 12/32" repo_url="https://gitlab.com/gitlab-org/gitlab.git" runner=EXAMPLEsA

Job completed:

time="2026-07-30T11:57:45+02:00" level=info msg="Job succeeded" duration_s=1274.5 gitlab_user_id=4155052 job=11559296127 job-status=success job_name="rspec unit pg16 12/32" namespace_id=9970 organization_id=1 pipeline_id=2145098231 project=278964 project_full_path=gitlab-org/gitlab root_namespace_id=9970 runner=EXAMPLEsA

Before this change the same lines had no job_name field, only the numeric job ID.

Edited by Igor

Merge request reports

Loading
Loading