From 6fc8499ec380ccd4b8993a76ebf89abfc61793c5 Mon Sep 17 00:00:00 2001 From: kai Date: Tue, 16 Apr 2024 13:39:15 +0100 Subject: [PATCH 1/3] apply timing changes --- Makefile | 9 ++ fdw.go | 6 +- go.mod | 91 ++++++------ go.sum | 266 ++++++++++++++--------------------- hub/hub.go | 2 +- hub/hub_base.go | 194 +++++++++++++++---------- hub/hub_local.go | 6 +- hub/hub_remote.go | 28 ++-- hub/in_memory_iterator.go | 27 ++-- hub/interface.go | 4 +- hub/query_timing_metadata.go | 70 +++++++++ hub/scan_iterator.go | 33 ++++- hub/scan_iterator_base.go | 55 +++----- hub/scan_iterator_local.go | 2 +- hub/scan_metadata.go | 43 ------ 15 files changed, 445 insertions(+), 391 deletions(-) create mode 100644 hub/query_timing_metadata.go delete mode 100644 hub/scan_metadata.go diff --git a/Makefile b/Makefile index 2c11532b..d73916b1 100644 --- a/Makefile +++ b/Makefile @@ -31,6 +31,15 @@ standalone: validate_plugin prebuild.go rm -f prebuild.go +build: prebuild.go + $(MAKE) -C ./fdw clean + $(MAKE) -C ./fdw go + $(MAKE) -C ./fdw + $(MAKE) -C ./fdw inst + + rm -f prebuild.go + + # render target render: validate_plugin prebuild.go @echo "Rendering code for plugin: $(plugin)" diff --git a/fdw.go b/fdw.go index c88b1829..96382605 100644 --- a/fdw.go +++ b/fdw.go @@ -6,6 +6,7 @@ package main #include "fdw_helpers.h" #include "utils/rel.h" #include "nodes/pg_list.h" +#include "utils/timestamp.h" */ import "C" @@ -241,7 +242,8 @@ func goFdwBeginForeignScan(node *C.ForeignScanState, eflags C.int) { } // if we are NOT explaining, create an iterator to scan for us if !explain { - iter, err := pluginHub.GetIterator(columns, quals, unhandledRestrictions, int64(execState.limit), opts) + ts := int64(C.GetSQLCurrentTimestamp(0)) + iter, err := pluginHub.GetIterator(columns, quals, unhandledRestrictions, int64(execState.limit), opts, ts) if err != nil { log.Printf("[WARN] pluginHub.GetIterator FAILED: %s", err) FdwError(err) @@ -275,7 +277,7 @@ func goFdwIterateForeignScan(node *C.ForeignScanState) *C.TupleTableSlot { log.Printf("[TRACE] goFdwIterateForeignScan, table '%s' (%p)", s.Opts["table"], s.Iter) // if the iterator has not started, start if s.Iter.Status() == hub.QueryStatusReady { - log.Printf("[INFO] goFdwIterateForeignScan calling pluginHub.StartScan, table '%s' (%p)", s.Opts["table"], s.Iter) + log.Printf("[INFO] goFdwIterateForeignScan calling pluginHub.StartScan, table '%s' Current timestamp: %d (%p)", s.Opts["table"], s.Iter.GetQueryTimestamp(), s.Iter) if err := pluginHub.StartScan(s.Iter); err != nil { FdwError(err) return slot diff --git a/go.mod b/go.mod index 333a32ef..866bff8c 100644 --- a/go.mod +++ b/go.mod @@ -7,27 +7,27 @@ toolchain go1.21.3 require ( github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/golang/protobuf v1.5.4 - github.com/hashicorp/go-hclog v1.6.2 + github.com/hashicorp/go-hclog v1.6.3 github.com/hashicorp/go-version v1.6.0 // indirect - github.com/turbot/go-kit v0.9.0 - // main - github.com/turbot/steampipe v1.7.0-rc.0.0.20240223132218-d8ddcad4cc90 - github.com/turbot/steampipe-plugin-sdk/v5 v5.9.0 - go.opentelemetry.io/otel v1.23.1 + github.com/turbot/go-kit v0.10.0-rc.0 + //join_timing + github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a + github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3 + go.opentelemetry.io/otel v1.24.0 google.golang.org/protobuf v1.33.0 ) require ( github.com/Masterminds/semver/v3 v3.2.1 - go.opentelemetry.io/otel/metric v1.23.1 + go.opentelemetry.io/otel/metric v1.24.0 ) require ( - cloud.google.com/go v0.111.0 // indirect - cloud.google.com/go/compute v1.23.3 // indirect + cloud.google.com/go v0.112.0 // indirect + cloud.google.com/go/compute v1.24.0 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect - cloud.google.com/go/iam v1.1.5 // indirect - cloud.google.com/go/storage v1.35.1 // indirect + cloud.google.com/go/iam v1.1.6 // indirect + cloud.google.com/go/storage v1.36.0 // indirect github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24 // indirect github.com/Microsoft/hcsshim v0.11.4 // indirect github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect @@ -38,11 +38,11 @@ require ( github.com/eko/gocache/lib/v4 v4.1.5 // indirect github.com/eko/gocache/store/bigcache/v4 v4.2.1 // indirect github.com/eko/gocache/store/ristretto/v4 v4.2.1 // indirect - github.com/felixge/httpsnoop v1.0.3 // indirect - github.com/gabriel-vasile/mimetype v1.4.2 // indirect + github.com/felixge/httpsnoop v1.0.4 // indirect + github.com/gabriel-vasile/mimetype v1.4.3 // indirect github.com/go-playground/locales v0.14.1 // indirect github.com/go-playground/universal-translator v0.18.1 // indirect - github.com/go-playground/validator/v10 v10.15.5 // indirect + github.com/go-playground/validator/v10 v10.19.0 // indirect github.com/golang/mock v1.6.0 // indirect github.com/google/s2a-go v0.1.7 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect @@ -51,31 +51,34 @@ require ( github.com/hashicorp/go-safetemp v1.0.0 // indirect github.com/hashicorp/terraform-registry-address v0.2.1 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect - github.com/jackc/pgx/v5 v5.5.4 // indirect + github.com/jackc/pgx/v5 v5.5.5 // indirect github.com/jackc/puddle/v2 v2.2.1 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/karrick/gows v0.3.0 // indirect github.com/klauspost/compress v1.17.0 // indirect - github.com/leodido/go-urn v1.2.4 // indirect + github.com/leodido/go-urn v1.4.0 // indirect github.com/moby/locker v1.0.1 // indirect - github.com/oras-project/oras-credentials-go v0.3.1 // indirect github.com/rs/xid v1.5.0 // indirect github.com/sagikazarmark/locafero v0.4.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/cobra v1.8.0 // indirect - github.com/turbot/pipe-fittings v0.2.2 // indirect + github.com/thediveo/enumflag/v2 v2.0.5 // indirect + github.com/turbot/pipe-fittings v1.1.0 // indirect github.com/turbot/terraform-components v0.0.0-20231213122222-1f3526cab7a7 // indirect github.com/ulikunitz/xz v0.5.10 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 // indirect + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0 // indirect go.uber.org/atomic v1.9.0 // indirect go.uber.org/multierr v1.9.0 // indirect - golang.org/x/term v0.16.0 // indirect + golang.org/x/mod v0.13.0 // indirect + golang.org/x/term v0.18.0 // indirect golang.org/x/time v0.5.0 // indirect - google.golang.org/api v0.153.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20240102182953-50ed04b92917 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240102182953-50ed04b92917 // indirect - oras.land/oras-go/v2 v2.4.0 // indirect + golang.org/x/tools v0.14.0 // indirect + google.golang.org/api v0.162.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de // indirect + oras.land/oras-go/v2 v2.5.0 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) @@ -91,7 +94,7 @@ require ( github.com/btubbs/datetime v0.1.1 // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/containerd/containerd v1.7.13 // indirect + github.com/containerd/containerd v1.7.14 // indirect github.com/danwakefield/fnmatch v0.0.0-20160403171240-cbb64ac3d964 // indirect github.com/dustin/go-humanize v1.0.0 // indirect github.com/fatih/color v1.16.0 // indirect @@ -101,7 +104,7 @@ require ( github.com/go-logr/logr v1.4.1 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.2.6 // indirect - github.com/golang/glog v1.1.2 // indirect + github.com/golang/glog v1.2.0 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/uuid v1.6.0 // indirect @@ -112,15 +115,15 @@ require ( github.com/hashicorp/go-plugin v1.6.0 // indirect github.com/hashicorp/go-uuid v1.0.3 // indirect github.com/hashicorp/hcl v1.0.0 // indirect - github.com/hashicorp/hcl/v2 v2.19.1 // indirect + github.com/hashicorp/hcl/v2 v2.20.1 // indirect github.com/hashicorp/terraform-svchost v0.1.1 // indirect github.com/hashicorp/yamux v0.1.1 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/jackc/chunkreader/v2 v2.0.1 // indirect - github.com/jackc/pgconn v1.14.1 // indirect + github.com/jackc/pgconn v1.14.3 // indirect github.com/jackc/pgio v1.0.0 // indirect github.com/jackc/pgpassfile v1.0.0 // indirect - github.com/jackc/pgproto3/v2 v2.3.2 // indirect + github.com/jackc/pgproto3/v2 v2.3.3 // indirect github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a // indirect github.com/logrusorgru/aurora v2.0.3+incompatible // indirect github.com/magiconair/properties v1.8.7 // indirect @@ -137,7 +140,7 @@ require ( github.com/olekukonko/tablewriter v0.0.5 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0 // indirect - github.com/pelletier/go-toml/v2 v2.1.0 // indirect + github.com/pelletier/go-toml/v2 v2.2.0 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/prometheus/client_golang v1.14.0 // indirect github.com/prometheus/client_model v0.3.0 // indirect @@ -159,26 +162,26 @@ require ( github.com/tkrajina/go-reflector v0.5.6 // indirect github.com/xlab/treeprint v1.2.0 // indirect github.com/yusufpapurcu/wmi v1.2.2 // indirect - github.com/zclconf/go-cty v1.14.2 // indirect + github.com/zclconf/go-cty v1.14.4 // indirect github.com/zclconf/go-cty-yaml v1.0.3 // indirect go.opencensus.io v0.24.0 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.23.1 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.1 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.1 // indirect - go.opentelemetry.io/otel/sdk v1.23.1 // indirect - go.opentelemetry.io/otel/sdk/metric v1.23.1 // indirect - go.opentelemetry.io/otel/trace v1.23.1 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.24.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.24.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.24.0 // indirect + go.opentelemetry.io/otel/sdk v1.24.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.24.0 // indirect + go.opentelemetry.io/otel/trace v1.24.0 // indirect go.opentelemetry.io/proto/otlp v1.1.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.21.0 // indirect golang.org/x/exp v0.0.0-20231006140011-7918f672742d - golang.org/x/net v0.19.0 // indirect - golang.org/x/oauth2 v0.15.0 // indirect - golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.16.0 // indirect + golang.org/x/net v0.22.0 // indirect + golang.org/x/oauth2 v0.17.0 // indirect + golang.org/x/sync v0.7.0 // indirect + golang.org/x/sys v0.18.0 // indirect golang.org/x/text v0.14.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231212172506-995d672761c0 // indirect - google.golang.org/grpc v1.61.1 // indirect + google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de // indirect + google.golang.org/grpc v1.63.2 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/go.sum b/go.sum index 30df1274..f910c1bc 100644 --- a/go.sum +++ b/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= -cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= +cloud.google.com/go v0.112.0 h1:tpFCD7hpHFlQ8yPwT3x+QeXqc2T6+n6T+hmABHfDUSM= +cloud.google.com/go v0.112.0/go.mod h1:3jEEVwZ/MHU4djK5t5RHuKOA/GbLddgTdVubX1qnPD4= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -68,8 +68,8 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute v1.23.3 h1:6sVlXXBmbd7jNX0Ipq0trII3e4n1/MsADLK6a+aiVlk= -cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= +cloud.google.com/go/compute v1.24.0 h1:phWcR2eWzRJaL/kOiJwfFsPs4BaKq1j6vnpZrc1YlVg= +cloud.google.com/go/compute v1.24.0/go.mod h1:kw1/T+h/+tK2LJK0wiPPx1intgdAM3j/g3hFDlscY40= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= @@ -109,8 +109,8 @@ cloud.google.com/go/gkehub v0.10.0/go.mod h1:UIPwxI0DsrpsVoWpLB0stwKCP+WFVG9+y97 cloud.google.com/go/grafeas v0.2.0/go.mod h1:KhxgtF2hb0P191HlY5besjYm6MqTSTj3LSI+M+ByZHc= cloud.google.com/go/iam v0.3.0/go.mod h1:XzJPvDayI+9zsASAFO68Hk07u3z+f+JrT2xXNdp4bnY= cloud.google.com/go/iam v0.5.0/go.mod h1:wPU9Vt0P4UmCux7mqtRu6jcpPAb74cP1fh50J3QpkUc= -cloud.google.com/go/iam v1.1.5 h1:1jTsCu4bcsNsE4iiqNT5SHwrDRCfRmIaaaVFhRveTJI= -cloud.google.com/go/iam v1.1.5/go.mod h1:rB6P/Ic3mykPbFio+vo7403drjlgvoWfYpJhMXEbzv8= +cloud.google.com/go/iam v1.1.6 h1:bEa06k05IO4f4uJonbB5iAgKTPpABy1ayxaIZV/GHVc= +cloud.google.com/go/iam v1.1.6/go.mod h1:O0zxdPeGBoFdWW3HWmBxJsk0pfvNM/p/qa82rWOGTwI= cloud.google.com/go/language v1.4.0/go.mod h1:F9dRpNFQmJbkaop6g0JhSBXCNlO90e1KWx5iDdxbWic= cloud.google.com/go/language v1.6.0/go.mod h1:6dJ8t3B+lUYfStgls25GusK04NLh3eDLQnWM3mdEbhI= cloud.google.com/go/lifesciences v0.5.0/go.mod h1:3oIKy8ycWGPUyZDR/8RNnTOYevhaMLqh5vLUXs9zvT8= @@ -171,8 +171,8 @@ cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9 cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= -cloud.google.com/go/storage v1.35.1 h1:B59ahL//eDfx2IIKFBeT5Atm9wnNmj3+8xG/W4WB//w= -cloud.google.com/go/storage v1.35.1/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= +cloud.google.com/go/storage v1.36.0 h1:P0mOkAcaJxhCTvAkMhxMfrTKiNcub4YmmPBtlhAyTr8= +cloud.google.com/go/storage v1.36.0/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= cloud.google.com/go/talent v1.1.0/go.mod h1:Vl4pt9jiHKvOgF9KoZo6Kob9oV4lwd/ZD5Cto54zDRw= cloud.google.com/go/talent v1.2.0/go.mod h1:MoNF9bhFQbiJ6eFD3uSsg0uBALw4n4gaCaEjBw9zo8g= cloud.google.com/go/videointelligence v1.6.0/go.mod h1:w0DIDlVRKtwPCn/C4iwZIJdvC69yInhW0cfi+p546uU= @@ -257,19 +257,17 @@ github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= +github.com/cncf/xds/go v0.0.0-20231128003011-0fa0005c9caa h1:jQCWAUqqlij9Pgj2i/PB79y4KOPYVyFYdROxgaCwdTQ= +github.com/cncf/xds/go v0.0.0-20231128003011-0fa0005c9caa/go.mod h1:x/1Gn8zydmfq8dk6e9PdstVsDgu9RuyIIJqAaF//0IM= github.com/containerd/cgroups v1.1.0 h1:v8rEWFl6EoqHB+swVNjVoCJE8o3jX7e8nqBGPLaDFBM= github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHqJDGwsa1mIw= -github.com/containerd/containerd v1.7.13 h1:wPYKIeGMN8vaggSKuV1X0wZulpMz4CrgEsZdaCyB6Is= -github.com/containerd/containerd v1.7.13/go.mod h1:zT3up6yTRfEUa6+GsITYIJNgSVL9NQ4x4h1RPzk0Wu4= +github.com/containerd/containerd v1.7.14 h1:H/XLzbnGuenZEGK+v0RkwTdv2u1QFAruMe5N0GNPJwA= +github.com/containerd/containerd v1.7.14/go.mod h1:YMC9Qt5yzNqXx/fO4j/5yYVIHXSRrlB3H7sxkUTvspg= github.com/containerd/continuity v0.4.2 h1:v3y/4Yz5jwnvqPKJJ+7Wf93fyWoCB3F5EclWG023MDM= github.com/containerd/continuity v0.4.2/go.mod h1:F6PTNCKepoxEaXLQp3wDAjygEnImnZ/7o4JzpodfroQ= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= -github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/danwakefield/fnmatch v0.0.0-20160403171240-cbb64ac3d964 h1:y5HC9v93H5EPKqaS1UYVg1uYah5Xf51mBfIoWehClUQ= github.com/danwakefield/fnmatch v0.0.0-20160403171240-cbb64ac3d964/go.mod h1:Xd9hchkHSWYkEqJwUGisez3G1QY8Ryz0sdWrLPMGjLk= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -298,18 +296,20 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.m github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/envoyproxy/protoc-gen-validate v1.0.4 h1:gVPz/FMfvh57HdSJQyvBtF00j8JU4zdyUgIUNhlgg0A= +github.com/envoyproxy/protoc-gen-validate v1.0.4/go.mod h1:qys6tmnRsYrQqIhm2bvKZH4Blx/1gTIZ2UKVY1M+Yew= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= -github.com/felixge/httpsnoop v1.0.3 h1:s/nj+GCswXYzN5v2DpNMuMQYe+0DDwt5WVCU6CWBdXk= -github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= +github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= -github.com/gabriel-vasile/mimetype v1.4.2 h1:w5qFW6JKBz9Y393Y4q372O9A7cUSequkh1Q7OhCmWKU= -github.com/gabriel-vasile/mimetype v1.4.2/go.mod h1:zApsH/mKG4w07erKIaJPFiX0Tsq9BFQgN3qGY5GnNgA= +github.com/gabriel-vasile/mimetype v1.4.3 h1:in2uUcidCuFcDKtdcBxlR0rJ1+fsokWf+uqxgUFjbI0= +github.com/gabriel-vasile/mimetype v1.4.3/go.mod h1:d8uq/6HKRL6CGdk+aubisF/M5GcPfT7nKyLpA0lbSSk= github.com/gertd/go-pluralize v0.2.1 h1:M3uASbVjMnTsPb0PNqg+E/24Vwigyo/tvyMTtAlLgiA= github.com/gertd/go-pluralize v0.2.1/go.mod h1:rbYaKDbsXxmRfr8uygAEKhOWsjyrrqrkHVpZvoOp8zk= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= @@ -338,17 +338,19 @@ github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/o github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= -github.com/go-playground/validator/v10 v10.15.5 h1:LEBecTWb/1j5TNY1YYG2RcOUN3R7NLylN+x8TTueE24= -github.com/go-playground/validator/v10 v10.15.5/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= +github.com/go-playground/validator/v10 v10.19.0 h1:ol+5Fu+cSq9JD7SoSqe04GMI92cbn0+wvQ3bZ8b/AU4= +github.com/go-playground/validator/v10 v10.19.0/go.mod h1:dbuPbCMFw/DrkbEynArYaCwl3amGuJotoKCe95atGMM= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= +github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= github.com/go-test/deep v1.1.0 h1:WOcxcdHcvdgThNXjw0t76K42FXTU7HpNQWHpA2HHNlg= github.com/go-test/deep v1.1.0/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.1.2 h1:DVjP2PbBOzHyzA+dn3WhHIq4NdVu3Q+pvivFICf/7fo= -github.com/golang/glog v1.1.2/go.mod h1:zR+okUeTbrL6EL3xHUDxZuEtGv04p5shwip1+mL/rLQ= +github.com/golang/glog v1.2.0 h1:uCdmnmatrKCgMBlM4rMuJZWOkPDqdbZPnrMXDY4gI68= +github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -424,6 +426,7 @@ github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1 h1:K6RDEckDVWvDI9JAJYCmNdQXq6neHJOYx3V6jnqNEec= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= @@ -459,8 +462,8 @@ github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9n github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-getter v1.7.3 h1:bN2+Fw9XPFvOCjB0UOevFIMICZ7G2XSQHzfvLUyOM5E= github.com/hashicorp/go-getter v1.7.3/go.mod h1:W7TalhMmbPmsSMdNjD0ZskARur/9GJ17cfHTRtXV744= -github.com/hashicorp/go-hclog v1.6.2 h1:NOtoftovWkDheyUM/8JW3QMiXyxJK3uHRK7wV04nD2I= -github.com/hashicorp/go-hclog v1.6.2/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= +github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k= +github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= github.com/hashicorp/go-plugin v1.6.0 h1:wgd4KxHJTVGGqWBq4QPB1i5BZNEx9BR8+OFmHDmTk8A= @@ -475,8 +478,8 @@ github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= -github.com/hashicorp/hcl/v2 v2.19.1 h1://i05Jqznmb2EXqa39Nsvyan2o5XyMowW5fnCKW5RPI= -github.com/hashicorp/hcl/v2 v2.19.1/go.mod h1:ThLC89FV4p9MPW804KVbe/cEXoQ8NZEh+JtMeeGErHE= +github.com/hashicorp/hcl/v2 v2.20.1 h1:M6hgdyz7HYt1UN9e61j+qKJBqR3orTWbI1HKBJEdxtc= +github.com/hashicorp/hcl/v2 v2.20.1/go.mod h1:TZDqQ4kNKCbh1iJp99FdPiUaVDDUPivbqxZulxDYqL4= github.com/hashicorp/terraform-registry-address v0.2.1 h1:QuTf6oJ1+WSflJw6WYOHhLgwUiQ0FrROpHPYFtwTYWM= github.com/hashicorp/terraform-registry-address v0.2.1/go.mod h1:BSE9fIFzp0qWsJUUyGquo4ldV9k2n+psif6NYkBRS3Y= github.com/hashicorp/terraform-svchost v0.1.1 h1:EZZimZ1GxdqFRinZ1tpJwVxxt49xc/S52uzrw4x0jKQ= @@ -489,47 +492,23 @@ github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1: github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= github.com/jackc/chunkreader/v2 v2.0.0/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= github.com/jackc/chunkreader/v2 v2.0.1 h1:i+RDz65UE+mmpjTfyz0MoVTnzeYxroil2G82ki7MGG8= github.com/jackc/chunkreader/v2 v2.0.1/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= -github.com/jackc/pgconn v0.0.0-20190420214824-7e0022ef6ba3/go.mod h1:jkELnwuX+w9qN5YIfX0fl88Ehu4XC3keFuOJJk9pcnA= -github.com/jackc/pgconn v0.0.0-20190824142844-760dd75542eb/go.mod h1:lLjNuW/+OfW9/pnVKPazfWOgNfH2aPem8YQ7ilXGvJE= -github.com/jackc/pgconn v0.0.0-20190831204454-2fabfa3c18b7/go.mod h1:ZJKsE/KZfsUgOEh9hBm+xYTstcNHg7UPMVJqRfQxq4s= -github.com/jackc/pgconn v1.8.0/go.mod h1:1C2Pb36bGIP9QHGBYCjnyhqu7Rv3sGshaQUvmfGIB/o= -github.com/jackc/pgconn v1.9.0/go.mod h1:YctiPyvzfU11JFxoXokUOOKQXQmDMoJL9vJzHH8/2JY= -github.com/jackc/pgconn v1.14.1 h1:smbxIaZA08n6YuxEX1sDyjV/qkbtUtkH20qLkR9MUR4= -github.com/jackc/pgconn v1.14.1/go.mod h1:9mBNlny0UvkgJdCDvdVHYSjI+8tD2rnKK69Wz8ti++E= +github.com/jackc/pgconn v1.14.3 h1:bVoTr12EGANZz66nZPkMInAV/KHD2TxH9npjXXgiB3w= +github.com/jackc/pgconn v1.14.3/go.mod h1:RZbme4uasqzybK2RK5c65VsHxoyaml09lx3tXOcO/VM= github.com/jackc/pgio v1.0.0 h1:g12B9UwVnzGhueNavwioyEEpAmqMe1E/BN9ES+8ovkE= github.com/jackc/pgio v1.0.0/go.mod h1:oP+2QK2wFfUWgr+gxjoBH9KGBb31Eio69xUb0w5bYf8= -github.com/jackc/pgmock v0.0.0-20190831213851-13a1b77aafa2/go.mod h1:fGZlG77KXmcq05nJLRkk0+p82V8B8Dw8KN2/V9c/OAE= -github.com/jackc/pgmock v0.0.0-20201204152224-4fe30f7445fd/go.mod h1:hrBW0Enj2AZTNpt/7Y5rr2xe/9Mn757Wtb2xeBzPv2c= github.com/jackc/pgmock v0.0.0-20210724152146-4ad1a8207f65 h1:DadwsjnMwFjfWc9y5Wi/+Zz7xoE5ALHsRQlOctkOiHc= github.com/jackc/pgmock v0.0.0-20210724152146-4ad1a8207f65/go.mod h1:5R2h2EEX+qri8jOWMbJCtaPWkrrNc7OHwsp2TCqp7ak= github.com/jackc/pgpassfile v1.0.0 h1:/6Hmqy13Ss2zCq62VdNG8tM1wchn8zjSGOBJ6icpsIM= github.com/jackc/pgpassfile v1.0.0/go.mod h1:CEx0iS5ambNFdcRtxPj5JhEz+xB6uRky5eyVu/W2HEg= -github.com/jackc/pgproto3 v1.1.0/go.mod h1:eR5FA3leWg7p9aeAqi37XOTgTIbkABlvcPB3E5rlc78= -github.com/jackc/pgproto3/v2 v2.0.0-alpha1.0.20190420180111-c116219b62db/go.mod h1:bhq50y+xrl9n5mRYyCBFKkpRVTLYJVWeCc+mEAI3yXA= -github.com/jackc/pgproto3/v2 v2.0.0-alpha1.0.20190609003834-432c2951c711/go.mod h1:uH0AWtUmuShn0bcesswc4aBTWGvw0cAxIJp+6OB//Wg= -github.com/jackc/pgproto3/v2 v2.0.0-rc3/go.mod h1:ryONWYqW6dqSg1Lw6vXNMXoBJhpzvWKnT95C46ckYeM= -github.com/jackc/pgproto3/v2 v2.0.0-rc3.0.20190831210041-4c03ce451f29/go.mod h1:ryONWYqW6dqSg1Lw6vXNMXoBJhpzvWKnT95C46ckYeM= -github.com/jackc/pgproto3/v2 v2.0.6/go.mod h1:WfJCnwN3HIg9Ish/j3sgWXnAfK8A9Y0bwXYU5xKaEdA= -github.com/jackc/pgproto3/v2 v2.1.1/go.mod h1:WfJCnwN3HIg9Ish/j3sgWXnAfK8A9Y0bwXYU5xKaEdA= -github.com/jackc/pgproto3/v2 v2.3.2 h1:7eY55bdBeCz1F2fTzSz69QC+pG46jYq9/jtSPiJ5nn0= -github.com/jackc/pgproto3/v2 v2.3.2/go.mod h1:WfJCnwN3HIg9Ish/j3sgWXnAfK8A9Y0bwXYU5xKaEdA= -github.com/jackc/pgservicefile v0.0.0-20200714003250-2b9c44734f2b/go.mod h1:vsD4gTJCa9TptPL8sPkXrLZ+hDuNrZCnj29CQpr4X1E= +github.com/jackc/pgproto3/v2 v2.3.3 h1:1HLSx5H+tXR9pW3in3zaztoEwQYRC9SQaYUHjTSUOag= +github.com/jackc/pgproto3/v2 v2.3.3/go.mod h1:WfJCnwN3HIg9Ish/j3sgWXnAfK8A9Y0bwXYU5xKaEdA= github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a h1:bbPeKD0xmW/Y25WS6cokEszi5g+S0QxI/d45PkRi7Nk= github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a/go.mod h1:5TJZWKEWniPve33vlWYSoGYefn3gLQRzjfDlhSJ9ZKM= -github.com/jackc/pgtype v0.0.0-20190421001408-4ed0de4755e0/go.mod h1:hdSHsc1V01CGwFsrv11mJRHWJ6aifDLfdV3aVjFF0zg= -github.com/jackc/pgtype v0.0.0-20190824184912-ab885b375b90/go.mod h1:KcahbBH1nCMSo2DXpzsoWOAfFkdEtEJpPbVLq8eE+mc= -github.com/jackc/pgtype v0.0.0-20190828014616-a8802b16cc59/go.mod h1:MWlu30kVJrUS8lot6TQqcg7mtthZ9T0EoIBFiJcmcyw= -github.com/jackc/pgx/v4 v4.0.0-20190420224344-cc3461e65d96/go.mod h1:mdxmSJJuR08CZQyj1PVQBHy9XOp5p8/SHH6a0psbY9Y= -github.com/jackc/pgx/v4 v4.0.0-20190421002000-1b8f0016e912/go.mod h1:no/Y67Jkk/9WuGR0JG/JseM9irFbnEPbuWV2EELPNuM= -github.com/jackc/pgx/v4 v4.0.0-pre1.0.20190824185557-6972a5742186/go.mod h1:X+GQnOEnf1dqHGpw7JmHqHc1NxDoalibchSk9/RWuDc= -github.com/jackc/pgx/v5 v5.5.4 h1:Xp2aQS8uXButQdnCMWNmvx6UysWQQC+u1EoizjguY+8= -github.com/jackc/pgx/v5 v5.5.4/go.mod h1:ez9gk+OAat140fv9ErkZDYFWmXLfV+++K0uAOiwgm1A= -github.com/jackc/puddle v0.0.0-20190413234325-e4ced69a3a2b/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= -github.com/jackc/puddle v0.0.0-20190608224051-11cab39313c9/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= +github.com/jackc/pgx/v5 v5.5.5 h1:amBjrZVmksIdNjxGW/IiIMzxMKZFelXbUoPNb+8sjQw= +github.com/jackc/pgx/v5 v5.5.5/go.mod h1:ez9gk+OAat140fv9ErkZDYFWmXLfV+++K0uAOiwgm1A= github.com/jackc/puddle/v2 v2.2.1 h1:RhxXJtFG022u4ibrCSMSiu5aOq1i77R3OHKNJj77OAk= github.com/jackc/puddle/v2 v2.2.1/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= @@ -554,37 +533,27 @@ github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrD github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= github.com/klauspost/compress v1.17.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= -github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= -github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= -github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= +github.com/leodido/go-urn v1.4.0 h1:WT9HwE9SGECu3lg4d/dIA+jxlljEa1/ffXKmRjqdmIQ= +github.com/leodido/go-urn v1.4.0/go.mod h1:bvxc+MVxLKB4z00jd1z+Dvzr47oO32F/QSNjSBOlFxI= github.com/logrusorgru/aurora v2.0.3+incompatible h1:tOpm7WcpBTn4fjmVfgpQq0EfczGlG91VSDkswnjF5A8= github.com/logrusorgru/aurora v2.0.3+incompatible/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= @@ -622,16 +591,18 @@ github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= +github.com/onsi/ginkgo/v2 v2.13.0 h1:0jY9lJquiL8fcf3M4LAXN5aMlS/b2BV86HFFPCPMgE4= +github.com/onsi/ginkgo/v2 v2.13.0/go.mod h1:TE309ZR8s5FsKKpuB1YAQYBzCaAfUgatB/xlT/ETL/o= +github.com/onsi/gomega v1.28.1 h1:MijcGUbfYuznzK/5R4CPNoUP/9Xvuo20sXfEm6XxoTA= +github.com/onsi/gomega v1.28.1/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0 h1:8SG7/vwALn54lVB/0yZ/MMwhFrPYtpEHQb2IpWsCzug= github.com/opencontainers/image-spec v1.1.0/go.mod h1:W4s4sFTMaBeK1BQLXbG4AdM2szdn85PY75RI83NrTrM= -github.com/oras-project/oras-credentials-go v0.3.1 h1:sfGqZ8sjPifEaOtjHOQTPr8D+Tql4bpw58Dd9wjmm9w= -github.com/oras-project/oras-credentials-go v0.3.1/go.mod h1:fFCebDQo0Do+gnM96uV9YUnRay0pwuRQupypvofsp4s= github.com/otiai10/copy v1.14.0 h1:dCI/t1iTdYGtkvCuBG2BgR6KZa83PTclw4U5n2wAllU= github.com/otiai10/copy v1.14.0/go.mod h1:ECfuL02W+/FkTWZWgQqXPWZgW9oeKCSQ5qVfSc4qc4w= -github.com/pelletier/go-toml/v2 v2.1.0 h1:FnwAJ4oYMvbT/34k9zzHuZNrhlz48GB3/s6at6/MHO4= -github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= +github.com/pelletier/go-toml/v2 v2.2.0 h1:QLgLl2yMN7N+ruc31VynXs1vhMZa7CeHHejIeBAsoHo= +github.com/pelletier/go-toml/v2 v2.2.0/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -671,28 +642,20 @@ github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6L github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= -github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= github.com/rs/xid v1.5.0 h1:mKX4bl4iPYJtEIxp6CYiUuLQ/8DYMoz0PUdtGgMFRVc= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= -github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= -github.com/rs/zerolog v1.15.0/go.mod h1:xYTKnLHcpfU2225ny5qZjxnj9NvkumZYjJHlAThCjNc= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sagikazarmark/locafero v0.4.0 h1:HApY1R9zGo4DBgr7dqsTH/JJxLTTsOt7u6keLGt6kNQ= github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= -github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= -github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= -github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/sethvargo/go-retry v0.2.4 h1:T+jHEQy/zKJf5s95UkguisicE0zuF9y7+/vgz08Ocec= github.com/sethvargo/go-retry v0.2.4/go.mod h1:1afjQuvh7s4gflMObvjLPaWgluLLyhA1wmVZ6KLpICw= github.com/shiena/ansicolor v0.0.0-20230509054315-a9deabde6e02 h1:v9ezJDHA1XGxViAUSIoO/Id7Fl63u6d0YmsAm+/p2hs= github.com/shiena/ansicolor v0.0.0-20230509054315-a9deabde6e02/go.mod h1:RF16/A3L0xSa0oSERcnhd8Pu3IXSDZSK2gmGIMsttFE= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= -github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= -github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= @@ -714,9 +677,9 @@ github.com/stevenle/topsort v0.2.0 h1:LLWgtp34HPX6/RBDRS0kElVxGOTzGBLI1lSAa5Lb46 github.com/stevenle/topsort v0.2.0/go.mod h1:ck2WG2/ZrOr6dLApQ/5Xrqy5wv3T0qhKYWE7r9tkibc= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= @@ -727,25 +690,29 @@ github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= +github.com/thediveo/enumflag/v2 v2.0.5 h1:VJjvlAqUb6m6mxOrB/0tfBJI0Kvi9wJ8ulh38xK87i8= +github.com/thediveo/enumflag/v2 v2.0.5/go.mod h1:0NcG67nYgwwFsAvoQCmezG0J0KaIxZ0f7skg9eLq1DA= +github.com/thediveo/success v1.0.1 h1:NVwUOwKUwaN8szjkJ+vsiM2L3sNBFscldoDJ2g2tAPg= +github.com/thediveo/success v1.0.1/go.mod h1:AZ8oUArgbIsCuDEWrzWNQHdKnPbDOLQsWOFj9ynwLt0= github.com/tklauser/go-sysconf v0.3.9 h1:JeUVdAOWhhxVcU6Eqr/ATFHgXk/mmiItdKeJPev3vTo= github.com/tklauser/go-sysconf v0.3.9/go.mod h1:11DU/5sG7UexIrp/O6g35hrWzu0JxlwQ3LSFUzyeuhs= github.com/tklauser/numcpus v0.3.0 h1:ILuRUQBtssgnxw0XXIjKUC56fgnOrFoQQ/4+DeU2biQ= github.com/tklauser/numcpus v0.3.0/go.mod h1:yFGUr7TUHQRAhyqBcEg0Ge34zDBAsIvJJcyE6boqnA8= github.com/tkrajina/go-reflector v0.5.6 h1:hKQ0gyocG7vgMD2M3dRlYN6WBBOmdoOzJ6njQSepKdE= github.com/tkrajina/go-reflector v0.5.6/go.mod h1:ECbqLgccecY5kPmPmXg1MrHW585yMcDkVl6IvJe64T4= -github.com/turbot/go-kit v0.9.0 h1:7RVIFpHa0vdsh8GMEr4cM+D4jQ7h4pGeFmT2EVG/U5Y= -github.com/turbot/go-kit v0.9.0/go.mod h1:fFQqR59I5z5JeeBLfK1PjSifn4Oprs3NiQx0CxeSJxs= -github.com/turbot/pipe-fittings v0.2.2 h1:+DVVTu0gIaq2nxXy285SvdJPnpjt/ySxMZ76dEaB5BE= -github.com/turbot/pipe-fittings v0.2.2/go.mod h1:HcB+ftqI2fHyE/ktn0v6VfdNsP4WpuB4oQz7/t1Z/Ac= -github.com/turbot/steampipe v1.7.0-rc.0.0.20240223132218-d8ddcad4cc90 h1:staXtiUBNyNcx4KhDVTRaKAyfrSJ7r1Ws7ydChfbA2E= -github.com/turbot/steampipe v1.7.0-rc.0.0.20240223132218-d8ddcad4cc90/go.mod h1:f7Y70HJeJvtM1GYFuIXKDG1s756p1jK0hRIAK6WPicY= -github.com/turbot/steampipe-plugin-sdk/v5 v5.9.0 h1:L+VBJlbVj2JuHiJVFpx0y8XoEZVjmRsfTxwoMCtrbsE= -github.com/turbot/steampipe-plugin-sdk/v5 v5.9.0/go.mod h1:vqj/+uM5I7U5fYhlvMvKc1uirKqVCR9YuxVIzhIbA2I= +github.com/turbot/go-kit v0.10.0-rc.0 h1:kd+jp2ibbIV33Hc8SsMAN410Dl9Pz6SJ40axbKUlSoA= +github.com/turbot/go-kit v0.10.0-rc.0/go.mod h1:fFQqR59I5z5JeeBLfK1PjSifn4Oprs3NiQx0CxeSJxs= +github.com/turbot/pipe-fittings v1.1.0 h1:GQ6Hc73uihduLJjiqqj4Iz97w0jQ+QGmd1628X9WnrQ= +github.com/turbot/pipe-fittings v1.1.0/go.mod h1:Cgy232VEhVjtDibJS8v5Zf4lKQnfZJOBtsuUNZ7MzTc= +github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a h1:viFKbPBX99c3Ml1VNMrz0ErPuQ0jBy9MDvJHIwv9cBg= +github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a/go.mod h1:FCNkoNAsGRk4f+C18Za7ttH2xRCb+zXr2e+jOFSfM9Y= +github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3 h1:QU64Yve9b1I4bhpG4mUyLpCBtaCIZTkTRAuBpii8qfQ= +github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3/go.mod h1:DJ9gPbPzmCe4M2sp+KzCmOhFuucl5/6hXnXvFvS/9nQ= github.com/turbot/terraform-components v0.0.0-20231213122222-1f3526cab7a7 h1:qDMxFVd8Zo0rIhnEBdCIbR+T6WgjwkxpFZMN8zZmmjg= github.com/turbot/terraform-components v0.0.0-20231213122222-1f3526cab7a7/go.mod h1:5hzpfalEjfcJWp9yq75/EZoEu2Mzm34eJAPm3HOW2tw= github.com/ulikunitz/xz v0.5.10 h1:t92gobL9l3HE202wg3rlk19F6X+JOxl9BBrCCMYEYd8= @@ -760,13 +727,12 @@ github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1 github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg= github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= -github.com/zclconf/go-cty v1.14.2 h1:kTG7lqmBou0Zkx35r6HJHUQTvaRPr5bIAf3AoHS0izI= -github.com/zclconf/go-cty v1.14.2/go.mod h1:VvMs5i0vgZdhYawQNq5kePSpLAoz8u1xvZgrPIxfnZE= +github.com/zclconf/go-cty v1.14.4 h1:uXXczd9QDGsgu0i/QFR/hzI5NYCHLf6NQw/atrbnhq8= +github.com/zclconf/go-cty v1.14.4/go.mod h1:VvMs5i0vgZdhYawQNq5kePSpLAoz8u1xvZgrPIxfnZE= github.com/zclconf/go-cty-debug v0.0.0-20191215020915-b22d67c1ba0b h1:FosyBZYxY34Wul7O/MSKey3txpPYyCqVO5ZyceuQJEI= github.com/zclconf/go-cty-debug v0.0.0-20191215020915-b22d67c1ba0b/go.mod h1:ZRKQfBXbGkpdV6QMzT3rU1kSTAnfu1dO8dPKjYprgj8= github.com/zclconf/go-cty-yaml v1.0.3 h1:og/eOQ7lvA/WWhHGFETVWNduJM7Rjsv2RRpx1sdFMLc= github.com/zclconf/go-cty-yaml v1.0.3/go.mod h1:9YLUH4g7lOhVWqUbctnVlZ5KLpg7JAprQNgxSZ1Gyxs= -github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= @@ -776,53 +742,44 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 h1:x8Z78aZx8cOF0+Kkazoc7lwUNMGy0LrzEMxTm4BbTxg= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0/go.mod h1:62CPTSry9QZtOaSsE3tOzhx6LzDhHnXJ6xHeMNNiM6Q= -go.opentelemetry.io/otel v1.23.1 h1:Za4UzOqJYS+MUczKI320AtqZHZb7EqxO00jAHE0jmQY= -go.opentelemetry.io/otel v1.23.1/go.mod h1:Td0134eafDLcTS4y+zQ26GE8u3dEuRBiBCTUIRHaikA= -go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.23.1 h1:ZqRWZJGHXV/1yCcEEVJ6/Uz2JtM79DNS8OZYa3vVY/A= -go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.23.1/go.mod h1:D7ynngPWlGJrqyGSDOdscuv7uqttfCE3jcBvffDv9y4= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.1 h1:o8iWeVFa1BcLtVEV0LzrCxV2/55tB3xLxADr6Kyoey4= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.1/go.mod h1:SEVfdK4IoBnbT2FXNM/k8yC08MrfbhWk3U4ljM8B3HE= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.1 h1:p3A5+f5l9e/kuEBwLOrnpkIDHQFlHmbiVxMURWRK6gQ= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.1/go.mod h1:OClrnXUjBqQbInvjJFjYSnMxBSCXBF8r3b34WqjiIrQ= -go.opentelemetry.io/otel/metric v1.23.1 h1:PQJmqJ9u2QaJLBOELl1cxIdPcpbwzbkjfEyelTl2rlo= -go.opentelemetry.io/otel/metric v1.23.1/go.mod h1:mpG2QPlAfnK8yNhNJAxDZruU9Y1/HubbC+KyH8FaCWI= -go.opentelemetry.io/otel/sdk v1.23.1 h1:O7JmZw0h76if63LQdsBMKQDWNb5oEcOThG9IrxscV+E= -go.opentelemetry.io/otel/sdk v1.23.1/go.mod h1:LzdEVR5am1uKOOwfBWFef2DCi1nu3SA8XQxx2IerWFk= -go.opentelemetry.io/otel/sdk/metric v1.23.1 h1:T9/8WsYg+ZqIpMWwdISVVrlGb/N0Jr1OHjR/alpKwzg= -go.opentelemetry.io/otel/sdk/metric v1.23.1/go.mod h1:8WX6WnNtHCgUruJ4TJ+UssQjMtpxkpX0zveQC8JG/E0= -go.opentelemetry.io/otel/trace v1.23.1 h1:4LrmmEd8AU2rFvU1zegmvqW7+kWarxtNOPyeL6HmYY8= -go.opentelemetry.io/otel/trace v1.23.1/go.mod h1:4IpnpJFwr1mo/6HL8XIPJaE9y0+u1KcVmuW7dwFSVrI= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 h1:UNQQKPfTDe1J81ViolILjTKPr9WetKW6uei2hFgJmFs= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0/go.mod h1:r9vWsPS/3AQItv3OSlEJ/E4mbrhUbbw18meOjArPtKQ= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0 h1:sv9kVfal0MK0wBMCOGr+HeJm9v803BkJxGrk2au7j08= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0/go.mod h1:SK2UL73Zy1quvRPonmOmRDiWk1KBV3LyIeeIxcEApWw= +go.opentelemetry.io/otel v1.24.0 h1:0LAOdjNmQeSTzGBzduGe/rU4tZhMwL5rWgtp9Ku5Jfo= +go.opentelemetry.io/otel v1.24.0/go.mod h1:W7b9Ozg4nkF5tWI5zsXkaKKDjdVjpD4oAt9Qi/MArHo= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.24.0 h1:f2jriWfOdldanBwS9jNBdeOKAQN7b4ugAMaNu1/1k9g= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.24.0/go.mod h1:B+bcQI1yTY+N0vqMpoZbEN7+XU4tNM0DmUiOwebFJWI= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.24.0 h1:t6wl9SPayj+c7lEIFgm4ooDBZVb01IhLB4InpomhRw8= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.24.0/go.mod h1:iSDOcsnSA5INXzZtwaBPrKp/lWu/V14Dd+llD0oI2EA= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.24.0 h1:Mw5xcxMwlqoJd97vwPxA8isEaIoxsta9/Q51+TTJLGE= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.24.0/go.mod h1:CQNu9bj7o7mC6U7+CA/schKEYakYXWr79ucDHTMGhCM= +go.opentelemetry.io/otel/metric v1.24.0 h1:6EhoGWWK28x1fbpA4tYTOWBkPefTDQnb8WSGXlc88kI= +go.opentelemetry.io/otel/metric v1.24.0/go.mod h1:VYhLe1rFfxuTXLgj4CBiyz+9WYBA8pNGJgDcSFRKBco= +go.opentelemetry.io/otel/sdk v1.24.0 h1:YMPPDNymmQN3ZgczicBY3B6sf9n62Dlj9pWD3ucgoDw= +go.opentelemetry.io/otel/sdk v1.24.0/go.mod h1:KVrIYw6tEubO9E96HQpcmpTKDVn9gdv35HoYiQWGDFg= +go.opentelemetry.io/otel/sdk/metric v1.24.0 h1:yyMQrPzF+k88/DbH7o4FMAs80puqd+9osbiBrJrz/w8= +go.opentelemetry.io/otel/sdk/metric v1.24.0/go.mod h1:I6Y5FjH6rvEnTTAYQz3Mmv2kl6Ek5IIrmwTLqMrrOE0= +go.opentelemetry.io/otel/trace v1.24.0 h1:CsKnnL4dUAr/0llH9FKuc698G04IrpWV0MQA/Y1YELI= +go.opentelemetry.io/otel/trace v1.24.0/go.mod h1:HPc3Xr/cOApsBI154IU0OI0HJexz+aw5uPdbs3UCjNU= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.opentelemetry.io/proto/otlp v1.1.0 h1:2Di21piLrCqJ3U3eXGCTPHE9R8Nh+0uglSnOyxikMeI= go.opentelemetry.io/proto/otlp v1.1.0/go.mod h1:GpBHCBWiqvVLDqmHZsoMM3C5ySeKTC7ej/RNTae6MdY= -go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE= go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= -go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI= go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ= -go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20190411191339-88737f569e3a/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201203163018-be400aefbc4c/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.21.0 h1:X31++rzVUdKhX5sWmSOFZxx8UW/ldWx55cbf08iNAMA= +golang.org/x/crypto v0.21.0/go.mod h1:0BP7YvVV9gBbVKyeTG0Gyn+gZm94bibOW5BjDEYAOMs= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -877,7 +834,6 @@ golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -914,9 +870,8 @@ golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= -golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= -golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= +golang.org/x/net v0.22.0 h1:9sGLhx7iRIHEiX0oAJ3MRZMUCElJgy7Br1nO+AMN3Tc= +golang.org/x/net v0.22.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -942,8 +897,8 @@ golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= -golang.org/x/oauth2 v0.15.0 h1:s8pnnxNVzjWyrvYdFUQq5llS1PX2zhPXmccZv99h7uQ= -golang.org/x/oauth2 v0.15.0/go.mod h1:q48ptWNTY5XWf+JNten23lcvHpLJ0ZSxF5ttTHKVCAM= +golang.org/x/oauth2 v0.17.0 h1:6m3ZPmLEFdVxKKWnKq4VqZ60gutO35zm+zrAHVmHyDQ= +golang.org/x/oauth2 v0.17.0/go.mod h1:OzPDGQiuQMguemayvdylqddI7qcD9lnSDb+1FiwQ5HA= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -958,15 +913,13 @@ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= -golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= +golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -975,10 +928,8 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1044,17 +995,14 @@ golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= -golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= +golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= +golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= -golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= +golang.org/x/term v0.18.0 h1:FcHjZXDMxI8mM3nwhX9HlKop4C0YQvCVCdwYl2wOtE8= +golang.org/x/term v0.18.0/go.mod h1:ILwASektA3OnRv7amZ1xhE/KTR+u50pbXfZ03+6Nx58= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1066,7 +1014,6 @@ golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1081,14 +1028,12 @@ golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3 golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190425163242-31fd60d6bfdc/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1130,8 +1075,6 @@ golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.14.0 h1:jvNa2pY0M4r62jkRQ6RwEZZyPcymeL9XZMLBbV7U2nc= golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= -golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1189,8 +1132,8 @@ google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= -google.golang.org/api v0.153.0 h1:N1AwGhielyKFaUqH07/ZSIQR3uNPcV7NVw0vj+j4iR4= -google.golang.org/api v0.153.0/go.mod h1:3qNJX5eOmhiWYc67jRA/3GsDw97UFb5ivv7Y2PrriAY= +google.golang.org/api v0.162.0 h1:Vhs54HkaEpkMBdgGdOT2P6F0csGG/vxDS0hWHJzmmps= +google.golang.org/api v0.162.0/go.mod h1:6SulDkfoBIg4NFmCuZ39XeeAgSHCPecfSUuDyYlAHs0= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -1301,12 +1244,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231212172506-995d672761c0 h1:YJ5pD9rF8o9Qtta0Cmy9rdBwkSjrTCT6XTiUQVOtIos= -google.golang.org/genproto v0.0.0-20231212172506-995d672761c0/go.mod h1:l/k7rMz0vFTBPy+tFSGvXEd3z+BcoG1k7EHbqm+YBsY= -google.golang.org/genproto/googleapis/api v0.0.0-20240102182953-50ed04b92917 h1:rcS6EyEaoCO52hQDupoSfrxI3R6C2Tq741is7X8OvnM= -google.golang.org/genproto/googleapis/api v0.0.0-20240102182953-50ed04b92917/go.mod h1:CmlNWB9lSezaYELKS5Ym1r44VrrbPUa7JTvw+6MbpJ0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240102182953-50ed04b92917 h1:6G8oQ016D88m1xAKljMlBOOGWDZkes4kMhgGFlf8WcQ= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240102182953-50ed04b92917/go.mod h1:xtjpI3tXFPP051KaWnhvxkiubL/6dJ18vLVf7q2pTOU= +google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de h1:F6qOa9AZTYJXOUEr4jDysRDLrm4PHePlge4v4TGAlxY= +google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:VUhTRKeHn9wwcdrk73nvdC9gF178Tzhmt/qyaFcPLSo= +google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de h1:jFNzHPIeuzhdRwVhbZdiym9q0ory/xY3sA+v2wPg8I0= +google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:5iCWqnniDlqZHrd3neWVTOwvh/v6s3232omMecelax8= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de h1:cZGRis4/ot9uVm639a+rHCUaG0JJHEsdyzSQTMX+suY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:H4O17MA/PE9BsGx3w+a+W2VOLLD1Qf7oJneAoU6WktY= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -1342,8 +1285,8 @@ google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACu google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= -google.golang.org/grpc v1.61.1 h1:kLAiWrZs7YeDM6MumDe7m3y4aM6wacLzM1Y/wiLP9XY= -google.golang.org/grpc v1.61.1/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= +google.golang.org/grpc v1.63.2 h1:MUeiw1B2maTVZthpU5xvASfTh3LDbxHd6IJ6QQVU+xM= +google.golang.org/grpc v1.63.2/go.mod h1:WAX/8DgncnokcFUldAxq7GeB5DXHDbMF+lLvDomNkRA= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= @@ -1370,7 +1313,6 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/cheggaaa/pb.v1 v1.0.27/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= -gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -1392,8 +1334,8 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -oras.land/oras-go/v2 v2.4.0 h1:i+Wt5oCaMHu99guBD0yuBjdLvX7Lz8ukPbwXdR7uBMs= -oras.land/oras-go/v2 v2.4.0/go.mod h1:osvtg0/ClRq1KkydMAEu/IxFieyjItcsQ4ut4PPF+f8= +oras.land/oras-go/v2 v2.5.0 h1:o8Me9kLY74Vp5uw07QXPiitjsw7qNXi8Twd+19Zf02c= +oras.land/oras-go/v2 v2.5.0/go.mod h1:z4eisnLP530vwIOUOJeBIj0aGI0L1C3d53atvCBqZHg= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= diff --git a/hub/hub.go b/hub/hub.go index 8d3e837b..9317768c 100644 --- a/hub/hub.go +++ b/hub/hub.go @@ -12,7 +12,7 @@ type Hub interface { GetConnectionConfigByName(string) *proto.ConnectionConfig LoadConnectionConfig() (bool, error) GetSchema(remoteSchema string, localSchema string) (*proto.Schema, error) - GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options) (Iterator, error) + GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options, queryTimestamp int64) (Iterator, error) GetRelSize(columns []string, quals []*proto.Qual, opts types.Options) (types.RelSize, error) GetPathKeys(opts types.Options) ([]types.PathKey, error) Explain(columns []string, quals []*proto.Qual, sortKeys []string, verbose bool, opts types.Options) ([]string, error) diff --git a/hub/hub_base.go b/hub/hub_base.go index ea983c5a..e483efd2 100644 --- a/hub/hub_base.go +++ b/hub/hub_base.go @@ -3,8 +3,10 @@ package hub import ( "context" "fmt" + "github.com/turbot/steampipe/pkg/query/queryresult" "log" "strings" + "sync" "time" "github.com/turbot/go-kit/helpers" @@ -21,12 +23,8 @@ import ( ) type hubBase struct { - // array of scan metadata - // we append to this every time a scan completes (either due to end of data, or Postgres terminating) - scanMetadata []ScanMetadata - - // list of iterators currently executing scans - runningIterators []Iterator + runningIterators map[Iterator]struct{} + runningIteratorsLock sync.RWMutex // cacheSettings cacheSettings *settings.HubCacheSettings @@ -35,6 +33,17 @@ type hubBase struct { // callback function to shutdown telemetry telemetryShutdownFunc func() hydrateCallsCounter metric.Int64Counter + queryTiming *queryTimingMetadata +} + +func newHubBase(enableScanMetadata bool) hubBase { + h := hubBase{ + runningIterators: make(map[Iterator]struct{}), + } + if enableScanMetadata { + h.queryTiming = newQueryTimingMetadata() + } + return h } // GetRelSize is a method called from the planner to estimate the resulting relation size for a scan. @@ -147,17 +156,6 @@ func (h *hubBase) Explain(columns []string, quals []*proto.Qual, sortKeys []stri return make([]string, 0), nil } -// RemoveIterator removes an iterator from list of running iterators -func (h *hubBase) RemoveIterator(iterator Iterator) { - for idx, it := range h.runningIterators { - if it == iterator { - // remove from list - h.runningIterators = append(h.runningIterators[:idx], h.runningIterators[idx+1:]...) - return - } - } -} - // StartScan starts a scan func (h *hubBase) StartScan(i Iterator) error { log.Printf("[INFO] hubBase StartScan") @@ -180,10 +178,14 @@ func (h *hubBase) StartScan(i Iterator) error { // EndScan is called when Postgres terminates the scan (because it has received enough rows of data) func (h *hubBase) EndScan(iter Iterator, limit int64) { + log.Printf("[INFO] hubBase EndScan") + // is the iterator still running? If so it means postgres is stopping a scan before all rows have been read if iter.Status() == QueryStatusStarted { + log.Printf("[INFO] ending scan before iterator complete - limit: %v, iterator: %p", limit, iter) + // we normally add the scan metadata when the scan completes - if the scan has not completed, we need to + // add the metadata here h.AddScanMetadata(iter) - log.Printf("[TRACE] ending scan before iterator complete - limit: %v, iterator: %p", limit, iter) iter.Close() } @@ -194,56 +196,60 @@ func (h *hubBase) EndScan(iter Iterator, limit int64) { // we append to this every time a scan completes (either due to end of data, or Postgres terminating) // the full array is returned whenever a pop_scan_metadata command is received and the array is cleared func (h *hubBase) AddScanMetadata(i Iterator) { + // for local hub we do not store scan metadata + if h.queryTiming != nil { + return + } // if iterator is not a pluginIterator, do nothing - iterator, ok := i.(pluginIterator) + iter, ok := i.(pluginIterator) if !ok { + log.Printf("[INFO] AddScanMetadata - not a pluginIterator so returning") return } - log.Printf("[TRACE] AddScanMetadata for iterator %p (%s)", iterator, iterator.GetConnectionName()) - // get the id of the last metadata item we currently have - // (id starts at 1) - id := 1 - metadataLen := len(h.scanMetadata) - if metadataLen > 0 { - id = h.scanMetadata[metadataLen-1].Id + 1 - } - ctx := iterator.GetTraceContext().Ctx + queryTimestamp := iter.GetQueryTimestamp() + log.Printf("[INFO] AddScanMetadata for iterator %p query timestamp %d (%s)", iter, queryTimestamp, iter.GetConnectionName()) + + h.queryTiming.scanMetadataLock.Lock() + defer h.queryTiming.scanMetadataLock.Unlock() + + ctx := iter.GetTraceContext().Ctx - connectionName := iterator.GetConnectionName() - pluginName := iterator.GetPluginName() + connectionName := iter.GetConnectionName() + pluginName := iter.GetPluginName() // get scan metadata from iterator - m := iterator.GetScanMetadata() - - // set ID - m.Id = id - log.Printf("[TRACE] got metadata table: %s cache hit: %v, rows fetched %d, hydrate calls: %d", - m.Table, m.CacheHit, m.RowsFetched, m.HydrateCalls) - // read the scan metadata from the iterator and add to our stack - h.scanMetadata = append(h.scanMetadata, m) - - // hydrate metric labels - labels := []attribute.KeyValue{ - attribute.String("table", m.Table), - attribute.String("connection", connectionName), - attribute.String("plugin", pluginName), + scanMetadata := iter.GetScanMetadata() + querySummary := h.queryTiming.queryRowSummary[queryTimestamp] + if querySummary == nil { + querySummary = queryresult.NewQueryRowSummary() } - log.Printf("[TRACE] update hydrate calls counter with %d", m.HydrateCalls) - h.hydrateCallsCounter.Add(ctx, m.HydrateCalls, metric.WithAttributes(labels...)) - - // now trim scan metadata - max 1000 items - const maxMetadataItems = 1000 - if metadataLen > maxMetadataItems { - startOffset := maxMetadataItems - 1000 - h.scanMetadata = h.scanMetadata[startOffset:] + + // ensure we only keep scan metadata for this query, and limit the amount of metadata we keep + h.queryTiming.removeStaleScanMetadata(queryTimestamp) + + for _, m := range scanMetadata { + // update summary + querySummary.Update(m) + + // add the scan metadata to the list + // (if we have exceeded the max number of scan metadata items, this will keep the slowest items + h.queryTiming.addScanMetadata(queryTimestamp, m) + + // hydrate metric labels + labels := []attribute.KeyValue{ + attribute.String("table", m.Table), + attribute.String("connection", connectionName), + attribute.String("plugin", pluginName), + } + log.Printf("[TRACE] update hydrate calls counter with %d", m.HydrateCalls) + h.hydrateCallsCounter.Add(ctx, m.HydrateCalls, metric.WithAttributes(labels...)) } -} + // write the scan metadata and summary back to the hub + h.queryTiming.queryRowSummary[queryTimestamp] = querySummary -// ClearScanMetadata deletes all stored scan metadata. It is called by steampipe after retrieving timing information -// for the previous query -func (h *hubBase) ClearScanMetadata() { - h.scanMetadata = nil + log.Printf("[INFO] AddScanMetadata complete - there are now %d entries for query timestamp %d", len(h.queryTiming.scanMetadata[queryTimestamp]), queryTimestamp) + log.Printf("[INFO] summary: %v", h.queryTiming.queryRowSummary) } // Close shuts down all plugin clients @@ -254,22 +260,22 @@ func (h *hubBase) Close() { log.Println("[TRACE] shutdown telemetry") h.telemetryShutdownFunc() } - - // TODO KAI should this shut plugins } // Abort shuts down currently running queries func (h *hubBase) Abort() { - log.Printf("[INFO] RemoteHub Abort") // for all running iterators - for _, iter := range h.runningIterators { + h.runningIteratorsLock.RLock() + defer h.runningIteratorsLock.RUnlock() + + for iter := range h.runningIterators { // read the scan metadata from the iterator and add to our stack h.AddScanMetadata(iter) // close the iterator iter.Close() - // remove it from the saved list of iterators - h.RemoveIterator(iter) } + // clear running iterators + h.runningIterators = make(map[Iterator]struct{}) } // settings @@ -280,6 +286,7 @@ func (h *hubBase) ApplySetting(key string, value string) error { } func (h *hubBase) GetSettingsSchema() map[string]*proto.TableSchema { + // todo kai only in remote??? return map[string]*proto.TableSchema{ constants.ForeignTableSettings: { Columns: []*proto.ColumnDefinition{ @@ -287,18 +294,30 @@ func (h *hubBase) GetSettingsSchema() map[string]*proto.TableSchema { {Name: constants.ForeignTableSettingsValueColumn, Type: proto.ColumnType_STRING}, }, }, + // todo kai only in remote??? constants.ForeignTableScanMetadata: { Columns: []*proto.ColumnDefinition{ - {Name: "id", Type: proto.ColumnType_INT}, + {Name: "connection", Type: proto.ColumnType_STRING}, {Name: "table", Type: proto.ColumnType_STRING}, {Name: "cache_hit", Type: proto.ColumnType_BOOL}, {Name: "rows_fetched", Type: proto.ColumnType_INT}, {Name: "hydrate_calls", Type: proto.ColumnType_INT}, {Name: "start_time", Type: proto.ColumnType_TIMESTAMP}, - {Name: "duration", Type: proto.ColumnType_DOUBLE}, + {Name: "duration_ms", Type: proto.ColumnType_INT}, {Name: "columns", Type: proto.ColumnType_JSON}, {Name: "limit", Type: proto.ColumnType_INT}, - {Name: "quals", Type: proto.ColumnType_STRING}, + {Name: "quals", Type: proto.ColumnType_JSON}, + }, + }, + // todo kai only in remote??? + constants.ForeignTableScanMetadataSummary: { + Columns: []*proto.ColumnDefinition{ + {Name: "cached_rows_fetched", Type: proto.ColumnType_INT}, + {Name: "uncached_rows_fetched", Type: proto.ColumnType_INT}, + {Name: "hydrate_calls", Type: proto.ColumnType_INT}, + {Name: "duration_ms", Type: proto.ColumnType_INT}, + {Name: "scan_count", Type: proto.ColumnType_INT}, + {Name: "connection_count", Type: proto.ColumnType_INT}, }, }, } @@ -323,16 +342,34 @@ func (h *hubBase) ProcessImportForeignSchemaOptions(types.Options, string) error return nil } -func (h *hubBase) executeCommandScan(connectionName, table string) (Iterator, error) { +func (h *hubBase) executeCommandScan(connectionName, table string, queryTimestamp int64) (Iterator, error) { switch table { + case constants.ForeignTableScanMetadataSummary: + // we expect to only have metadata for one query at a time - this is ebforced by the metadata writing code + if summaryCount := len(h.queryTiming.queryRowSummary); summaryCount > 1 { + return nil, fmt.Errorf(" executeCommandScan for table '%s' - %d summaries in metadata store - there should only be 1. ", table, summaryCount) + } + + res := &QueryResult{} + for _, summary := range h.queryTiming.queryRowSummary { + res.Rows = append(res.Rows, summary.AsResultRow()) + } + + return newInMemoryIterator(connectionName, res, queryTimestamp), nil case constants.ForeignTableScanMetadata, constants.LegacyCommandTableScanMetadata: - res := &QueryResult{ - Rows: make([]map[string]interface{}, len(h.scanMetadata)), + if metadataCount := len(h.queryTiming.scanMetadata); metadataCount > 1 { + return nil, fmt.Errorf(" executeCommandScan for table '%s' - %d summaries in metadata store - there should only be 1. ", metadataCount, table) } - for i, m := range h.scanMetadata { - res.Rows[i] = m.AsResultRow() + + res := &QueryResult{} + for _, scansForQuery := range h.queryTiming.scanMetadata { + log.Printf("[INFO] metadata rows %d", len(scansForQuery)) + for _, m := range scansForQuery { + res.Rows = append(res.Rows, m.AsResultRow()) + } } - return newInMemoryIterator(connectionName, res), nil + + return newInMemoryIterator(connectionName, res, queryTimestamp), nil default: return nil, fmt.Errorf("cannot select from command table '%s'", table) } @@ -426,10 +463,19 @@ func (h *hubBase) initialiseTelemetry() error { } func (h *hubBase) addIterator(iterator Iterator) { - h.runningIterators = append(h.runningIterators, iterator) + h.runningIteratorsLock.Lock() + defer h.runningIteratorsLock.Unlock() + + h.runningIterators[iterator] = struct{}{} } -// legacy remove +// RemoveIterator removes an iterator from list of running iterators +func (h *hubBase) RemoveIterator(iterator Iterator) { + h.runningIteratorsLock.Lock() + defer h.runningIteratorsLock.Unlock() + + delete(h.runningIterators, iterator) +} func (h *hubBase) GetLegacySettingsSchema() map[string]*proto.TableSchema { return map[string]*proto.TableSchema{ diff --git a/hub/hub_local.go b/hub/hub_local.go index 25f7fb36..86d6b4ee 100644 --- a/hub/hub_local.go +++ b/hub/hub_local.go @@ -30,6 +30,7 @@ func newLocalHub() (*HubLocal, error) { imageRef := ociinstaller.NewSteampipeImageRef(pluginAlias).DisplayImageRef() hub := &HubLocal{ + hubBase: newHubBase(false), plugin: plugin.Server(&plugin.ServeOpts{ PluginFunc: getPluginFunc(), }), @@ -107,7 +108,7 @@ func (l *HubLocal) GetSchema(_, connectionName string) (*proto.Schema, error) { return res.GetSchema(), nil } -func (l *HubLocal) GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options) (Iterator, error) { +func (l *HubLocal) GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options, queryTimestamp int64) (Iterator, error) { logging.LogTime("GetIterator start") qualMap, err := buildQualMap(quals) connectionName := opts["connection"] @@ -115,7 +116,7 @@ func (l *HubLocal) GetIterator(columns []string, quals *proto.Quals, unhandledRe log.Printf("[TRACE] RemoteHub GetIterator() table '%s'", table) if connectionName == constants.InternalSchema || connectionName == constants.LegacyCommandSchema { - return l.executeCommandScan(connectionName, table) + return l.executeCommandScan(connectionName, table, queryTimestamp) } // create a span for this scan @@ -197,6 +198,7 @@ func (l *HubLocal) startScanForConnection(connectionName string, table string, q log.Printf("[TRACE] startScanForConnection creating a new scan iterator") iterator := newScanIteratorLocal(l, connectionName, table, l.pluginName, connectionLimitMap, qualMap, columns, limit, scanTraceCtx) + return iterator, nil } diff --git a/hub/hub_remote.go b/hub/hub_remote.go index 1e0c088b..34c2afae 100644 --- a/hub/hub_remote.go +++ b/hub/hub_remote.go @@ -4,6 +4,11 @@ import ( "context" "errors" "fmt" + "log" + "os" + "path" + "time" + typehelpers "github.com/turbot/go-kit/types" "github.com/turbot/steampipe-plugin-sdk/v5/grpc" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" @@ -17,10 +22,6 @@ import ( "github.com/turbot/steampipe/pkg/steampipeconfig" "github.com/turbot/steampipe/pkg/steampipeconfig/modconfig" "github.com/turbot/steampipe/pkg/utils" - "log" - "os" - "path" - "time" ) const ( @@ -36,7 +37,9 @@ type RemoteHub struct { //// lifecycle //// func newRemoteHub() (*RemoteHub, error) { - hub := &RemoteHub{} + hub := &RemoteHub{ + hubBase: newHubBase(true), + } hub.connections = newConnectionFactory(hub) // TODO CHECK TELEMETRY ENABLED? @@ -87,7 +90,7 @@ func (h *RemoteHub) GetSchema(remoteSchema string, localSchema string) (*proto.S } // GetIterator creates and returns an iterator -func (h *RemoteHub) GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options) (Iterator, error) { +func (h *RemoteHub) GetIterator(columns []string, quals *proto.Quals, unhandledRestrictions int, limit int64, opts types.Options, queryTimestamp int64) (Iterator, error) { logging.LogTime("GetIterator start") qualMap, err := buildQualMap(quals) connectionName := opts["connection"] @@ -95,12 +98,12 @@ func (h *RemoteHub) GetIterator(columns []string, quals *proto.Quals, unhandledR log.Printf("[TRACE] RemoteHub GetIterator() table '%s'", table) if connectionName == constants.InternalSchema || connectionName == constants.LegacyCommandSchema { - return h.executeCommandScan(connectionName, table) + return h.executeCommandScan(connectionName, table, queryTimestamp) } // create a span for this scan scanTraceCtx := h.traceContextForScan(table, columns, limit, qualMap, connectionName) - iterator, err := h.startScanForConnection(connectionName, table, qualMap, unhandledRestrictions, columns, limit, scanTraceCtx) + iterator, err := h.startScanForConnection(connectionName, table, qualMap, unhandledRestrictions, columns, limit, scanTraceCtx, queryTimestamp) if err != nil { log.Printf("[TRACE] RemoteHub GetIterator() failed :( %s", err) @@ -153,7 +156,8 @@ func (h *RemoteHub) GetPathKeys(opts types.Options) ([]types.PathKey, error) { //// internal implementation //// // startScanForConnection starts a scan for a single connection, using a scanIterator or a legacyScanIterator -func (h *RemoteHub) startScanForConnection(connectionName string, table string, qualMap map[string]*proto.Quals, unhandledRestrictions int, columns []string, limit int64, scanTraceCtx *telemetry.TraceCtx) (_ Iterator, err error) { + +func (h *RemoteHub) startScanForConnection(connectionName string, table string, qualMap map[string]*proto.Quals, unhandledRestrictions int, columns []string, limit int64, scanTraceCtx *telemetry.TraceCtx, queryTimestamp int64) (_ Iterator, err error) { defer func() { if err != nil { // close the span in case of errir @@ -202,12 +206,12 @@ func (h *RemoteHub) startScanForConnection(connectionName string, table string, } log.Printf("[TRACE] startScanForConnection creating a new scan iterator") - iterator := newScanIterator(h, connectionPlugin, connectionName, table, connectionLimitMap, qualMap, columns, limit, scanTraceCtx) + iterator := newScanIterator(h, connectionPlugin, connectionName, table, connectionLimitMap, qualMap, columns, limit, scanTraceCtx, queryTimestamp) return iterator, nil } func (h *RemoteHub) buildConnectionLimitMap(table string, qualMap map[string]*proto.Quals, unhandledRestrictions int, connectionNames []string, limit int64, connectionPlugin *steampipeconfig.ConnectionPlugin) (map[string]int64, error) { - log.Printf("[TRACE] buildConnectionLimitMap, table: '%s', %d %s, limit: %d", table, len(connectionNames), utils.Pluralize("connection", len(connectionNames)), limit) + log.Printf("[INFO] buildConnectionLimitMap, table: '%s', %d %s, limit: %d", table, len(connectionNames), utils.Pluralize("connection", len(connectionNames)), limit) connectionSchema, err := connectionPlugin.GetSchema(connectionNames[0]) if err != nil { @@ -219,7 +223,7 @@ func (h *RemoteHub) buildConnectionLimitMap(table string, qualMap map[string]*pr // for a static schema, the limit will be the same for all connections (i.e. we either pushdown for all or none) // check once whether we should push down if limit != -1 && schemaMode == plugin.SchemaModeStatic { - log.Printf("[TRACE] static schema - using same limit for all connections") + log.Printf("[INFO] static schema - using same limit for all connections") if !h.shouldPushdownLimit(table, qualMap, unhandledRestrictions, connectionSchema) { limit = -1 } diff --git a/hub/in_memory_iterator.go b/hub/in_memory_iterator.go index 7c6f37ab..926f4615 100644 --- a/hub/in_memory_iterator.go +++ b/hub/in_memory_iterator.go @@ -2,23 +2,26 @@ package hub import ( "context" + "github.com/turbot/steampipe/pkg/query/queryresult" "log" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" ) type inMemoryIterator struct { - name string - rows []map[string]interface{} - index int - status queryStatus + name string + rows []map[string]interface{} + index int + status queryStatus + queryTimestamp int64 } -func newInMemoryIterator(name string, result *QueryResult) *inMemoryIterator { +func newInMemoryIterator(name string, result *QueryResult, queryTimestamp int64) *inMemoryIterator { return &inMemoryIterator{ - name: name, - rows: result.Rows, - status: QueryStatusStarted, // set as started + name: name, + rows: result.Rows, + status: QueryStatusStarted, // set as started + queryTimestamp: queryTimestamp, } } @@ -70,9 +73,13 @@ func (i *inMemoryIterator) CanIterate() bool { } } -func (i *inMemoryIterator) GetScanMetadata() ScanMetadata { - return ScanMetadata{} +func (i *inMemoryIterator) GetScanMetadata() []queryresult.ScanMetadataRow { + return nil } func (i *inMemoryIterator) GetTraceContext() *telemetry.TraceCtx { return &telemetry.TraceCtx{Ctx: context.Background()} } + +func (i *inMemoryIterator) GetQueryTimestamp() int64 { + return i.queryTimestamp +} diff --git a/hub/interface.go b/hub/interface.go index 8e82e830..a2c1ed21 100644 --- a/hub/interface.go +++ b/hub/interface.go @@ -5,6 +5,7 @@ import ( "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/row_stream" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" + "github.com/turbot/steampipe/pkg/query/queryresult" ) // Iterator is an interface for table scanner implementations. @@ -19,6 +20,7 @@ type Iterator interface { Status() queryStatus Error() error CanIterate() bool + GetQueryTimestamp() int64 GetTraceContext() *telemetry.TraceCtx } @@ -33,6 +35,6 @@ type pluginIterator interface { GetConnectionLimitMap() map[string]int64 SetError(err error) GetTable() string - GetScanMetadata() ScanMetadata + GetScanMetadata() []queryresult.ScanMetadataRow Start(pluginExecutor) error } diff --git a/hub/query_timing_metadata.go b/hub/query_timing_metadata.go new file mode 100644 index 00000000..8b7f146b --- /dev/null +++ b/hub/query_timing_metadata.go @@ -0,0 +1,70 @@ +package hub + +import ( + "github.com/turbot/steampipe/pkg/query/queryresult" + "log" + "sort" + "sync" +) + +const ( + scanMetadataBufferSize = 20 +) + +type queryTimingMetadata struct { + // map of scan metadata, keyed by query id + // we append to this every time a scan completes (either due to end of data, or Postgres terminating) + // each array is ordered slowest to fasteyt + scanMetadata map[int64][]queryresult.ScanMetadataRow + // map of scan totals, keyed by query timestamp (which is a unique query identifier + queryRowSummary map[int64]*queryresult.QueryRowSummary + + scanMetadataLock sync.RWMutex +} + +func (m *queryTimingMetadata) addScanMetadata(queryTimestamp int64, scanMetadata queryresult.ScanMetadataRow) { + metadataForQuery := m.scanMetadata[queryTimestamp] + + if len(metadataForQuery) < scanMetadataBufferSize { + metadataForQuery = append(metadataForQuery, scanMetadata) + m.scanMetadata[queryTimestamp] = metadataForQuery + // sort the metadata by decreasing time + sort.Slice(metadataForQuery, func(i, j int) bool { + return metadataForQuery[i].DurationMs > metadataForQuery[j].DurationMs + }) + return + } + + // so we have the maximum number of scan metadata items - if this scan is faster than the slowest item, ignore it + if scanMetadata.DurationMs < metadataForQuery[len(metadataForQuery)-1].DurationMs { + return + } + + // add the scan metadata to the list, resort and trim to the max number of items + metadataForQuery = append(metadataForQuery, scanMetadata) + sort.Slice(metadataForQuery, func(i, j int) bool { + return metadataForQuery[i].DurationMs > metadataForQuery[j].DurationMs + + }) + m.scanMetadata[queryTimestamp] = metadataForQuery[:scanMetadataBufferSize] +} + +func newQueryTimingMetadata() *queryTimingMetadata { + return &queryTimingMetadata{ + scanMetadata: make(map[int64][]queryresult.ScanMetadataRow), + queryRowSummary: make(map[int64]*queryresult.QueryRowSummary), + } +} + +func (m *queryTimingMetadata) removeStaleScanMetadata(currentTimestamp int64) { + log.Printf("[INFO] removeStaleScanMetadata for current query timestamp %d", currentTimestamp) + + // clear all query metadata for previous queries + for existingTimestamp := range m.scanMetadata { + if existingTimestamp != currentTimestamp { + log.Printf("[INFO] REMOVING timestamp %d", existingTimestamp) + delete(m.scanMetadata, existingTimestamp) + delete(m.queryRowSummary, existingTimestamp) + } + } +} diff --git a/hub/scan_iterator.go b/hub/scan_iterator.go index 8257f164..68de0356 100644 --- a/hub/scan_iterator.go +++ b/hub/scan_iterator.go @@ -6,8 +6,10 @@ import ( "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/row_stream" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" + "github.com/turbot/steampipe/pkg/query/queryresult" "github.com/turbot/steampipe/pkg/steampipeconfig" "log" + "time" ) // TODO think about when we reset status from complete to ready @@ -18,9 +20,9 @@ type scanIterator struct { hub *RemoteHub } -func newScanIterator(hub Hub, connectionPlugin *steampipeconfig.ConnectionPlugin, connectionName, table string, connectionLimitMap map[string]int64, qualMap map[string]*proto.Quals, columns []string, limit int64, traceCtx *telemetry.TraceCtx) *scanIterator { +func newScanIterator(hub Hub, connectionPlugin *steampipeconfig.ConnectionPlugin, connectionName, table string, connectionLimitMap map[string]int64, qualMap map[string]*proto.Quals, columns []string, limit int64, traceCtx *telemetry.TraceCtx, queryTimestamp int64) *scanIterator { return &scanIterator{ - scanIteratorBase: newBaseScanIterator(hub, connectionName, table, connectionLimitMap, qualMap, columns, limit, traceCtx), + scanIteratorBase: newBaseScanIterator(hub, connectionName, table, connectionLimitMap, qualMap, columns, limit, traceCtx, queryTimestamp), connectionPlugin: connectionPlugin, } } @@ -41,3 +43,30 @@ func (i *scanIterator) execute(req *proto.ExecuteRequest) (row_stream.Receiver, } return stream, ctx, cancel, nil } + +// GetScanMetadata returns the scan metadata for this iterator +// note: if this is an aggregator query, we will have a scan metadata for each connection +// we need to combine them into a single scan metadata object +func (i *scanIterator) GetScanMetadata() []queryresult.ScanMetadataRow { + log.Printf("[INFO] scanIterator GetScanMetadata (%p) (%s)", i, i.callId) + defer log.Printf("[INFO] scanIterator GetScanMetadata end (%p) (%s)", i, i.callId) + var res = make([]queryresult.ScanMetadataRow, 0, len(i.scanMetadata)) + + for connection, m := range i.scanMetadata { + res = append(res, i.newScanMetadata(connection, m)) + } + // if there is no scan metadata, add an empty one + if len(res) == 0 { + for connection := range i.connectionLimitMap { + res = append(res, i.newScanMetadata(connection, nil)) + } + } + return res + +} + +func (i *scanIterator) newScanMetadata(connection string, m *proto.QueryMetadata) queryresult.ScanMetadataRow { + res := queryresult.NewScanMetadataRow(connection, i.table, i.queryContext.Columns, i.queryContext.Quals, i.startTime, time.Since(i.startTime), i.connectionLimitMap[connection], m) + + return res +} diff --git a/hub/scan_iterator_base.go b/hub/scan_iterator_base.go index 0fedb7ed..6b753203 100644 --- a/hub/scan_iterator_base.go +++ b/hub/scan_iterator_base.go @@ -31,12 +31,15 @@ type scanIteratorBase struct { cancel context.CancelFunc traceCtx *telemetry.TraceCtx queryContext *proto.QueryContext + // the query timestamp is used to uniquely identify the parent query + // NOTE: all scans for the query will have the same timestamp + queryTimestamp int64 startTime time.Time callId string } -func newBaseScanIterator(hub Hub, connectionName, table string, connectionLimitMap map[string]int64, qualMap map[string]*proto.Quals, columns []string, limit int64, traceCtx *telemetry.TraceCtx) scanIteratorBase { +func newBaseScanIterator(hub Hub, connectionName, table string, connectionLimitMap map[string]int64, qualMap map[string]*proto.Quals, columns []string, limit int64, traceCtx *telemetry.TraceCtx, queryTimestamp int64) scanIteratorBase { return scanIteratorBase{ status: QueryStatusReady, rows: make(chan *proto.Row, rowBufferSize), @@ -49,6 +52,7 @@ func newBaseScanIterator(hub Hub, connectionName, table string, connectionLimitM startTime: time.Now(), queryContext: proto.NewQueryContext(columns, qualMap, limit), callId: grpc.BuildCallId(), + queryTimestamp: queryTimestamp, } } @@ -87,8 +91,10 @@ func (i *scanIteratorBase) Next() (map[string]interface{}, error) { // if the row channel closed, complete the iterator state var res map[string]interface{} if row == nil { - // close the span - i.closeSpan() + // close the span and set the status + i.Close() + // remove from hub running iterators + i.hub.RemoveIterator(i) // if iterator is in error, return the error if i.Status() == QueryStatusError { @@ -96,10 +102,7 @@ func (i *scanIteratorBase) Next() (map[string]interface{}, error) { return nil, i.err } // otherwise mark iterator complete, caching result - i.status = QueryStatusComplete - } else { - // so we got a row var err error res, err = i.populateRow(row) @@ -112,16 +115,6 @@ func (i *scanIteratorBase) Next() (map[string]interface{}, error) { } func (i *scanIteratorBase) closeSpan() { - // if we have scan metadata, add to span - // TODO SUM ALL metadata - //if i.scanMetadata != nil { - // i.traceCtx.Span.SetAttributes( - // attribute.Int64("hydrate_calls", i.scanMetadata.HydrateCalls), - // attribute.Int64("rows_fetched", i.scanMetadata.RowsFetched), - // attribute.Bool("cache_hit", i.scanMetadata.CacheHit), - // ) - //} - i.traceCtx.Span.End() } @@ -135,7 +128,6 @@ func (i *scanIteratorBase) Close() { } i.closeSpan() - } // CanIterate returns true if this iterator has results available to iterate @@ -150,26 +142,6 @@ func (i *scanIteratorBase) CanIterate() bool { } -// note: if this is an aggregator query, we will have a scan metadata for each connection -// we need to combine them into a single scan metadata object - -func (i *scanIteratorBase) GetScanMetadata() ScanMetadata { - res := ScanMetadata{ - Table: i.table, - Columns: i.queryContext.Columns, - Quals: i.queryContext.Quals, - StartTime: i.startTime, - Duration: time.Since(i.startTime), - } - for _, m := range i.scanMetadata { - res.CacheHit = res.CacheHit || m.CacheHit - res.RowsFetched += m.RowsFetched - res.HydrateCalls += m.HydrateCalls - } - return res - -} - func (i *scanIteratorBase) GetTraceContext() *telemetry.TraceCtx { return i.traceCtx } @@ -214,6 +186,15 @@ func (i *scanIteratorBase) Start(executor pluginExecutor) error { return nil } +// GetPluginName implements Iterator (this should be implemented by the concrete iterator) +func (i *scanIteratorBase) GetPluginName() string { + panic("method GetPluginName not implemented") +} + +func (i *scanIteratorBase) GetQueryTimestamp() int64 { + return i.queryTimestamp +} + func (i *scanIteratorBase) newExecuteRequest() *proto.ExecuteRequest { req := &proto.ExecuteRequest{ Table: i.table, diff --git a/hub/scan_iterator_local.go b/hub/scan_iterator_local.go index 849e55e3..df4d98a0 100644 --- a/hub/scan_iterator_local.go +++ b/hub/scan_iterator_local.go @@ -17,7 +17,7 @@ type scanIteratorLocal struct { func newScanIteratorLocal(hub Hub, connectionName, table, pluginName string, connectionLimitMap map[string]int64, qualMap map[string]*proto.Quals, columns []string, limit int64, traceCtx *telemetry.TraceCtx) *scanIteratorLocal { return &scanIteratorLocal{ - scanIteratorBase: newBaseScanIterator(hub, connectionName, table, connectionLimitMap, qualMap, columns, limit, traceCtx), + scanIteratorBase: newBaseScanIterator(hub, connectionName, table, connectionLimitMap, qualMap, columns, limit, traceCtx, 0), pluginName: pluginName, } } diff --git a/hub/scan_metadata.go b/hub/scan_metadata.go deleted file mode 100644 index 5aef70b4..00000000 --- a/hub/scan_metadata.go +++ /dev/null @@ -1,43 +0,0 @@ -package hub - -import ( - "time" - - "github.com/turbot/steampipe-plugin-sdk/v5/grpc" - "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" -) - -type ScanMetadata struct { - Id int - Table string - CacheHit bool - RowsFetched int64 - HydrateCalls int64 - Columns []string - Quals map[string]*proto.Quals - Limit int64 - StartTime time.Time - Duration time.Duration -} - -// AsResultRow returns the ScanMetadata as a map[string]interface which can be returned as a query result -func (m ScanMetadata) AsResultRow() map[string]interface{} { - res := map[string]interface{}{ - "id": m.Id, - "table": m.Table, - "cache_hit": m.CacheHit, - "rows_fetched": m.RowsFetched, - "hydrate_calls": m.HydrateCalls, - "start_time": m.StartTime, - "duration": m.Duration.Milliseconds(), - "columns": m.Columns, - } - if m.Limit != -1 { - res["limit"] = m.Limit - } - if len(m.Quals) > 0 { - // ignore error - res["quals"], _ = grpc.QualMapToJSONString(m.Quals) - } - return res -} From ba6224e941acb6b31166c4143f3802c5e036fe08 Mon Sep 17 00:00:00 2001 From: kai Date: Tue, 16 Apr 2024 16:37:01 +0100 Subject: [PATCH 2/3] works --- Makefile | 2 +- go.mod | 1 + hub/hub_base.go | 10 +++++++--- hub/query_timing_metadata.go | 14 +++++++++++++- hub/scan_iterator.go | 27 ++++++++++----------------- hub/scan_iterator_base.go | 14 ++++++++------ 6 files changed, 40 insertions(+), 28 deletions(-) diff --git a/Makefile b/Makefile index d73916b1..eb5ba0e2 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ # Makefile -default: build +default: install STEAMPIPE_INSTALL_DIR ?= ~/.steampipe diff --git a/go.mod b/go.mod index 866bff8c..87e1ae3c 100644 --- a/go.mod +++ b/go.mod @@ -197,4 +197,5 @@ replace ( github.com/piquette/edgr => github.com/e-gineer/edgr v0.0.2-0.20210901021602-7664639af765 github.com/vartanbeno/go-reddit/v2 => github.com/abhiturbot/go-reddit/v2 v2.0.0-20220917030010-f0fe7d8ac15c oras.land/oras-go => oras.land/oras-go v1.1.0 + github.com/turbot/steampipe => ../steampipe ) diff --git a/hub/hub_base.go b/hub/hub_base.go index e483efd2..3743f919 100644 --- a/hub/hub_base.go +++ b/hub/hub_base.go @@ -197,7 +197,7 @@ func (h *hubBase) EndScan(iter Iterator, limit int64) { // the full array is returned whenever a pop_scan_metadata command is received and the array is cleared func (h *hubBase) AddScanMetadata(i Iterator) { // for local hub we do not store scan metadata - if h.queryTiming != nil { + if h.queryTiming == nil { return } // if iterator is not a pluginIterator, do nothing @@ -208,6 +208,7 @@ func (h *hubBase) AddScanMetadata(i Iterator) { } queryTimestamp := iter.GetQueryTimestamp() + log.Printf("[INFO] AddScanMetadata for iterator %p query timestamp %d (%s)", iter, queryTimestamp, iter.GetConnectionName()) h.queryTiming.scanMetadataLock.Lock() @@ -242,7 +243,6 @@ func (h *hubBase) AddScanMetadata(i Iterator) { attribute.String("connection", connectionName), attribute.String("plugin", pluginName), } - log.Printf("[TRACE] update hydrate calls counter with %d", m.HydrateCalls) h.hydrateCallsCounter.Add(ctx, m.HydrateCalls, metric.WithAttributes(labels...)) } // write the scan metadata and summary back to the hub @@ -345,7 +345,7 @@ func (h *hubBase) ProcessImportForeignSchemaOptions(types.Options, string) error func (h *hubBase) executeCommandScan(connectionName, table string, queryTimestamp int64) (Iterator, error) { switch table { case constants.ForeignTableScanMetadataSummary: - // we expect to only have metadata for one query at a time - this is ebforced by the metadata writing code + // we expect to only have metadata for one query at a time - this is enforced by the metadata writing code if summaryCount := len(h.queryTiming.queryRowSummary); summaryCount > 1 { return nil, fmt.Errorf(" executeCommandScan for table '%s' - %d summaries in metadata store - there should only be 1. ", table, summaryCount) } @@ -354,6 +354,8 @@ func (h *hubBase) executeCommandScan(connectionName, table string, queryTimestam for _, summary := range h.queryTiming.queryRowSummary { res.Rows = append(res.Rows, summary.AsResultRow()) } + // now we have read the summary, we can clear the cached data + h.queryTiming.clearSummary() return newInMemoryIterator(connectionName, res, queryTimestamp), nil case constants.ForeignTableScanMetadata, constants.LegacyCommandTableScanMetadata: @@ -368,6 +370,8 @@ func (h *hubBase) executeCommandScan(connectionName, table string, queryTimestam res.Rows = append(res.Rows, m.AsResultRow()) } } + // now we have read the scan metadata, we can clear the cached data + h.queryTiming.clearScanMetadata() return newInMemoryIterator(connectionName, res, queryTimestamp), nil default: diff --git a/hub/query_timing_metadata.go b/hub/query_timing_metadata.go index 8b7f146b..10c21ecd 100644 --- a/hub/query_timing_metadata.go +++ b/hub/query_timing_metadata.go @@ -8,7 +8,7 @@ import ( ) const ( - scanMetadataBufferSize = 20 + scanMetadataBufferSize = 500 ) type queryTimingMetadata struct { @@ -68,3 +68,15 @@ func (m *queryTimingMetadata) removeStaleScanMetadata(currentTimestamp int64) { } } } + +func (m *queryTimingMetadata) clearSummary() { + m.scanMetadataLock.Lock() + defer m.scanMetadataLock.Unlock() + m.queryRowSummary = make(map[int64]*queryresult.QueryRowSummary) +} + +func (m *queryTimingMetadata) clearScanMetadata() { + m.scanMetadataLock.Lock() + defer m.scanMetadataLock.Unlock() + m.scanMetadata = make(map[int64][]queryresult.ScanMetadataRow) +} diff --git a/hub/scan_iterator.go b/hub/scan_iterator.go index 68de0356..4ed367c2 100644 --- a/hub/scan_iterator.go +++ b/hub/scan_iterator.go @@ -2,14 +2,15 @@ package hub import ( "context" + "log" + "github.com/turbot/steampipe-plugin-sdk/v5/grpc" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/row_stream" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" "github.com/turbot/steampipe/pkg/query/queryresult" "github.com/turbot/steampipe/pkg/steampipeconfig" - "log" - "time" + "golang.org/x/exp/maps" ) // TODO think about when we reset status from complete to ready @@ -50,23 +51,15 @@ func (i *scanIterator) execute(req *proto.ExecuteRequest) (row_stream.Receiver, func (i *scanIterator) GetScanMetadata() []queryresult.ScanMetadataRow { log.Printf("[INFO] scanIterator GetScanMetadata (%p) (%s)", i, i.callId) defer log.Printf("[INFO] scanIterator GetScanMetadata end (%p) (%s)", i, i.callId) - var res = make([]queryresult.ScanMetadataRow, 0, len(i.scanMetadata)) - - for connection, m := range i.scanMetadata { - res = append(res, i.newScanMetadata(connection, m)) + // if we have scan metadata, return it + if len(i.scanMetadata) > 0 { + return maps.Values(i.scanMetadata) } + // if there is no scan metadata, add an empty one - if len(res) == 0 { - for connection := range i.connectionLimitMap { - res = append(res, i.newScanMetadata(connection, nil)) - } + var res []queryresult.ScanMetadataRow + for connection := range i.connectionLimitMap { + res = append(res, i.newScanMetadata(connection, nil)) } return res - -} - -func (i *scanIterator) newScanMetadata(connection string, m *proto.QueryMetadata) queryresult.ScanMetadataRow { - res := queryresult.NewScanMetadataRow(connection, i.table, i.queryContext.Columns, i.queryContext.Quals, i.startTime, time.Since(i.startTime), i.connectionLimitMap[connection], m) - - return res } diff --git a/hub/scan_iterator_base.go b/hub/scan_iterator_base.go index 6b753203..edb26a53 100644 --- a/hub/scan_iterator_base.go +++ b/hub/scan_iterator_base.go @@ -12,6 +12,7 @@ import ( "github.com/turbot/steampipe-plugin-sdk/v5/row_stream" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" "github.com/turbot/steampipe-postgres-fdw/types" + "github.com/turbot/steampipe/pkg/query/queryresult" "google.golang.org/protobuf/reflect/protoreflect" "log" "time" @@ -21,7 +22,7 @@ type scanIteratorBase struct { status queryStatus err error rows chan *proto.Row - scanMetadata map[string]*proto.QueryMetadata + scanMetadata map[string]queryresult.ScanMetadataRow pluginRowStream row_stream.Receiver rel *types.Relation hub Hub @@ -43,7 +44,7 @@ func newBaseScanIterator(hub Hub, connectionName, table string, connectionLimitM return scanIteratorBase{ status: QueryStatusReady, rows: make(chan *proto.Row, rowBufferSize), - scanMetadata: make(map[string]*proto.QueryMetadata), + scanMetadata: make(map[string]queryresult.ScanMetadataRow), hub: hub, table: table, connectionName: connectionName, @@ -73,12 +74,10 @@ func (i *scanIteratorBase) Error() error { // Next implements Iterator // return the next row. Nil row means there are no more rows to scan. func (i *scanIteratorBase) Next() (map[string]interface{}, error) { - log.Printf("[Trace] scanIteratorBase Next") // check the iterator state - has an error occurred if i.status == QueryStatusError { return nil, i.err } - logging.LogTime("[hub] Next start") if !i.CanIterate() { // this is a bug @@ -110,7 +109,6 @@ func (i *scanIteratorBase) Next() (map[string]interface{}, error) { return nil, err } } - logging.LogTime("[hub] Next end") return res, nil } @@ -303,7 +301,7 @@ func (i *scanIteratorBase) readPluginResult(ctx context.Context) bool { continueReading = false } else { // update the scan metadata for this connection (this will overwrite any existing from the previous row) - i.scanMetadata[rowResult.Connection] = rowResult.Metadata + i.scanMetadata[rowResult.Connection] = i.newScanMetadata(rowResult.Connection, rowResult.Metadata) // so we have a row i.rows <- rowResult.Row @@ -321,6 +319,10 @@ func (i *scanIteratorBase) readPluginResult(ctx context.Context) bool { return continueReading } +func (i *scanIteratorBase) newScanMetadata(connection string, m *proto.QueryMetadata) queryresult.ScanMetadataRow { + return queryresult.NewScanMetadataRow(connection, i.table, i.queryContext.Columns, i.queryContext.Quals, i.startTime, time.Since(i.startTime), i.connectionLimitMap[connection], m) +} + // if there is an error other than EOF, save error and set state to QueryStatusError func (i *scanIteratorBase) setError(err error) { if err != nil && err.Error() != "EOF" { From 27b8f6a8e8977cbee1e55f586ad7baf38f2e5f8d Mon Sep 17 00:00:00 2001 From: kai Date: Tue, 16 Apr 2024 17:07:54 +0100 Subject: [PATCH 3/3] tidy --- Makefile | 9 --------- go.mod | 3 +-- go.sum | 4 ++-- hub/hub_base.go | 10 ---------- hub/hub_local.go | 1 - hub/hub_remote.go | 1 - hub/scan_iterator.go | 2 -- 7 files changed, 3 insertions(+), 27 deletions(-) diff --git a/Makefile b/Makefile index eb5ba0e2..e909d2d7 100644 --- a/Makefile +++ b/Makefile @@ -31,15 +31,6 @@ standalone: validate_plugin prebuild.go rm -f prebuild.go -build: prebuild.go - $(MAKE) -C ./fdw clean - $(MAKE) -C ./fdw go - $(MAKE) -C ./fdw - $(MAKE) -C ./fdw inst - - rm -f prebuild.go - - # render target render: validate_plugin prebuild.go @echo "Rendering code for plugin: $(plugin)" diff --git a/go.mod b/go.mod index 87e1ae3c..fccf9a97 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,7 @@ require ( github.com/hashicorp/go-version v1.6.0 // indirect github.com/turbot/go-kit v0.10.0-rc.0 //join_timing - github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a + github.com/turbot/steampipe v1.7.0-rc.0.0.20240416155719-57f19d8b0a9e github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3 go.opentelemetry.io/otel v1.24.0 google.golang.org/protobuf v1.33.0 @@ -197,5 +197,4 @@ replace ( github.com/piquette/edgr => github.com/e-gineer/edgr v0.0.2-0.20210901021602-7664639af765 github.com/vartanbeno/go-reddit/v2 => github.com/abhiturbot/go-reddit/v2 v2.0.0-20220917030010-f0fe7d8ac15c oras.land/oras-go => oras.land/oras-go v1.1.0 - github.com/turbot/steampipe => ../steampipe ) diff --git a/go.sum b/go.sum index f910c1bc..61391e17 100644 --- a/go.sum +++ b/go.sum @@ -709,8 +709,8 @@ github.com/turbot/go-kit v0.10.0-rc.0 h1:kd+jp2ibbIV33Hc8SsMAN410Dl9Pz6SJ40axbKU github.com/turbot/go-kit v0.10.0-rc.0/go.mod h1:fFQqR59I5z5JeeBLfK1PjSifn4Oprs3NiQx0CxeSJxs= github.com/turbot/pipe-fittings v1.1.0 h1:GQ6Hc73uihduLJjiqqj4Iz97w0jQ+QGmd1628X9WnrQ= github.com/turbot/pipe-fittings v1.1.0/go.mod h1:Cgy232VEhVjtDibJS8v5Zf4lKQnfZJOBtsuUNZ7MzTc= -github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a h1:viFKbPBX99c3Ml1VNMrz0ErPuQ0jBy9MDvJHIwv9cBg= -github.com/turbot/steampipe v1.7.0-rc.0.0.20240416091846-b11d8943513a/go.mod h1:FCNkoNAsGRk4f+C18Za7ttH2xRCb+zXr2e+jOFSfM9Y= +github.com/turbot/steampipe v1.7.0-rc.0.0.20240416155719-57f19d8b0a9e h1:D8jiRhpFg/OzU30sBU6W0idCFPIgRmqbbsv+HN51CTM= +github.com/turbot/steampipe v1.7.0-rc.0.0.20240416155719-57f19d8b0a9e/go.mod h1:FCNkoNAsGRk4f+C18Za7ttH2xRCb+zXr2e+jOFSfM9Y= github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3 h1:QU64Yve9b1I4bhpG4mUyLpCBtaCIZTkTRAuBpii8qfQ= github.com/turbot/steampipe-plugin-sdk/v5 v5.10.0-rc.3/go.mod h1:DJ9gPbPzmCe4M2sp+KzCmOhFuucl5/6hXnXvFvS/9nQ= github.com/turbot/terraform-components v0.0.0-20231213122222-1f3526cab7a7 h1:qDMxFVd8Zo0rIhnEBdCIbR+T6WgjwkxpFZMN8zZmmjg= diff --git a/hub/hub_base.go b/hub/hub_base.go index 3743f919..d81008c0 100644 --- a/hub/hub_base.go +++ b/hub/hub_base.go @@ -178,8 +178,6 @@ func (h *hubBase) StartScan(i Iterator) error { // EndScan is called when Postgres terminates the scan (because it has received enough rows of data) func (h *hubBase) EndScan(iter Iterator, limit int64) { - log.Printf("[INFO] hubBase EndScan") - // is the iterator still running? If so it means postgres is stopping a scan before all rows have been read if iter.Status() == QueryStatusStarted { log.Printf("[INFO] ending scan before iterator complete - limit: %v, iterator: %p", limit, iter) @@ -203,7 +201,6 @@ func (h *hubBase) AddScanMetadata(i Iterator) { // if iterator is not a pluginIterator, do nothing iter, ok := i.(pluginIterator) if !ok { - log.Printf("[INFO] AddScanMetadata - not a pluginIterator so returning") return } @@ -247,9 +244,6 @@ func (h *hubBase) AddScanMetadata(i Iterator) { } // write the scan metadata and summary back to the hub h.queryTiming.queryRowSummary[queryTimestamp] = querySummary - - log.Printf("[INFO] AddScanMetadata complete - there are now %d entries for query timestamp %d", len(h.queryTiming.scanMetadata[queryTimestamp]), queryTimestamp) - log.Printf("[INFO] summary: %v", h.queryTiming.queryRowSummary) } // Close shuts down all plugin clients @@ -286,7 +280,6 @@ func (h *hubBase) ApplySetting(key string, value string) error { } func (h *hubBase) GetSettingsSchema() map[string]*proto.TableSchema { - // todo kai only in remote??? return map[string]*proto.TableSchema{ constants.ForeignTableSettings: { Columns: []*proto.ColumnDefinition{ @@ -294,7 +287,6 @@ func (h *hubBase) GetSettingsSchema() map[string]*proto.TableSchema { {Name: constants.ForeignTableSettingsValueColumn, Type: proto.ColumnType_STRING}, }, }, - // todo kai only in remote??? constants.ForeignTableScanMetadata: { Columns: []*proto.ColumnDefinition{ {Name: "connection", Type: proto.ColumnType_STRING}, @@ -309,7 +301,6 @@ func (h *hubBase) GetSettingsSchema() map[string]*proto.TableSchema { {Name: "quals", Type: proto.ColumnType_JSON}, }, }, - // todo kai only in remote??? constants.ForeignTableScanMetadataSummary: { Columns: []*proto.ColumnDefinition{ {Name: "cached_rows_fetched", Type: proto.ColumnType_INT}, @@ -365,7 +356,6 @@ func (h *hubBase) executeCommandScan(connectionName, table string, queryTimestam res := &QueryResult{} for _, scansForQuery := range h.queryTiming.scanMetadata { - log.Printf("[INFO] metadata rows %d", len(scansForQuery)) for _, m := range scansForQuery { res.Rows = append(res.Rows, m.AsResultRow()) } diff --git a/hub/hub_local.go b/hub/hub_local.go index 86d6b4ee..e437eaa8 100644 --- a/hub/hub_local.go +++ b/hub/hub_local.go @@ -198,7 +198,6 @@ func (l *HubLocal) startScanForConnection(connectionName string, table string, q log.Printf("[TRACE] startScanForConnection creating a new scan iterator") iterator := newScanIteratorLocal(l, connectionName, table, l.pluginName, connectionLimitMap, qualMap, columns, limit, scanTraceCtx) - return iterator, nil } diff --git a/hub/hub_remote.go b/hub/hub_remote.go index 34c2afae..ae8e6da6 100644 --- a/hub/hub_remote.go +++ b/hub/hub_remote.go @@ -156,7 +156,6 @@ func (h *RemoteHub) GetPathKeys(opts types.Options) ([]types.PathKey, error) { //// internal implementation //// // startScanForConnection starts a scan for a single connection, using a scanIterator or a legacyScanIterator - func (h *RemoteHub) startScanForConnection(connectionName string, table string, qualMap map[string]*proto.Quals, unhandledRestrictions int, columns []string, limit int64, scanTraceCtx *telemetry.TraceCtx, queryTimestamp int64) (_ Iterator, err error) { defer func() { if err != nil { diff --git a/hub/scan_iterator.go b/hub/scan_iterator.go index 4ed367c2..256f465c 100644 --- a/hub/scan_iterator.go +++ b/hub/scan_iterator.go @@ -49,8 +49,6 @@ func (i *scanIterator) execute(req *proto.ExecuteRequest) (row_stream.Receiver, // note: if this is an aggregator query, we will have a scan metadata for each connection // we need to combine them into a single scan metadata object func (i *scanIterator) GetScanMetadata() []queryresult.ScanMetadataRow { - log.Printf("[INFO] scanIterator GetScanMetadata (%p) (%s)", i, i.callId) - defer log.Printf("[INFO] scanIterator GetScanMetadata end (%p) (%s)", i, i.callId) // if we have scan metadata, return it if len(i.scanMetadata) > 0 { return maps.Values(i.scanMetadata)