{"id":26468680,"url":"https://github.com/llarsson/grpc-caching-interceptors","last_synced_at":"2025-07-15T12:02:44.170Z","repository":{"id":42529612,"uuid":"232986658","full_name":"llarsson/grpc-caching-interceptors","owner":"llarsson","description":"gRPC Interceptors for response caching, written in Go","archived":false,"fork":false,"pushed_at":"2020-08-25T06:58:02.000Z","size":118,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-15T07:36:38.100Z","etag":null,"topics":["go","golang","grpc","grpc-interceptor"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/llarsson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-01-10T07:03:14.000Z","updated_at":"2024-09-27T13:42:42.000Z","dependencies_parsed_at":"2022-07-07T22:23:22.575Z","dependency_job_id":null,"html_url":"https://github.com/llarsson/grpc-caching-interceptors","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llarsson%2Fgrpc-caching-interceptors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llarsson%2Fgrpc-caching-interceptors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llarsson%2Fgrpc-caching-interceptors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llarsson%2Fgrpc-caching-interceptors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/llarsson","download_url":"https://codeload.github.com/llarsson/grpc-caching-interceptors/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244460247,"owners_count":20456301,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["go","golang","grpc","grpc-interceptor"],"created_at":"2025-03-19T16:15:06.004Z","updated_at":"2025-03-19T16:15:06.512Z","avatar_url":"https://github.com/llarsson.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gRPC caching interceptors\n\nInterceptors used to make gRPC caching-aware. Used in \"Towards soft circuit breaking in service meshes via application-agnostic caching\".\n\nThe `client/` directory contains the interceptor you want to use to get a simple TTL-abiding Cache component. See the [Value Service Caching Component](https://github.com/llarsson/value-service-caching) repo for how to use the code. You may want to use the reverse proxy that [our modified Protobuf compiler](https://github.com/llarsson/protobuf) gives you, but should not have to.\n\nThe `server/` directory contains the interceptor that lets you estimate how long a response is valid. You can affect how this estimate is produced by setting the following environment variables for your program that includes the interceptor:\n\n * `PROXY_CACHE_BLACKLIST` should be a regular expression that blacklists operations in your gRPC service from caching (they will not be assigned a caching header, and thus, not cached).\n * `PROXY_MAX_AGE` should be set to one of the following values (if not possible to parse, the Estimator will act in pass-through mode and just not assign a TTL to responses):\n   * `static-N`, where `N` is the number of seconds to statically always respond with, e.g., `static-10` for 10 second TTL for every response object.\n   * `dynamic-adaptive-N`, where N is the parameter to the Adaptive TTL algorithm (read the paper).\n   * `dynamic-updaterisk-N`, where N is the parameter to the Update-risk based algorithm (read the paper).\n\nSee the [Value Service Estimator Component](https://github.com/llarsson/value-service-estimator) repo for how to use the code. As with the Caching interceptor, you may want to use the reverse proxy that [our modified Protobuf compiler](https://github.com/llarsson/protobuf) gives you, but (again!) should not have to.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllarsson%2Fgrpc-caching-interceptors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fllarsson%2Fgrpc-caching-interceptors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllarsson%2Fgrpc-caching-interceptors/lists"}