open-telemetry/opentelemetry-collector

[configtls] Add `Validate` method on `ClientConfig` type

Opened this issue · 1 comments

Is your feature request related to a problem? Please describe.

According to this document, if insecure is false, then cert_pem and key_pem are required paramaters for tls configuration. The current Validate method only checks if ca file exists. We should have a Validate method on ClientConfig for the users of this API to validate all required paramaters are set

Describe the solution you'd like

A Validate method to verify required paramaters are set given insecure is set to true or false

mx-psi commented

I support this