Skip to content
Snippets Groups Projects
Commit 2d7466b4 authored by Christian Wulf's avatar Christian Wulf
Browse files

added log blocks

parent 158da1f4
No related branches found
No related tags found
No related merge requests found
...@@ -53,7 +53,9 @@ public final class PipeFactoryLoader { ...@@ -53,7 +53,9 @@ public final class PipeFactoryLoader {
pipeFactories.add(pipeFactory); pipeFactories.add(pipeFactory);
} }
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
LOGGER.warn("Could not find class: " + line, e); // NOMPD (PMD.GuardLogStatement) if (LOGGER.isWarnEnabled()) {
LOGGER.warn("Could not find class: " + line, e);
}
} catch (InstantiationException e) { } catch (InstantiationException e) {
LOGGER.warn("Could not instantiate pipe factory", e); LOGGER.warn("Could not instantiate pipe factory", e);
} catch (IllegalAccessException e) { } catch (IllegalAccessException e) {
......
...@@ -101,7 +101,9 @@ public final class PipeFactoryRegistry { ...@@ -101,7 +101,9 @@ public final class PipeFactoryRegistry {
public void register(final IPipeFactory pipeFactory) { public void register(final IPipeFactory pipeFactory) {
final String key = this.buildKey(pipeFactory.getThreadCommunication(), pipeFactory.getOrdering(), pipeFactory.isGrowable()); final String key = this.buildKey(pipeFactory.getThreadCommunication(), pipeFactory.getOrdering(), pipeFactory.isGrowable());
this.pipeFactories.put(key, pipeFactory); this.pipeFactories.put(key, pipeFactory);
LOGGER.info("Registered pipe factory: " + pipeFactory.getClass().getCanonicalName()); if (LOGGER.isInfoEnabled()) {
LOGGER.info("Registered pipe factory: " + pipeFactory.getClass().getCanonicalName());
}
} }
private String buildKey(final ThreadCommunication tc, final PipeOrdering ordering, final boolean growable) { private String buildKey(final ThreadCommunication tc, final PipeOrdering ordering, final boolean growable) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment