diff --git a/internal/dataplane/config/dbmode.go b/internal/dataplane/config/dbmode.go index 341d8d03a2..0ca960d694 100644 --- a/internal/dataplane/config/dbmode.go +++ b/internal/dataplane/config/dbmode.go @@ -26,6 +26,6 @@ func (m DBMode) IsDBLessMode() bool { // DBBacked returns true if the gateway is DB backed. // reverse of IsDBLessMode for readability. -func (m DBMode) DBBacked() bool { +func (m DBMode) IsDBBacked() bool { return !m.IsDBLessMode() } diff --git a/internal/dataplane/kong_client.go b/internal/dataplane/kong_client.go index 5c827e69a2..ff40e345ad 100644 --- a/internal/dataplane/kong_client.go +++ b/internal/dataplane/kong_client.go @@ -478,7 +478,7 @@ func (c *KongClient) sendOutToGatewayClients( // since only ONE gateway client is chosen to send requests and store SHA of latest configurations, // we should propagate the SHA from the chosen client to other clients // as well as they will pick the configuration from the shared database. - if c.dbmode.DBBacked() && + if c.dbmode.IsDBBacked() && len(gatewayClients) > 1 { for _, client := range gatewayClients { client.SetLastConfigSHA([]byte(shas[0]))