MCPcopy
hub / github.com/redis/go-redis / Receive

Method Receive

pubsub.go:528–530  ·  pubsub.go::PubSub.Receive

Receive returns a message as a Subscription, Message, Pong or error. See PubSub example for details. This is low-level API and in most cases Channel should be used instead. Receive returns a message as a Subscription, Message, Pong, or an error. See PubSub example for details. This is a low-level AP

(ctx context.Context)

Source from the content-addressed store, hash-verified

526// It may return early with an error if the context is canceled, the connection fails,
527// or other internal errors occur.
528func (c *PubSub) Receive(ctx context.Context) (interface{}, error) {
529 return c.ReceiveTimeout(ctx, 0)
530}
531
532// ReceiveMessage returns a Message or error ignoring Subscription and Pong
533// messages. This is low-level API and in most cases Channel should be used

Callers 8

ReceiveMessageMethod · 0.95
pubsub_test.goFile · 0.80
initMsgChanMethod · 0.80
initAllChanMethod · 0.80
ExamplePubSubFunction · 0.80
tls_test.goFile · 0.80
redis_test.goFile · 0.80

Calls 1

ReceiveTimeoutMethod · 0.95

Tested by 1

ExamplePubSubFunction · 0.64