Git Product home page Git Product logo

websocket-test-bench's Introduction

WebSocket Test Bench

This is a test bench for WebSocket. This can be used to test a WebSocket server with number of concurrent users with different payload sizes and different time periods. This test bench does not wait for a message round trips in order to send the next message to the server. Instead it sends messages without delays to the server and expect the echo back of it with the same sequence.

Building the project

Prerequisites

  • Java 8
  • Maven

Steps to build

  • Clone the project
  • Run mvn package in the project derectory
  • You can find the websocket-test-bench-jar-with-dependencies.jar jar file on target directory

Running the test bench

java -jar websocket-test-bench-jar-with-dependencies.jar <options>

Options

option description default value
-u , --url URL of the server (Mandotory) Non
-n , --connections No of connections to be made to the server 1
-m , --messages No of messages to be sent to the server per connection (This is not valid with -t option) 100
-p , --payload Payload size of a message in bytes 100
-t , --time Time period which test should run in minutes (If this option is enabled then messages will be sent for a given period of time ignoring the -m option) 0
-d , --delay Delay between two consecutive messages in a given client 0

eg: java -jar websocket-test-bench-jar-with-dependencies.jar -u ws://localhost:15500/websocket -n 10 -m 100

Test Result

At the end of the test following results can be obtained

Result indicator Description
TPS per each client Transactions per second per each client
Average TPS per client This is obtained as a average TPS per each client
Total time taken for the test This indicates the total time taken for the test to complete in minutes
Max no of concurrent connections Even though we specify the no of concurrent connections for a given test, server might not be able to handle them.This indicate such situations.
eg: In the test 1000 connections are specified to be connected to the server but server can handle only 700 connections concurrently
Total no of message round trips Total number of messages which are sent and received
No of error messages This test bench expect the same message to be echo backed from the server. If not this indicates the no of error messages received out of the total no of messages sent and received.
Throughput Throughput of the server

websocket-test-bench's People

Contributors

irunika avatar

Watchers

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