@ceki , are you ok with following ? in logback.groovy:
statusListener(PrintOnlyErrorStreamStatusListener)
in project:
public class PrintOnlyErrorStreamStatusListener extends OnConsoleStatusListener {
@Override
public void addStatusEvent(Status status) {
if (status.getLevel() == Status.ERROR) {
super.addStatusEvent(status);
}
}
}
Will you accept such simple Listener to be part of library ? propose better name or implementation or ... Rationale: we have very extended logbook configuration, it create os much noise in logging that let I miss ERRORs in configuration. By usage of such Listener, it is good to be notified only when ERROR is happening. If engineer interested in details he can always to deactivate such StatusListener and see all details. |