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

Respect the configured execution mode, even within the CLI #1056

Merged
merged 1 commit into from
Aug 30, 2023

Conversation

bensheldon
Copy link
Owner

Closes #1052.

"Execution Mode" is a bit overly broad because it defines both what the Adapter should do with the job after it is enqueued, as well as what background work should be activated (e.g. cron, job scheduler, etc.)

In this case, I think it makes sense that when executing jobs within the CLI that setting execution mode should still configure what the Active Job Adapter does with jobs that enqueued during the performance of other jobs. In this case:

  • :external jobs are enqueued and executed anywhere
  • :inline jobs are enqueued and executed inline
  • :async_all jobs are enqueued and are attempted to be executed within the same process, and if that's not possible, then treated like :external jobs
  • I didn't change the meaning of :async which is intended to only configure behavior on webservers. If a CLI is configured in :async mode, the execution mode treated as :external

@bensheldon bensheldon added the enhancement New feature or request label Aug 30, 2023
@bensheldon bensheldon merged commit 1a70248 into main Aug 30, 2023
19 checks passed
@bensheldon bensheldon deleted the cli_execution_mode branch August 30, 2023 04:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

Successfully merging this pull request may close these issues.

[Feature Request?] Config Option to Inline Child-Jobs in Worker Processes
1 participant