Git Product home page Git Product logo

go-benchmark-app's Introduction

Go Benchmark App

Build Status License codecov Coverage Status Go Report Card GoDoc

The efficiency and speed of application - our goal and the basic idea.

Go Benchmark App

Application for HTTP-benchmarking via different rules and configurations.

Configurations provided via TOML-config.

Our main aims - compare different web-applications that we want to compare with same benchmarks tools, same parameters, repeated and distributed in time. Get average results and compare it with other applications.

This will allow us to analyze and compare the performance bottlenecks, and to take appropriate measures. The efficiency and speed of application - our goal and the basic idea.

Benchmarks tools

ab, wrk, siege

It should be installed.

How to configure

All config at config/main.toml

# Title for describing benchmarks
title = "CMS benchmarks"
# Benchmarks version
version = "0.1"
# Delay via try in seconds
delay = 20
# How much we should try
try = 10

# ab benchmarks parametres
[ab]
concurency = 5000
keepalive = false
requests = 10000

# wrk benchmarks parametres
[wrk]
connections = 5000
duration = 10
threads = 1000

# siege benchmarks parametres
[siege]
concurrent = 100
time = 30

# Applications parametres - list
[[app]]
title = "Application Banchamrs Title"
path = "fool/path/to/app"
url = "http://localhost:5000/test"

How to use

  • Installed Go 1.6+

  • Check is benchmarks tools installed:

    $ whereis ab

    $ whereis wrk

    $ whereis siege

  • Configure config/main.toml in current dirrectory as mentioned before.

  • Install application: $ go install github.com/mrlsd/go-benchmark-app

  • Command-line help: $ go-benchmark-app -h

Go Benchmark Applications v1.0.0
Options:
  -c FILE
    	load configuration from FILE (default "config/main.toml")
  -v	verbose output
  • To change config file - run: $ go-benchmark-app -c path/to/cfg.toml
  • Verbose output: $ go-benchmark-app -v

Tips & Tricks

  • When your benchmarks test failed with socket error (more resources unawailable), try increase delay options at config file (for example 60 sec) or/and change system limits to opened files, TCP/IP configuration and other system limitations.
  • For flexibility running test applications you can create recipe for that. For example set at config file:
[[app]]
title = "My App"
path = "apps/myapp.sh"
url = "http://localhost:5000/test"

and apps/myapp.sh file:

#!/bin/sh
prepare -to -run
/full/path/to/app -v param -d param -etc

in that way you can run docker, nginx or another useful commands.

For one application we use one URL, because it's simplify results analyze, interpretation, comparison.

License: MIT License

go-benchmark-app's People

Contributors

mrlsd avatar

Watchers

 avatar

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.