You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
5427afc fixed several bugs, by caching codelists in-memory for a day.
However, if a remote URL is inaccessible, then an error is raised.
We could implement a fallback, where the codelists are also written to disk. Whenever the in-memory cache expires, the code attempts to retrieve the codelist. If it succeeds, it compares checksums and updates the file on disk if changed. If it fails, then it logs a warning and reads from disk.
When reading/writing to disk, we can use file locking (if the file is shared between workers).
In terms of where to write the file, https://docs.docker.com/storage/tmpfs/ might be appropriate. Alternately, we can write the files to the host (via a mount), so that the on-disk cache survives any worker restarts, and so that Salt can install initial copies of the codelists, to bootstrap this fallback method.
The text was updated successfully, but these errors were encountered:
5427afc fixed several bugs, by caching codelists in-memory for a day.
However, if a remote URL is inaccessible, then an error is raised.
We could implement a fallback, where the codelists are also written to disk. Whenever the in-memory cache expires, the code attempts to retrieve the codelist. If it succeeds, it compares checksums and updates the file on disk if changed. If it fails, then it logs a warning and reads from disk.
When reading/writing to disk, we can use file locking (if the file is shared between workers).
In terms of where to write the file, https://docs.docker.com/storage/tmpfs/ might be appropriate. Alternately, we can write the files to the host (via a mount), so that the on-disk cache survives any worker restarts, and so that Salt can install initial copies of the codelists, to bootstrap this fallback method.
The text was updated successfully, but these errors were encountered: