node-celery-redis
Advanced tools
Comparing version 0.0.1 to 0.0.2
{ | ||
"name": "node-celery-redis", | ||
"version": "0.0.1", | ||
"description": "Celery client for Node - redis backend ", | ||
"author": { | ||
"name": "Mher Movsisyan", | ||
"email": "mher.movsisyan@gmail.com" | ||
}, | ||
"dependencies": { | ||
"amqp": "*", | ||
"node-uuid": "*", | ||
"redis": "*" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/dial-once/node-celery-redis" | ||
}, | ||
"devDependencies": { | ||
"mocha": "*" | ||
}, | ||
"engine": "node >= 0.8.2", | ||
"main": "celery.js", | ||
"contributors": [ | ||
{ | ||
"name": "==================================" | ||
"name": "node-celery-redis", | ||
"version": "0.0.2", | ||
"description": "Celery client for Node", | ||
"author": "Mher Movsisyan <mher.movsisyan@gmail.com>", | ||
"dependencies": { | ||
"amqp": "*", | ||
"node-uuid": "*", | ||
"redis": "*" | ||
}, | ||
{ | ||
"name": "AUTHORS", | ||
"url": "in chronological order" | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/dial-once/node-celery-redis" | ||
}, | ||
{ | ||
"name": "==================================" | ||
"devDependencies": { | ||
"mocha": "*" | ||
}, | ||
{ | ||
"name": "Mher Movsisyan" | ||
}, | ||
{ | ||
"name": "Esco Obong" | ||
}, | ||
{ | ||
"name": "Jeffrey Luyau" | ||
}, | ||
{ | ||
"name": "Mihail Mikov" | ||
} | ||
], | ||
"bugs": { | ||
"url": "https://github.com/dial-once/node-celery-redis/issues" | ||
}, | ||
"homepage": "https://github.com/dial-once/node-celery-redis", | ||
"maintainers": [ | ||
{ | ||
"name": "pukoren", | ||
"email": "github.koren@pukogames.com" | ||
} | ||
], | ||
"directories": {} | ||
"engine": "node >= 0.8.2", | ||
"main": "celery.js" | ||
} |
var uuid = require('node-uuid'); | ||
var fields = ['task', 'id', 'args', 'kwargs', 'retires', 'eta', 'expires', 'queue', | ||
var fields = ['task', 'id', 'args', 'kwargs', 'retries', 'eta', 'expires', 'queue', | ||
'taskset', 'chord', 'utc', 'callbacks', 'errbacks', 'timeouts']; | ||
@@ -5,0 +5,0 @@ |
@@ -1,11 +0,3 @@ | ||
# Celery client for Node.js - REDIS BACKEND FORK | ||
# Celery client for Node.js | ||
# READ THIS BEFORE USE | ||
This package is a fork of node-celery with redis backend PR merged, used while PR has not been merged | ||
Use it with caution and keep in mind this is a temporary package | ||
Original repo: https://github.com/mher/node-celery/ | ||
# ORIGINAL README | ||
Celery is an asynchronous task/job queue based on distributed | ||
@@ -49,2 +41,26 @@ message passing. node-celery allows to queue tasks from Node.js. | ||
For RabbitMQ backends, the entire broker options can be passed as an object that is handed off to AMQP. | ||
This allows you to specify parameters such as SSL keyfiles, vhost, and connection timeout among others. | ||
```javascript | ||
var celery = require('node-celery'), | ||
client = celery.createClient({ | ||
CELERY_BROKER_OPTIONS: { | ||
host: 'localhost', | ||
port: '5672', | ||
login: 'guest', | ||
password: 'guest', | ||
authMechanism: 'AMQPLAIN', | ||
vhost: '/', | ||
ssl: { | ||
enabled: true, | ||
keyFile: '/path/to/keyFile.pem', | ||
certFile: '/path/to/certFile.pem', | ||
caFile: '/path/to/caFile.pem' | ||
} | ||
}, | ||
CELERY_RESULT_BACKEND: 'amqp' | ||
}); | ||
``` | ||
### ETA | ||
@@ -157,4 +173,1 @@ | ||
[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/mher/node-celery/trend.png)](https://bitdeli.com/free "Bitdeli Badge") | ||
@@ -8,2 +8,5 @@ var celery = require('../celery'), | ||
}; | ||
var conf_redis = { | ||
CELERY_BROKER_URL: 'redis://' | ||
}; | ||
@@ -62,2 +65,19 @@ describe('celery functional tests', function() { | ||
}); | ||
it('should call a task without error', function(done) { | ||
var client = celery.createClient(conf_redis), | ||
add = client.createTask('tasks.add'); | ||
client.on('connect', function() { | ||
add.call([1, 2]); | ||
setTimeout(function() { | ||
client.end(); | ||
}, 100); | ||
}); | ||
client.once('end', function() { | ||
done(); | ||
}); | ||
}); | ||
}); | ||
@@ -64,0 +84,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
29166
654
172
2
2