command-line tool to publish, subscribe, and process messages for AMQP 0.9.1 compliant message brokers

Bunny

A BSD licenced, go-powered CLI tool for publishing and subscribing to RabbitMQ, loosely based off https://github.com/algesten/rabbiteer-rs which doesn't support TLS without major surgery.

Install

Install bunny:

$ go get -v github.com/skunkwerks/bunny

Command format

The command has two "modes", publish and subscribe.

$ bunny [general opts] publish/subscribe [specific opts]

General options

$ bunny --help
...
OPTIONS:
    -u, --uri               AMQP connection url (amqp://user:pass@host:port/vhost)

Environment variables

AMQP_URL

The connection string can be set using the AMQP_URL environment variable.

$ export AMQP_URI="amqp://joe:secret@myspecialhost/somevhost"
$ bunny subscribe -e ttninjs-batch

Publish

Publishing pushes data from stdin or a file to an exchange.

Filename (- is stdin) [default: -] -H, --header
... Header on the form "My-Header: Value" -r, --routing-key Routing key [default: ] -z, --priority Priority -t, --rpctimeout RPC timeout in milliseconds ">
$ bunny publish --help
...
FLAGS:
    --rpc        Publish as RPC with replyTo and wait for reply.
OPTIONS:
    -c, --content-type     Content type such as application/json. Inferred from filename if
                                         possible.
    -e, --exchange             Exchange to publish to [default ""]
    -f, --file                     Filename (- is stdin) [default: -]
    -H, --header 
... Header on the form "My-Header: Value" -r, --routing-key Routing key [default: ] -z, --priority Priority -t, --rpctimeout RPC timeout in milliseconds

Example

From stdin

Provide the content-type as arg.

$ echo "{\"panda\":true}" | \
    bunny -u admin -p admin -v prod publish -e myexchange -c application/json

From a file

Content-type is inferred if possible.

$ bunny -u admin -p admin -v prod publish -e myexchange -H "batch: true" -f ./foo.json

Supports RabbitMQ style RPC

Using the replyTo header.

$ bunny publish -e myservice -r somecall --rpc -f ./foo.json

Calls myservice/somecall using the contents of file foo.json and sets up a replyTo header and waits the the rpc reply. The reply will be printed to stdout.

Subscribe

Subscribing binds an anonymous queue to an exchange and listens to messages pushed to that exchange. The messages can either be dumped to stdout or as files to a directory.

Output directory (- is stdout) [default: -] -r, --routing-key Routing key [default: #] ">
$ bunny subscribe --help
...
FLAGS:
    -i, --info       Include delivery info (and headers).
OPTIONS:
    -e, --exchange           Exchange to subscribe to [default ""]
    -o, --output               Output directory (- is stdout) [default: -]
    -r, --routing-key     Routing key [default: #]

Example

To stdout

Outputs the body of each message to stdout. Makes no conversion of the body. If the body is binary, you will see gibberish in the terminal.

$ bunny subscribe -e myexchange
...
With delivery info

-i means we make a JSON wrapping of the message so we can include some basic information about the delivery.

This always produces a JSON structure. When the body is binary (as indicated by content_type), the data is base64 encoded and when the type is text/..., we output it as a JSON string.

The format is:

{
    "deliver":{
        "consumer_tag":"amq.ctag-Tjxx5Qy5zAr0o_yiLOsNEg",
        "delivery_tag":1,
        "redelivered":false,
        "exchange":"myexchange",
        "routing_key":"text"
    },
    "props":{
        "content_type":"application/json",
        "headers":{
            "backendUpdate":false,
            "batch":false,
            "index":"dist-text",
            "oper":"index"
        }
    },
    "data": "body"
}
$ bunny subscribe -e myexchange -i
...

To a directory

With -o the body of each individual message is output to a separate file. The header fileName can be supplied by the sender, in which case that file is (over-)written.

$ bunny subscribe -e myexchange -o /tmp
...
Owner
SkunkWerks GmbH
Building Multi-Peer Distributed Systems for the Internet
SkunkWerks GmbH
Similar Resources

Golang library with POSIX-compliant command-line UI (CLI) and Hierarchical-configuration. Better substitute for stdlib flag.

Golang library with POSIX-compliant command-line UI (CLI) and Hierarchical-configuration. Better substitute for stdlib flag.

cmdr cmdr is a POSIX-compliant, command-line UI (CLI) library in Golang. It is a getopt-like parser of command-line options, be compatible with the ge

Oct 28, 2022

Simple docker container to publish a fixed message to a specified queue. Created to be used with k8s CRON scheduling.

RabbitMQ Publish CRON Simple docker container to publish a fixed message to a specified rabbitmq exchange. Created to be used as part of a Kubernetes

Dec 20, 2021

Gowl is a process management and process monitoring tool at once. An infinite worker pool gives you the ability to control the pool and processes and monitor their status.

Gowl is a process management and process monitoring tool at once. An infinite worker pool gives you the ability to control the pool and processes and monitor their status.

Gowl is a process management and process monitoring tool at once. An infinite worker pool gives you the ability to control the pool and processes and monitor their status.

Nov 10, 2022

A command line tool that builds and (re)starts your web application everytime you save a Go or template fileA command line tool that builds and (re)starts your web application everytime you save a Go or template file

# Fresh Fresh is a command line tool that builds and (re)starts your web application everytime you save a Go or template file. If the web framework yo

Nov 22, 2021

Command Line Tool for decrypting armored pgp messages

Decrypt-PGP-Message A simple command line tool for decrypting armored pgp messages How to build? make build How to use? Usage: -key=path to your pr

Nov 4, 2021

A Go (golang) package providing high-performance asynchronous logging, message filtering by severity and category, and multiple message targets.

ozzo-log Other languages 简体中文 Русский Description ozzo-log is a Go package providing enhanced logging support for Go programs. It has the following fe

Dec 17, 2022

A tool to enumerate all the command-line arguments used to start a Linux process written in Go.

A tool to enumerate all the command-line arguments used to start a Linux process written in Go.

ranwith A tool to enumerate all the command-line arguments used to start a Linux process written in Go. ranwith uses the Linux /proc directory to obta

Jun 30, 2022

:envelope: A streaming Go library for the Internet Message Format and mail messages

go-message A Go library for the Internet Message Format. It implements: RFC 5322: Internet Message Format RFC 2045, RFC 2046 and RFC 2047: Multipurpos

Dec 26, 2022

Provide cloud-edge message synergy solutions for companies and individuals.the cloud-edge message system based on NATS.

Swarm This project is a cloud-edge synergy solution based on NATS. quikly deploy cloud deploy on k8s #pull the project. git clone https://github.com/g

Jan 11, 2022

Priority queue with message-group based partitioning and equal attention guarantee for each message group based on Redis

redis-ordered-queue-go Priority queue with message-group based partitioning and equal attention guarantee for each message group based on Redis What i

Oct 21, 2022

rpipe relays message between child process and redis pubsub channel.

rpipe rpipe relays message between child process and redis pubsub channel. rpipe subscribes Redis channel named HOSTNAME. rpipe spawns child process a

Jan 27, 2022

Tool for collect statistics from AMQP (RabbitMQ) broker. Good for cloud native service calculation.

amqp-statisticator Tool for collect statistics around your AMQP broker. For example RabbitMQ expose a lot information trought the management API, but

Dec 13, 2021

An open-source GitLab command line tool bringing GitLab's cool features to your command line

An open-source GitLab command line tool bringing GitLab's cool features to your command line

GLab is an open source GitLab CLI tool bringing GitLab to your terminal next to where you are already working with git and your code without switching

Dec 30, 2022

A command line tool to prompt for a value to be included in another command line.

readval is a command line tool which is designed for one specific purpose—to prompt for a value to be included in another command line. readval prints

Dec 22, 2021

Handle any SQS use case, monitor any queue. Reusable for any project! Invoke in a goroutine to process SQS messages.

GOSQS This package is intended to be a Go SQS listener that can be imported and invoked as a goroutine handled by the life cycle of your service. It's

Dec 22, 2021

Nrod-go - Sample application to process Train Movements messages from the Network Rail Open Data feed

NROD Train Movements Processor Sample application to process Train Movements mes

Dec 3, 2022

Alertmanager go message broker - A simple message broker made to integrate with alertmanager/prometheus

Alertmanager message broker Prerequisites Go 1.16+ Sqllite driver About: The alertmanager message broker is a project made to meet some of my needs to

Dec 27, 2021

Search running process for a given dll/function. Exposes a bufio.Scanner-like interface for walking a process' PEB

Search running process for a given dll/function. Exposes a bufio.Scanner-like interface for walking a process' PEB

Apr 21, 2022

The mec platform for service register/discovery/subscribe and other functions.roject main repo.

EdgeGallery MEP project Introduction Edgegallery MEP is an open source implementation of MEC platform according to ETSI MEC 003 [1] and 011 [2] docume

Nov 15, 2022
Instant messaging platform. Backend in Go. Clients: Swift iOS, Java Android, JS webapp, scriptable command line; chatbots
Instant messaging platform. Backend in Go. Clients: Swift iOS, Java Android, JS webapp, scriptable command line; chatbots

Tinode Instant Messaging Server Instant messaging server. Backend in pure Go (license GPL 3.0), client-side binding in Java, Javascript, and Swift, as

Jan 6, 2023
Instant messaging server for the Extensible Messaging and Presence Protocol (XMPP).
Instant messaging server for the Extensible Messaging and Presence Protocol (XMPP).

Instant messaging server for the Extensible Messaging and Presence Protocol (XMPP).

Dec 31, 2022
Gorabbit - Simple library for AMQP Rabbit MQ publish subscribe

gorabbit Rabbit MQ Publish & Subscribe Simple library for AMQP Rabbit MQ publish

Oct 4, 2022
:incoming_envelope: A fast Message/Event Hub using publish/subscribe pattern with support for topics like* rabbitMQ exchanges for Go applications

Hub ?? A fast enough Event Hub for go applications using publish/subscribe with support patterns on topics like rabbitMQ exchanges. Table of Contents

Dec 17, 2022
DERO: Secure, Anonymous Blockchain with Smart Contracts. Subscribe to Dero announcements by sending mail to [email protected] with subject: subscribe announcements
DERO: Secure, Anonymous Blockchain with Smart Contracts.  Subscribe to Dero announcements by sending mail to lists@dero.io with subject: subscribe announcements

Welcome to the Dero Project DERO News Forum Wiki Explorer Source Twitter Discord Github Stats WebWallet Medium Table of Contents ABOUT DERO PROJECT DE

Dec 7, 2022
An AMQP 0-9-1 Go client maintained by the RabbitMQ team. Originally by @streadway: `streadway/amqp`

Go RabbitMQ Client Library This is a Go AMQP 0.9.1 client maintained by the RabbitMQ core team. It was originally developed by Sean Treadway. Differen

Jan 1, 2023
High performance, distributed and low latency publish-subscribe platform.
High performance, distributed and low latency publish-subscribe platform.

Emitter: Distributed Publish-Subscribe Platform Emitter is a distributed, scalable and fault-tolerant publish-subscribe platform built with MQTT proto

Jan 2, 2023
Connect, Subscribe and Publish over MQTT broker to check its status.

MQTT Blackbox Exporter Introduction In each probe it sends a message over MQTT broker and then wait for getting it over subscription. By measuring thi

Aug 27, 2022
Prometheus Common Data Exporter can parse JSON, XML, yaml or other format data from various sources (such as HTTP response message, local file, TCP response message and UDP response message) into Prometheus metric data.
Prometheus Common Data Exporter can parse JSON, XML, yaml or other format data from various sources (such as HTTP response message, local file, TCP response message and UDP response message) into Prometheus metric data.

Prometheus Common Data Exporter Prometheus Common Data Exporter 用于将多种来源(如http响应报文、本地文件、TCP响应报文、UDP响应报文)的Json、xml、yaml或其它格式的数据,解析为Prometheus metric数据。

May 18, 2022
Simple and easy to use client for stock market, forex and crypto data from finnhub.io written in Go. Access real-time financial market data from 60+ stock exchanges, 10 forex brokers, and 15+ crypto exchanges

go-finnhub Simple and easy to use client for stock, forex and crpyto data from finnhub.io written in Go. Access real-time market data from 60+ stock e

Dec 28, 2022