From 977be7749397d4fb81eb173f54608f1bd7caf633 Mon Sep 17 00:00:00 2001 From: Mark Anderson Date: Thu, 28 Oct 2021 13:31:10 -0700 Subject: [PATCH] Fix back compat issues with UDS config (#11318) SocketPath needs to be omitted when empty to avoid confusing older versions of Consul Signed-off-by: Mark Anderson --- .changelog/11318.txt | 3 +++ api/agent.go | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 .changelog/11318.txt diff --git a/.changelog/11318.txt b/.changelog/11318.txt new file mode 100644 index 0000000000..ed32f82154 --- /dev/null +++ b/.changelog/11318.txt @@ -0,0 +1,3 @@ +```release-note:bug +api: fixed backwards compatibility issue with AgentService SocketPath field. +``` diff --git a/api/agent.go b/api/agent.go index 032446af47..e4be1e6dc2 100644 --- a/api/agent.go +++ b/api/agent.go @@ -84,7 +84,7 @@ type AgentService struct { Meta map[string]string Port int Address string - SocketPath string + SocketPath string `json:",omitempty"` TaggedAddresses map[string]ServiceAddress `json:",omitempty"` Weights AgentWeights EnableTagOverride bool