I've found this package to be useful for this in the past: https://github.com/jellydator/ttlcache
--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/a59272be-7277-4cb6-a7a7-8bf4bdcefc40n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/924e3ebf-c2a6-4288-be14-8b187a46ab25n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/fc43af25-566a-4e88-b1e3-ba97e226f351n%40googlegroups.com.