Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Delivery candidates aren't flagged with all applicable subscriptions when batched #95

Closed
kevin-dutra opened this issue Jun 6, 2017 · 0 comments

Comments

@kevin-dutra
Copy link
Contributor

While accumulating subscribers in message_subscribe_message_subscribe_get_subscribers(), a query is issued for each type of subscription to get users with subscriptions that match the given context. If a limit is being utilized (e.g. for queue running), there is a good chance that the delivery candidate does not reflect all the valid subscriptions. For example, if the limit was 3 and there were users with valid subscriptions:

term: [5, 20, 32, 44]
node: [5, 15, 22, 32, 44]

The first batch round, it would query and find [5, 20, 32] due to the term subscriptions but only [5, 15, 22] for node subscriptions. The delivery candidate for user 32 would only reflect the term subscription even though they also had an applicable node subscription.

Also, as a side effect of #88, you end up with more than the user limit being processed. (Instead you get up to "number of subscription types" X limit.)

kevin-dutra added a commit to kevin-dutra/message_subscribe that referenced this issue Jun 6, 2017
kevin-dutra added a commit to kevin-dutra/message_subscribe that referenced this issue Jun 6, 2017
jhedstrom added a commit that referenced this issue Jun 7, 2017
#95 Missing subscriptions on delivery candidates when batched.
@jhedstrom jhedstrom added this to the 8.x-1.0 rc milestone Jun 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants