-
Notifications
You must be signed in to change notification settings - Fork 24.6k
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
Remove Guice as a dependency #43881
Comments
Pinging @elastic/es-core-infra |
This commit removes most of the remaining direct execute calls, mostly in gateway code. They are replaced with registering the actions as internal actions. relates elastic#43881
) This commit removes most of the remaining direct execute calls, mostly in gateway code. They are replaced with registering the actions as internal actions. relates #43881
There are currently 3 variants of TransportAction.execute. The implementations of these require additional ctor arguments to all TransportAction implementations. While the non test uses can be converted to using NodeClient to execute other actions, using that for test cases would be cumbersome and defeat the purpose of unit tests testing an action's implementation directly. This commit adds a public test-only utility method for test to use to call execute. This method will continue to be available when the execute implementations are collapsed and made package private. relates elastic#43881
There are currently 3 variants of TransportAction.execute. The implementations of these require additional ctor arguments to all TransportAction implementations. While the non test uses can be converted to using NodeClient to execute other actions, using that for test cases would be cumbersome and defeat the purpose of unit tests testing an action's implementation directly. This commit adds a public test-only utility method for test to use to call execute. This method will continue to be available when the execute implementations are collapsed and made package private. relates #43881
As of early 2021, this is still an important meta issue for the Core/Infra team. |
Guice Version questionAs part of my security audit, I need to find out what version of Guice you forked from. I'm using Thanks for the effort to clean it up. I know from experience how tough it is to remove IoC dependencies. |
@rjernst - very helpful, thank you. |
All of this was removed via static analysis with Idea. We shouldn't have almost 6k lines of unused code around the codebase. This also makes it at least a little clearer what parts of Guice we still use. relates elastic#43881
All of this was removed via static analysis with Idea. We shouldn't have almost 6k lines of unused code around the codebase. This also makes it at least a little clearer what parts of Guice we still use. relates #43881
Pinging @elastic/es-core-infra (Team:Core/Infra) |
Elasticsearch currently uses a forked version of Guice that is embedded into the codebase to manage construction of parts of the Node on startup. In addition to the overhead of keeping a forked copy, Guice blocks us from having a stable plugin api because plugin authors can get at any internal service from any plugin.
This is a meta issue to track removal of Guice. Thanks to an effort spanning multiple years by several people, it is well relegated to just a few places within Node construction:
The text was updated successfully, but these errors were encountered: