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

CMS-545: Update api fetching on park operating dates page #1560

Merged
merged 1 commit into from
Jan 9, 2025
Merged

Conversation

ayumi-oxd
Copy link
Collaborator

Jira Ticket:

CMS-545

Description:

  • Update API fetching on the park operating dates page
  • Previously the API was called 1000 times as the same as the number of parks.
    After talking to @fatbird we've decided to change the API call rather than changing the API rate limit:
    • Fetch all the advisories so that we just need one API call
    • Filter advisories with protectedArea.orc so that we can determine each park access status

@ayumi-oxd ayumi-oxd marked this pull request as ready for review January 8, 2025 01:58
@ayumi-oxd ayumi-oxd requested a review from duncan-oxd January 8, 2025 01:58
Copy link
Collaborator

@duncan-oxd duncan-oxd left a comment

Choose a reason for hiding this comment

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

Batching requests whenever possible is a good idea! We might still want to change the rate limit on the dev environment, because I often have trouble even building the site with the Dev Strapi because of how many calls it does. But this looks like a big improvement for the public site 👍

@ayumi-oxd ayumi-oxd merged commit 2e03eb0 into alpha Jan 9, 2025
4 checks passed
@ayumi-oxd ayumi-oxd deleted the CMS-545 branch January 9, 2025 23:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants