This project aims to test the performance of various messaging queue systems, including SSE-MQ, Kafka, and RabbitMQ, using a specific set of criteria.
- Node.js (v14.x or later)
- Docker
To test different messaging queues, update the MESSAGE_QUEUE
constant in config.js
. Supported values are:
- 'ssemq'
- 'kafka'
- 'rabbitmq'
- Clone the repository:
git clone https://github.com/Mohamad-Kamar/sse-mq-perf-testing.git
- Enter the project directory:
cd sse-mq-perf-testing
- Install dependencies:
npm install
- Start the Docker containers for the messaging queues:
docker-compose up -d
If you want to start only specific messaging queue services, you can use one of the following commands:
- SSE-MQ:
docker-compose up -d sse-mq
- Kafka:
docker-compose up -d kafka zookeeper
- RabbitMQ:
docker-compose up -d rabbitmq
To run the performance test, use the following command:
npm start
This will execute the index.js
file, which contains the main testing logic.
The test results will be displayed on the console, displaying the time taken for message creation and consumption, as well as the average time for message processing.
To test different queues from the start command without changing the config file, use the command:
npm run start:<your-queue-name>
To stop and remove the Docker containers after testing, run:
docker-compose down
If you would like to contribute to this project, please open an issue or submit a pull request.
This project is licensed under the MIT License.