Code Monkey home page Code Monkey logo

nabbix's Introduction

nolstoy-packages MyGet Build StatusNuget download Nuget download

What?

A lightweight Zabbix Agent that can be embedded in any .Net program ~ ASP.Net, Windows Service or Console Applications.

Why?

Zabbix does have a Windows Agent. It's largely limited to Performance Counters, Log Files and the Windows Event Log. When monitoring a .Net application, it's a non trivial task to install the agent and register custom performance counters.

With Nabbix, monitoring a .Net program only requires referencing a NuGet package and adding a few lines of code.

How?

1. Add nabbix NuGet Package

Install-Package Nabbix

2. Create class(es) with the counter(s)


// Class containing a single Zabbix Item 'long_example'
private class MyCounter
{
	private long _incrementing;
    internal void Increment()
	{
		Interlocked.Increment(ref _incrementing);
	}

	[NabbixItem("long_example")]
    public long Incrementing => Interlocked.Read(ref _incrementing);
}

3. Create a Nabbix Agent and register instances of the counter classes.

private static void Main()
{
	// Create the instance of the counter class with a single Zabbix Item
    var counters = new MyCounter();
            
    // Start the agent.
    var agent = new NabbixAgent(10052, counters);

    // Increment the counter. Normally done on API or method call.
    counters.Increment();

    // Shutdown
	Console.ReadKey();
    agent.Stop();
}

More information?

https://github.com/nolstoy/nabbix/wiki

nabbix's People

Contributors

nolstoy avatar marksl avatar ahartlin avatar davidindra avatar

Stargazers

Yevhenii Stoiev avatar pedoc avatar Sergey avatar Mladen Mihajlović avatar  avatar  avatar Alex Jones avatar Eric Paul avatar Tomasz Dłuski avatar  avatar lobster2012-user avatar Bauyrzhan avatar Rashid Salim avatar fanjun avatar David Koenig avatar Elias Pizarro Rodríguez avatar  avatar Luiz Sales avatar VolhvPorechja avatar Admir avatar 白菜 avatar Nick Martyshchenko avatar Lyshenko Volodymyr avatar  avatar Bartek Kois avatar Ryan Armstrong avatar Jan Garaj avatar  avatar

Watchers

Eric Paul avatar  avatar  avatar VolhvPorechja avatar Admir avatar Elias Pizarro Rodríguez avatar Luiz Sales avatar Tomasz Dłuski avatar

nabbix's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.