Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dei79/node-azure-queue-client
https://github.com/dei79/node-azure-queue-client
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/dei79/node-azure-queue-client
- Owner: dei79
- Created: 2015-01-17T15:53:54.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2018-08-20T21:17:57.000Z (over 6 years ago)
- Last Synced: 2024-11-12T19:13:11.268Z (3 months ago)
- Language: JavaScript
- Size: 27.3 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# node-azure-queue-client
A simple to use client for azure queues. The module allows to listen on an azure queue and
when a job comes into the queue it will be processed. The most important features are:* simple to listen a queue
* simple to enqueue jobs
* simple to delay jobs
* prepared for job routing
* support for wrapped xml from Azure Scheduler
* listening on multiple queues supported## Install
```shell
npm install azure-queue-client --save
```## Sample
```javascript
// config with your settings
var qName = '<>';
var qStorageAccount = '<>';
var qStorageSecret = '<>';
var qPolling = 2;// load the module
var azureQueueClient = new require('azure-queue-client');// create the listener
var queueListener = new azureQueueClient.AzureQueueListener();// establish a message handler
queueListener.onMessage(function(message) {// log something
console.log('Message received: ' + JSON.stringify(message));// job is finished without errors
return queueListener.done();
});// start the listening
queueListener.listen(qName, qStorageAccount, qStorageSecret, qPolling, null);
```