@Plugin(name="ApplicationInsightsAppender",
category="Core",
elementType="appender")
public class ApplicationInsightsAppender
extends org.apache.logging.log4j.core.appender.AbstractAppender
| Modifier | Constructor and Description |
|---|---|
protected |
ApplicationInsightsAppender(java.lang.String name,
java.lang.String instrumentationKey)
Constructs new Application Insights appender.
|
| Modifier and Type | Method and Description |
|---|---|
void |
append(org.apache.logging.log4j.core.LogEvent event)
Logs a LogEvent using whatever logic this Appender wishes to use.
|
static ApplicationInsightsAppender |
createAppender(java.lang.String name,
java.lang.String instrumentationKey)
Creates new appender with the given name and instrumentation key.
|
LogTelemetryClientProxy |
getTelemetryClientProxy() |
void |
start()
This method is being called on object initialization.
|
error, error, error, getHandler, getLayout, getName, ignoreExceptions, parseInt, setHandler, toStringaddFilter, getFilter, hasFilter, isFiltered, removeFilter, stopequals, getState, hashCode, isInitialized, isStarted, isStarting, isStopped, isStopping, setStarted, setStarting, setState, setStopped, setStoppingprotected ApplicationInsightsAppender(java.lang.String name,
java.lang.String instrumentationKey)
name - The appender name.instrumentationKey - The instrumentation key.public LogTelemetryClientProxy getTelemetryClientProxy()
@PluginFactory public static ApplicationInsightsAppender createAppender(@PluginAttribute(value="name") java.lang.String name, @PluginAttribute(value="instrumentationKey") java.lang.String instrumentationKey)
name - The appender name.instrumentationKey - The instrumentation key.public void append(org.apache.logging.log4j.core.LogEvent event)
event - The LogEvent.public void start()
start in interface org.apache.logging.log4j.core.LifeCyclestart in class org.apache.logging.log4j.core.filter.AbstractFilterable