From 31a39c9528aace8c493dbad413305bb8dc3d5a7f Mon Sep 17 00:00:00 2001 From: VictorBac Date: Wed, 19 Jan 2022 16:09:15 -0500 Subject: [PATCH] Add GRPC and GRPCUseTLS to api.HealthCheckDefinition (#12108) * Add GRPC to HealthCheckDefinition * add GRPC and GRPCUseTLS --- agent/txn_endpoint.go | 2 ++ api/health.go | 2 ++ 2 files changed, 4 insertions(+) diff --git a/agent/txn_endpoint.go b/agent/txn_endpoint.go index afe298d629..f954ace410 100644 --- a/agent/txn_endpoint.go +++ b/agent/txn_endpoint.go @@ -277,6 +277,8 @@ func (s *HTTPHandlers) convertOps(resp http.ResponseWriter, req *http.Request) ( Method: check.Definition.Method, Body: check.Definition.Body, TCP: check.Definition.TCP, + GRPC: check.Definition.GRPC, + GRPCUseTLS: check.Definition.GRPCUseTLS, Interval: interval, Timeout: timeout, DeregisterCriticalServiceAfter: deregisterCriticalServiceAfter, diff --git a/api/health.go b/api/health.go index 2785c4c91c..e70861c8ad 100644 --- a/api/health.go +++ b/api/health.go @@ -62,6 +62,8 @@ type HealthCheckDefinition struct { TLSServerName string TLSSkipVerify bool TCP string + GRPC string + GRPCUseTLS bool IntervalDuration time.Duration `json:"-"` TimeoutDuration time.Duration `json:"-"` DeregisterCriticalServiceAfterDuration time.Duration `json:"-"`