Open jwijenbergh opened 1 year ago
The discovery cache is initially prefilled at compile time, right? So, even on initial startup eduvpn-common should have discovery cached.
The discovery cache is initially prefilled at compile time, right? So, even on initial startup eduvpn-common should have discovery cached.
This is true but it still tries to get it from the network (if they should be updated as deemed by the common lib). If you have a slow connection it only falls back to the cache after the HTTP timeout, which may be a problem?
Didn't get a lot of +1s from the team
discussed with roop
Problem:
getting disco servers/organizations can be slow due to the discovery server or the users network being slow. Even though we have a timeout and a cookie, it might be nice to introduce a
local
/cache
argument to the functionsIf non-zero/true this means that only the cached copy is returned. Clients can thus first call the functions with true and then asynchronously call it with false to get the most up to date copy.
This is right now the most problematic on startup where clients have no discovery cache filled