Commit Graph

160 Commits

Author SHA1 Message Date
Paul van Tilburg 9b9b1a5f77
Refactor so that no static is necessary for the maps cache
* Replace the lazy `once_cell` by a maps handle type
* Use Rocket's managed state to manage a handle
* Ensure that the handlers have access to it
* Pass another handle to the maps updater loop
* Try to keep the lock as short as possible

Still, long downloads block the lock. Add a FIXME to refactor this
so the lock is only taken when updating the maps fields.
2022-02-12 21:35:58 +01:00
Paul van Tilburg 72fe9577bd
Implement retrieving and caching maps 2022-02-12 21:08:13 +01:00
Paul van Tilburg d058ab4448
Set up a global maps (cache) object 2022-02-12 17:20:36 +01:00
Paul van Tilburg b5dae45868
Create maps cache and run its task next to Rocket 2022-02-12 17:12:06 +01:00
Paul van Tilburg 6b24c4f6e7
Move blocking geocding forward resolving to a separate thread 2022-02-12 17:12:01 +01:00
Paul van Tilburg ae2d2c1c56 Merge pull request 'Clarify that PAQI is the combination of pollen and air quality index' (#1) from admar/sinoptik:clarify-PAQI into main
Reviewed-on: #1
2022-02-12 17:10:45 +01:00
Admar Schoonen 85d5d34a65 Clarify that PAQI is the combination of pollen and air quality index 2022-02-12 16:18:30 +01:00
Paul van Tilburg 7b496887c2
Properly implement all metrics expansion 2022-02-12 15:03:02 +01:00
Paul van Tilburg ebf1b0618b
Number forecast output per metric (for now)
Also don't include a `null` value in the JSON if it is not enabled.
2022-02-12 15:03:02 +01:00
Paul van Tilburg 0b5e980f04
Initial import into Git 2022-02-12 15:03:00 +01:00