-
-
Notifications
You must be signed in to change notification settings - Fork 222
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
fix(hybrid-cloud): Adds region fan-out to organizations list command #1860
Conversation
It isn't super easy to test the fan-out ability without kicking up another mockito server and changing some of the mocking behavior, so I just updated existing testing to hit the mock server. I'm open to feedback on whether this coverage is worth pursuing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me from a hybrid cloud compatibility point of view, but I'm no rust expert.
Co-authored-by: Sebastian Zivota <loewenheim@users.noreply.github.com>
The
organization list
command currently relies on the basehttps://sentry.io/api/0/organizations/
route to query the user's active organizations; however, this will stop working when we incorporate multiple regions.In order to address this, we've added logic to query an active user's regions, then fan-out to each of the individual regions in order to query all active organizations. This list is then combined and sorted by name as per usual.
In order to make this change, some of the underlying URI and request construction code had to be modified to allow overriding the request hostname with the region's hostname.