No description
Find a file
Torbjørn Marø 0cdf821a3f Merge pull request #1 from gitter-badger/gitter-badge
Add a Gitter chat badge to README.md
2015-04-29 16:44:42 +02:00
doc Nothing much 2015-04-12 17:03:16 +02:00
examples Fixed bug in parallel example.. 2015-04-13 22:49:42 +02:00
gfx A state transition diagram for beanstalkd jobs, 2015-04-13 07:53:56 +02:00
.gitignore gitignoring.. 2015-04-10 16:42:08 +02:00
beanstalkd.nim Documentation, and renamed putStr to put. 2015-04-12 13:37:23 +02:00
beanstalkd.nimble Vagrant: Install nimble (for package testing) 2015-04-12 15:15:01 +02:00
compile More examples... 2015-04-12 08:59:21 +02:00
gendoc Nothing much 2015-04-12 17:03:16 +02:00
LICENSE Initial commit 2015-04-10 16:20:37 +02:00
README.md Added Gitter badge 2015-04-29 14:43:49 +00:00
test Example: Two step pipeline parallel 2015-04-12 09:48:12 +02:00
TODO.md Updated TODOs 2015-04-12 00:22:58 +02:00
Vagrantfile Nothing much 2015-04-12 17:03:16 +02:00

beanstalkd.nim logo

This is a Nim client library to connect to and use beanstalkd.

Status: Beta, ready for experimental usage, may not be production ready.

Installation

Join the chat at https://gitter.im/tormaroe/beanstalkd.nim

Install this library using the nimble package manager:

nimble install beanstalkd

Usage

beanstalkd.nim maps pretty closely to the beanstalkd protocol. For complete module documentation, see tormaroe.github.io/beanstalkd.nim.

import beanstalkd

let client = beanstalkd.open("127.0.0.1")
discard client.put("hello world")

let job = client.reserve
echo job
 #==> (success: true, status: reserved, id: 42, job: hello world)

let result = client.delete(job.id)
echo result
 #==> (success: true, status: deleted)

Development

This project uses vagrant to bootstrap the development environment. To get started:

$ git clone https://github.com/tormaroe/beanstalkd.nim
$ cd beanstalkd.nim
$ vagrant up
$ vagrant ssh
$ cd /vagrant

Now to build and run all the examples, do:

$ ./test

Executables are located in /vagrant/build. To only compile the beanstalkd module, do:

$ ./compile

To re-generate module documentation, run:

$ ./gendoc

TODO: How to prepare new release...