npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

toki-method-rabbit

v1.0.4

Published

Plugin

Downloads

12

Readme

toki-method-rabbit

RabbitMQ plugin used in Toki core.

This plugin interfaces Toki core with the BunnyBus RabbitMQ driver.

Lead Maintainer: Wes Tyler

npm version Build Status Known Vulnerabilities NSP Status

How to integrate with Toki

Getting started with RabbitMQ and Toki is a simple 2-step process!

  1. npm install --save toki-method-rabbit
  2. Add your toki-method-rabbit action configuration to your Toki rules-engine configuration.

That's it! The Toki rules engine handles all of the code requireing and context setup behind the scenes, freeing you to focus on more important things.

toki-method-rabbit Action Configuration Schema

toki-method-rabbit is meant to be used as an action step in a Toki rules-engine configuration definition. This method is intended for publishing messages to a RabbitMQ message bus in the course of a Toki process lifecycle. Like other toki-method-* modules, toki-method-rabbit is implemented through the Toki rule configuration. There are 4 required configuration properties for this method:

  1. "name"
{{string}}

The name of the action step. Eg. `"rabbit"`
  1. "type"
{{string}}

The type of action to be taken by the Toki rules engine. In this case the value should always be `"toki-method-rabbit"`
  1. "rabbitConfiguration"
{{object}}

The connection configurations for the RabbitMQ bus being used.

See the [BunnyBus configurations](https://github.com/xogroup/bunnybus/blob/master/API.md#config) for more information.
  1. "inputConfiguration"
{{object}}

The mapping schema used to create the Rabbit message being published to the exchange. toki-method-rabbit leverages [toki-templater](https://github.com/xogroup/toki-templater) to support dynamic templating in your inputConfiguration mappings.

Examples can be found in the sample Toki config.

Contributing

We love community and contributions! Please check out our guidelines before making any PRs.

Setting up for development

Getting yourself setup and bootstrapped is easy. Use the following commands after you clone down.

npm install && npm test

Please note that the tests make use of Docker and require the rabbitmq:3-management Docker image. Once you have Docker installed, if tests fail then follow these steps:

  1. Ensure that you have the rabbitmq host mappings in your /env/hosts file: 127.0.0.1 rabbitmq
  2. If your tests are able to connect to the Docker image, but you have a Socket closed abruptly during opening handshake error, your Docker image may be initializing too slowly. Try increasing the sleep delay in the wait-on-resources file.