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

Make YAML Configuration and Rails Config Equivalent #102

Closed
allcentury opened this issue Dec 29, 2023 · 3 comments
Closed

Make YAML Configuration and Rails Config Equivalent #102

allcentury opened this issue Dec 29, 2023 · 3 comments

Comments

@allcentury
Copy link
Contributor

For matt_accessor's that are settable, I am unable to set some of these in config.yml.

For example, silence_polling in development:

development:
  <<: *default
  silence_polling: true

I'm unable to find the exact problem but happy to put in a fix if someone can point me in the right direction. Maybe here, but I don't see how is this line called?

@rosa
Copy link
Member

rosa commented Dec 29, 2023

Hey @allcentury, sorry for the confusion! All the settings in this section can be set in your config/application.rb file or in your environment specific file (such as development.rb), or in an initializer for Solid Queue alone. For example, in your application.rb file, you'd include something like:

config.solid_queue.silence_polling = true

@allcentury
Copy link
Contributor Author

Thanks @rosa! Having some values settable in application.rb and others set in config.yaml is a confusing developer experience. I would think they would have parity

@allcentury allcentury changed the title Configuration Make YAML Configuration and Rails Config Equivalent Dec 29, 2023
@rosa
Copy link
Member

rosa commented Dec 29, 2023

Hey @allcentury, the configuration in solid_queue.yml is for specific workers and dispatchers, whereas the configuration options set via config.solid_queue are for the Solid Queue's engine. Having these separate is a common pattern in Rails. For example, Active Storage's engine configuration options vs. Active Storage's specific storage service configuration. I'll make this clearer in the README.

neuged added a commit to neuged/solid_queue that referenced this issue Feb 6, 2024
neuged added a commit to neuged/solid_queue that referenced this issue Feb 6, 2024
@rosa rosa closed this as completed Feb 13, 2024
rosa pushed a commit that referenced this issue Feb 13, 2024
This was proposed as resolution to issue #102.
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

No branches or pull requests

2 participants