Skip to content
This repository has been archived by the owner on Apr 23, 2024. It is now read-only.

Allow custom ThrowableHandlingConverter in JsonLayout #9

Merged
merged 1 commit into from
Apr 6, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
package ch.qos.logback.contrib.json.classic;

import ch.qos.logback.classic.Level;
import ch.qos.logback.classic.pattern.ThrowableHandlingConverter;
import ch.qos.logback.classic.pattern.ThrowableProxyConverter;
import ch.qos.logback.classic.spi.ILoggingEvent;
import ch.qos.logback.classic.spi.IThrowableProxy;
Expand Down Expand Up @@ -120,7 +121,7 @@ public class JsonLayout extends JsonLayoutBase<ILoggingEvent> {
protected boolean includeException;
protected boolean includeContextName;

private final ThrowableProxyConverter throwableProxyConverter;
private ThrowableHandlingConverter throwableProxyConverter;

public JsonLayout() {
super();
Expand Down Expand Up @@ -299,4 +300,12 @@ public boolean isIncludeContextName() {
public void setIncludeContextName(boolean includeContextName) {
this.includeContextName = includeContextName;
}

public ThrowableHandlingConverter getThrowableProxyConverter() {
return throwableProxyConverter;
}

public void setThrowableProxyConverter(ThrowableHandlingConverter throwableProxyConverter) {
this.throwableProxyConverter = throwableProxyConverter;
}
}