All Projects → btfak → Sniper

btfak / Sniper

A powerful & high-performance http load tester

Programming Languages

go
31211 projects - #10 most used programming language

Labels

Projects that are alternatives of or similar to Sniper

resloader
🎉A image preloaded plugin and can display the loaded image progress bar
Stars: ✭ 20 (-94.64%)
Mutual labels:  loader
Ngx Skeleton Loader
Make beautiful, animated loading skeletons that automatically adapt to your Angular apps
Stars: ✭ 278 (-25.47%)
Mutual labels:  loader
Markdown Loader
markdown loader for webpack
Stars: ✭ 335 (-10.19%)
Mutual labels:  loader
snowplow-bigquery-loader
Loads Snowplow enriched events into Google BigQuery
Stars: ✭ 15 (-95.98%)
Mutual labels:  loader
React Image Appear
ReactJS component to make images appear with transition as they load.
Stars: ✭ 264 (-29.22%)
Mutual labels:  loader
Lodjs
JavaScript模块加载器,基于AMD。迄今为止,对AMD理解最好的实现。
Stars: ✭ 296 (-20.64%)
Mutual labels:  loader
postcss-font-grabber
A postcss plugin, it grabs remote font files and update your CSS, just like that.
Stars: ✭ 26 (-93.03%)
Mutual labels:  loader
Sass Loader
Compiles Sass to CSS
Stars: ✭ 3,718 (+896.78%)
Mutual labels:  loader
Lumie
✨ An opinionated way to keep your express API organized
Stars: ✭ 277 (-25.74%)
Mutual labels:  loader
Ng Http Loader
🍡 Smart angular HTTP interceptor - Intercepts automagically HTTP requests and shows a spinkit spinner / loader / progress bar
Stars: ✭ 327 (-12.33%)
Mutual labels:  loader
ngx-smart-loader
Smart loader handler to manage loaders everywhere in Angular apps.
Stars: ✭ 28 (-92.49%)
Mutual labels:  loader
Vue Spinners
💫 A collection of loading spinner components for Vuejs
Stars: ✭ 255 (-31.64%)
Mutual labels:  loader
Loading Bar
Flexible, light weighted and super fast Progress Bar Library
Stars: ✭ 300 (-19.57%)
Mutual labels:  loader
config
Simple configuration management for PHP
Stars: ✭ 15 (-95.98%)
Mutual labels:  loader
React Load Script
React component that makes it easy to load 3rd party scripts
Stars: ✭ 347 (-6.97%)
Mutual labels:  loader
typed-css-modules-loader
💠 Webpack loader for typed-css-modules auto-creation
Stars: ✭ 62 (-83.38%)
Mutual labels:  loader
Rsup Progress
❤️ A simple progress bar with promises support
Stars: ✭ 290 (-22.25%)
Mutual labels:  loader
Ngx Ui Loader
Multiple Loaders / spinners and Progress bar for Angular 5, 6, 7 and 8+
Stars: ✭ 368 (-1.34%)
Mutual labels:  loader
Ssspinnerbutton
Forget about typical stereotypic loading, It's time to change. SSSpinnerButton is an elegant button with a diffrent spinner animations.
Stars: ✭ 357 (-4.29%)
Mutual labels:  loader
Waitme
jquery plugin for easy creating loading css3/images animations
Stars: ✭ 302 (-19.03%)
Mutual labels:  loader

Sniper

Sniper is a powerful and high-performance http load tester writing in Golang. Basing on advantage of goroutine,achieving high concurrency,low memory,rich graphics display.

Notice: This project is on pre-alpha stage !

Try it

Pre-compiled executables

Features

  • GET / POST
  • Keep-alive
  • Https
  • Graphics display result
  • Multi-target
  • Large file support
  • Cross-platform——Linux,FreeBSD,Darwin

Compare

