Package de.lema.appender
Class LemaAppender
- java.lang.Object
-
- ch.qos.logback.core.spi.ContextAwareBase
-
- ch.qos.logback.core.AppenderBase<ch.qos.logback.classic.spi.LoggingEvent>
-
- de.lema.appender.LemaAppender
-
- All Implemented Interfaces:
ch.qos.logback.core.Appender<ch.qos.logback.classic.spi.LoggingEvent>,ch.qos.logback.core.spi.ContextAware,ch.qos.logback.core.spi.FilterAttachable<ch.qos.logback.classic.spi.LoggingEvent>,ch.qos.logback.core.spi.LifeCycle
public final class LemaAppender extends ch.qos.logback.core.AppenderBase<ch.qos.logback.classic.spi.LoggingEvent>Asynchroner Socket-Appender. Die Klasse verwaltet die Attribute und stellt Logback zufrieden; das eigentliche Senden uebernimmt der EventSender.
-
-
Constructor Summary
Constructors Constructor Description LemaAppender()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidappend(ch.qos.logback.classic.spi.LoggingEvent event)SocketThreadcreateSenderController(de.lema.appender.Identifikation ident, ConnectionProperties connectionProperties)StringgetApplication()StringgetApplicationVersion()intgetBufferSize()StringgetConnectionLostStrategy()StringgetConnectionLostStrategyParameter()intgetConnectOnDemandDisconnectTime()StringgetEnvironmentId()intgetEnvironmentIdAsInt()StringgetHostname()booleangetLocationInfo()StringgetPort()StringgetReconnectionDelay()StringgetRemoteHost()booleangetSendeBeacon()booleanisAppendExtraInfo()booleanisConnectOnDemand()booleanrequiresLayout()The SocketAppender does not use a layout.Stringresolve(String variable, String def)voidsetAppendExtraInfo(boolean appendExtraInfo)voidsetApplication(String application)voidsetApplicationVersion(String applicationVersion)voidsetBufferSize(int bufferSize)voidsetConnectionLostStrategy(String connectionLostStrategy)voidsetConnectionLostStrategyParameter(String connectionLostStrategyParameter)voidsetConnectOnDemand(boolean connectOnDemand)voidsetConnectOnDemandDisconnectTime(int connectOnDemandDisconnectTime)voidsetEnvironmentId(String environmentId)voidsetHostname(String hostname)voidsetLocationInfo(boolean locationInfo)The LocationInfo option takes a boolean value.voidsetPort(String port)voidsetReconnectionDelay(String delay)voidsetRemoteHost(String host)The RemoteHost option takes a string value which should be the host name of the server where aSocketNodeis running.voidsetSendeBeacon(boolean sendeBeacon)voidstart()Startet den Sender; Scheitert dies hier wird es nicht nocheinmal probiert, da ein Fataler Fehler vorliegt.voidstop()-
Methods inherited from class ch.qos.logback.core.AppenderBase
addFilter, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setName, toString
-
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContext
-
-
-
-
Method Detail
-
getBufferSize
public int getBufferSize()
-
setBufferSize
public void setBufferSize(int bufferSize)
-
setConnectOnDemand
public void setConnectOnDemand(boolean connectOnDemand)
-
getConnectOnDemandDisconnectTime
public int getConnectOnDemandDisconnectTime()
-
setConnectOnDemandDisconnectTime
public void setConnectOnDemandDisconnectTime(int connectOnDemandDisconnectTime)
-
isConnectOnDemand
public boolean isConnectOnDemand()
-
isAppendExtraInfo
public boolean isAppendExtraInfo()
-
setAppendExtraInfo
public void setAppendExtraInfo(boolean appendExtraInfo)
-
getConnectionLostStrategyParameter
public String getConnectionLostStrategyParameter()
-
setConnectionLostStrategyParameter
public void setConnectionLostStrategyParameter(String connectionLostStrategyParameter)
-
getConnectionLostStrategy
public String getConnectionLostStrategy()
-
setConnectionLostStrategy
public void setConnectionLostStrategy(String connectionLostStrategy)
-
getApplicationVersion
public String getApplicationVersion()
-
setApplicationVersion
public void setApplicationVersion(String applicationVersion)
-
getSendeBeacon
public boolean getSendeBeacon()
-
setSendeBeacon
public void setSendeBeacon(boolean sendeBeacon)
-
start
public void start()
Startet den Sender; Scheitert dies hier wird es nicht nocheinmal probiert, da ein Fataler Fehler vorliegt.- Specified by:
startin interfacech.qos.logback.core.spi.LifeCycle- Overrides:
startin classch.qos.logback.core.AppenderBase<ch.qos.logback.classic.spi.LoggingEvent>
-
createSenderController
public SocketThread createSenderController(de.lema.appender.Identifikation ident, ConnectionProperties connectionProperties)
-
append
public void append(ch.qos.logback.classic.spi.LoggingEvent event)
- Specified by:
appendin classch.qos.logback.core.AppenderBase<ch.qos.logback.classic.spi.LoggingEvent>
-
stop
public void stop()
- Specified by:
stopin interfacech.qos.logback.core.spi.LifeCycle- Overrides:
stopin classch.qos.logback.core.AppenderBase<ch.qos.logback.classic.spi.LoggingEvent>
-
getApplication
public String getApplication()
-
getLocationInfo
public boolean getLocationInfo()
-
getPort
public String getPort()
-
getReconnectionDelay
public String getReconnectionDelay()
-
getRemoteHost
public String getRemoteHost()
-
getEnvironmentId
public String getEnvironmentId()
-
getEnvironmentIdAsInt
public int getEnvironmentIdAsInt()
-
requiresLayout
public boolean requiresLayout()
The SocketAppender does not use a layout. Hence, this method returnsfalse.
-
setApplication
public void setApplication(String application)
-
setLocationInfo
public void setLocationInfo(boolean locationInfo)
The LocationInfo option takes a boolean value. If true, the information sent to the remote host will include location information.
-
setPort
public void setPort(String port)
-
setReconnectionDelay
public void setReconnectionDelay(String delay)
-
setRemoteHost
public void setRemoteHost(String host)
The RemoteHost option takes a string value which should be the host name of the server where aSocketNodeis running.
-
setEnvironmentId
public void setEnvironmentId(String environmentId)
-
getHostname
public String getHostname()
-
setHostname
public void setHostname(String hostname)
-
-