Questions tagged [go-nsq]

NSQ is a realtime message processing system designed to operate at bitly’s scale, handling billions of messages per day.

4 questions
2
votes
0 answers

How to create a channel in NSQ without consuming a message

I am using github.com/nsqio/go-nsq Go package to work with NSQ, and I've met following problem. When producer writes a message - it creates a topic, but not a channel, and it seems that NSQ server just discards a messages when there are no channels.…
xakepp35
  • 2,878
  • 7
  • 26
  • 54
2
votes
1 answer

nsq cannot consume message by connecting to nsqlookupd

I tried to use docker-compose to run nsq, the docker-compose.yml as below: version: '3' services: nsqlookupd: image: nsqio/nsq command: /nsqlookupd ports: - "4160:4160" - "4161:4161" nsqd: image: nsqio/nsq …
pangpang
  • 8,581
  • 11
  • 60
  • 96
1
vote
1 answer

nsqjs clients, not receiving messages immediately from go-nsq server side

trying to learn nsq, and following the examples from here golang example and here nsqjs. I am sending messages in server side doing w/ a for loop and go routines var wg sync.WaitGroup for i := 0; i < 100; i++ { wg.Add(1) go func(x int) { …
Hokutosei
  • 2,114
  • 5
  • 24
  • 42
0
votes
1 answer

defer log.SetOutput(os.Stdout) after log.SetOutput(ioutil.Discard)

In go-nsq library (https://github.com/bitly/go-nsq/blob/master/writer_test.go#L38), I found the following code: log.SetOutput(ioutil.Discard) defer log.SetOutput(os.Stdout) Why does the author defer logging to stdout after discard the log?
Mingyu
  • 31,751
  • 14
  • 55
  • 60