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

Support multiple controllers_paths #214

Open
xanderman opened this issue Nov 7, 2024 · 0 comments
Open

Support multiple controllers_paths #214

xanderman opened this issue Nov 7, 2024 · 0 comments

Comments

@xanderman
Copy link

What? Why?

Organizing rpc controllers in a complex project, using Rails Engines or other organization tools, is currently only possible with hacks that require each controller, like Dir.glob("#{path_to_engine_rpc_controllers}/**/*.rb").each { |f| require f }. Doing that means losing all the benefits of controllers_path, like hot reloading. If controllers_path could be a list, Gruf could managing autoloading/reloading the controllers in the engine itself.

Ideally, Gruf.configure would be reentrant so that the engine could add the path in its initializers, but even if it has to be in the top-level initializer that would still be a big step up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant