bharos opened a new issue, #10746:
URL: https://github.com/apache/gravitino/issues/10746

   ### What would you like to be improved?
   
   **Cache `JWKSource` at initialization** — 
`JWKSourceBuilder.create(url).build()` is currently
      called on every `validateToken()` invocation, potentially triggering an 
HTTP fetch to the JWKS
      endpoint per request. The Nimbus `JWKSource` already provides built-in 
caching (5 min TTL),
      refresh-ahead, and rate-limiting, so a single instance should be created 
once in `initialize()`
      and reused.
   
   
   ### How should we improve?
   
   
   - Avoids unnecessary network overhead and latency from per-request 
`JWKSource` creation.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to