CompositeJsonEncoder throws a NullPointerException if not started when encode() is called. The null pointer is caused by lineSeparatorBytes being null at line 116.
This unsafe behaviour is particularly annoying when the encoder is used with an OutputStreamAppender like the console or file appenders: the appender turns itself off whenever an exception is thrown when processing a log event (should the exception be thrown by the encoder or the output stream).
Note that this issue is already fixed thanks to PR #472 (see line #74 in CompositeJsonEncoder.)