Skip to content

Conversation

@deadlycoconuts
Copy link
Collaborator

What this PR does / why we need it:
Message ordering is not turned on for PubSub subscriptions created by the Treatment Service (and by extension the XP plugin), which means that messages received are not guaranteed to be in order. This poses a problem when there is a high volume of messages sent by the Management Service in a short span of time, as the order of messages received is important since these messages directly impact how the correct treatment is assigned to each request (e.g. an experiment is repeatedly turned on and off over a short period of time).

This PR thus turns on message ordering all subscriptions created to ensure that all instances of the Treatment Service/plugin are consistent in serving the same treatment to each request by maintaining strict message ordering.

See for more details: https://cloud.google.com/pubsub/docs/ordering#go

Which issue(s) this PR fixes:

Fixes #

@deadlycoconuts deadlycoconuts added the bug Something isn't working label Mar 26, 2025
@deadlycoconuts deadlycoconuts self-assigned this Mar 26, 2025
Copy link

@bthari bthari left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

woah, I just saw this MR again, but LGTM! Thanks for catching this!

@deadlycoconuts
Copy link
Collaborator Author

Whoa thanks for the approval! I almost forgot about this! 🙏🏼

@deadlycoconuts deadlycoconuts merged commit cd4de6a into caraml-dev:main May 2, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants