stargate-grpc-go-client icon indicating copy to clipboard operation
stargate-grpc-go-client copied to clipboard

Token cache

Open searedcircuit opened this issue 3 years ago • 4 comments

Could do with some polish, but this will cut down on the auth spam. Cursory tests show significant throughput/latency gains.

What this PR does:

  • Cache auth token
  • Read max-age Cache-Control header & set expiration if possible, default to 10 minutes, or honor no-cache/no-store directives
  • Refresh within 30 seconds of expiration

Which issue(s) this PR fixes: Fixes #18

Checklist

  • [x] Changes manually tested
  • [N/A] Automated Tests added/updated
  • [N/A] Documentation added/updated
  • [x] CLA Signed: DataStax CLA

searedcircuit avatar Feb 02 '22 01:02 searedcircuit