Skip to content

Create executions from the job record instead of its id - #819

Merged
rosa merged 1 commit into
rails:mainfrom
andrewfader:execution-from-job
Nov 3, 2026
Merged

rosa merged 1 commit into
rails:mainfrom
andrewfader:execution-from-job

Conversation

@andrewfader

Copy link
Copy Markdown
Contributor

Ready, scheduled and blocked executions were created with job_id: id, so assume_attributes_from_job loaded the job again: one extra SELECT per enqueue.

Passing job: self reuses the record already in memory. Test added.

@andrewfader
andrewfader marked this pull request as ready for review October 23, 2026 00:27
@rosa
rosa force-pushed the execution-from-job branch from 2f824cf to 2daa6ba Compare November 2, 2026 19:01
@rosa

rosa commented Nov 3, 2026

Copy link
Copy Markdown
Member

Great spot! Thank you @andrewfader!

@rosa
rosa merged commit 3bf333c into rails:main Nov 3, 2026
58 checks passed
@andrewfader
andrewfader deleted the execution-from-job branch November 3, 2026 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants