to_nsq

command
v1.0.0-compat Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2017 License: MIT Imports: 13 Imported by: 0

README

to_nsq

A tool for publishing to an nsq topic with data from stdin.

Usage

Usage of ./to_nsq:
  -delimiter string
    	character to split input from stdin (default "\n")
  -nsqd-tcp-address value
    	destination nsqd TCP address (may be given multiple times)
  -producer-opt value
    	option to passthrough to nsq.Producer (may be given multiple times, http://godoc.org/github.com/nsqio/go-nsq#Config)
  -rate int
    	Throttle messages to n/second. 0 to disable
  -topic string
    	NSQ topic to publish to
Examples

Publish each line of a file:

$ cat source.txt | to_nsq -topic="topic" -nsqd-tcp-address="127.0.0.1:4150"

Publish three messages, in one go:

$ echo "one,two,three" | to_nsq -delimiter="," -topic="topic" -nsqd-tcp-address="127.0.0.1:4150"

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL