All Projects → jamiealquiza → Sangrenel

jamiealquiza / Sangrenel

Licence: mit
Apache Kafka load testing "...basically a cloth bag filled with small jagged pieces of scrap iron"

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Sangrenel

Memtier benchmark
NoSQL Redis and Memcache traffic generation and benchmarking tool.
Stars: ✭ 480 (+166.67%)
Mutual labels:  benchmark, load-testing
goku
goku is a HTTP load testing application written in Rust
Stars: ✭ 29 (-83.89%)
Mutual labels:  benchmark, load-testing
Oha
Ohayou(おはよう), HTTP load generator, inspired by rakyll/hey with tui animation.
Stars: ✭ 641 (+256.11%)
Mutual labels:  benchmark, load-testing
jmeter-grpc-plugin
A JMeter plugin supports load test gRPC
Stars: ✭ 36 (-80%)
Mutual labels:  benchmark, load-testing
Gatling Dubbo
A gatling plugin for running load tests on Apache Dubbo(https://github.com/apache/incubator-dubbo) and other java ecosystem.
Stars: ✭ 131 (-27.22%)
Mutual labels:  benchmark, load-testing
Spark Kafka Writer
Write your Spark data to Kafka seamlessly
Stars: ✭ 175 (-2.78%)
Mutual labels:  kafka
Kafkactl
Command Line Tool for managing Apache Kafka
Stars: ✭ 177 (-1.67%)
Mutual labels:  kafka
Operators
Collection of Kubernetes Operators built with KUDO.
Stars: ✭ 175 (-2.78%)
Mutual labels:  kafka
Kafka Streams Dotnet
.NET Stream Processing Library for Apache Kafka 🚀
Stars: ✭ 173 (-3.89%)
Mutual labels:  kafka
Jmh Visualizer
Visually explore your JMH Benchmarks
Stars: ✭ 180 (+0%)
Mutual labels:  benchmark
Tsung
Tsung is a high-performance benchmark framework for various protocols including HTTP, XMPP, LDAP, etc.
Stars: ✭ 2,185 (+1113.89%)
Mutual labels:  benchmark
Gbm Perf
Performance of various open source GBM implementations
Stars: ✭ 177 (-1.67%)
Mutual labels:  benchmark
Kafka View
Kafka web UI
Stars: ✭ 176 (-2.22%)
Mutual labels:  kafka
Sparkstreaming
💥 🚀 封装sparkstreaming动态调节batch time(有数据就执行计算);🚀 支持运行过程中增删topic;🚀 封装sparkstreaming 1.6 - kafka 010 用以支持 SSL。
Stars: ✭ 179 (-0.56%)
Mutual labels:  kafka
Fero
light, fast, scalable, streaming microservices made easy
Stars: ✭ 175 (-2.78%)
Mutual labels:  kafka
Train Ticket
Train Ticket - A Benchmark Microservice System
Stars: ✭ 180 (+0%)
Mutual labels:  benchmark
Sdk Java
Java SDK for CloudEvents
Stars: ✭ 173 (-3.89%)
Mutual labels:  kafka
Bigdata Playground
A complete example of a big data application using : Kubernetes (kops/aws), Apache Spark SQL/Streaming/MLib, Apache Flink, Scala, Python, Apache Kafka, Apache Hbase, Apache Parquet, Apache Avro, Apache Storm, Twitter Api, MongoDB, NodeJS, Angular, GraphQL
Stars: ✭ 177 (-1.67%)
Mutual labels:  kafka
Seconds Kill
基于 Springboot + Redis + Kafka 的秒杀系统,乐观锁 + 缓存 + 限流 + 异步,TPS 从 500 优化到 3000
Stars: ✭ 180 (+0%)
Mutual labels:  kafka
Performance Plugin
Performance Test Running and Reporting for Jenkins CI
Stars: ✭ 176 (-2.22%)
Mutual labels:  load-testing

sangrenel

[Update] Sangrenel is currently being updated. Take note of issues.

"...basically a cloth bag filled with small jagged pieces of scrap iron"

Sangrenel is Kafka cluster load testing tool. Sangrenel was originally created for some baseline performance testing, exemplified in my Load testing Apache Kafka on AWS blog post.

While using this tool, keep in mind that benchmarking is always an examination of total systems performance, and that the testing software itself is part of the system (meaning you're not just testing Kafka, but Kafka+Sangrenel).

Example

Sangrenel takes configurable message/batch sizing, concurrency and other settings and writes messages to a reference topic. Message throughput, batch write latency (p99, harmonic mean, min, max) and a latency histogram are dumped every 5 seconds.

img_0856

Installation

Assuming Go is installed (tested with 1.7+) and $GOPATH is set:

  • go get -u github.com/jamiealquiza/sangrenel
  • go install github.com/jamiealquiza/sangrenel

Binary will be found at $GOPATH/bin/sangrenel

Usage

Usage output:

Usage of sangrenel:
  -api-version string
    	Explicit sarama.Version string
  -brokers string
    	Comma delimited list of Kafka brokers (default "localhost:9092")
  -compression string
    	Message compression: none, gzip, snappy (default "none")
  -graphite-ip string
    	Destination Graphite IP address
  -graphite-metrics-prefix string
    	Top-level Graphite namespace prefix (defaults to hostname) (default "ja.local")
  -graphite-port string
    	Destination Graphite plaintext port
  -interval int
    	Statistics output interval (seconds) (default 5)
  -message-batch-size int
    	Messages per batch (default 500)
  -message-size int
    	Message size (bytes) (default 300)
  -noop
    	Test message generation performance (does not connect to Kafka)
  -produce-rate uint
    	Global write rate limit (messages/sec) (default 100000000)
  -required-acks string
    	RequiredAcks config: none, local, all (default "local")
  -tls
      Whether to enable TLS communcation (default "false")
  -tls-ca-cert string
      Path to the CA SSL certificate
  -tls-cert-file string
      Path to the certificate file
  -tls-key-file string
      Path to the private key file
  -tls-insecure-skip-verify
      TLS insecure skip verify (default false)
  -topic string
    	Kafka topic to produce to (default "sangrenel")
  -workers int
    	Number of workers (default 1)
  -writers-per-worker int
    	Number of writer (Kafka producer) goroutines per worker (default 5)

Sangrenel uses the Kafka client library Sarama. Sangrenel starts one or more workers, each of which instantiate a unique Kafka client connection to the target cluster. Each worker has a number of writers which generate and send message data to Kafka, sharing the parent worker client connection. The number of workers is configurable via the -workers flag, the number of writers per worker via the -writers-per-worker. This is done for scaling purposes; while a single Sarama client can be used for multiple writers (which live in separate goroutines), performance begins to flatline at some point. It's best to leave the writers-per-worker at the default 5 and scaling the worker count as needed, but the option is exposed for more control. Left as a technical exercise for the user, there's a different between 2 workers with 5 writers each and 1 worker with 10 writers.

The -topic flag specifies which topic is used, allowing configs such as parition count and replication factor to be prepared ahead of time for performance comparisons (by switching which topic Sangrenel is using). The -message-batch-size, -message-size and -produce-rate flags can be used to dictate message size, number of messages to batch per write, and the total Sangrenel write rate. -required-acks sets the Sarama RequiredAcks config. The -api-version flag allows Sarama to be configured at a specific API level (See the version field of the Sarama Config struct). The supported API versions can be found here.

Two important factors to note:

  • Sangrenel uses Sarama's SyncProducer, meaning messages are written synchronously
  • At a given message size, Sangrenel should be tested in -noop mode to ensure the desired number of messages can be generated (even if a -produce-rate is specified)

Once running, Sangrenel generates and writes messages as fast as possible (or to the configured -produce-rate). Every 5 seconds, message throughput, rates, latency and other metrics (via tachymeter) are printed to console.

If optionally defined, some metric data can be written to Graphite. Better metric output options will be added soon.

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].