Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename GoodJob::Job to GoodJob::Execution #377

Merged
merged 1 commit into from
Sep 15, 2021
Merged

Conversation

bensheldon
Copy link
Owner

@bensheldon bensheldon commented Sep 13, 2021

Closes #376.

  • Preserves but deprecates GoodJob::Job.
  • Also renames GoodJob::CurrentExecution to GoodJob::CurrentThread
  • Updates Dashboard controllers and views/partials; puts the "Active Job ID" column first in the table view; wraps UUIDs with <code> tags
  • Renames scopesGoodJob::Execution.with_job_class(class_name) to GoodJob::Execution.job_class(class_name)

@bensheldon bensheldon temporarily deployed to goodjob-rename-job-to-e-knfelz September 13, 2021 14:29 Inactive
@bensheldon bensheldon force-pushed the rename_job_to_execution branch from fe6dd28 to 1484d1f Compare September 13, 2021 15:15
@bensheldon bensheldon temporarily deployed to goodjob-rename-job-to-e-knfelz September 13, 2021 15:15 Inactive
@bensheldon bensheldon force-pushed the rename_job_to_execution branch from 1484d1f to a258735 Compare September 13, 2021 15:36
@bensheldon bensheldon temporarily deployed to goodjob-rename-job-to-e-knfelz September 13, 2021 15:37 Inactive
@morgoth
Copy link
Collaborator

morgoth commented Sep 14, 2021

I'm wondering how many people are using internals of the gem.
In example we have some hand crafted simple monitoring tool in place to check for jobs, so we're using GoodJob::Job directly, but we also have tests for it so we will notice the change.

The other example is the hirefire gem (for autoscalling heroku dynos) that uses the class directly https://github.com/hirefire/hirefire-resource/blob/master/lib/hirefire/macro/good_job.rb

Do you plan to release it as 2.2 version? Maybe we should deprecate the Job somehow first?

@bensheldon
Copy link
Owner Author

@morgoth thanks for drawing my attention to that. You're right, there should be a deprecation notice on this, and probably preserve the presence of the GoodJob::Job class until v3.

- Also renames `GoodJob::CurrentExecution` to `GoodJob::CurrentThread`
- Updates Dashboard controllers and views/partials; puts the "Active Job ID" column first in the table view; wraps UUIDs with `<code>` tags
@bensheldon bensheldon force-pushed the rename_job_to_execution branch from a258735 to 508133d Compare September 14, 2021 14:16
@bensheldon bensheldon temporarily deployed to goodjob-rename-job-to-e-knfelz September 14, 2021 14:16 Inactive
@bensheldon
Copy link
Owner Author

I'm now preserving/deprecating GoodJob::Job instead of removing it (class Job < Execution).

@bensheldon bensheldon merged commit 9b5bdc1 into main Sep 15, 2021
@bensheldon bensheldon deleted the rename_job_to_execution branch September 15, 2021 12:46
@bensheldon bensheldon added the refactor Code changes that do not introduce new features label Sep 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactor Code changes that do not introduce new features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rename GoodJob::Job to be GoodJob::Execution
2 participants