tool language keep-alive https multi-target result-show proxy
ab c NO YES NO html,standard output YES
siege c YES YES YES csv,standard output YES
http_load c NO YES YES standard output YES
webbench c NO YES NO standard output YES
sniper go YES YES YES js+html5,standard output NO

Performance

  • Memory usage less than Apache Benchmark(ab)
  • Execution speed close to ab
  • Large file support

Alt text

Graphics display

  • Analyse each request and record it
  • Output http connect time
  • Output server processing time
  • Output total time

Basing on dygraphs and html5,show the detail of server's performance. Get 1000 samples from whole result,show the details of connect,processing,and server's response.

The chart below show the total time and connect time. Wait,how can golang get the connect time ? In a word,Sniper implements part of HTTP protocol stack, discard net/http package to get the details. Also improve the performance.

Alt text

Usage manual

1. install Golang

Please reference Go install chapter of open-source Golang book "build-web-application-with-golang".

2. install Sniper

$ go get github.com/lubia/sniper
$ go install github.com/lubia/sniper
$ cp src/github.com/lubia/sniper/.sniperc ~

3. Parameter declaration

Example

GET

$sniper -c 10 -n 100 http://www.google.com

POST

$sniper -c 10 -n 100 -p postData.txt http://www.google.com

Parameter

Command line parameter
Usage:
   sniper [options] http[s]://hostname[:port][/path]                 http or https,ip or domain support
   sniper [options] -f urls.txt                                      multi-target,format:each url per line
Options:
   -c, --concurrent     concurrent users, default is 1.              
   -n, --requests       number of requests to perform.               
   -r, --repetitions    number of times to run the test.             
   -t, --time           testing time, 30 mean 30 seconds.            
   -R, --sniperc        specify an sniperc file to get config        
                        (default is $HOME/.sniperc).               
   -f, --urlfile        select a specific URLS file.                 
   -p, --post           select a specific file to POST.              
   -T, --content-type   set Content-Type in request                  
                        (default is text/plain).
   -V, --Version        print the version number.                    
   -h, --help           print this section.                          
   -C, --config         show the current config.                     
   -s, --plot           plot detail transactions' info               
                        (true | false,default set true,              
                        notice: set -t will not plot anyhow).

Config file parameter
Notice:default get config file from $HOME/.sniperc,config file and command line parameter complement each other. CMD -R to specified config file, CMD -C to get default configuration.  
[protocol]
version = HTTP/1.1                            
#connection = keep-alive                      # to comment
connection = close
accept-encoding = gzip                        
user-agent = golang & sniper                  

[header]
#cookie = SSID=Abh_TYcDc6YSQh-GB              user-defined header

[process]
timeout = 30                                  socket timeout
failures = 64                                 max failure,socket failure over it then application break

[Authenticate]
login = jeff:supersecret                      HTTP Authenticate

[ssl]
ssl-cert = /root/cert.pem                     ssl-cert file
ssl-key = /root/key.pem                       ssl-key file
ssl-timeout = 30                              https timeout
Output

chart output to current directory "plot.html"

Transactions:                   1000 hits           total requests
Availability:                   100.00 %            percentage completion    
Elapsed time:                   0.15 secs           sniper elapsed time
Document length:               1162 Bytes           single response length
TotalTransfer:                  1.11 MB             total data transfer
Transaction rate:            6625.60 trans/sec      transactions per second
Throughput:                     7.34 MB/sec         throughput
Successful:                     1000 hits           result code not 200 also successful
Failed:                           0 hits            socket errors
TransactionTime:               1.495 ms(mean)       each request total time (average)
ConnectionTime:                0.596 ms(mean)       connect time(average,tcp handshake)
ProcessTime:                   0.900 ms(mean)       TransactionTime = ConnectionTime + ProcessTime
StateCode:                    1000(code 200)        the number of result code is 200

About

Twin projects

Author

Blog:Programer

Contact:yanyuan2046 at 126.com

Licence

Apache License, Version 2.0.

中文文档

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].