diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2021-10-01 17:03:17 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-01 17:03:17 +0200 |
commit | 81286072eea21017cc4f24046bdcbe531c2f55b8 (patch) | |
tree | d0fc5fad3e1faacaa90cb4e3dad41a2796eef073 | |
parent | 4fe9367ec8e0153330dde29294525f6893079e77 (diff) | |
parent | be47cb0be990fd15b09fb0f528c84cb98b209915 (diff) |
Merge pull request #19402 from vespa-engine/balder/info-logging-on-use-of-fallback-injector
Make use of fallback injector a warning.
-rw-r--r-- | container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentGraph.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentGraph.java b/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentGraph.java index 179abba42c8..cdc11cbb0c8 100644 --- a/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentGraph.java +++ b/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentGraph.java @@ -258,7 +258,10 @@ public class ComponentGraph { if (component.isEmpty()) { Object instance; try { - log.log(Level.FINE, () -> "Trying the fallback injector to create" + messageForNoGlobalComponent(clazz, node)); + // This is an indication that you have not set up your components correctly in the model + // And tit will cause unnecessary reconstruction of your components. + // TODO: this should perhaps bee a warning. + log.log(Level.INFO, () -> "Trying the fallback injector to create" + messageForNoGlobalComponent(clazz, node)); instance = fallbackInjector.getInstance(key); } catch (ConfigurationException e) { throw removeStackTrace(new IllegalStateException( |