rmannibucau commented on PR #7:
URL: https://github.com/apache/geronimo-jwt-auth/pull/7#issuecomment-1932192015

   > When we have a cache miss later it probably is because of a key rotation 
and then we have to block anyway.
   
   Not really cause we refresh it in background. How I see things is a 
scheduled executor service following the manager lifecycle 
(postconstruct/predestroy) and the `refresh` of  submit(() -> refresh()) 
wrapped to be a volatile `CompletionFuture` - initialized in the postconstruct.
   This way we always do `getNow(null)`. The promise is only needed during the 
init - at runtime we use it as a volatile field - but shouldn't be a big deal. 
Idea is to limit the blocking to almost never.
   
   > LRUMap
   
   I'm not sure, the rotation is not about the order since it uses identifier, 
we can store the remote identifiers, when we refresh compare to the one in the 
"soon new" map and remove the ones no more there only, sounds sufficient to me.
   
   Does it make sense?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@geronimo.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to