leventov commented on a change in pull request #7222: refactor lookups to be
more chill to router
URL: https://github.com/apache/incubator-druid/pull/7222#discussion_r275356034
##########
File path: services/src/main/java/org/apache/druid/cli/CliRouter.java
##########
@@ -80,44 +79,39 @@ public CliRouter()
new QueryRunnerFactoryModule(),
new JettyHttpClientModule("druid.router.http", Router.class),
JettyHttpClientModule.global(),
- new Module()
- {
- @Override
- public void configure(Binder binder)
- {
-
binder.bindConstant().annotatedWith(Names.named("serviceName")).to("druid/router");
-
binder.bindConstant().annotatedWith(Names.named("servicePort")).to(8888);
-
binder.bindConstant().annotatedWith(Names.named("tlsServicePort")).to(9088);
+ binder -> {
Review comment:
I'm not sure an anonymous class conversion to a lambda makes code better in
this case. You lose visibility into the fact that this lambda is a `Module` and
that the method is `configure()`, making the code more cryptic, IMO.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]