open-consul/agent
Paul Banks b61e00b772
cache: fix bug where TTLs were ignored leading to leaked memory in client agents (#9978)
* Fix bug in cache where TTLs are effectively ignored

This mostly affects streaming since streaming will immediately return from Fetch calls when the state is Closed on eviction which causes the race condition every time.

However this also affects all other cache types if the fetch call happens to return between the eviction and then next time around the Get loop by any client.

There is a separate bug that allows cache items to be evicted even when there are active clients which is the trigger here.

* Add changelog entry

* Update .changelog/9978.txt
2021-04-08 11:08:56 +01:00
..
ae testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
auto-config config: improve the interface of Load 2021-01-27 17:34:43 -05:00
cache cache: fix bug where TTLs were ignored leading to leaked memory in client agents (#9978) 2021-04-08 11:08:56 +01:00
cache-types Tune streaming backoff on errors to retry a bit faster when TCP connections drop 2021-04-07 14:13:30 +01:00
checks structs: Fix printing of IDs 2021-01-07 18:47:38 -05:00
config connect: add toggle to globally disable wildcard outbound network access when transparent proxy is enabled (#9973) 2021-04-06 13:19:59 -05:00
connect Replace CertURI.Authorize() calls. 2021-03-15 18:06:04 -06:00
consul connect: add toggle to globally disable wildcard outbound network access when transparent proxy is enabled (#9973) 2021-04-06 13:19:59 -05:00
debug chore: upgrade to gopsutil/v3 (#9118) 2020-11-06 20:48:38 -05:00
dns
exec
grpc Set gRPC keepalives to mirror Yamux keepalive behaviour 2021-04-07 14:09:22 +01:00
local local: default to the agent token instead of the user token 2021-02-19 18:35:08 -05:00
metadata Refactor to call non-voting servers read replicas (#9191) 2020-11-17 10:53:57 -05:00
mock
pool introduce certopts (#9606) 2021-03-22 10:16:41 +01:00
proxycfg connect: add toggle to globally disable wildcard outbound network access when transparent proxy is enabled (#9973) 2021-04-06 13:19:59 -05:00
router Correcting the changed function name in comment 2021-02-06 20:23:40 -05:00
routine-leak-checker introduce certopts (#9606) 2021-03-22 10:16:41 +01:00
rpc/subscribe structs: remove EnterpriseMeta.GetNamespace 2021-03-09 15:17:26 -05:00
rpcclient/health api: ensure v1/health/ingress/:service endpoint works properly when streaming is enabled (#9967) 2021-04-05 13:23:00 -05:00
structs missed build tag on this file (#9974) 2021-04-06 13:24:11 -05:00
submatview submatview: do not reset retry waiter when materializer is reset 2021-02-09 13:56:50 -05:00
systemd
token
uiserver auto-updated agent/uiserver/bindata_assetfs.go from commit a0d12ff16 2021-04-07 16:48:59 +00:00
xds connect: add toggle to globally disable wildcard outbound network access when transparent proxy is enabled (#9973) 2021-04-06 13:19:59 -05:00
acl.go Remove two unused delegate methods 2020-11-17 18:16:26 -05:00
acl_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
acl_endpoint_legacy.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
acl_endpoint_legacy_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
acl_endpoint_test.go Add fields to the /acl/auth-methods endpoint. (#9741) 2021-02-17 08:16:57 -08:00
acl_test.go config: improve the interface of Load 2021-01-27 17:34:43 -05:00
agent.go api: ensure v1/health/ingress/:service endpoint works properly when streaming is enabled (#9967) 2021-04-05 13:23:00 -05:00
agent_endpoint.go Finish cleanup from ServiceConfigRequest changes 2021-03-15 16:38:01 -06:00
agent_endpoint_test.go Set default enterprise meta in test case 2021-03-25 17:40:22 -04:00
agent_oss.go
agent_test.go Merge pull request #9301 from hashicorp/dnephin/add-service-2 2021-01-26 12:01:34 -05:00
apiserver.go agent: fix bug with multiple listeners 2020-11-18 13:03:29 -05:00
apiserver_test.go
catalog_endpoint.go http: Check HTTPUseCache in a single place 2020-12-11 14:03:47 -05:00
catalog_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
check.go
config_endpoint.go connect: intentions are now managed as a new config entry kind "service-intentions" (#8834) 2020-10-06 13:24:05 -05:00
config_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
connect_auth.go Replace CertURI.Authorize() calls. 2021-03-15 18:06:04 -06:00
connect_ca_endpoint.go Add capability for the v1/connect/ca/roots endpoint to return a PEM encoded certificate chain (#8774) 2020-10-09 10:43:33 -04:00
connect_ca_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
coordinate_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
coordinate_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
denylist.go
denylist_test.go
discovery_chain_endpoint.go http: Check HTTPUseCache in a single place 2020-12-11 14:03:47 -05:00
discovery_chain_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
dns.go Do not filter tags unless req.TagFilter is set 2021-02-10 10:36:11 +01:00
dns_oss.go
dns_test.go streaming: move ServiceTag and NodeMetaFiltering to the cache-entry 2021-02-11 20:20:09 -05:00
enterprise_delegate_oss.go
event_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
event_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
federation_state_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
health_endpoint.go api: ensure v1/health/ingress/:service endpoint works properly when streaming is enabled (#9967) 2021-04-05 13:23:00 -05:00
health_endpoint_test.go api: ensure v1/health/ingress/:service endpoint works properly when streaming is enabled (#9967) 2021-04-05 13:23:00 -05:00
http.go http: fix a bug that would cause runtimeConfig to be cached 2021-03-24 14:48:18 -04:00
http_decode_test.go Add support for configuring TLS ServerName for health checks 2021-03-16 18:16:44 -04:00
http_oss.go http: fix a bug that would cause runtimeConfig to be cached 2021-03-24 14:48:18 -04:00
http_oss_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
http_register.go Switch to using the external autopilot module 2020-11-09 09:22:11 -05:00
http_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
intentions_endpoint.go agent: allow the /v1/connect/intentions/match endpoint to use the agent cache (#8875) 2020-10-08 14:51:53 -05:00
intentions_endpoint_oss_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
intentions_endpoint_test.go server: deletions of intentions by name using the intention API is now idempotent (#9278) 2021-01-04 11:27:00 -06:00
keyring.go
keyring_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
kvs_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
kvs_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
nodeid.go chore: upgrade to gopsutil/v3 (#9118) 2020-11-06 20:48:38 -05:00
nodeid_test.go
notify.go
notify_test.go
operator_endpoint.go Switch to using the external autopilot module 2020-11-09 09:22:11 -05:00
operator_endpoint_oss.go Add a CLI command for retrieving the autopilot configuration. (#9142) 2020-11-11 13:19:02 -05:00
operator_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
prepared_query_endpoint.go http: Check HTTPUseCache in a single place 2020-12-11 14:03:47 -05:00
prepared_query_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
reload.go Refactor uiserver to separate package, cleaner Reloading 2020-10-01 11:32:25 +01:00
remote_exec.go
remote_exec_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
retry_join.go
retry_join_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
service_checks_test.go agent: move deprecated AddServiceFromSource to a test file 2021-01-25 17:25:03 -05:00
service_manager.go Split up normalizing from defaulting values for upstream cfg 2021-03-17 21:37:55 -06:00
service_manager_test.go Fixup enterprise tests from tproxy changes 2021-03-17 23:05:00 -06:00
session_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
session_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
setup.go cache: log a warning when Cache.Notify handles an error 2021-02-12 13:02:23 -05:00
sidecar_service.go agent: move deprecated AddServiceFromSource to a test file 2021-01-25 17:25:03 -05:00
sidecar_service_test.go agent: move deprecated AddServiceFromSource to a test file 2021-01-25 17:25:03 -05:00
signal_unix.go
signal_windows.go
snapshot_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
snapshot_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
status_endpoint.go api: rename HTTPServer to HTTPHandlers 2020-09-18 17:38:23 -04:00
status_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
streaming_test.go Added testing of GRPC with TLS combinations 2021-01-06 22:20:23 +01:00
testagent.go introduce certopts (#9606) 2021-03-22 10:16:41 +01:00
testagent_test.go
translate_addr.go
txn_endpoint.go Add support for configuring TLS ServerName for health checks 2021-03-16 18:16:44 -04:00
txn_endpoint_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
ui_endpoint.go api: Ensure the internal/ui/gateway-service-nodes endpoint responds with an array (#9593) 2021-01-20 16:59:02 +00:00
ui_endpoint_oss_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
ui_endpoint_test.go ui: Remove any trailing fullstop/period DNS characters from Gateways UI API (#9752) 2021-02-25 09:34:47 +00:00
user_event.go subscribe: Add steps to rpc/subscribe tests 2020-10-08 15:38:01 -04:00
user_event_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
util.go
util_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
watch_handler.go
watch_handler_test.go