From 5980dd1aa84aace91225ab4b767514b08ae5a4ca Mon Sep 17 00:00:00 2001 From: Karsten Bundgaard <17275346+kbundgaard@users.noreply.github.com> Date: Mon, 25 Sep 2023 13:28:54 -0400 Subject: [PATCH] BDF-1252: Add GetLevel to address `*HCLogAdapter does not implement hclog.Logger (missing method GetLevel)` --- consul/log.go | 4 ++++ docker-compose.yaml | 1 + 2 files changed, 5 insertions(+) diff --git a/consul/log.go b/consul/log.go index e0b63a4..810660e 100644 --- a/consul/log.go +++ b/consul/log.go @@ -87,6 +87,10 @@ func (a *HCLogAdapter) SetLevel(hclog.Level) { // we don't currently. } +func (a *HCLogAdapter) GetLevel() hclog.Level { + return hclog.Level(a.log.WithFields(logrus.Fields{}).Level) +} + func (a *HCLogAdapter) With(args ...interface{}) hclog.Logger { e := a.CreateEntry(args) return &HCLogAdapter{ diff --git a/docker-compose.yaml b/docker-compose.yaml index c2c6ee6..486b12a 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -13,6 +13,7 @@ services: -initial-cluster etcd0=http://0.0.0.0:2381 -initial-cluster-state new -enable-v2=false + platform: linux/amd64 ports: - 22379:22379