GithubHelp home page GithubHelp logo

dd-dm's Introduction

Log dasboard

Allow to monitor input http request. Display several stats about the most section hit, number request per second and a raw list of section found.

alt text

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

Before starting make sure you have below packages installed:

  • go version go1.13.1 linux/amd64 Optional:
  • Docker version 18.09.7

Installing

First, make sure your gitlab profil have a ssh key to allow clone

$ git clone [email protected]:Royalsspirit/dd-dm.git

Usage

Makefile

You can run the project thanks to Makefile and docker by tyiping:

$ make up

It will take a locafile.log by default and a threshold of 10.

You can also override these values:

$ make up threshold=20 logfile=/tmp/access.log

Binary

You can find some help by typing:

$ make help

It should display:

Usage:
  -logfile string
    	a path of log file wanted to monitoring (default "./localfile.log")
  -threshold string
    	a threshold request per second (default "10")

If you don't want to use Makefile, you can also build binary as usually then run it:

$ go build -o ./bin/dd-monitoring ./cmd/cli && ./bin/dd-monitoring -threshold 20 -logfile /tmp/access.log

Running the tests

$ make test

Built With

  • termUi - Golang terminal dashboard
  • standard layoug - Standard Go Project Layout
  • daemon-golang - A daemon package for use with Go (golang) services with no dependencies
  • fsnotify - Cross-platform file system notifications for Go

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

dd-dm's People

Contributors

royalsspirit avatar

dd-dm's Issues

debugging

To improve debugging manage error in a seperate file

Data generation

To be able to test the dashboard quickly, it would be great to have a tool to append data into log file randomly

For now, it's also be possible to do:

echo "127.0.0.1 - jill [09/May/2018:16:00:41 +0000] "GET /api/user HTTP/1.0" 200 234
  127.0.0.1 - frank [09/May/2018:16:00:42 +0000] "POST /api/user HTTP/1.0" 200 34
  127.0.0.1 - mary [09/May/2018:16:00:42 +0000] "POST /api/user HTTP/1.0" 503 12
  127.0.0.1 - james [09/May/2018:16:00:39 +0000] "GET /report HTTP/1.0" 200 123
  127.0.0.1 - james [09/May/2018:16:00:39 +0000] "GET /report HTTP/1.0" 200 121
" >> localfile.log

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.