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

Cache Current Week #195

Open
ramanxg opened this issue Apr 11, 2022 · 3 comments
Open

Cache Current Week #195

ramanxg opened this issue Apr 11, 2022 · 3 comments
Assignees
Labels
Story Point 3 Change to an endpoint or response. Unit Testing required.

Comments

@ramanxg
Copy link
Member

ramanxg commented Apr 11, 2022

From PR #191

Add a JSON cache for the current week helpers. The helpers can use the JSON for data instead of making requests to uci, (especially old dates). We can run a script to update the cache every year, and keep the script in /utils.

@ramanxg ramanxg added the Story Point 3 Change to an endpoint or response. Unit Testing required. label Apr 11, 2022
@ramanxg
Copy link
Member Author

ramanxg commented Apr 12, 2022

Ten year plan for UCI: https://www.reg.uci.edu/calendars/academic/tenyr-19-29.html
Maybe we can use this for caching instead.

@Edwu29
Copy link
Contributor

Edwu29 commented May 3, 2022

This is how Peterportal client cached the data, although to MongoDB, might be helpful.
https://github.com/icssc/peterportal-client/blob/master/api/src/helpers/week.ts

@ramanxg
Copy link
Member Author

ramanxg commented May 3, 2022

TODO:

  • Write a script that scrapes UCI Calendar and creates a JSON in our cache
  • In our week.helper, use the json to reference the dates, instead of the scraped data. We shouldn't ever need to scrape.
  • Test!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Story Point 3 Change to an endpoint or response. Unit Testing required.
Projects
Status: Backlog
Development

No branches or pull requests

3 participants