Skip to content

thirdscreen/slab-sinks

 
 

Repository files navigation

slab-sinks

This project contains Semantic Logging Application Block (SLAB) sinks to persist application events published to ETW and consumed by SLAB.

Sinks

  • Elasticsearch (Where else would you write events?)

##Elasticsearch Sink A sink to write Semantic Logging Application Block (SLAB) events to Elasticsearch.

###0 Create an event source Create a class derived from EventSource

You could also use EventSourceProxy

###1 Install NuGet

Install-Package EnterpriseLibrary.SemanticLogging.Elasticsearch

###2 Create a listener and enable events

var listener = new ObservableEventListener();

listener.EnableEvents(CommonEventSource.Log, EventLevel.LogAlways, ~EventKeywords.None);

###3 Send events to Elasticsearch

listener.LogToElasticsearch(
    Environment.MachineName,
    "http://localhost:9200",
    "slab",
    "mylogs");

About

Semantic Logging Application Block Sinks

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 100.0%