consul/agent/hcp
Melissa Kam c112a6632d
[CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072)
* Option to set HCP client at runtime

Allows us to initially set a nil HCP client for the
telemetry provider and update it later.

* Set telemetry provider HCP client in HCP manager

Set the telemetry provider as a dependency and pass it to
the manager. Update the telemetry provider's HCP client
when the HCP manager starts.

* Add a provider interface for the metrics client

This provider will allow us to configure and reconfigure the
retryable HTTP client and the headers for the metrics client.

* Move HTTP retryable client to separate file

Copied directly from the metrics client.

* Abstract HCP specific values in HTTP client

Remove HCP specific references and instead initiate with
a generic TLS configuration and authentication source.

* Set up HTTP client and headers in the provider

Move setup from the metrics client to the HCP telemetry
provider.

* Update the telemetry provider in the HCP manager

Initialize the provider without the HCP configs and then update
it in the HCP manager to enable it.

* Improve test assertion, fix method comment

* Move client provider to metrics client

* Stop the manager on setup error

* Add separate lock for http configuration

* Start telemetry provider in HCP manager

* Update HCP client and config as part of Run

* Remove option to set config at initialization

* Simplify and clean up setting HCP configs

* Add test for telemetry provider Run method

* Fix race condition

* Use clone of HTTP headers

* Only allow initial update and run once
2024-01-16 10:46:12 -06:00
..
bootstrap [COMPLIANCE] License changes (#18443) 2023-08-11 09:12:13 -04:00
client [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
config [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
discover [COMPLIANCE] License changes (#18443) 2023-08-11 09:12:13 -04:00
scada [CC-7041] Update and start the SCADA provider in HCP manager (#19976) 2024-01-08 09:49:29 -06:00
telemetry Fix flaky test (#18805) 2023-09-14 16:46:47 +00:00
testserver [COMPLIANCE] License changes (#18443) 2023-08-11 09:12:13 -04:00
deps.go [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
deps_test.go [HCP Telemetry] Move first TelemetryConfig Fetch into the TelemetryConfigProvider (#18318) 2023-08-30 13:25:26 -04:00
manager.go [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
manager_test.go [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
telemetry_provider.go [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
telemetry_provider_test.go [CC-7042] Update and enable the HCP metrics sink in the HCP manager (#20072) 2024-01-16 10:46:12 -06:00
testing.go [Cloud][CC-6925] Updates to pushing server state (#19682) 2023-12-04 10:25:18 -05:00