= Qgres: A *simple* queuing system

[![PGXN version](https://badge.fury.io/pg/qgres.svg)](https://badge.fury.io/pg/qgres)
[![Build Status](https://travis-ci.org/decibel/qgres.png)](https://travis-ci.org/decibel/qgres)

== Another queuing system?

What makes Qgres unique is that it is *simple*.

What makes most queuing systems complex is they allow for concurrent publishers
and subscribers on a single queue. That creates all kinds of headaches and race
conditions.

Qgres simplifies things by forcing per-queue serialization of either publishing
or consuming. That makes it simple to either track subscribers (if publishing
is serialized), or to allow multiple publishers (if only one consumer can
remove from the queue at once).

Obviously, there are significant drawbacks to this design. Qgres is not meant
to solve every queuing need. If you need something more sophisticated in
Postgres, I suggest you check out http://pgq.github.io/[PgQ]; it's much more
sophisticated ... and more complicated ;).

== Installation
The easiest way to install Qgres is to use the http://pgxnclient.projects.pgfoundry.org/install.html[PGXN client].

To load Qgres into a database named "database_name":

    pgxn load -d database_name qgres

Alternatively, you can use pgxn to install the extension on the server, and then lead it using `CREATE EXTENSION`:

    pgxn install qgres
    psql
    CREATE EXTENSION qgres;

If you have this repository checked out, you can use GNU make:

    gmake
    gmake test
    sudo gmake install

You will need to use `CREATE EXTENSION` to load the extension into your database.

== Documentation
Full documentation is available http://pgxn.org/dist/qgres/doc/qgres.html[online] or see doc/qgres.adoc.
