Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dotunj/pvent

Pvent is a CLI tool for sending messages across different message brokers.
https://github.com/dotunj/pvent

kafka message-brokers pubsub sqs

Last synced: 3 months ago
JSON representation

Pvent is a CLI tool for sending messages across different message brokers.

Awesome Lists containing this project

README

        

## Pvent

Pvent is a CLI tool for sending events across different message brokers. At the moment, only Google Pub/Sub,
Kafka, Amazon SQS and RabbitMQ are supported.

### Installation
To install Pvent using homebrew, you can run the following commands:

```bash
brew tap dotunj/tools
brew install dotunj/tools/pvent
```
You can also check the [releases section](https://github.com/Dotunj/pvent/releases) to download the binary for your OS.

### Getting Started

To get started with using Pvent, you need to provide your message brokers credentials in a config file.

An example `pvent.json` config file looks like:

```json
{
"type": "sqs",
"sqs": {
"access_key_id": "",
"secret_access_key": "",
"region": "",
"queue_name": ""
},
"kafka": {
"address": "

",
"topic": "",
"auth": {
"tls": true,
"type": "scram",
"hash": "SHA256",
"username": "",
"password": ""
}
},
"google": {
"project_id": "",
"topic_name": ""
},
"rabbitmq": {
"dsn": "",
"queue_name": ""
}
}
```
Using the CLI, you can now run:

```bash
pvent dispatch --target payload.json --rate 1
```
If you're using Google Pub/Sub, you'll need to expose the path to your service account credentials file as an environment variable

```bash
export GOOGLE_APPLICATION_CREDENTIALS="/Users/dotunj/Documents/certs/service.json"
```

### CLI Usage Manual
```
Usage: pvent [command flags]

dispatch command:
- type string
Message Brokers Type (sqs, google, kafka, rabbitmq)
- rate int
Total number of events to send
- target string
Path to JSON payload to dispatch
- config
Path to Pvent config file
```

### License
The MIT License (MIT). Please see [License File](LICENSE.md) for more information.