Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

feat: add RequestContext to PubSubConn #603

Merged
merged 1 commit into from
Mar 23, 2022

Conversation

pabigot
Copy link
Contributor

@pabigot pabigot commented Mar 17, 2022

Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: #592

redis/pubsub.go Outdated Show resolved Hide resolved
pabigot added a commit to pabigot/redigo that referenced this pull request Mar 17, 2022
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from bf087ba to 7a12a16 Compare March 17, 2022 16:50
@pabigot pabigot marked this pull request as ready for review March 17, 2022 16:51
pabigot added a commit to pabigot/redigo that referenced this pull request Mar 17, 2022
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from 7a12a16 to c6262f1 Compare March 17, 2022 17:21
@pabigot
Copy link
Contributor Author

pabigot commented Mar 21, 2022

It doesn't seem that the de#tent is to limit the features of PubSubConn, but an alternative approach that's only slightly less ideal would be to expose pubsub/receiveInternal as a visible, documented reply helper so we could do:

v := redis.PubSubReply(redis.ReceiveContext(c, ctx))

That might be useful anyway.

@pabigot pabigot changed the title feat: add RequestContext to PubSubConn (TBD) feat: add RequestContext to PubSubConn Mar 22, 2022
pabigot added a commit to pabigot/redigo that referenced this pull request Mar 22, 2022
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from c6262f1 to 4e84dfc Compare March 22, 2022 17:59
redis/pubsub.go Outdated Show resolved Hide resolved
redis/pubsub_test.go Outdated Show resolved Hide resolved
pabigot added a commit to pabigot/redigo that referenced this pull request Mar 23, 2022
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from 4e84dfc to 3706d8e Compare March 23, 2022 23:07
pabigot added a commit to pabigot/redigo that referenced this pull request Mar 23, 2022
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from 3706d8e to 72f6445 Compare March 23, 2022 23:09
Add a wrapper that goes through the standard receiveInternal
processing to match the API of the existing PubSubConn Receive
methods.

Fixes: gomodule#592
@pabigot pabigot force-pushed the pabigot/20220317a branch from 72f6445 to ad7e9d2 Compare March 23, 2022 23:11
@stevenh stevenh merged commit 3eb0774 into gomodule:master Mar 23, 2022
@stevenh
Copy link
Collaborator

stevenh commented Mar 23, 2022

Thanks for the PR

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add PubSubConn.ReceiveContext()
2 participants