Skip to content

YuraSidorets/NLog.Targets.ActiveMQ

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

NLog.Targets.ActiveMQ NuGet Release

NLog custom target for ActiveMQ

Options

Name Type Description
Uri Layout URL for the ActiveMQ Connecttion. Default: tcp://localhost:61616
Destination Layout Destination for the ActiveMQ message. Default: queue://nlog.messages
Layout Layout Payload for the ActiveMQ message
Persistent Bool Control delivery-mode whether Persistent or NonPersistent. Default = True
UseCompression Bool Control whether to enable compression for producer. Default = False
Username Layout Optional UserName for basic authentication
Password Layout Optional Password for basic authentication
ClientId Layout Optional identifier for this publisher-client

Example NLog.config

<nlog>
  <extensions>
    <add assembly="NLog.Targets.ActiveMQ" />
  </extensions>

  <targets>
    <target type="ActiveMQ" name="ActiveMQ" Uri="tcp://localhost:61616" Destination="queue://nlog.messages">
      <layout>${longdate} ${level} ${message} ${exception}</layout>
    </target>
  </targets>

  <rules>
    <logger name="*" minlevel="Info" writeTo="ActiveMQ" />
  </rules>
</nlog>

See also: ActiveMQ Uri Configuration

Based on Nlog.Contrib.ActiveMq

Releases

No releases published

Packages

No packages published

Languages