Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/segment-boneyard/nsq-manage
Manage nsqd instances
https://github.com/segment-boneyard/nsq-manage
Last synced: about 5 hours ago
JSON representation
Manage nsqd instances
- Host: GitHub
- URL: https://github.com/segment-boneyard/nsq-manage
- Owner: segment-boneyard
- Created: 2014-04-01T22:39:44.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-04-02T00:27:57.000Z (over 10 years ago)
- Last Synced: 2024-05-21T12:11:19.901Z (6 months ago)
- Language: JavaScript
- Size: 138 KB
- Stars: 9
- Watchers: 40
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: History.md
Awesome Lists containing this project
README
[![Build Status](https://circleci.com/gh/segmentio/nsq-manage.png?circle-token=32f95a26531457eb2db113cff8d28fb1e3fb29e3)](https://circleci.com/gh/segmentio/nsq-manage)
# nsq-manage
Manage nsqd instances. Basically a lightweight wrapper about nsqd's http api.
## Installation
```bash
$ npm install nsq-manage
```## Example
```bash
var manage = require('nsq-manage')('http://localhost:4151');manage.createTopic('name', function(err){
// ...
});
```## API
### Manage(nsqd)
Create a management instance with the `nsqd` http address.
### #createTopic(topic, fn)
Create `topic`.
### #deleteTopic(topic, fn)
Delete `topic`.
### #createChannel(topic, channel, fn)
Create `channel` for an existing `topic`.
### #deleteChannel(topic, channel, fn)
Delete `channel` for an existing `topic`.
### #emptyChannel(topic, channel, fn)
Empty `channel` for an existing `topic`.
### #pauseChannel(topic, channel, fn)
Pause `channel` for an existing `topic`.
### #unpauseChannel(topic, channel, fn)
Unpause `channel` for an existing `topic`.
### #stats(fn)
Get internal instrumented statistics.
### #ping(fn)
Check health.
## License
MIT