stillalex commented on code in PR #1778:
URL: https://github.com/apache/solr/pull/1778#discussion_r1275093386


##########
solr/core/src/java/org/apache/solr/core/PluginBag.java:
##########
@@ -288,6 +294,20 @@ public PluginHolder<T> put(String name, PluginHolder<T> 
plugin) {
     return old;
   }
 
+  static final class APIConfigProviderBinder extends AbstractBinder {
+
+    private final APIConfigProvider<?> cfgProvider;
+
+    public APIConfigProviderBinder(APIConfigProvider<?> cfgProvider) {
+      this.cfgProvider = cfgProvider;
+    }
+
+    @Override
+    protected void configure() {
+      bindFactory(cfgProvider).to(cfgProvider.getConfigClass());

Review Comment:
   I agree with the perf aspect, this will get called on each call. my thought 
was that the config object gets created once and simply returned as many times 
as needed. I would suggest we leave as is and revisit this pattern if needed, 
but let me double check again on the scope parts.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to