MCPcopy
hub / github.com/nats-io/nats.go / QueueSubscribeSync

Method QueueSubscribeSync

js.go:1529–1532  ·  view source on GitHub ↗

QueueSubscribeSync creates a Subscription with a queue group that can be used to process messages synchronously. See important note in QueueSubscribe()

(subj, queue string, opts ...SubOpt)

Source from the content-addressed store, hash-verified

1527// QueueSubscribeSync creates a Subscription with a queue group that can be used to process messages synchronously.
1528// See important note in QueueSubscribe()
1529func (js *js) QueueSubscribeSync(subj, queue string, opts ...SubOpt) (*Subscription, error) {
1530 mch := make(chan *Msg, js.nc.Opts.SubChanLen)
1531 return js.subscribe(subj, queue, nil, mch, true, false, opts)
1532}
1533
1534// ChanSubscribe creates channel based Subscription.
1535// Using ChanSubscribe without buffered capacity is not recommended since

Callers

nothing calls this directly

Calls 1

subscribeMethod · 0.95

Tested by

no test coverage detected