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 🙏

© 2026 – Pkg Stats / Ryan Hefner

adonis-ironium

v0.1.10

Published

Ironium provider for the Adonis 4.x framework

Readme

Adonis Ironium

An Ironium provider for the Adonis 4.x framework.

Easy integration of job queues backed by beanstalkd, ironMQ, and Amazon SQS

Installation & Configuration

See instructions.md

adonis install adonis-ironium

Usage

Command List

Command | Description :------------------------|:----------- adonis make:job | Make a new Job Queue adonis ironium:listen | Start the queue listener

Creating your first job queue

At it's most basic, a job queue provides an async handle method that job data is passed into, upon which it operates. This could be anything from simply the user id for a new user we want to send a welcome email, or a collection of data needing further processing that doesn't make sense to occur during a regular user request.

The handle method is the only requirement!

| Name | Required | Type | Static | Description | |-------------|----------|-----------|--------|-------------------------------------------------------| | handle | true | function | false | An async function that is called for this job. |

Here's an example.

The only real limitation is job payload size, which is dictated by the queue backend:

  • AWS and IronMQ: 256k
  • beanstalkd: 64k by default, but configurable

NOTE:

adonis make:job MyQueue will create a job class in app/Jobs, these are automatically registered and accessibly simply by specifying the class name as the queue name when dispatching a job.

ie: ironium.dispatch('MyQueue', { payload_data: 'goes here' })

Dispatching jobs

Dispatching jobs is pretty straightforward...

const ironium = use('Ironium')
const queueName = 'Example'
const job = {
  message: 'This is my test job!'
}

const jobID = ironium.dispatch(queueName, job)

It will return a job ID, and process your job behind the scenes.

You can also pass in an array of jobs, and optionally specify a delay in a format parsable by ms:

const ironium = use('Ironium')
const queueName = 'Example'
const delay = '2hr'
const job = {
  message: 'This is my test job!'
}

const jobID = ironium.dispatch(queueName, job, delay)
const ironium = use('Ironium')
const queueName = 'Example'

const jobs = [
  { message: 'This is my test job!' },
  { message: 'Another test job!' },
]

const jobID = ironium.dispatch(queueName, jobs)

Reminder

Queued jobs won't process until you fire up one or more queue workers with the ironium:listen command.

Important Note

If you wish to dispatch jobs from within jobs, use does not appear to behave as one might expect, so instead you should use ioc.make() like so:

const { ioc } = require('@adonisjs/fold')

class Example {
  async handle (job) {
    const Ironium = ioc.make('Ironium')
    const Logger = ioc.make('Logger')

    const jobId = await Ironium.dispatch('AnotherJob', anotherPayload)
    Logger.info('Dispatching Job(s): ', jobId)

    return
  }
}

Thanks

Heavily inspired by Adonis Kue, thanks Nick Rempel for that!

Also to Harminder Virk for creating Adonis.