Skip to content

Commit

Permalink
Merge pull request quarkusio#45313 from geoand/beancontainer-debug
Browse files Browse the repository at this point in the history
Conditionally log debug statement about missing factory
  • Loading branch information
Guillaume Smet authored Jan 3, 2025
2 parents 7a7876c + e9d35e5 commit 6d38d50
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,11 @@ public <T> Factory<T> beanInstanceFactory(Supplier<Factory<T>> fallbackSupplier,
private <T> Factory<T> createFactory(Supplier<InstanceHandle<T>> handleSupplier, Supplier<Factory<T>> fallbackSupplier,
Class<T> type, Annotation... qualifiers) {
if (handleSupplier == null) {
LOGGER.debugf(
"No matching bean found for type %s and qualifiers %s. The bean might have been marked as unused and removed during build.",
type, Arrays.toString(qualifiers));
if (LOGGER.isDebugEnabled()) {
LOGGER.debugf(
"No matching bean found for type %s and qualifiers %s. The bean might have been marked as unused and removed during build.",
type, Arrays.toString(qualifiers));
}
if (fallbackSupplier != null) {
return fallbackSupplier.get();
} else {
Expand Down

0 comments on commit 6d38d50

Please sign in to comment.