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

feat: switch alert requests for specific routes to cache #2130

Merged
merged 5 commits into from
Aug 14, 2024

Conversation

sloanelybutsurely
Copy link
Contributor

Replaces calls to Alert.fetch/1 and Alert.fetch_or_empty_list/1 that only filter on route_id with calls to Alert.fetch_from_cache/1 and Alert.fetch_from_cache_or_empty_list/1 respectively.

@sloanelybutsurely sloanelybutsurely requested a review from a team as a code owner August 14, 2024 17:49
Copy link
Contributor

@cmaddox5 cmaddox5 left a comment

Choose a reason for hiding this comment

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

Excited to see how this turns out.

@sloanelybutsurely sloanelybutsurely merged commit 6f7211c into main Aug 14, 2024
13 checks passed
@sloanelybutsurely sloanelybutsurely deleted the sloane/switch-route-only-alerts-to-cache branch August 14, 2024 19:35
@digitalcora
Copy link
Contributor

I'm a bit late here, but when fetching based on route ID from the cache, shouldn't we also specify a route type? An alert that affects a whole route type (without specifying individual routes) affects all routes of that type. In the V3 API if I request alerts for route=Red, I'll also get any alerts with route_type=1.

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

Successfully merging this pull request may close these issues.

3 participants