- All Known Implementing Classes:
NopComponentLog
public interface ComponentLog
The ComponentLog provides a mechanism to ensure that all NiFi components are logging and reporting information in a consistent way. When messages are logged to the ComponentLog, each message has the following characteristics:
-
The
toString()of the component is automatically prepended to the message so that it is clear which component is providing the information. This is important, since a single component may have many different instances within the same NiFi instance. -
If the last value in an Object... argument that is passed to the logger is a
Throwable, then the logged message will include a
toString()of the Throwable; in addition, if the component's logger is set to DEBUG level via the logback configuration, the Stacktrace will also be logged. This provides a mechanism to easily enable stacktraces in the logs when they are desired without filling the logs with unneeded stack traces for messages that end up occurring often. - Any message that is logged with a Severity level that meets or exceeds the configured Bulletin Level for that component will also cause a Bulletin to be generated, so that the message is visible in the UI, allowing Dataflow Managers to understand that a problem exists and what the issue is.
-
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoiddefault voiddebug(LogMessage logMessage) voidvoidvoiddefault voiderror(LogMessage logMessage) getName()voidvoidvoiddefault voidinfo(LogMessage logMessage) booleanbooleanbooleanbooleanbooleandefault voiddefault voiddefault voiddefault voidlog(LogLevel level, LogMessage logMessage) default voidlog(LogMessage message) voidvoidvoiddefault voidtrace(LogMessage logMessage) voidvoidvoiddefault voidwarn(LogMessage logMessage)
-
Method Details
-
warn
-
warn
-
warn
-
warn
-
trace
-
trace
-
trace
-
trace
-
isWarnEnabled
boolean isWarnEnabled() -
isTraceEnabled
boolean isTraceEnabled() -
isInfoEnabled
boolean isInfoEnabled() -
isErrorEnabled
boolean isErrorEnabled() -
isDebugEnabled
boolean isDebugEnabled() -
info
-
info
-
info
-
info
-
getName
String getName() -
error
-
error
-
error
-
error
-
debug
-
debug
-
debug
-
debug
-
log
-
log
-
log
-
log
-
log
-