diff --git a/central/activecomponent/datastore/internal/store/postgres/store.go b/central/activecomponent/datastore/internal/store/postgres/store.go index 44906a033f1b6..e23901b374584 100644 --- a/central/activecomponent/datastore/internal/store/postgres/store.go +++ b/central/activecomponent/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/alert/datastore/internal/store/postgres/store.go b/central/alert/datastore/internal/store/postgres/store.go index f8d1de97ce071..b7ba39196b0d5 100644 --- a/central/alert/datastore/internal/store/postgres/store.go +++ b/central/alert/datastore/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/apitoken/datastore/internal/store/postgres/store.go b/central/apitoken/datastore/internal/store/postgres/store.go index 3f1549732330e..345d9be589a5f 100644 --- a/central/apitoken/datastore/internal/store/postgres/store.go +++ b/central/apitoken/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/authprovider/datastore/internal/store/postgres/store.go b/central/authprovider/datastore/internal/store/postgres/store.go index e59f6977ead5d..e80f52f32732d 100644 --- a/central/authprovider/datastore/internal/store/postgres/store.go +++ b/central/authprovider/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/blob/datastore/store/postgres/store.go b/central/blob/datastore/store/postgres/store.go index 982ab3ae71c13..c947acfc37727 100644 --- a/central/blob/datastore/store/postgres/store.go +++ b/central/blob/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/blob/datastore/store/store.go b/central/blob/datastore/store/store.go index d070a0097af6e..d5634982f941d 100644 --- a/central/blob/datastore/store/store.go +++ b/central/blob/datastore/store/store.go @@ -4,7 +4,7 @@ import ( "context" "io" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/blob/datastore/store/postgres" "github.com/stackrox/rox/generated/storage" diff --git a/central/cluster/store/cluster/postgres/store.go b/central/cluster/store/cluster/postgres/store.go index 2b62193bb3b98..1054c26302f19 100644 --- a/central/cluster/store/cluster/postgres/store.go +++ b/central/cluster/store/cluster/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/cluster/store/clusterhealth/postgres/store.go b/central/cluster/store/clusterhealth/postgres/store.go index bd1439f94b095..5d792c26affde 100644 --- a/central/cluster/store/clusterhealth/postgres/store.go +++ b/central/cluster/store/clusterhealth/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/clusterinit/store/postgres/store.go b/central/clusterinit/store/postgres/store.go index 9de232fb9aedf..fa554e0ada27b 100644 --- a/central/clusterinit/store/postgres/store.go +++ b/central/clusterinit/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/compliance/datastore/internal/store/postgres/compliance_config/store.go b/central/compliance/datastore/internal/store/postgres/compliance_config/store.go index e065759f5d156..1f351b71cf20f 100644 --- a/central/compliance/datastore/internal/store/postgres/compliance_config/store.go +++ b/central/compliance/datastore/internal/store/postgres/compliance_config/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/compliance/datastore/internal/store/postgres/domain/store.go b/central/compliance/datastore/internal/store/postgres/domain/store.go index 9d8ba16270ed8..326142148b3ae 100644 --- a/central/compliance/datastore/internal/store/postgres/domain/store.go +++ b/central/compliance/datastore/internal/store/postgres/domain/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/compliance/datastore/internal/store/postgres/metadata/store.go b/central/compliance/datastore/internal/store/postgres/metadata/store.go index fb6355fb2f8d4..4d8009de106c8 100644 --- a/central/compliance/datastore/internal/store/postgres/metadata/store.go +++ b/central/compliance/datastore/internal/store/postgres/metadata/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/compliance/datastore/internal/store/postgres/results/store.go b/central/compliance/datastore/internal/store/postgres/results/store.go index cfba6fd93443c..f09cd9a4203f8 100644 --- a/central/compliance/datastore/internal/store/postgres/results/store.go +++ b/central/compliance/datastore/internal/store/postgres/results/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/compliance/datastore/internal/store/postgres/strings/store.go b/central/compliance/datastore/internal/store/postgres/strings/store.go index f918725b5b33a..c3269c1f5d3e8 100644 --- a/central/compliance/datastore/internal/store/postgres/strings/store.go +++ b/central/compliance/datastore/internal/store/postgres/strings/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperator/checkresults/store/postgres/store.go b/central/complianceoperator/checkresults/store/postgres/store.go index 3f79f5bf101cb..1f835cbe8d3a1 100644 --- a/central/complianceoperator/checkresults/store/postgres/store.go +++ b/central/complianceoperator/checkresults/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperator/profiles/store/postgres/store.go b/central/complianceoperator/profiles/store/postgres/store.go index 570cfa8faa48d..72d0db269ca17 100644 --- a/central/complianceoperator/profiles/store/postgres/store.go +++ b/central/complianceoperator/profiles/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperator/rules/store/postgres/store.go b/central/complianceoperator/rules/store/postgres/store.go index d424b7bc4259f..a7727bb138a9e 100644 --- a/central/complianceoperator/rules/store/postgres/store.go +++ b/central/complianceoperator/rules/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperator/scans/store/postgres/store.go b/central/complianceoperator/scans/store/postgres/store.go index 733fdd5e14d50..7de1c587314ea 100644 --- a/central/complianceoperator/scans/store/postgres/store.go +++ b/central/complianceoperator/scans/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperator/scansettingbinding/store/postgres/store.go b/central/complianceoperator/scansettingbinding/store/postgres/store.go index 9aeede95b3929..882994cad6810 100644 --- a/central/complianceoperator/scansettingbinding/store/postgres/store.go +++ b/central/complianceoperator/scansettingbinding/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/complianceoperatorintegration/store/postgres/store.go b/central/complianceoperatorintegration/store/postgres/store.go index ebf256d1be290..39593cbfa8d5b 100644 --- a/central/complianceoperatorintegration/store/postgres/store.go +++ b/central/complianceoperatorintegration/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/cve/cluster/datastore/store/postgres/full_store.go b/central/cve/cluster/datastore/store/postgres/full_store.go index f9563e5873bbe..d67610e08e623 100644 --- a/central/cve/cluster/datastore/store/postgres/full_store.go +++ b/central/cve/cluster/datastore/store/postgres/full_store.go @@ -6,7 +6,7 @@ import ( "time" protoTypes "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/cve/cluster/datastore/store" "github.com/stackrox/rox/central/cve/converter/v2" "github.com/stackrox/rox/central/metrics" diff --git a/central/cve/cluster/datastore/store/postgres/store.go b/central/cve/cluster/datastore/store/postgres/store.go index db908bd4a7c61..4169024a4c6cb 100644 --- a/central/cve/cluster/datastore/store/postgres/store.go +++ b/central/cve/cluster/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/cve/image/datastore/store/postgres/store.go b/central/cve/image/datastore/store/postgres/store.go index 6e43784d583cd..37ab77457bd04 100644 --- a/central/cve/image/datastore/store/postgres/store.go +++ b/central/cve/image/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/cve/node/datastore/store/postgres/store.go b/central/cve/node/datastore/store/postgres/store.go index 94dab688a8263..efebd01de95f9 100644 --- a/central/cve/node/datastore/store/postgres/store.go +++ b/central/cve/node/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/declarativeconfig/health/datastore/store/postgres/store.go b/central/declarativeconfig/health/datastore/store/postgres/store.go index 9c69c56aed92f..50a066cb1d3b4 100644 --- a/central/declarativeconfig/health/datastore/store/postgres/store.go +++ b/central/declarativeconfig/health/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/deployment/datastore/search_comparison_test.go b/central/deployment/datastore/search_comparison_test.go index 5ddb4cda1fe17..02cff765210d9 100644 --- a/central/deployment/datastore/search_comparison_test.go +++ b/central/deployment/datastore/search_comparison_test.go @@ -19,7 +19,6 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" - "go.uber.org/mock/gomock" ) var ( @@ -33,7 +32,6 @@ func TestSearchComparison(t *testing.T) { type SearchComparisonTestSuite struct { suite.Suite - mockCtrl *gomock.Controller testDB *pgtest.TestPostgres imageDatastore imageDataStore.DataStore deploymentDatastore DataStore diff --git a/central/deployment/store/postgres/store.go b/central/deployment/store/postgres/store.go index 28f1a2101ceef..4d3b4a42e67ca 100644 --- a/central/deployment/store/postgres/store.go +++ b/central/deployment/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/externalbackups/internal/store/postgres/store.go b/central/externalbackups/internal/store/postgres/store.go index 0a8e149036c6c..48c91243c4bee 100644 --- a/central/externalbackups/internal/store/postgres/store.go +++ b/central/externalbackups/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/group/datastore/internal/store/postgres/store.go b/central/group/datastore/internal/store/postgres/store.go index 7267ea74e9c0d..49cde7a0d2eba 100644 --- a/central/group/datastore/internal/store/postgres/store.go +++ b/central/group/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/hash/datastore/store/postgres/store.go b/central/hash/datastore/store/postgres/store.go index b71460b3d9455..f611a1792801c 100644 --- a/central/hash/datastore/store/postgres/store.go +++ b/central/hash/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/image/datastore/store/postgres/store.go b/central/image/datastore/store/postgres/store.go index fcbd37defafc3..33a638c5ad64d 100644 --- a/central/image/datastore/store/postgres/store.go +++ b/central/image/datastore/store/postgres/store.go @@ -5,7 +5,7 @@ import ( "time" protoTypes "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/image/datastore/store" "github.com/stackrox/rox/central/image/datastore/store/common/v2" diff --git a/central/imagecomponent/datastore/store/postgres/store.go b/central/imagecomponent/datastore/store/postgres/store.go index 28acf81c65c67..3a894728bcbec 100644 --- a/central/imagecomponent/datastore/store/postgres/store.go +++ b/central/imagecomponent/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/imageintegration/store/postgres/store.go b/central/imageintegration/store/postgres/store.go index d937965d2c4b9..df70604dae4ec 100644 --- a/central/imageintegration/store/postgres/store.go +++ b/central/imageintegration/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/integrationhealth/store/postgres/store.go b/central/integrationhealth/store/postgres/store.go index 5dd6876b7c8ee..38ef51fe82580 100644 --- a/central/integrationhealth/store/postgres/store.go +++ b/central/integrationhealth/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/logimbue/store/postgres/store.go b/central/logimbue/store/postgres/store.go index 3c7290ebd66ff..7a51624908b6c 100644 --- a/central/logimbue/store/postgres/store.go +++ b/central/logimbue/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/namespace/store/postgres/store.go b/central/namespace/store/postgres/store.go index 670bf976bed86..4cbc3c960bb14 100644 --- a/central/namespace/store/postgres/store.go +++ b/central/namespace/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/networkbaseline/store/postgres/store.go b/central/networkbaseline/store/postgres/store.go index c41d90f4242f5..4abd74332e32b 100644 --- a/central/networkbaseline/store/postgres/store.go +++ b/central/networkbaseline/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/networkgraph/config/datastore/internal/store/postgres/store.go b/central/networkgraph/config/datastore/internal/store/postgres/store.go index 03ab802942435..215378dac0822 100644 --- a/central/networkgraph/config/datastore/internal/store/postgres/store.go +++ b/central/networkgraph/config/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/networkgraph/entity/datastore/internal/store/postgres/store.go b/central/networkgraph/entity/datastore/internal/store/postgres/store.go index db2ec3c9bb2de..e13f0e1411187 100644 --- a/central/networkgraph/entity/datastore/internal/store/postgres/store.go +++ b/central/networkgraph/entity/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/networkgraph/flow/datastore/internal/store/postgres/store.go b/central/networkgraph/flow/datastore/internal/store/postgres/store.go index 903bacb0aa7c3..a081a3cfb4bcc 100644 --- a/central/networkgraph/flow/datastore/internal/store/postgres/store.go +++ b/central/networkgraph/flow/datastore/internal/store/postgres/store.go @@ -8,7 +8,7 @@ import ( "time" "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" "github.com/stackrox/rox/generated/storage" diff --git a/central/networkpolicies/datastore/internal/store/postgres/store.go b/central/networkpolicies/datastore/internal/store/postgres/store.go index 4ccf6966d9538..73903e5a97f34 100644 --- a/central/networkpolicies/datastore/internal/store/postgres/store.go +++ b/central/networkpolicies/datastore/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/networkpolicies/datastore/internal/undodeploymentstore/postgres/store.go b/central/networkpolicies/datastore/internal/undodeploymentstore/postgres/store.go index 45fb2bc6fe018..5d5fb8e3558ab 100644 --- a/central/networkpolicies/datastore/internal/undodeploymentstore/postgres/store.go +++ b/central/networkpolicies/datastore/internal/undodeploymentstore/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/networkpolicies/datastore/internal/undostore/postgres/store.go b/central/networkpolicies/datastore/internal/undostore/postgres/store.go index 1cf8b5e2f83ad..ab5fb253af2d0 100644 --- a/central/networkpolicies/datastore/internal/undostore/postgres/store.go +++ b/central/networkpolicies/datastore/internal/undostore/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/node/datastore/store/postgres/store.go b/central/node/datastore/store/postgres/store.go index 1f2e27eb76ea3..403dd5cdd158a 100644 --- a/central/node/datastore/store/postgres/store.go +++ b/central/node/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "time" protoTypes "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" "github.com/stackrox/rox/central/node/datastore/store/common/v2" diff --git a/central/nodecomponent/datastore/store/postgres/store.go b/central/nodecomponent/datastore/store/postgres/store.go index d49c05177306e..ec11e35617446 100644 --- a/central/nodecomponent/datastore/store/postgres/store.go +++ b/central/nodecomponent/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/notifier/datastore/internal/store/postgres/store.go b/central/notifier/datastore/internal/store/postgres/store.go index 04c25df7a55b2..16179831ecdd9 100644 --- a/central/notifier/datastore/internal/store/postgres/store.go +++ b/central/notifier/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/pod/store/postgres/store.go b/central/pod/store/postgres/store.go index 5a7da533a415e..d6bd5ec44b35d 100644 --- a/central/pod/store/postgres/store.go +++ b/central/pod/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/policy/store/postgres/store.go b/central/policy/store/postgres/store.go index 3786986f88335..3faca25c9392a 100644 --- a/central/policy/store/postgres/store.go +++ b/central/policy/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/policycategory/store/postgres/store.go b/central/policycategory/store/postgres/store.go index eb6f508eb1650..2f327d2316265 100644 --- a/central/policycategory/store/postgres/store.go +++ b/central/policycategory/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/policycategoryedge/store/postgres/store.go b/central/policycategoryedge/store/postgres/store.go index 2481334a240ed..395797dd1c4d2 100644 --- a/central/policycategoryedge/store/postgres/store.go +++ b/central/policycategoryedge/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/processbaseline/store/postgres/store.go b/central/processbaseline/store/postgres/store.go index b64e458ae5634..5b65874fda5ce 100644 --- a/central/processbaseline/store/postgres/store.go +++ b/central/processbaseline/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/processbaselineresults/datastore/internal/store/postgres/store.go b/central/processbaselineresults/datastore/internal/store/postgres/store.go index a6f992c415ffd..f0ca84dcdce65 100644 --- a/central/processbaselineresults/datastore/internal/store/postgres/store.go +++ b/central/processbaselineresults/datastore/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/processindicator/store/postgres/store.go b/central/processindicator/store/postgres/store.go index 8f007f4e55668..de4799ba50c8c 100644 --- a/central/processindicator/store/postgres/store.go +++ b/central/processindicator/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/processlisteningonport/store/postgres/full_store.go b/central/processlisteningonport/store/postgres/full_store.go index f4b01a2987140..95e04a3a79319 100644 --- a/central/processlisteningonport/store/postgres/full_store.go +++ b/central/processlisteningonport/store/postgres/full_store.go @@ -5,7 +5,7 @@ import ( "time" "github.com/gogo/protobuf/proto" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" metrics "github.com/stackrox/rox/central/metrics" "github.com/stackrox/rox/central/processlisteningonport/store" "github.com/stackrox/rox/generated/storage" diff --git a/central/processlisteningonport/store/postgres/store.go b/central/processlisteningonport/store/postgres/store.go index 3751f02ba4959..86b3b2b8d071c 100644 --- a/central/processlisteningonport/store/postgres/store.go +++ b/central/processlisteningonport/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/rbac/k8srole/internal/store/postgres/store.go b/central/rbac/k8srole/internal/store/postgres/store.go index 613a98a774da5..8e7b1978b8e56 100644 --- a/central/rbac/k8srole/internal/store/postgres/store.go +++ b/central/rbac/k8srole/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/rbac/k8srolebinding/internal/store/postgres/store.go b/central/rbac/k8srolebinding/internal/store/postgres/store.go index b1791d418d655..ad168f925d62e 100644 --- a/central/rbac/k8srolebinding/internal/store/postgres/store.go +++ b/central/rbac/k8srolebinding/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/reportconfigurations/store/postgres/store.go b/central/reportconfigurations/store/postgres/store.go index 7a72bc34ff2a2..b954a2a3558db 100644 --- a/central/reportconfigurations/store/postgres/store.go +++ b/central/reportconfigurations/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/reports/metadata/datastore/store/postgres/store.go b/central/reports/metadata/datastore/store/postgres/store.go index 25e2527365e51..2df6b661d5169 100644 --- a/central/reports/metadata/datastore/store/postgres/store.go +++ b/central/reports/metadata/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/reports/snapshot/datastore/store/postgres/store.go b/central/reports/snapshot/datastore/store/postgres/store.go index b9c1497091b22..c6b6fa928ff3c 100644 --- a/central/reports/snapshot/datastore/store/postgres/store.go +++ b/central/reports/snapshot/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/resourcecollection/datastore/store/postgres/store.go b/central/resourcecollection/datastore/store/postgres/store.go index e331ac7816645..6abccb5f81fe0 100644 --- a/central/resourcecollection/datastore/store/postgres/store.go +++ b/central/resourcecollection/datastore/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/risk/datastore/internal/store/postgres/store.go b/central/risk/datastore/internal/store/postgres/store.go index 5d4a744098671..19d378a9ca3b2 100644 --- a/central/risk/datastore/internal/store/postgres/store.go +++ b/central/risk/datastore/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/role/store/permissionset/postgres/store.go b/central/role/store/permissionset/postgres/store.go index 8cf47936e698e..effff94da7887 100644 --- a/central/role/store/permissionset/postgres/store.go +++ b/central/role/store/permissionset/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/role/store/role/postgres/store.go b/central/role/store/role/postgres/store.go index 56a49668f582f..a6d5242d54397 100644 --- a/central/role/store/role/postgres/store.go +++ b/central/role/store/role/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/role/store/simpleaccessscope/postgres/store.go b/central/role/store/simpleaccessscope/postgres/store.go index cfce1cf8d98b5..bfdc8aeff733a 100644 --- a/central/role/store/simpleaccessscope/postgres/store.go +++ b/central/role/store/simpleaccessscope/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/secret/internal/store/postgres/store.go b/central/secret/internal/store/postgres/store.go index d67a6e6ac4738..e8c4a9a493261 100644 --- a/central/secret/internal/store/postgres/store.go +++ b/central/secret/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/serviceaccount/internal/store/postgres/store.go b/central/serviceaccount/internal/store/postgres/store.go index 45841ddeb624e..d3585ee2272d7 100644 --- a/central/serviceaccount/internal/store/postgres/store.go +++ b/central/serviceaccount/internal/store/postgres/store.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" diff --git a/central/serviceidentities/internal/store/postgres/store.go b/central/serviceidentities/internal/store/postgres/store.go index 40e73532e8a48..6816cd890a5f0 100644 --- a/central/serviceidentities/internal/store/postgres/store.go +++ b/central/serviceidentities/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/signatureintegration/store/postgres/store.go b/central/signatureintegration/store/postgres/store.go index f50674df04e59..e866e68fd8fee 100644 --- a/central/signatureintegration/store/postgres/store.go +++ b/central/signatureintegration/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/vulnerabilityrequest/datastore/internal/store/postgres/store.go b/central/vulnerabilityrequest/datastore/internal/store/postgres/store.go index 0e5979ce82d01..1c58fc635490a 100644 --- a/central/vulnerabilityrequest/datastore/internal/store/postgres/store.go +++ b/central/vulnerabilityrequest/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/central/watchedimage/datastore/internal/store/postgres/store.go b/central/watchedimage/datastore/internal/store/postgres/store.go index 9d5ce5f35a410..9cc38f962d50c 100644 --- a/central/watchedimage/datastore/internal/store/postgres/store.go +++ b/central/watchedimage/datastore/internal/store/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/go.mod b/go.mod index a66f25879c658..55ecf67936f38 100644 --- a/go.mod +++ b/go.mod @@ -34,7 +34,7 @@ require ( github.com/facebookincubator/nvdtools v0.1.5 github.com/fatih/color v1.15.0 github.com/fullsailor/pkcs7 v0.0.0 - github.com/georgysavva/scany v1.2.1 + github.com/georgysavva/scany/v2 v2.0.0 github.com/ghodss/yaml v1.0.0 github.com/go-logr/logr v1.2.4 github.com/go-logr/zapr v1.2.4 @@ -58,10 +58,8 @@ require ( github.com/heimdalr/dag v1.2.1 github.com/helm/helm-mapkubeapis v0.4.1 github.com/heroku/docker-registry-client v0.0.0 - github.com/jackc/pgconn v1.14.0 - github.com/jackc/pgproto3/v2 v2.3.2 github.com/jackc/pgtype v1.14.0 - github.com/jackc/pgx/v4 v4.18.1 + github.com/jackc/pgx/v5 v5.4.2 github.com/joshdk/go-junit v1.0.0 github.com/lib/pq v1.10.9 github.com/machinebox/graphql v0.2.2 @@ -251,11 +249,13 @@ require ( github.com/itchyny/gojq v0.12.13 // indirect github.com/itchyny/timefmt-go v0.1.5 // indirect github.com/jackc/chunkreader/v2 v2.0.1 // indirect + github.com/jackc/pgconn v1.14.0 // 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/pgservicefile v0.0.0-20221227161230-091c0ba34f0a // indirect - github.com/jackc/pgx/v5 v5.3.1 // indirect - github.com/jackc/puddle v1.3.0 // indirect + github.com/jackc/pgx/v4 v4.18.0 // indirect + github.com/jackc/puddle/v2 v2.2.0 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect github.com/jedisct1/go-minisign v0.0.0-20211028175153-1c139d1cc84b // indirect github.com/jinzhu/inflection v1.0.0 // indirect diff --git a/go.sum b/go.sum index 78510488a53f4..d0cd071729e49 100644 --- a/go.sum +++ b/go.sum @@ -243,7 +243,6 @@ github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I= github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= -github.com/cockroachdb/cockroach-go/v2 v2.2.0/go.mod h1:u3MiKYGupPPjkn3ozknpMUpxPaNLTFWAya419/zv6eI= github.com/cockroachdb/cockroach-go/v2 v2.3.3 h1:fNmtG6XhoA1DhdDCIu66YyGSsNb1szj4CaAsbDxRmy4= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/cockroachdb/datadriven v1.0.0/go.mod h1:5Ib8Meh+jk1RlHIXej6Pzevx/NLlNvQB9pmSBZErGA4= @@ -414,8 +413,8 @@ github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbS 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/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= -github.com/georgysavva/scany v1.2.1 h1:91PAMBpwBtDjvn46TaLQmuVhxpAG6p6sjQaU4zPHPSM= -github.com/georgysavva/scany v1.2.1/go.mod h1:vGBpL5XRLOocMFFa55pj0P04DrL3I7qKVRL49K6Eu5o= +github.com/georgysavva/scany/v2 v2.0.0 h1:RGXqxDv4row7/FYoK8MRXAZXqoWF/NM+NP0q50k3DKU= +github.com/georgysavva/scany/v2 v2.0.0/go.mod h1:sigOdh+0qb/+aOs3TVhehVT10p8qJL7K/Zhyz8vWo38= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= @@ -516,7 +515,6 @@ github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GO github.com/go-playground/validator/v10 v10.14.0 h1:vgvQWe3XCz3gIeFDm/HnTIbj6UGmg/+t63MyGU2n5js= github.com/go-playground/validator/v10 v10.14.0/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-sql-driver/mysql v1.7.1 h1:lUIinVbN1DY0xBg0eMOzmmtGoHwWBbvnWubQUrtU8EI= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= @@ -583,7 +581,6 @@ github.com/godbus/dbus/v5 v5.1.0/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5x github.com/godror/godror v0.24.2/go.mod h1:wZv/9vPiUib6tkoDl+AZ/QLf5YZgMravZ7jxH2eQWAE= github.com/gofrs/flock v0.8.0/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= -github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.4.0+incompatible h1:3qXRTX8/NbyulANqlc0lchS1gqAVxRgsuW1YrTJupqA= @@ -883,7 +880,6 @@ github.com/jackc/pgtype v0.0.0-20190828014616-a8802b16cc59/go.mod h1:MWlu30kVJrU github.com/jackc/pgtype v1.2.0/go.mod h1:5m2OfMh1wTK7x+Fk952IDmI4nw3nPrvtQdM0ZT4WpC0= github.com/jackc/pgtype v1.3.1-0.20200510190516-8cd94a14c75a/go.mod h1:vaogEUkALtxZMCH411K+tKzNpwzCKU+AnPzBKZ+I+Po= github.com/jackc/pgtype v1.3.1-0.20200606141011-f6355165a91c/go.mod h1:cvk9Bgu/VzJ9/lxTO5R5sf80p0DiucVtN7ZxvaC4GmQ= -github.com/jackc/pgtype v1.6.2/go.mod h1:JCULISAZBFGrHaOXIIFiyfzW5VY0GRitRr8NeJsrdig= github.com/jackc/pgtype v1.7.0/go.mod h1:ZnHF+rMePVqDKaOfJVI4Q8IVvAQMryDlDkZnKOI75BE= github.com/jackc/pgtype v1.8.1-0.20210724151600-32e20a603178/go.mod h1:C516IlIV9NKqfsMCXTdChteoXmwgUceqaLfjg2e3NlM= github.com/jackc/pgtype v1.14.0 h1:y+xUdabmyMkJLyApYuPj38mW+aAIqCe5uuBB51rH3Vw= @@ -894,13 +890,12 @@ github.com/jackc/pgx/v4 v4.0.0-pre1.0.20190824185557-6972a5742186/go.mod h1:X+GQ github.com/jackc/pgx/v4 v4.5.0/go.mod h1:EpAKPLdnTorwmPUUsqrPxy5fphV18j9q3wrfRXgo+kA= github.com/jackc/pgx/v4 v4.6.1-0.20200510190926-94ba730bb1e9/go.mod h1:t3/cdRQl6fOLDxqtlyhe9UWgfIi9R8+8v8GKV5TRA/o= github.com/jackc/pgx/v4 v4.6.1-0.20200606145419-4e5062306904/go.mod h1:ZDaNWkt9sW1JMiNn0kdYBaLelIhw7Pg4qd+Vk6tw7Hg= -github.com/jackc/pgx/v4 v4.10.1/go.mod h1:QlrWebbs3kqEZPHCTGyxecvzG6tvIsYu+A5b1raylkA= github.com/jackc/pgx/v4 v4.11.0/go.mod h1:i62xJgdrtVDsnL3U8ekyrQXEwGNTRoG7/8r+CIdYfcc= github.com/jackc/pgx/v4 v4.12.1-0.20210724153913-640aa07df17c/go.mod h1:1QD0+tgSXP7iUjYm9C1NxKhny7lq6ee99u/z+IHFcgs= -github.com/jackc/pgx/v4 v4.18.1 h1:YP7G1KABtKpB5IHrO9vYwSrCOhs7p3uqhvhhQBptya0= -github.com/jackc/pgx/v4 v4.18.1/go.mod h1:FydWkUyadDmdNH/mHnGob881GawxeEm7TcMCzkb+qQE= -github.com/jackc/pgx/v5 v5.3.1 h1:Fcr8QJ1ZeLi5zsPZqQeUZhNhxfkkKBOgJuYkJHoBOtU= -github.com/jackc/pgx/v5 v5.3.1/go.mod h1:t3JDKnCBlYIc0ewLF0Q7B8MXmoIaBOZj/ic7iHozM/8= +github.com/jackc/pgx/v4 v4.18.0 h1:Ltaa1ePvc7msFGALnCrqKJVEByu/qYh5jJBYcDtAno4= +github.com/jackc/pgx/v4 v4.18.0/go.mod h1:FydWkUyadDmdNH/mHnGob881GawxeEm7TcMCzkb+qQE= +github.com/jackc/pgx/v5 v5.4.2 h1:u1gmGDwbdRUZiwisBm/Ky2M14uQyUP65bG8+20nnyrg= +github.com/jackc/pgx/v5 v5.4.2/go.mod h1:q6iHT8uDNXWiFNOlRqJzBTaSH3+2xCXkokxHZC5qWFY= 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/puddle v1.1.0/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= @@ -908,6 +903,8 @@ github.com/jackc/puddle v1.1.1/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dv github.com/jackc/puddle v1.1.3/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v1.3.0 h1:eHK/5clGOatcjX3oWGBO/MpxpbHzSwud5EWTSCI+MX0= github.com/jackc/puddle v1.3.0/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= +github.com/jackc/puddle/v2 v2.2.0 h1:RdcDk92EJBuBS55nQMMYFXTxwstHug4jkhT5pq8VxPk= +github.com/jackc/puddle/v2 v2.2.0/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= github.com/jedisct1/go-minisign v0.0.0-20211028175153-1c139d1cc84b h1:ZGiXF8sz7PDk6RgkP+A/SFfUD0ZR/AgG6SpRNEDKZy8= @@ -919,7 +916,6 @@ github.com/jgautheron/goconst v0.0.0-20201117150253-ccae5bf973f3/go.mod h1:aAose github.com/jingyugao/rowserrcheck v0.0.0-20191204022205-72ab7603b68a/go.mod h1:xRskid8CManxVta/ALEhJha/pweKBaVG6fWgc0yH25s= github.com/jinzhu/inflection v1.0.0 h1:K317FqzuhWc8YvSVlFMCCUb36O/S9MCKRDI7QkRKD/E= github.com/jinzhu/inflection v1.0.0/go.mod h1:h+uFLlag+Qp1Va5pdKtLDYj+kHp5pxUVkryuEj+Srlc= -github.com/jinzhu/now v1.1.1/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= github.com/jinzhu/now v1.1.5 h1:/o9tlHleP7gOFmsnYNz3RGnqzefHA47wQpKrrdTIwXQ= github.com/jinzhu/now v1.1.5/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= github.com/jirfag/go-printf-func-name v0.0.0-20191110105641-45db9963cdd3/go.mod h1:HEWGJkRDzjJY2sqdDwxccsGicWEf9BQOZsq2tV+xzM0= @@ -931,7 +927,6 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC github.com/jmhodges/clock v1.2.0 h1:eq4kys+NI0PLngzaHEe7AmPT90XMGIEySD1JfV1PDIs= github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= github.com/jmoiron/sqlx v1.2.1-0.20190826204134-d7d95172beb5/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= -github.com/jmoiron/sqlx v1.3.1/go.mod h1:2BljVx/86SuTyjE+aPYlHCTNvZrnJXghYGpNiXLBMCQ= github.com/jmoiron/sqlx v1.3.5 h1:vFFPA71p1o5gAeqtEAwLU4dnX2napprKtHr7PYIcN3g= github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg= @@ -1024,7 +1019,6 @@ 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/lib/pq v1.3.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.10.0/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.2/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.7/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= @@ -1915,7 +1909,6 @@ golang.org/x/sys v0.0.0-20210616045830-e2b7044e8c71/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210906170528-6f6e22806c34/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -2269,11 +2262,8 @@ gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkep gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= -gorm.io/driver/postgres v1.0.8/go.mod h1:4eOzrI1MUfm6ObJU/UcmbXyiHSs8jSwH95G5P5dxcAg= gorm.io/driver/postgres v1.5.2 h1:ytTDxxEv+MplXOfFe3Lzm7SjG09fcdb3Z/c056DTBx0= gorm.io/driver/postgres v1.5.2/go.mod h1:fmpX0m2I1PKuR7mKZiEluwrP3hbs+ps7JIGMUBpCgl8= -gorm.io/gorm v1.20.12/go.mod h1:0HFTzE/SqkGTzK6TlDPPQbAYCluiVvhzoA1+aVyzenw= -gorm.io/gorm v1.21.4/go.mod h1:0HFTzE/SqkGTzK6TlDPPQbAYCluiVvhzoA1+aVyzenw= gorm.io/gorm v1.25.2 h1:gs1o6Vsa+oVKG/a9ElL3XgyGfghFfkKA2SInQaCyMho= gorm.io/gorm v1.25.2/go.mod h1:L4uxeKpfBml98NYqVqwAdmV1a2nBtAec/cf3fpucW/k= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= diff --git a/migrator/migrations/m_168_to_m_169_postgres_remove_clustercve_permission/permissionsetpostgresstore/postgres_plugin.go b/migrator/migrations/m_168_to_m_169_postgres_remove_clustercve_permission/permissionsetpostgresstore/postgres_plugin.go index 33a68062846b6..14d93abe53147 100644 --- a/migrator/migrations/m_168_to_m_169_postgres_remove_clustercve_permission/permissionsetpostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_168_to_m_169_postgres_remove_clustercve_permission/permissionsetpostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_169_to_m_170_collections_sac_resource_migration/permissionsetpostgresstore/postgres_plugin.go b/migrator/migrations/m_169_to_m_170_collections_sac_resource_migration/permissionsetpostgresstore/postgres_plugin.go index 26b0c8e15c9c7..bc75fe58d329b 100644 --- a/migrator/migrations/m_169_to_m_170_collections_sac_resource_migration/permissionsetpostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_169_to_m_170_collections_sac_resource_migration/permissionsetpostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategoryedgepostgresstore/store.go b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategoryedgepostgresstore/store.go index 7e26335d3fba0..8e49c39631cee 100644 --- a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategoryedgepostgresstore/store.go +++ b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategoryedgepostgresstore/store.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategorypostgresstore/store.go b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategorypostgresstore/store.go index 91dc15034e4b4..9c3ba5d360869 100644 --- a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategorypostgresstore/store.go +++ b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policycategorypostgresstore/store.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policypostgresstore/store.go b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policypostgresstore/store.go index 1de718a28f070..2b699c3c79bee 100644 --- a/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policypostgresstore/store.go +++ b/migrator/migrations/m_170_to_m_171_create_policy_categories_and_edges/policypostgresstore/store.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/accessScopePostgresStore/postgres_plugin.go b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/accessScopePostgresStore/postgres_plugin.go index 7174355040ffd..f1298e109c9f3 100644 --- a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/accessScopePostgresStore/postgres_plugin.go +++ b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/accessScopePostgresStore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/collectionPostgresStore/postgres_plugin.go b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/collectionPostgresStore/postgres_plugin.go index 719d06d4241c6..62510affd0e17 100644 --- a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/collectionPostgresStore/postgres_plugin.go +++ b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/collectionPostgresStore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/reportConfigurationPostgresStore/postgres_plugin.go b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/reportConfigurationPostgresStore/postgres_plugin.go index 6ecc12fec2932..9aacfe9808923 100644 --- a/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/reportConfigurationPostgresStore/postgres_plugin.go +++ b/migrator/migrations/m_171_to_m_172_move_scope_to_collection_in_report_configurations/reportConfigurationPostgresStore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/previous/store.go b/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/previous/store.go index 02537fbfb774a..2d10c5cb7de52 100644 --- a/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/previous/store.go +++ b/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/previous/store.go @@ -6,7 +6,7 @@ import ( "time" "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/generated/storage" frozenSchema "github.com/stackrox/rox/migrator/migrations/frozenschema/v73" "github.com/stackrox/rox/pkg/logging" diff --git a/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/updated/store.go b/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/updated/store.go index 95989d01d3e79..ed409d3778816 100644 --- a/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/updated/store.go +++ b/migrator/migrations/m_172_to_m_173_network_flows_partition/stores/updated/store.go @@ -7,7 +7,7 @@ import ( "time" "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/generated/storage" "github.com/stackrox/rox/pkg/logging" "github.com/stackrox/rox/pkg/postgres" diff --git a/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/previous/postgres_plugin.go b/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/previous/postgres_plugin.go index 063fc29deeda2..1606a3dcfd1a2 100644 --- a/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/previous/postgres_plugin.go +++ b/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/previous/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/updated/postgres_plugin.go b/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/updated/postgres_plugin.go index d18877cdd9ddb..68c5cc9e0bb72 100644 --- a/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/updated/postgres_plugin.go +++ b/migrator/migrations/m_173_to_m_174_group_unique_constraint/stores/updated/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/newapitokenpostgresstore/postgres_plugin.go b/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/newapitokenpostgresstore/postgres_plugin.go index e6edbc2674bc3..df3aafb286185 100644 --- a/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/newapitokenpostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/newapitokenpostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/oldapitokenpostgresstore/postgres_plugin.go b/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/oldapitokenpostgresstore/postgres_plugin.go index 28f5c2cfe4ce6..070ae52fb783e 100644 --- a/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/oldapitokenpostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_174_to_m_175_enable_search_on_api_tokens/oldapitokenpostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkbaselinestore/postgres_plugin.go b/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkbaselinestore/postgres_plugin.go index a3f936721f9c5..858c123410d7f 100644 --- a/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkbaselinestore/postgres_plugin.go +++ b/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkbaselinestore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkentitystore/postgres_plugin.go b/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkentitystore/postgres_plugin.go index 41e0f8e04231a..b03489af66f31 100644 --- a/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkentitystore/postgres_plugin.go +++ b/migrator/migrations/m_176_to_m_177_network_baselines_cidr/networkentitystore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_177_to_m_178_group_permissions/permissionsetpostgresstore/postgres_plugin.go b/migrator/migrations/m_177_to_m_178_group_permissions/permissionsetpostgresstore/postgres_plugin.go index 2bca217799e57..ee41725039a8e 100644 --- a/migrator/migrations/m_177_to_m_178_group_permissions/permissionsetpostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_177_to_m_178_group_permissions/permissionsetpostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/reportconfigstore/postgres_plugin.go b/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/reportconfigstore/postgres_plugin.go index 22175523a9189..74f35988978e2 100644 --- a/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/reportconfigstore/postgres_plugin.go +++ b/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/reportconfigstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/test/postgres_plugin.go b/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/test/postgres_plugin.go index 7cbb61cbb3cd0..239367f626699 100644 --- a/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/test/postgres_plugin.go +++ b/migrator/migrations/m_178_to_m_179_embedded_collections_search_label/test/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_179_to_m_180_openshift_policy_exclusions/postgres/store.go b/migrator/migrations/m_179_to_m_180_openshift_policy_exclusions/postgres/store.go index b144c78d17ed6..dbab1ea21edb9 100644 --- a/migrator/migrations/m_179_to_m_180_openshift_policy_exclusions/postgres/store.go +++ b/migrator/migrations/m_179_to_m_180_openshift_policy_exclusions/postgres/store.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_181_to_m_182_group_role_permission_with_access_one/permissionsetstore/store.go b/migrator/migrations/m_181_to_m_182_group_role_permission_with_access_one/permissionsetstore/store.go index 15ae785a04ecf..6ceb2741f4a3e 100644 --- a/migrator/migrations/m_181_to_m_182_group_role_permission_with_access_one/permissionsetstore/store.go +++ b/migrator/migrations/m_181_to_m_182_group_role_permission_with_access_one/permissionsetstore/store.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/apitokenstore/postgres_plugin.go b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/apitokenstore/postgres_plugin.go index 6d8415873307f..a3a1a3feb7f4f 100644 --- a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/apitokenstore/postgres_plugin.go +++ b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/apitokenstore/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/groupstore/postgres_plugin.go b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/groupstore/postgres_plugin.go index 7d39d0a6c7bfb..a514d74673987 100644 --- a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/groupstore/postgres_plugin.go +++ b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/groupstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/permissionsetstore/postgres_plugin.go b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/permissionsetstore/postgres_plugin.go index 797ca21171e2c..e589e82e6b891 100644 --- a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/permissionsetstore/postgres_plugin.go +++ b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/permissionsetstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/rolestore/postgres_plugin.go b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/rolestore/postgres_plugin.go index 9892df51779a4..d2faa5e61bdf4 100644 --- a/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/rolestore/postgres_plugin.go +++ b/migrator/migrations/m_182_to_m_183_remove_default_scope_manager_role/rolestore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_183_to_m_184_move_declarative_config_health/declarativeconfig/store/postgres_plugin.go b/migrator/migrations/m_183_to_m_184_move_declarative_config_health/declarativeconfig/store/postgres_plugin.go index c4d30841e10cd..11c3c80e890e9 100644 --- a/migrator/migrations/m_183_to_m_184_move_declarative_config_health/declarativeconfig/store/postgres_plugin.go +++ b/migrator/migrations/m_183_to_m_184_move_declarative_config_health/declarativeconfig/store/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" migrationSchema "github.com/stackrox/rox/migrator/migrations/m_183_to_m_184_move_declarative_config_health/declarativeconfig/schema" diff --git a/migrator/migrations/m_183_to_m_184_move_declarative_config_health/integrationhealth/store/postgres_plugin.go b/migrator/migrations/m_183_to_m_184_move_declarative_config_health/integrationhealth/store/postgres_plugin.go index c2559e08237e1..49c6803dbbc78 100644 --- a/migrator/migrations/m_183_to_m_184_move_declarative_config_health/integrationhealth/store/postgres_plugin.go +++ b/migrator/migrations/m_183_to_m_184_move_declarative_config_health/integrationhealth/store/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" migrationSchema "github.com/stackrox/rox/migrator/migrations/m_183_to_m_184_move_declarative_config_health/integrationhealth/schema" diff --git a/migrator/migrations/m_184_to_m_185_remove_policy_vulnerability_report_resources/permissionsetstore/postgres_plugin.go b/migrator/migrations/m_184_to_m_185_remove_policy_vulnerability_report_resources/permissionsetstore/postgres_plugin.go index b2ca1bda241d5..ac7b66dd39ec7 100644 --- a/migrator/migrations/m_184_to_m_185_remove_policy_vulnerability_report_resources/permissionsetstore/postgres_plugin.go +++ b/migrator/migrations/m_184_to_m_185_remove_policy_vulnerability_report_resources/permissionsetstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/m_185_to_m_186_more_policy_migrations/policypostgresstore/postgres_plugin.go b/migrator/migrations/m_185_to_m_186_more_policy_migrations/policypostgresstore/postgres_plugin.go index b01f4286848fa..06a3d9fd6cb81 100644 --- a/migrator/migrations/m_185_to_m_186_more_policy_migrations/policypostgresstore/postgres_plugin.go +++ b/migrator/migrations/m_185_to_m_186_more_policy_migrations/policypostgresstore/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_01_to_n_02_postgres_clusters/postgres/postgres_plugin.go b/migrator/migrations/n_01_to_n_02_postgres_clusters/postgres/postgres_plugin.go index bb31190ad6c49..d60d7c4dc4820 100644 --- a/migrator/migrations/n_01_to_n_02_postgres_clusters/postgres/postgres_plugin.go +++ b/migrator/migrations/n_01_to_n_02_postgres_clusters/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_02_to_n_03_postgres_namespaces/postgres/postgres_plugin.go b/migrator/migrations/n_02_to_n_03_postgres_namespaces/postgres/postgres_plugin.go index 5610cc32e06da..0673e013d4e57 100644 --- a/migrator/migrations/n_02_to_n_03_postgres_namespaces/postgres/postgres_plugin.go +++ b/migrator/migrations/n_02_to_n_03_postgres_namespaces/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_03_to_n_04_postgres_deployments/postgres/postgres_plugin.go b/migrator/migrations/n_03_to_n_04_postgres_deployments/postgres/postgres_plugin.go index 9c6967ee7d13b..ad97958256d64 100644 --- a/migrator/migrations/n_03_to_n_04_postgres_deployments/postgres/postgres_plugin.go +++ b/migrator/migrations/n_03_to_n_04_postgres_deployments/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_04_to_n_05_postgres_images/postgres/store.go b/migrator/migrations/n_04_to_n_05_postgres_images/postgres/store.go index edca43baa18f6..3d983cf35d620 100644 --- a/migrator/migrations/n_04_to_n_05_postgres_images/postgres/store.go +++ b/migrator/migrations/n_04_to_n_05_postgres_images/postgres/store.go @@ -8,7 +8,7 @@ import ( "github.com/gogo/protobuf/proto" protoTypes "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/generated/storage" pkgSchema "github.com/stackrox/rox/migrator/migrations/frozenschema/v73" diff --git a/migrator/migrations/n_05_to_n_06_postgres_active_components/postgres/postgres_plugin.go b/migrator/migrations/n_05_to_n_06_postgres_active_components/postgres/postgres_plugin.go index 931441ee07504..494850ebb17a0 100644 --- a/migrator/migrations/n_05_to_n_06_postgres_active_components/postgres/postgres_plugin.go +++ b/migrator/migrations/n_05_to_n_06_postgres_active_components/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_06_to_n_07_postgres_alerts/postgres/postgres_plugin.go b/migrator/migrations/n_06_to_n_07_postgres_alerts/postgres/postgres_plugin.go index aefd95e31f2ae..6bc6ccf14b5bd 100644 --- a/migrator/migrations/n_06_to_n_07_postgres_alerts/postgres/postgres_plugin.go +++ b/migrator/migrations/n_06_to_n_07_postgres_alerts/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_07_to_n_08_postgres_api_tokens/postgres/postgres_plugin.go b/migrator/migrations/n_07_to_n_08_postgres_api_tokens/postgres/postgres_plugin.go index 9dacdc02462af..4ef4fbeda1062 100644 --- a/migrator/migrations/n_07_to_n_08_postgres_api_tokens/postgres/postgres_plugin.go +++ b/migrator/migrations/n_07_to_n_08_postgres_api_tokens/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_08_to_n_09_postgres_auth_providers/postgres/postgres_plugin.go b/migrator/migrations/n_08_to_n_09_postgres_auth_providers/postgres/postgres_plugin.go index b8a820a1854c2..5d6e6397daee6 100644 --- a/migrator/migrations/n_08_to_n_09_postgres_auth_providers/postgres/postgres_plugin.go +++ b/migrator/migrations/n_08_to_n_09_postgres_auth_providers/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_09_to_n_10_postgres_cluster_cves/postgres/postgres_plugin.go b/migrator/migrations/n_09_to_n_10_postgres_cluster_cves/postgres/postgres_plugin.go index 686e2c09b9ebc..26c3e176dde10 100644 --- a/migrator/migrations/n_09_to_n_10_postgres_cluster_cves/postgres/postgres_plugin.go +++ b/migrator/migrations/n_09_to_n_10_postgres_cluster_cves/postgres/postgres_plugin.go @@ -7,7 +7,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_10_to_n_11_postgres_cluster_health_statuses/postgres/postgres_plugin.go b/migrator/migrations/n_10_to_n_11_postgres_cluster_health_statuses/postgres/postgres_plugin.go index 45aeb77999eb8..e2e66d5d109bb 100644 --- a/migrator/migrations/n_10_to_n_11_postgres_cluster_health_statuses/postgres/postgres_plugin.go +++ b/migrator/migrations/n_10_to_n_11_postgres_cluster_health_statuses/postgres/postgres_plugin.go @@ -7,7 +7,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_11_to_n_12_postgres_cluster_init_bundles/postgres/postgres_plugin.go b/migrator/migrations/n_11_to_n_12_postgres_cluster_init_bundles/postgres/postgres_plugin.go index 2b5b02b0d16da..9a7254aaec419 100644 --- a/migrator/migrations/n_11_to_n_12_postgres_cluster_init_bundles/postgres/postgres_plugin.go +++ b/migrator/migrations/n_11_to_n_12_postgres_cluster_init_bundles/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_12_to_n_13_postgres_compliance_domains/postgres/postgres_plugin.go b/migrator/migrations/n_12_to_n_13_postgres_compliance_domains/postgres/postgres_plugin.go index b92ac03de9312..d94fe311b0718 100644 --- a/migrator/migrations/n_12_to_n_13_postgres_compliance_domains/postgres/postgres_plugin.go +++ b/migrator/migrations/n_12_to_n_13_postgres_compliance_domains/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_13_to_n_14_postgres_compliance_operator_check_results/postgres/postgres_plugin.go b/migrator/migrations/n_13_to_n_14_postgres_compliance_operator_check_results/postgres/postgres_plugin.go index 7f1d7cb7f9ecf..ce5f17f2fe265 100644 --- a/migrator/migrations/n_13_to_n_14_postgres_compliance_operator_check_results/postgres/postgres_plugin.go +++ b/migrator/migrations/n_13_to_n_14_postgres_compliance_operator_check_results/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_14_to_n_15_postgres_compliance_operator_profiles/postgres/postgres_plugin.go b/migrator/migrations/n_14_to_n_15_postgres_compliance_operator_profiles/postgres/postgres_plugin.go index cc324d1cccdce..9306a784db734 100644 --- a/migrator/migrations/n_14_to_n_15_postgres_compliance_operator_profiles/postgres/postgres_plugin.go +++ b/migrator/migrations/n_14_to_n_15_postgres_compliance_operator_profiles/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_15_to_n_16_postgres_compliance_operator_rules/postgres/postgres_plugin.go b/migrator/migrations/n_15_to_n_16_postgres_compliance_operator_rules/postgres/postgres_plugin.go index 45b09b896dd1b..91b82b4bc336f 100644 --- a/migrator/migrations/n_15_to_n_16_postgres_compliance_operator_rules/postgres/postgres_plugin.go +++ b/migrator/migrations/n_15_to_n_16_postgres_compliance_operator_rules/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_16_to_n_17_postgres_compliance_operator_scan_setting_bindings/postgres/postgres_plugin.go b/migrator/migrations/n_16_to_n_17_postgres_compliance_operator_scan_setting_bindings/postgres/postgres_plugin.go index 42a7a440408f7..518bb3a623196 100644 --- a/migrator/migrations/n_16_to_n_17_postgres_compliance_operator_scan_setting_bindings/postgres/postgres_plugin.go +++ b/migrator/migrations/n_16_to_n_17_postgres_compliance_operator_scan_setting_bindings/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_17_to_n_18_postgres_compliance_operator_scans/postgres/postgres_plugin.go b/migrator/migrations/n_17_to_n_18_postgres_compliance_operator_scans/postgres/postgres_plugin.go index 4e75911851863..1de042a01dc4d 100644 --- a/migrator/migrations/n_17_to_n_18_postgres_compliance_operator_scans/postgres/postgres_plugin.go +++ b/migrator/migrations/n_17_to_n_18_postgres_compliance_operator_scans/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_18_to_n_19_postgres_compliance_run_metadata/postgres/postgres_plugin.go b/migrator/migrations/n_18_to_n_19_postgres_compliance_run_metadata/postgres/postgres_plugin.go index 7c66edd43cf4b..30b783f95644c 100644 --- a/migrator/migrations/n_18_to_n_19_postgres_compliance_run_metadata/postgres/postgres_plugin.go +++ b/migrator/migrations/n_18_to_n_19_postgres_compliance_run_metadata/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_19_to_n_20_postgres_compliance_run_results/postgres/postgres_plugin.go b/migrator/migrations/n_19_to_n_20_postgres_compliance_run_results/postgres/postgres_plugin.go index cd72d663c9aba..e748132aa875b 100644 --- a/migrator/migrations/n_19_to_n_20_postgres_compliance_run_results/postgres/postgres_plugin.go +++ b/migrator/migrations/n_19_to_n_20_postgres_compliance_run_results/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_20_to_n_21_postgres_compliance_strings/postgres/postgres_plugin.go b/migrator/migrations/n_20_to_n_21_postgres_compliance_strings/postgres/postgres_plugin.go index e81ca8fe51367..70b459f153cd7 100644 --- a/migrator/migrations/n_20_to_n_21_postgres_compliance_strings/postgres/postgres_plugin.go +++ b/migrator/migrations/n_20_to_n_21_postgres_compliance_strings/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_22_to_n_23_postgres_external_backups/postgres/postgres_plugin.go b/migrator/migrations/n_22_to_n_23_postgres_external_backups/postgres/postgres_plugin.go index 4c3568b1c8be7..1fc54562d6cff 100644 --- a/migrator/migrations/n_22_to_n_23_postgres_external_backups/postgres/postgres_plugin.go +++ b/migrator/migrations/n_22_to_n_23_postgres_external_backups/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_23_to_n_24_postgres_image_integrations/postgres/postgres_plugin.go b/migrator/migrations/n_23_to_n_24_postgres_image_integrations/postgres/postgres_plugin.go index a15269bfd84fd..dfe0cfdcfb73c 100644 --- a/migrator/migrations/n_23_to_n_24_postgres_image_integrations/postgres/postgres_plugin.go +++ b/migrator/migrations/n_23_to_n_24_postgres_image_integrations/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_25_to_n_26_postgres_integration_healths/postgres/postgres_plugin.go b/migrator/migrations/n_25_to_n_26_postgres_integration_healths/postgres/postgres_plugin.go index 6303ab6804b36..2fedd098cab1f 100644 --- a/migrator/migrations/n_25_to_n_26_postgres_integration_healths/postgres/postgres_plugin.go +++ b/migrator/migrations/n_25_to_n_26_postgres_integration_healths/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_26_to_n_27_postgres_k8s_roles/postgres/postgres_plugin.go b/migrator/migrations/n_26_to_n_27_postgres_k8s_roles/postgres/postgres_plugin.go index 1577d7fb78f0c..40b2b2fc3173d 100644 --- a/migrator/migrations/n_26_to_n_27_postgres_k8s_roles/postgres/postgres_plugin.go +++ b/migrator/migrations/n_26_to_n_27_postgres_k8s_roles/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_27_to_n_28_postgres_log_imbues/postgres/postgres_plugin.go b/migrator/migrations/n_27_to_n_28_postgres_log_imbues/postgres/postgres_plugin.go index 82120b63c84e1..f7cf1df4e4b74 100644 --- a/migrator/migrations/n_27_to_n_28_postgres_log_imbues/postgres/postgres_plugin.go +++ b/migrator/migrations/n_27_to_n_28_postgres_log_imbues/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_28_to_n_29_postgres_network_baselines/postgres/postgres_plugin.go b/migrator/migrations/n_28_to_n_29_postgres_network_baselines/postgres/postgres_plugin.go index 9e2ce5efeeec8..c1e99f0c0d2c2 100644 --- a/migrator/migrations/n_28_to_n_29_postgres_network_baselines/postgres/postgres_plugin.go +++ b/migrator/migrations/n_28_to_n_29_postgres_network_baselines/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_29_to_n_30_postgres_network_entities/postgres/postgres_plugin.go b/migrator/migrations/n_29_to_n_30_postgres_network_entities/postgres/postgres_plugin.go index f6dc82cb9ca3c..2d8e4e05bb5e3 100644 --- a/migrator/migrations/n_29_to_n_30_postgres_network_entities/postgres/postgres_plugin.go +++ b/migrator/migrations/n_29_to_n_30_postgres_network_entities/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_30_to_n_31_postgres_network_flows/postgres/flow_impl.go b/migrator/migrations/n_30_to_n_31_postgres_network_flows/postgres/flow_impl.go index e3a0cd7d06120..51bd90f346a63 100644 --- a/migrator/migrations/n_30_to_n_31_postgres_network_flows/postgres/flow_impl.go +++ b/migrator/migrations/n_30_to_n_31_postgres_network_flows/postgres/flow_impl.go @@ -9,7 +9,7 @@ import ( "time" "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/generated/storage" "github.com/stackrox/rox/migrator/migrations/n_30_to_n_31_postgres_network_flows/store" "github.com/stackrox/rox/pkg/logging" diff --git a/migrator/migrations/n_31_to_n_32_postgres_network_graph_configs/postgres/postgres_plugin.go b/migrator/migrations/n_31_to_n_32_postgres_network_graph_configs/postgres/postgres_plugin.go index 9b4883990b382..092db00db4d46 100644 --- a/migrator/migrations/n_31_to_n_32_postgres_network_graph_configs/postgres/postgres_plugin.go +++ b/migrator/migrations/n_31_to_n_32_postgres_network_graph_configs/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_32_to_n_33_postgres_networkpolicies/postgres/postgres_plugin.go b/migrator/migrations/n_32_to_n_33_postgres_networkpolicies/postgres/postgres_plugin.go index 5e1e79bcaceca..807b26d51780e 100644 --- a/migrator/migrations/n_32_to_n_33_postgres_networkpolicies/postgres/postgres_plugin.go +++ b/migrator/migrations/n_32_to_n_33_postgres_networkpolicies/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_33_to_n_34_postgres_networkpoliciesundodeployments/postgres/postgres_plugin.go b/migrator/migrations/n_33_to_n_34_postgres_networkpoliciesundodeployments/postgres/postgres_plugin.go index 9a8c8b277e879..1c5ce9f79ee47 100644 --- a/migrator/migrations/n_33_to_n_34_postgres_networkpoliciesundodeployments/postgres/postgres_plugin.go +++ b/migrator/migrations/n_33_to_n_34_postgres_networkpoliciesundodeployments/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_34_to_n_35_postgres_networkpolicyapplicationundorecords/postgres/postgres_plugin.go b/migrator/migrations/n_34_to_n_35_postgres_networkpolicyapplicationundorecords/postgres/postgres_plugin.go index 398ff3b71f694..8f49b02b2d8ec 100644 --- a/migrator/migrations/n_34_to_n_35_postgres_networkpolicyapplicationundorecords/postgres/postgres_plugin.go +++ b/migrator/migrations/n_34_to_n_35_postgres_networkpolicyapplicationundorecords/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_35_to_n_36_postgres_nodes/postgres/store_impl.go b/migrator/migrations/n_35_to_n_36_postgres_nodes/postgres/store_impl.go index 4a40fde7a2bb2..5259b4234ee5b 100644 --- a/migrator/migrations/n_35_to_n_36_postgres_nodes/postgres/store_impl.go +++ b/migrator/migrations/n_35_to_n_36_postgres_nodes/postgres/store_impl.go @@ -8,7 +8,7 @@ import ( "github.com/gogo/protobuf/proto" protoTypes "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_36_to_n_37_postgres_notifiers/postgres/postgres_plugin.go b/migrator/migrations/n_36_to_n_37_postgres_notifiers/postgres/postgres_plugin.go index 41432bc162859..91574fe5df98a 100644 --- a/migrator/migrations/n_36_to_n_37_postgres_notifiers/postgres/postgres_plugin.go +++ b/migrator/migrations/n_36_to_n_37_postgres_notifiers/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_38_to_n_39_postgres_pods/postgres/postgres_plugin.go b/migrator/migrations/n_38_to_n_39_postgres_pods/postgres/postgres_plugin.go index ec5a70d695537..7269a1bdba734 100644 --- a/migrator/migrations/n_38_to_n_39_postgres_pods/postgres/postgres_plugin.go +++ b/migrator/migrations/n_38_to_n_39_postgres_pods/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_39_to_n_40_postgres_policies/postgres/postgres_plugin.go b/migrator/migrations/n_39_to_n_40_postgres_policies/postgres/postgres_plugin.go index 08959fa216f73..01193d3014238 100644 --- a/migrator/migrations/n_39_to_n_40_postgres_policies/postgres/postgres_plugin.go +++ b/migrator/migrations/n_39_to_n_40_postgres_policies/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_40_to_n_41_postgres_process_baseline_results/postgres/postgres_plugin.go b/migrator/migrations/n_40_to_n_41_postgres_process_baseline_results/postgres/postgres_plugin.go index 25ec512ca03d1..b6d7c98997819 100644 --- a/migrator/migrations/n_40_to_n_41_postgres_process_baseline_results/postgres/postgres_plugin.go +++ b/migrator/migrations/n_40_to_n_41_postgres_process_baseline_results/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_41_to_n_42_postgres_process_baselines/postgres/postgres_plugin.go b/migrator/migrations/n_41_to_n_42_postgres_process_baselines/postgres/postgres_plugin.go index c6fff85141a1b..f2920464a1ba3 100644 --- a/migrator/migrations/n_41_to_n_42_postgres_process_baselines/postgres/postgres_plugin.go +++ b/migrator/migrations/n_41_to_n_42_postgres_process_baselines/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_42_to_n_43_postgres_process_indicators/postgres/postgres_plugin.go b/migrator/migrations/n_42_to_n_43_postgres_process_indicators/postgres/postgres_plugin.go index 70b9e636df99b..e068151a15484 100644 --- a/migrator/migrations/n_42_to_n_43_postgres_process_indicators/postgres/postgres_plugin.go +++ b/migrator/migrations/n_42_to_n_43_postgres_process_indicators/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_43_to_n_44_postgres_report_configurations/postgres/postgres_plugin.go b/migrator/migrations/n_43_to_n_44_postgres_report_configurations/postgres/postgres_plugin.go index e1c0997e0193a..28bd884aff3d9 100644 --- a/migrator/migrations/n_43_to_n_44_postgres_report_configurations/postgres/postgres_plugin.go +++ b/migrator/migrations/n_43_to_n_44_postgres_report_configurations/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_44_to_n_45_postgres_risks/postgres/postgres_plugin.go b/migrator/migrations/n_44_to_n_45_postgres_risks/postgres/postgres_plugin.go index 719b7ad8d11dd..cdb4fa2b96ae9 100644 --- a/migrator/migrations/n_44_to_n_45_postgres_risks/postgres/postgres_plugin.go +++ b/migrator/migrations/n_44_to_n_45_postgres_risks/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_45_to_n_46_postgres_role_bindings/postgres/postgres_plugin.go b/migrator/migrations/n_45_to_n_46_postgres_role_bindings/postgres/postgres_plugin.go index a647afdebbadc..07f37adaa2d3b 100644 --- a/migrator/migrations/n_45_to_n_46_postgres_role_bindings/postgres/postgres_plugin.go +++ b/migrator/migrations/n_45_to_n_46_postgres_role_bindings/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_47_to_n_48_postgres_secrets/postgres/postgres_plugin.go b/migrator/migrations/n_47_to_n_48_postgres_secrets/postgres/postgres_plugin.go index 2902da11b00c7..1e0cf2246fa68 100644 --- a/migrator/migrations/n_47_to_n_48_postgres_secrets/postgres/postgres_plugin.go +++ b/migrator/migrations/n_47_to_n_48_postgres_secrets/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_49_to_n_50_postgres_service_accounts/postgres/postgres_plugin.go b/migrator/migrations/n_49_to_n_50_postgres_service_accounts/postgres/postgres_plugin.go index c466695972abd..da7dff02f4440 100644 --- a/migrator/migrations/n_49_to_n_50_postgres_service_accounts/postgres/postgres_plugin.go +++ b/migrator/migrations/n_49_to_n_50_postgres_service_accounts/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_50_to_n_51_postgres_service_identities/postgres/postgres_plugin.go b/migrator/migrations/n_50_to_n_51_postgres_service_identities/postgres/postgres_plugin.go index 97cbf3ca15c67..fe5d6e18627f6 100644 --- a/migrator/migrations/n_50_to_n_51_postgres_service_identities/postgres/postgres_plugin.go +++ b/migrator/migrations/n_50_to_n_51_postgres_service_identities/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_51_to_n_52_postgres_signature_integrations/postgres/postgres_plugin.go b/migrator/migrations/n_51_to_n_52_postgres_signature_integrations/postgres/postgres_plugin.go index a69b0a2f01746..7674337a6b283 100644 --- a/migrator/migrations/n_51_to_n_52_postgres_signature_integrations/postgres/postgres_plugin.go +++ b/migrator/migrations/n_51_to_n_52_postgres_signature_integrations/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgrespermissionsets/postgres_plugin.go b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgrespermissionsets/postgres_plugin.go index ccb0dbd732adf..c70105243f9a0 100644 --- a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgrespermissionsets/postgres_plugin.go +++ b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgrespermissionsets/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresreportconfigurations/postgres_plugin.go b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresreportconfigurations/postgres_plugin.go index e1c0997e0193a..28bd884aff3d9 100644 --- a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresreportconfigurations/postgres_plugin.go +++ b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresreportconfigurations/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresroles/postgres_plugin.go b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresroles/postgres_plugin.go index 48e098b7c2079..e13351a28f04e 100644 --- a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresroles/postgres_plugin.go +++ b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgresroles/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgressimpleaccessscopes/postgres_plugin.go b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgressimpleaccessscopes/postgres_plugin.go index 8cad4827a8f29..b87304941f704 100644 --- a/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgressimpleaccessscopes/postgres_plugin.go +++ b/migrator/migrations/n_52_to_n_53_postgres_simple_access_scopes/postgressimpleaccessscopes/postgres_plugin.go @@ -4,7 +4,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_53_to_n_54_postgres_vulnerability_requests/postgres/postgres_plugin.go b/migrator/migrations/n_53_to_n_54_postgres_vulnerability_requests/postgres/postgres_plugin.go index 89b8251fb3abb..b8f2c9bf75e3f 100644 --- a/migrator/migrations/n_53_to_n_54_postgres_vulnerability_requests/postgres/postgres_plugin.go +++ b/migrator/migrations/n_53_to_n_54_postgres_vulnerability_requests/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_54_to_n_55_postgres_watched_images/postgres/postgres_plugin.go b/migrator/migrations/n_54_to_n_55_postgres_watched_images/postgres/postgres_plugin.go index 88f1c4fe92bd0..593d7a02b83d2 100644 --- a/migrator/migrations/n_54_to_n_55_postgres_watched_images/postgres/postgres_plugin.go +++ b/migrator/migrations/n_54_to_n_55_postgres_watched_images/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_55_to_n_56_postgres_policy_categories/postgres/postgres_plugin.go b/migrator/migrations/n_55_to_n_56_postgres_policy_categories/postgres/postgres_plugin.go index 50e19ad7e5504..d143dbe7a86ab 100644 --- a/migrator/migrations/n_55_to_n_56_postgres_policy_categories/postgres/postgres_plugin.go +++ b/migrator/migrations/n_55_to_n_56_postgres_policy_categories/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/n_56_to_n_57_postgres_groups/postgres/postgres_plugin.go b/migrator/migrations/n_56_to_n_57_postgres_groups/postgres/postgres_plugin.go index c2baa7cabe554..0b6f2f12503a3 100644 --- a/migrator/migrations/n_56_to_n_57_postgres_groups/postgres/postgres_plugin.go +++ b/migrator/migrations/n_56_to_n_57_postgres_groups/postgres/postgres_plugin.go @@ -6,7 +6,7 @@ import ( "context" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/migrator/migrations/policymigrationhelper/policypostgresstorefortest/postgres_plugin.go b/migrator/migrations/policymigrationhelper/policypostgresstorefortest/postgres_plugin.go index 28809927147f8..4cee762ba31b5 100644 --- a/migrator/migrations/policymigrationhelper/policypostgresstorefortest/postgres_plugin.go +++ b/migrator/migrations/policymigrationhelper/policypostgresstorefortest/postgres_plugin.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/pkg/mocks/github.com/jackc/pgx/v4/mocks/mocks.go b/pkg/mocks/github.com/jackc/pgx/v5/mocks/mocks.go similarity index 87% rename from pkg/mocks/github.com/jackc/pgx/v4/mocks/mocks.go rename to pkg/mocks/github.com/jackc/pgx/v5/mocks/mocks.go index 93de045b672f4..ee482a33c206c 100644 --- a/pkg/mocks/github.com/jackc/pgx/v4/mocks/mocks.go +++ b/pkg/mocks/github.com/jackc/pgx/v5/mocks/mocks.go @@ -1,5 +1,5 @@ // Code generated by MockGen. DO NOT EDIT. -// Source: github.com/jackc/pgx/v4 (interfaces: Tx,Row,Rows,BatchResults) +// Source: github.com/jackc/pgx/v5 (interfaces: Tx,Row,Rows,BatchResults) // Package mocks is a generated GoMock package. package mocks @@ -8,9 +8,8 @@ import ( context "context" reflect "reflect" - pgconn "github.com/jackc/pgconn" - pgproto3 "github.com/jackc/pgproto3/v2" - pgx "github.com/jackc/pgx/v4" + pgx "github.com/jackc/pgx/v5" + pgconn "github.com/jackc/pgx/v5/pgconn" gomock "go.uber.org/mock/gomock" ) @@ -52,20 +51,6 @@ func (mr *MockTxMockRecorder) Begin(arg0 interface{}) *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Begin", reflect.TypeOf((*MockTx)(nil).Begin), arg0) } -// BeginFunc mocks base method. -func (m *MockTx) BeginFunc(arg0 context.Context, arg1 func(pgx.Tx) error) error { - m.ctrl.T.Helper() - ret := m.ctrl.Call(m, "BeginFunc", arg0, arg1) - ret0, _ := ret[0].(error) - return ret0 -} - -// BeginFunc indicates an expected call of BeginFunc. -func (mr *MockTxMockRecorder) BeginFunc(arg0, arg1 interface{}) *gomock.Call { - mr.mock.ctrl.T.Helper() - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BeginFunc", reflect.TypeOf((*MockTx)(nil).BeginFunc), arg0, arg1) -} - // Commit mocks base method. func (m *MockTx) Commit(arg0 context.Context) error { m.ctrl.T.Helper() @@ -178,21 +163,6 @@ func (mr *MockTxMockRecorder) Query(arg0, arg1 interface{}, arg2 ...interface{}) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockTx)(nil).Query), varargs...) } -// QueryFunc mocks base method. -func (m *MockTx) QueryFunc(arg0 context.Context, arg1 string, arg2, arg3 []interface{}, arg4 func(pgx.QueryFuncRow) error) (pgconn.CommandTag, error) { - m.ctrl.T.Helper() - ret := m.ctrl.Call(m, "QueryFunc", arg0, arg1, arg2, arg3, arg4) - ret0, _ := ret[0].(pgconn.CommandTag) - ret1, _ := ret[1].(error) - return ret0, ret1 -} - -// QueryFunc indicates an expected call of QueryFunc. -func (mr *MockTxMockRecorder) QueryFunc(arg0, arg1, arg2, arg3, arg4 interface{}) *gomock.Call { - mr.mock.ctrl.T.Helper() - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryFunc", reflect.TypeOf((*MockTx)(nil).QueryFunc), arg0, arg1, arg2, arg3, arg4) -} - // QueryRow mocks base method. func (m *MockTx) QueryRow(arg0 context.Context, arg1 string, arg2 ...interface{}) pgx.Row { m.ctrl.T.Helper() @@ -330,6 +300,20 @@ func (mr *MockRowsMockRecorder) CommandTag() *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CommandTag", reflect.TypeOf((*MockRows)(nil).CommandTag)) } +// Conn mocks base method. +func (m *MockRows) Conn() *pgx.Conn { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "Conn") + ret0, _ := ret[0].(*pgx.Conn) + return ret0 +} + +// Conn indicates an expected call of Conn. +func (mr *MockRowsMockRecorder) Conn() *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Conn", reflect.TypeOf((*MockRows)(nil).Conn)) +} + // Err mocks base method. func (m *MockRows) Err() error { m.ctrl.T.Helper() @@ -345,10 +329,10 @@ func (mr *MockRowsMockRecorder) Err() *gomock.Call { } // FieldDescriptions mocks base method. -func (m *MockRows) FieldDescriptions() []pgproto3.FieldDescription { +func (m *MockRows) FieldDescriptions() []pgconn.FieldDescription { m.ctrl.T.Helper() ret := m.ctrl.Call(m, "FieldDescriptions") - ret0, _ := ret[0].([]pgproto3.FieldDescription) + ret0, _ := ret[0].([]pgconn.FieldDescription) return ret0 } @@ -486,21 +470,6 @@ func (mr *MockBatchResultsMockRecorder) Query() *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockBatchResults)(nil).Query)) } -// QueryFunc mocks base method. -func (m *MockBatchResults) QueryFunc(arg0 []interface{}, arg1 func(pgx.QueryFuncRow) error) (pgconn.CommandTag, error) { - m.ctrl.T.Helper() - ret := m.ctrl.Call(m, "QueryFunc", arg0, arg1) - ret0, _ := ret[0].(pgconn.CommandTag) - ret1, _ := ret[1].(error) - return ret0, ret1 -} - -// QueryFunc indicates an expected call of QueryFunc. -func (mr *MockBatchResultsMockRecorder) QueryFunc(arg0, arg1 interface{}) *gomock.Call { - mr.mock.ctrl.T.Helper() - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryFunc", reflect.TypeOf((*MockBatchResults)(nil).QueryFunc), arg0, arg1) -} - // QueryRow mocks base method. func (m *MockBatchResults) QueryRow() pgx.Row { m.ctrl.T.Helper() diff --git a/pkg/mocks/mocks.go b/pkg/mocks/mocks.go index c1b25f799f1f7..afd4166666ecc 100644 --- a/pkg/mocks/mocks.go +++ b/pkg/mocks/mocks.go @@ -2,4 +2,4 @@ package mocks //go:generate mockgen-wrapper SecurityHubAPI github.com/aws/aws-sdk-go/service/securityhub/securityhubiface -//go:generate mockgen-wrapper Tx,Row,Rows,BatchResults github.com/jackc/pgx/v4 +//go:generate mockgen-wrapper Tx,Row,Rows,BatchResults github.com/jackc/pgx/v5 diff --git a/pkg/postgres/batch.go b/pkg/postgres/batch.go index 3b0a601a300c4..c9bf890bb8ed6 100644 --- a/pkg/postgres/batch.go +++ b/pkg/postgres/batch.go @@ -3,8 +3,8 @@ package postgres import ( "context" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" ) // BatchResults wraps pgx.BatchResults @@ -29,7 +29,7 @@ func (b *BatchResults) Exec() (pgconn.CommandTag, error) { ct, err := b.BatchResults.Exec() if err != nil { incQueryErrors("batch", err) - return nil, toErrox(err) + return pgconn.CommandTag{}, toErrox(err) } return ct, err } diff --git a/pkg/postgres/conn.go b/pkg/postgres/conn.go index a307bbe245683..d542789bc09a7 100644 --- a/pkg/postgres/conn.go +++ b/pkg/postgres/conn.go @@ -3,8 +3,8 @@ package postgres import ( "context" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" "github.com/stackrox/rox/pkg/contextutil" ) @@ -56,7 +56,7 @@ func (c *Conn) Exec(ctx context.Context, sql string, args ...interface{}) (ct pg } if err != nil { incQueryErrors(sql, err) - return nil, toErrox(err) + return pgconn.CommandTag{}, toErrox(err) } return ct, nil } diff --git a/pkg/postgres/error.go b/pkg/postgres/error.go index aa085db9347b7..735cf41bf38fd 100644 --- a/pkg/postgres/error.go +++ b/pkg/postgres/error.go @@ -1,7 +1,7 @@ package postgres import ( - "github.com/jackc/pgconn" + "github.com/jackc/pgx/v5/pgconn" "github.com/pkg/errors" "github.com/stackrox/rox/pkg/errox" ) diff --git a/pkg/postgres/metrics.go b/pkg/postgres/metrics.go index 0d82eec82a6a6..3c255a8dd5e41 100644 --- a/pkg/postgres/metrics.go +++ b/pkg/postgres/metrics.go @@ -1,7 +1,7 @@ package postgres import ( - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/prometheus/client_golang/prometheus" "github.com/stackrox/rox/pkg/metrics" ) diff --git a/pkg/postgres/mocks/pgxpool_conn.go b/pkg/postgres/mocks/pgxpool_conn.go index f6f8c1729c0a4..391870457d9eb 100644 --- a/pkg/postgres/mocks/pgxpool_conn.go +++ b/pkg/postgres/mocks/pgxpool_conn.go @@ -8,8 +8,8 @@ import ( context "context" reflect "reflect" - pgconn "github.com/jackc/pgconn" - pgx "github.com/jackc/pgx/v4" + pgx "github.com/jackc/pgx/v5" + pgconn "github.com/jackc/pgx/v5/pgconn" gomock "go.uber.org/mock/gomock" ) diff --git a/pkg/postgres/mocks/pool.go b/pkg/postgres/mocks/pool.go index 13af6a825eafb..69a15c25cce4d 100644 --- a/pkg/postgres/mocks/pool.go +++ b/pkg/postgres/mocks/pool.go @@ -8,8 +8,8 @@ import ( context "context" reflect "reflect" - pgconn "github.com/jackc/pgconn" - pgx "github.com/jackc/pgx/v4" + pgx "github.com/jackc/pgx/v5" + pgconn "github.com/jackc/pgx/v5/pgconn" postgres "github.com/stackrox/rox/pkg/postgres" gomock "go.uber.org/mock/gomock" ) diff --git a/pkg/postgres/pgutils/error.go b/pkg/postgres/pgutils/error.go index b6fa376ad26a2..4a624ed50c804 100644 --- a/pkg/postgres/pgutils/error.go +++ b/pkg/postgres/pgutils/error.go @@ -5,8 +5,8 @@ import ( "net" "syscall" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" "github.com/pkg/errors" "github.com/stackrox/rox/pkg/errorhelpers" "github.com/stackrox/rox/pkg/set" diff --git a/pkg/postgres/pgutils/retry.go b/pkg/postgres/pgutils/retry.go index cf66f21d4e871..b4b929f60dd63 100644 --- a/pkg/postgres/pgutils/retry.go +++ b/pkg/postgres/pgutils/retry.go @@ -3,7 +3,7 @@ package pgutils import ( "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" ) const ( diff --git a/pkg/postgres/pgutils/scan.go b/pkg/postgres/pgutils/scan.go index bbbf52f497f9b..58085a6a08dab 100644 --- a/pkg/postgres/pgutils/scan.go +++ b/pkg/postgres/pgutils/scan.go @@ -2,7 +2,7 @@ package pgutils import ( "github.com/gogo/protobuf/proto" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" ) type unmarshaler[T any] interface { diff --git a/pkg/postgres/pgutils/utils.go b/pkg/postgres/pgutils/utils.go index 231e1d7f98f34..34e203b2f0e59 100644 --- a/pkg/postgres/pgutils/utils.go +++ b/pkg/postgres/pgutils/utils.go @@ -8,7 +8,7 @@ import ( "time" "github.com/gogo/protobuf/types" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/pkg/logging" "github.com/stackrox/rox/pkg/postgres" diff --git a/pkg/postgres/pgxpool_conn.go b/pkg/postgres/pgxpool_conn.go index f9c9ea316e158..43137b80f52cb 100644 --- a/pkg/postgres/pgxpool_conn.go +++ b/pkg/postgres/pgxpool_conn.go @@ -3,8 +3,8 @@ package postgres import ( "context" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" ) // PgxPoolConn is an interface to interact with pgxpool.Conn diff --git a/pkg/postgres/pool.go b/pkg/postgres/pool.go index 8ef3c97f28368..d6d23f91c3ec0 100644 --- a/pkg/postgres/pool.go +++ b/pkg/postgres/pool.go @@ -3,8 +3,8 @@ package postgres import ( "context" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" ) // DB is an interface to interact with database. diff --git a/pkg/postgres/pool_impl.go b/pkg/postgres/pool_impl.go index 91a962954a361..f1de3ab2ed265 100644 --- a/pkg/postgres/pool_impl.go +++ b/pkg/postgres/pool_impl.go @@ -4,9 +4,9 @@ import ( "context" "time" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" - "github.com/jackc/pgx/v4/pgxpool" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" + "github.com/jackc/pgx/v5/pgxpool" "github.com/stackrox/rox/pkg/contextutil" ) @@ -15,7 +15,7 @@ func New(ctx context.Context, config *Config) (*db, error) { ctx, cancel := contextutil.ContextWithTimeoutIfNotExists(ctx, 10*time.Second) defer cancel() - pool, err := pgxpool.ConnectConfig(ctx, config.Config) + pool, err := pgxpool.NewWithConfig(ctx, config.Config) if err != nil { incQueryErrors("connect", err) return nil, err @@ -39,7 +39,7 @@ func Connect(ctx context.Context, sourceWithDatabase string) (*db, error) { ctx, cancel := contextutil.ContextWithTimeoutIfNotExists(ctx, 10*time.Second) defer cancel() - pool, err := pgxpool.Connect(ctx, sourceWithDatabase) + pool, err := pgxpool.New(ctx, sourceWithDatabase) if err != nil { incQueryErrors("connect", err) return nil, err @@ -91,7 +91,7 @@ func (d *db) Exec(ctx context.Context, sql string, args ...interface{}) (pgconn. } if err != nil { incQueryErrors(sql, err) - return nil, toErrox(err) + return pgconn.CommandTag{}, toErrox(err) } return ct, nil } diff --git a/pkg/postgres/rows.go b/pkg/postgres/rows.go index 67320e2f35e27..a0b765144d6e7 100644 --- a/pkg/postgres/rows.go +++ b/pkg/postgres/rows.go @@ -3,7 +3,7 @@ package postgres import ( "context" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" ) // Row wraps pgx.Row diff --git a/pkg/postgres/schema/schema_test.go b/pkg/postgres/schema/schema_test.go index a8c46d72bcf8b..d83585820e7bc 100644 --- a/pkg/postgres/schema/schema_test.go +++ b/pkg/postgres/schema/schema_test.go @@ -9,7 +9,7 @@ import ( "strings" "testing" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/pkg/postgres" pkgPostgres "github.com/stackrox/rox/pkg/postgres" "github.com/stackrox/rox/pkg/postgres/pgtest/conn" diff --git a/pkg/postgres/tests/conn_test.go b/pkg/postgres/tests/conn_test.go index 1b7b8aabfd859..a3a668631ac4b 100644 --- a/pkg/postgres/tests/conn_test.go +++ b/pkg/postgres/tests/conn_test.go @@ -4,10 +4,10 @@ import ( "context" "testing" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" "github.com/pkg/errors" - pkgmocks "github.com/stackrox/rox/pkg/mocks/github.com/jackc/pgx/v4/mocks" + pkgmocks "github.com/stackrox/rox/pkg/mocks/github.com/jackc/pgx/v5/mocks" "github.com/stackrox/rox/pkg/postgres" "github.com/stackrox/rox/pkg/postgres/mocks" "github.com/stretchr/testify/suite" @@ -77,9 +77,9 @@ func (s *postgresConnTestSuite) TestConnBegin() { } func (s *postgresConnTestSuite) TestConnExec() { - expectedCt := pgconn.CommandTag("signature") + expectedCt := pgconn.NewCommandTag("signature") errFunc := func(ctx context.Context, sql string, args ...interface{}) (pgconn.CommandTag, error) { - return nil, errFake + return pgconn.CommandTag{}, errFake } successFunc := func(ctx context.Context, sql string, args ...interface{}) (pgconn.CommandTag, error) { return expectedCt, nil @@ -103,13 +103,13 @@ func (s *postgresConnTestSuite) TestConnExec() { s.mockTx.EXPECT().Exec(gomock.Any(), "command3").Times(1).DoAndReturn(errFunc) ct, err = s.conn.Exec(ctxWithTx, "command3") s.Equal(errFake, err) - s.Nil(ct) + s.Empty(ct) // Error Handling without Tx s.mockPgxPoolConn.EXPECT().Exec(gomock.Any(), "command4").Times(1).DoAndReturn(errFunc) ct, err = s.conn.Exec(context.Background(), "command4") s.Equal(errFake, err) - s.Nil(ct) + s.Empty(ct) } func (s *postgresConnTestSuite) TestConnQuery() { diff --git a/pkg/postgres/tx.go b/pkg/postgres/tx.go index dc926be8e9a81..92289a01080e9 100644 --- a/pkg/postgres/tx.go +++ b/pkg/postgres/tx.go @@ -4,8 +4,8 @@ import ( "context" "errors" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" "github.com/stackrox/rox/pkg/utils" ) @@ -34,7 +34,7 @@ func (t *Tx) Exec(ctx context.Context, sql string, args ...interface{}) (command ct, err := t.Tx.Exec(ctx, sql, args...) if err != nil { incQueryErrors(sql, err) - return nil, err + return pgconn.CommandTag{}, err } return ct, err } diff --git a/pkg/search/postgres/common.go b/pkg/search/postgres/common.go index 5f9e9a3e7fbf8..5f65a474ab73f 100644 --- a/pkg/search/postgres/common.go +++ b/pkg/search/postgres/common.go @@ -9,8 +9,8 @@ import ( "time" "github.com/gogo/protobuf/proto" - "github.com/jackc/pgconn" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" + "github.com/jackc/pgx/v5/pgconn" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/pkg/contextutil" @@ -638,7 +638,7 @@ func retryableRunSearchRequestForSchema(ctx context.Context, query *query, schem for rows.Next() { if err := rows.Scan(bufferToScanRowInto...); err != nil { - return nil, err + return nil, errors.Wrap(err, "could not scan row") } idParts := make([]string, 0, numPrimaryKeys) diff --git a/pkg/search/postgres/query/array_query.go b/pkg/search/postgres/query/array_query.go index ea89b55d70859..1b7e786677cb7 100644 --- a/pkg/search/postgres/query/array_query.go +++ b/pkg/search/postgres/query/array_query.go @@ -5,7 +5,6 @@ import ( "fmt" "strconv" - "github.com/jackc/pgtype" "github.com/stackrox/rox/pkg/search" ) @@ -22,15 +21,15 @@ func getStringArrayPostTransformFunc(entry *QueryEntry) (func(val interface{}) i return nil, errors.New("no filter func found") } return func(val interface{}) interface{} { - textArray, _ := val.(*pgtype.TextArray) + textArray, _ := val.(*[]string) if textArray == nil { - return (*pgtype.TextArray)(nil) + return (*[]string)(nil) } var out []string - for _, elem := range textArray.Elements { - if elem.Status == pgtype.Present && filterFunc(elem.String) { - out = append(out, elem.String) + for _, elem := range *textArray { + if filterFunc(elem) { + out = append(out, elem) } } return out diff --git a/pkg/search/postgres/query_metadata.go b/pkg/search/postgres/query_metadata.go index 931b002b634af..5571f12fb4101 100644 --- a/pkg/search/postgres/query_metadata.go +++ b/pkg/search/postgres/query_metadata.go @@ -41,7 +41,8 @@ var ( }, postgres.StringArray: { alloc: func() interface{} { - return &pgtype.TextArray{} + out := make([]string, 0) + return &out }, printer: func(val interface{}) []string { // All the work of conversion is done by the post transform func, so diff --git a/pkg/search/postgres/select.go b/pkg/search/postgres/select.go index a8b872e4e826a..c9ecae454706e 100644 --- a/pkg/search/postgres/select.go +++ b/pkg/search/postgres/select.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/georgysavva/scany/pgxscan" + "github.com/georgysavva/scany/v2/pgxscan" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/pkg/postgres" diff --git a/pkg/search/postgres/store.go b/pkg/search/postgres/store.go index a4c55d2f7a5ca..543d549eff340 100644 --- a/pkg/search/postgres/store.go +++ b/pkg/search/postgres/store.go @@ -5,7 +5,7 @@ import ( "time" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/multitest/postgres/store.go b/tools/generate-helpers/pg-table-bindings/multitest/postgres/store.go index c0294e773a9b4..48e2544efcc44 100644 --- a/tools/generate-helpers/pg-table-bindings/multitest/postgres/store.go +++ b/tools/generate-helpers/pg-table-bindings/multitest/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/store.go.tpl b/tools/generate-helpers/pg-table-bindings/store.go.tpl index a82a6930665e9..abf2508eb5704 100644 --- a/tools/generate-helpers/pg-table-bindings/store.go.tpl +++ b/tools/generate-helpers/pg-table-bindings/store.go.tpl @@ -36,7 +36,7 @@ import ( "time" "github.com/hashicorp/go-multierror" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/pkg/errors" "github.com/stackrox/rox/central/metrics" pkgSchema "github.com/stackrox/rox/pkg/postgres/schema" diff --git a/tools/generate-helpers/pg-table-bindings/test/postgres/store.go b/tools/generate-helpers/pg-table-bindings/test/postgres/store.go index 7993a0ed386ea..b5e80dffad5e5 100644 --- a/tools/generate-helpers/pg-table-bindings/test/postgres/store.go +++ b/tools/generate-helpers/pg-table-bindings/test/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1/store.go index cb0b1674bbc79..a46c47c292c76 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1p4/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1p4/store.go index f07a4c671c344..f4fa64a89f7e7 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1p4/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild1p4/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild2/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild2/store.go index 01b14fbd6f8b6..8f16f8ce1465d 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild2/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testchild2/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testg2grandchild1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testg2grandchild1/store.go index a6e3146f65423..38ab41429c4a1 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testg2grandchild1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testg2grandchild1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testg3grandchild1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testg3grandchild1/store.go index ab6115849d1b5..0bcbe11726916 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testg3grandchild1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testg3grandchild1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testggrandchild1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testggrandchild1/store.go index d98c722022dbd..35254c4244347 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testggrandchild1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testggrandchild1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandchild1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandchild1/store.go index 1a00b106c95e6..c8c91c7892128 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandchild1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandchild1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandparent/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandparent/store.go index 112723ceb64aa..9137ceb088a66 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandparent/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testgrandparent/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent1/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent1/store.go index 228e6b1379e5d..5f3ed3ce78c0b 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent1/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent1/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent2/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent2/store.go index 6ccbb0cf62bb0..303b85e9b1524 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent2/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent2/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent3/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent3/store.go index ab5e405cc1281..950aa3d9c233b 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent3/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent3/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent4/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent4/store.go index 0c7d0aa7205ee..6cc890373c4d6 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent4/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testparent4/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testgraphtables/testshortcircuit/store.go b/tools/generate-helpers/pg-table-bindings/testgraphtables/testshortcircuit/store.go index 974f8b233c9a7..d70a4cdc24d99 100644 --- a/tools/generate-helpers/pg-table-bindings/testgraphtables/testshortcircuit/store.go +++ b/tools/generate-helpers/pg-table-bindings/testgraphtables/testshortcircuit/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage" diff --git a/tools/generate-helpers/pg-table-bindings/testuuidkey/postgres/store.go b/tools/generate-helpers/pg-table-bindings/testuuidkey/postgres/store.go index 7cf0debbfbe01..12409b8186011 100644 --- a/tools/generate-helpers/pg-table-bindings/testuuidkey/postgres/store.go +++ b/tools/generate-helpers/pg-table-bindings/testuuidkey/postgres/store.go @@ -6,7 +6,7 @@ import ( "context" "time" - "github.com/jackc/pgx/v4" + "github.com/jackc/pgx/v5" "github.com/stackrox/rox/central/metrics" v1 "github.com/stackrox/rox/generated/api/v1" "github.com/stackrox/rox/generated/storage"