From 3b71a40afdfd43ebdded63628cea1ad9140d2ef8 Mon Sep 17 00:00:00 2001 From: Maria Bazhlekova Date: Tue, 25 Oct 2022 11:24:15 -0500 Subject: [PATCH] chore: upgrade newrelic-client-go to v2 --- cmd/newrelic/command.go | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- internal/apiaccess/command.go | 2 +- internal/apm/command_application.go | 4 ++-- internal/apm/command_deployment.go | 2 +- internal/client/client.go | 6 +++--- internal/config/config.go | 2 +- internal/diagnose/config_validator.go | 6 +++--- internal/edge/command_trace_observer.go | 2 +- internal/entities/command_search.go | 2 +- internal/entities/command_tags.go | 4 ++-- internal/entities/command_tags_test.go | 2 +- internal/install/command.go | 2 +- internal/install/execution/installevents_client.go | 2 +- internal/install/execution/installevents_reporter.go | 4 ++-- .../installevents_reporter_integration_test.go | 4 ++-- .../install/execution/mock_installevents_client.go | 2 +- internal/install/execution/mock_nerdstorage_client.go | 2 +- internal/install/execution/nerdstorage_client.go | 2 +- .../install/execution/nerdstorage_status_reporter.go | 2 +- .../nerdstorage_status_reporter_integration_test.go | 10 +++++----- internal/install/execution/platform_link_generator.go | 2 +- internal/install/execution/recipe_log_forwarder.go | 6 +++--- internal/install/recipe_installer.go | 2 +- internal/install/recipe_installer_test.go | 2 +- internal/install/validation/mock_nrdb_client.go | 2 +- .../validation/polling_recipe_validator_test.go | 2 +- internal/nerdgraph/command_query.go | 2 +- internal/nerdstorage/command_collection.go | 2 +- internal/nerdstorage/command_document.go | 2 +- internal/nrql/command_query.go | 2 +- internal/profile/command.go | 2 +- internal/synthetics/command_monitor.go | 4 ++-- internal/utils/nrdb_client.go | 2 +- internal/utils/retry.go | 2 +- internal/utils/retry_test.go | 2 +- internal/utils/terraform/dashboard.go | 2 +- internal/utils/validation/polling_nrql_validator.go | 2 +- internal/workload/command_workload.go | 6 +++--- 40 files changed, 59 insertions(+), 59 deletions(-) diff --git a/cmd/newrelic/command.go b/cmd/newrelic/command.go index 4c7d94421..9ba7038c0 100644 --- a/cmd/newrelic/command.go +++ b/cmd/newrelic/command.go @@ -12,8 +12,8 @@ import ( "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/split" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/newrelic" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + "github.com/newrelic/newrelic-client-go/v2/newrelic" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) var ( diff --git a/go.mod b/go.mod index dafede3ff..1a4f61bc3 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/jedib0t/go-pretty/v6 v6.4.0 github.com/joshdk/go-junit v0.0.0-20210226021600-6145f504ca0d github.com/mitchellh/go-homedir v1.1.0 - github.com/newrelic/newrelic-client-go v1.1.0 + github.com/newrelic/newrelic-client-go/v2 v2.1.0 github.com/pkg/errors v0.9.1 github.com/shirou/gopsutil/v3 v3.22.2 github.com/sirupsen/logrus v1.9.0 diff --git a/go.sum b/go.sum index a6a5f1897..036aca539 100644 --- a/go.sum +++ b/go.sum @@ -121,8 +121,8 @@ github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrk github.com/mitchellh/hashstructure/v2 v2.0.2 h1:vGKWl0YJqUNxE8d+h8f6NJLcCJrgbhC4NcD46KavDd4= github.com/mitchellh/hashstructure/v2 v2.0.2/go.mod h1:MG3aRVU/N29oo/V/IhBX8GR/zz4kQkprJgF2EVszyDE= github.com/mitchellh/mapstructure v1.4.3 h1:OVowDSCllw/YjdLkam3/sm7wEtOy59d8ndGgCcyj8cs= -github.com/newrelic/newrelic-client-go v1.1.0 h1:aflNjzQ21c+2GwBVh+UbAf9lznkRfCcVABoc5UM4IXw= -github.com/newrelic/newrelic-client-go v1.1.0/go.mod h1:RYMXt7hgYw7nzuXIGd2BH0F1AivgWw7WrBhNBQZEB4k= +github.com/newrelic/newrelic-client-go/v2 v2.1.0 h1:UfrRxEGbDokFLrYWiDjLsIwmY9DlhlKAwJ5PjhsycI0= +github.com/newrelic/newrelic-client-go/v2 v2.1.0/go.mod h1:xDZ6IDWI6fpl7MhTI4Hk75alJLAIfXzOt/rINEolxhQ= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= diff --git a/internal/apiaccess/command.go b/internal/apiaccess/command.go index 604a135cc..9693f353c 100644 --- a/internal/apiaccess/command.go +++ b/internal/apiaccess/command.go @@ -8,7 +8,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/client" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/apiaccess" + "github.com/newrelic/newrelic-client-go/v2/pkg/apiaccess" ) var Command = &cobra.Command{ diff --git a/internal/apm/command_application.go b/internal/apm/command_application.go index 9072824fd..0c4dcdbd6 100644 --- a/internal/apm/command_application.go +++ b/internal/apm/command_application.go @@ -6,8 +6,8 @@ import ( log "github.com/sirupsen/logrus" "github.com/spf13/cobra" - "github.com/newrelic/newrelic-client-go/pkg/common" - "github.com/newrelic/newrelic-client-go/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/common" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" "github.com/newrelic/newrelic-cli/internal/client" configAPI "github.com/newrelic/newrelic-cli/internal/config/api" diff --git a/internal/apm/command_deployment.go b/internal/apm/command_deployment.go index 5d7c7baf9..3636781e0 100644 --- a/internal/apm/command_deployment.go +++ b/internal/apm/command_deployment.go @@ -4,7 +4,7 @@ import ( log "github.com/sirupsen/logrus" "github.com/spf13/cobra" - "github.com/newrelic/newrelic-client-go/pkg/apm" + "github.com/newrelic/newrelic-client-go/v2/pkg/apm" "github.com/newrelic/newrelic-cli/internal/client" "github.com/newrelic/newrelic-cli/internal/output" diff --git a/internal/client/client.go b/internal/client/client.go index 2c7cd180a..7f58cddf4 100644 --- a/internal/client/client.go +++ b/internal/client/client.go @@ -12,9 +12,9 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/install/types" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/newrelic" - "github.com/newrelic/newrelic-client-go/pkg/apiaccess" - clientLogging "github.com/newrelic/newrelic-client-go/pkg/logging" + "github.com/newrelic/newrelic-client-go/v2/newrelic" + "github.com/newrelic/newrelic-client-go/v2/pkg/apiaccess" + clientLogging "github.com/newrelic/newrelic-client-go/v2/pkg/logging" log "github.com/sirupsen/logrus" ) diff --git a/internal/config/config.go b/internal/config/config.go index 10a242e30..a61b050fd 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -7,7 +7,7 @@ import ( "github.com/mitchellh/go-homedir" log "github.com/sirupsen/logrus" - "github.com/newrelic/newrelic-client-go/pkg/region" + "github.com/newrelic/newrelic-client-go/v2/pkg/region" ) const ( diff --git a/internal/diagnose/config_validator.go b/internal/diagnose/config_validator.go index 899bb5919..3b9a372c7 100644 --- a/internal/diagnose/config_validator.go +++ b/internal/diagnose/config_validator.go @@ -13,9 +13,9 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/utils" "github.com/newrelic/newrelic-cli/internal/utils/validation" - "github.com/newrelic/newrelic-client-go/newrelic" - "github.com/newrelic/newrelic-client-go/pkg/apiaccess" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + "github.com/newrelic/newrelic-client-go/v2/newrelic" + "github.com/newrelic/newrelic-client-go/v2/pkg/apiaccess" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) const ( diff --git a/internal/edge/command_trace_observer.go b/internal/edge/command_trace_observer.go index f59b516e3..e8263ec43 100644 --- a/internal/edge/command_trace_observer.go +++ b/internal/edge/command_trace_observer.go @@ -8,7 +8,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/edge" + "github.com/newrelic/newrelic-client-go/v2/pkg/edge" ) var ( diff --git a/internal/entities/command_search.go b/internal/entities/command_search.go index 37628d91a..775be8dc6 100644 --- a/internal/entities/command_search.go +++ b/internal/entities/command_search.go @@ -9,7 +9,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/client" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" ) var cmdEntitySearch = &cobra.Command{ diff --git a/internal/entities/command_tags.go b/internal/entities/command_tags.go index 9d4003e17..de6d96bae 100644 --- a/internal/entities/command_tags.go +++ b/internal/entities/command_tags.go @@ -7,8 +7,8 @@ import ( log "github.com/sirupsen/logrus" "github.com/spf13/cobra" - "github.com/newrelic/newrelic-client-go/pkg/common" - "github.com/newrelic/newrelic-client-go/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/common" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" "github.com/newrelic/newrelic-cli/internal/client" "github.com/newrelic/newrelic-cli/internal/output" diff --git a/internal/entities/command_tags_test.go b/internal/entities/command_tags_test.go index a3552fedd..c023fd801 100644 --- a/internal/entities/command_tags_test.go +++ b/internal/entities/command_tags_test.go @@ -10,7 +10,7 @@ import ( "github.com/spf13/cobra" "github.com/stretchr/testify/assert" - "github.com/newrelic/newrelic-client-go/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" ) func TestEntitiesGetTags(t *testing.T) { diff --git a/internal/install/command.go b/internal/install/command.go index 8cb558fb6..403e5fc97 100644 --- a/internal/install/command.go +++ b/internal/install/command.go @@ -12,7 +12,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/install/types" "github.com/newrelic/newrelic-cli/internal/utils" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) var ( diff --git a/internal/install/execution/installevents_client.go b/internal/install/execution/installevents_client.go index 30f897765..62c4bdef8 100644 --- a/internal/install/execution/installevents_client.go +++ b/internal/install/execution/installevents_client.go @@ -1,6 +1,6 @@ package execution -import "github.com/newrelic/newrelic-client-go/pkg/installevents" +import "github.com/newrelic/newrelic-client-go/v2/pkg/installevents" type InstallEventsClient interface { InstallationCreateRecipeEvent(int, installevents.InstallationRecipeStatus) (*installevents.InstallationRecipeEvent, error) diff --git a/internal/install/execution/installevents_reporter.go b/internal/install/execution/installevents_reporter.go index 126a57abc..f97291e19 100644 --- a/internal/install/execution/installevents_reporter.go +++ b/internal/install/execution/installevents_reporter.go @@ -5,8 +5,8 @@ import ( log "github.com/sirupsen/logrus" - "github.com/newrelic/newrelic-client-go/pkg/common" - "github.com/newrelic/newrelic-client-go/pkg/installevents" + "github.com/newrelic/newrelic-client-go/v2/pkg/common" + "github.com/newrelic/newrelic-client-go/v2/pkg/installevents" configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/install/types" diff --git a/internal/install/execution/installevents_reporter_integration_test.go b/internal/install/execution/installevents_reporter_integration_test.go index 4787714ef..7d71e58e7 100644 --- a/internal/install/execution/installevents_reporter_integration_test.go +++ b/internal/install/execution/installevents_reporter_integration_test.go @@ -11,8 +11,8 @@ import ( "github.com/stretchr/testify/require" "github.com/newrelic/newrelic-cli/internal/install/types" - "github.com/newrelic/newrelic-client-go/newrelic" - "github.com/newrelic/newrelic-client-go/pkg/config" + "github.com/newrelic/newrelic-client-go/v2/newrelic" + "github.com/newrelic/newrelic-client-go/v2/pkg/config" ) func TestInstallEventsReporter_Basic(t *testing.T) { diff --git a/internal/install/execution/mock_installevents_client.go b/internal/install/execution/mock_installevents_client.go index 3556ee64d..28794ca6e 100644 --- a/internal/install/execution/mock_installevents_client.go +++ b/internal/install/execution/mock_installevents_client.go @@ -1,6 +1,6 @@ package execution -import "github.com/newrelic/newrelic-client-go/pkg/installevents" +import "github.com/newrelic/newrelic-client-go/v2/pkg/installevents" type MockInstalleventsClient struct { CreateInstallEventVal *installevents.InstallationRecipeEvent diff --git a/internal/install/execution/mock_nerdstorage_client.go b/internal/install/execution/mock_nerdstorage_client.go index 9bf01e94c..039b547ba 100644 --- a/internal/install/execution/mock_nerdstorage_client.go +++ b/internal/install/execution/mock_nerdstorage_client.go @@ -1,6 +1,6 @@ package execution -import "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" +import "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" type MockNerdStorageClient struct { WriteDocumentWithUserScopeVal interface{} diff --git a/internal/install/execution/nerdstorage_client.go b/internal/install/execution/nerdstorage_client.go index 9cb086a05..90c60bfa8 100644 --- a/internal/install/execution/nerdstorage_client.go +++ b/internal/install/execution/nerdstorage_client.go @@ -1,7 +1,7 @@ package execution import ( - "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" + "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" ) type NerdStorageClient interface { diff --git a/internal/install/execution/nerdstorage_status_reporter.go b/internal/install/execution/nerdstorage_status_reporter.go index ab21dd457..d10d5b5d9 100644 --- a/internal/install/execution/nerdstorage_status_reporter.go +++ b/internal/install/execution/nerdstorage_status_reporter.go @@ -5,7 +5,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/install/types" - "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" + "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" ) const ( diff --git a/internal/install/execution/nerdstorage_status_reporter_integration_test.go b/internal/install/execution/nerdstorage_status_reporter_integration_test.go index 955d0e103..d9debb1fb 100644 --- a/internal/install/execution/nerdstorage_status_reporter_integration_test.go +++ b/internal/install/execution/nerdstorage_status_reporter_integration_test.go @@ -11,11 +11,11 @@ import ( "github.com/stretchr/testify/require" - "github.com/newrelic/newrelic-client-go/newrelic" - "github.com/newrelic/newrelic-client-go/pkg/common" - "github.com/newrelic/newrelic-client-go/pkg/config" - "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" - "github.com/newrelic/newrelic-client-go/pkg/workloads" + "github.com/newrelic/newrelic-client-go/v2/newrelic" + "github.com/newrelic/newrelic-client-go/v2/pkg/common" + "github.com/newrelic/newrelic-client-go/v2/pkg/config" + "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" + "github.com/newrelic/newrelic-client-go/v2/pkg/workloads" "github.com/newrelic/newrelic-cli/internal/install/types" ) diff --git a/internal/install/execution/platform_link_generator.go b/internal/install/execution/platform_link_generator.go index 9e048a8b3..6a2f934d8 100644 --- a/internal/install/execution/platform_link_generator.go +++ b/internal/install/execution/platform_link_generator.go @@ -12,7 +12,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/config" configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/region" + "github.com/newrelic/newrelic-client-go/v2/pkg/region" ) type PlatformLinkGenerator struct { diff --git a/internal/install/execution/recipe_log_forwarder.go b/internal/install/execution/recipe_log_forwarder.go index 46f6fc240..35aa9b294 100644 --- a/internal/install/execution/recipe_log_forwarder.go +++ b/internal/install/execution/recipe_log_forwarder.go @@ -13,9 +13,9 @@ import ( log "github.com/sirupsen/logrus" "golang.org/x/net/context" - nrConfig "github.com/newrelic/newrelic-client-go/pkg/config" - nrLogs "github.com/newrelic/newrelic-client-go/pkg/logs" - "github.com/newrelic/newrelic-client-go/pkg/region" + nrConfig "github.com/newrelic/newrelic-client-go/v2/pkg/config" + nrLogs "github.com/newrelic/newrelic-client-go/v2/pkg/logs" + "github.com/newrelic/newrelic-client-go/v2/pkg/region" ) type LogEntry struct { diff --git a/internal/install/recipe_installer.go b/internal/install/recipe_installer.go index ba56a5e0b..84fb4fc16 100644 --- a/internal/install/recipe_installer.go +++ b/internal/install/recipe_installer.go @@ -21,7 +21,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/install/ux" "github.com/newrelic/newrelic-cli/internal/install/validation" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/newrelic" + "github.com/newrelic/newrelic-client-go/v2/newrelic" ) const ( diff --git a/internal/install/recipe_installer_test.go b/internal/install/recipe_installer_test.go index 1863f9901..2edc2412b 100644 --- a/internal/install/recipe_installer_test.go +++ b/internal/install/recipe_installer_test.go @@ -18,7 +18,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/install/recipes" "github.com/newrelic/newrelic-cli/internal/install/types" "github.com/newrelic/newrelic-cli/internal/install/ux" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) func TestConnectToPlatformShouldSuccess(t *testing.T) { diff --git a/internal/install/validation/mock_nrdb_client.go b/internal/install/validation/mock_nrdb_client.go index f6b0a0d25..6c361f458 100644 --- a/internal/install/validation/mock_nrdb_client.go +++ b/internal/install/validation/mock_nrdb_client.go @@ -4,7 +4,7 @@ import ( "context" "errors" - "github.com/newrelic/newrelic-client-go/pkg/nrdb" + "github.com/newrelic/newrelic-client-go/v2/pkg/nrdb" ) type MockNRDBClient struct { diff --git a/internal/install/validation/polling_recipe_validator_test.go b/internal/install/validation/polling_recipe_validator_test.go index 8af918a7a..55183146c 100644 --- a/internal/install/validation/polling_recipe_validator_test.go +++ b/internal/install/validation/polling_recipe_validator_test.go @@ -11,7 +11,7 @@ import ( "github.com/stretchr/testify/require" "github.com/newrelic/newrelic-cli/internal/install/types" - "github.com/newrelic/newrelic-client-go/pkg/nrdb" + "github.com/newrelic/newrelic-client-go/v2/pkg/nrdb" ) const ( diff --git a/internal/nerdgraph/command_query.go b/internal/nerdgraph/command_query.go index 733577fd3..5d150a706 100644 --- a/internal/nerdgraph/command_query.go +++ b/internal/nerdgraph/command_query.go @@ -13,7 +13,7 @@ import ( "github.com/newrelic/newrelic-cli/internal/client" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - ng "github.com/newrelic/newrelic-client-go/pkg/nerdgraph" + ng "github.com/newrelic/newrelic-client-go/v2/pkg/nerdgraph" ) var ( diff --git a/internal/nerdstorage/command_collection.go b/internal/nerdstorage/command_collection.go index 227a5a357..5bdcbb1ab 100644 --- a/internal/nerdstorage/command_collection.go +++ b/internal/nerdstorage/command_collection.go @@ -10,7 +10,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" + "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" ) var cmdCollection = &cobra.Command{ diff --git a/internal/nerdstorage/command_document.go b/internal/nerdstorage/command_document.go index 5b1056ea0..d2897f514 100644 --- a/internal/nerdstorage/command_document.go +++ b/internal/nerdstorage/command_document.go @@ -11,7 +11,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/nerdstorage" + "github.com/newrelic/newrelic-client-go/v2/pkg/nerdstorage" ) var cmdDocument = &cobra.Command{ diff --git a/internal/nrql/command_query.go b/internal/nrql/command_query.go index 5a106a561..41602e8bb 100644 --- a/internal/nrql/command_query.go +++ b/internal/nrql/command_query.go @@ -8,7 +8,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/nrdb" + "github.com/newrelic/newrelic-client-go/v2/pkg/nrdb" ) var ( diff --git a/internal/profile/command.go b/internal/profile/command.go index 622d85a3c..edd2f911a 100644 --- a/internal/profile/command.go +++ b/internal/profile/command.go @@ -14,7 +14,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/accounts" + "github.com/newrelic/newrelic-client-go/v2/pkg/accounts" ) const ( diff --git a/internal/synthetics/command_monitor.go b/internal/synthetics/command_monitor.go index 14d1a8ee6..fda6b6e4d 100644 --- a/internal/synthetics/command_monitor.go +++ b/internal/synthetics/command_monitor.go @@ -13,8 +13,8 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/output" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/entities" - "github.com/newrelic/newrelic-client-go/pkg/synthetics" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/synthetics" ) var ( diff --git a/internal/utils/nrdb_client.go b/internal/utils/nrdb_client.go index 0061541b6..bb42ce5f5 100644 --- a/internal/utils/nrdb_client.go +++ b/internal/utils/nrdb_client.go @@ -3,7 +3,7 @@ package utils import ( "context" - "github.com/newrelic/newrelic-client-go/pkg/nrdb" + "github.com/newrelic/newrelic-client-go/v2/pkg/nrdb" ) type NRDBClient interface { diff --git a/internal/utils/retry.go b/internal/utils/retry.go index 55deb195c..a42dd48b2 100644 --- a/internal/utils/retry.go +++ b/internal/utils/retry.go @@ -4,7 +4,7 @@ import ( "context" "time" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) type RetryContext struct { diff --git a/internal/utils/retry_test.go b/internal/utils/retry_test.go index 92f179d33..31cdc7bd4 100644 --- a/internal/utils/retry_test.go +++ b/internal/utils/retry_test.go @@ -10,7 +10,7 @@ import ( "github.com/stretchr/testify/require" - nrErrors "github.com/newrelic/newrelic-client-go/pkg/errors" + nrErrors "github.com/newrelic/newrelic-client-go/v2/pkg/errors" ) var ( diff --git a/internal/utils/terraform/dashboard.go b/internal/utils/terraform/dashboard.go index 93231b547..6e9dc7c28 100644 --- a/internal/utils/terraform/dashboard.go +++ b/internal/utils/terraform/dashboard.go @@ -6,7 +6,7 @@ import ( log "github.com/sirupsen/logrus" - "github.com/newrelic/newrelic-client-go/pkg/dashboards" + "github.com/newrelic/newrelic-client-go/v2/pkg/dashboards" ) var ( diff --git a/internal/utils/validation/polling_nrql_validator.go b/internal/utils/validation/polling_nrql_validator.go index cb3d57b74..e9c00122f 100644 --- a/internal/utils/validation/polling_nrql_validator.go +++ b/internal/utils/validation/polling_nrql_validator.go @@ -9,7 +9,7 @@ import ( configAPI "github.com/newrelic/newrelic-cli/internal/config/api" "github.com/newrelic/newrelic-cli/internal/utils" - "github.com/newrelic/newrelic-client-go/pkg/nrdb" + "github.com/newrelic/newrelic-client-go/v2/pkg/nrdb" ) const ( diff --git a/internal/workload/command_workload.go b/internal/workload/command_workload.go index 427c7edb7..2d8c6ea2b 100644 --- a/internal/workload/command_workload.go +++ b/internal/workload/command_workload.go @@ -6,9 +6,9 @@ import ( log "github.com/sirupsen/logrus" "github.com/spf13/cobra" - "github.com/newrelic/newrelic-client-go/pkg/common" - "github.com/newrelic/newrelic-client-go/pkg/entities" - "github.com/newrelic/newrelic-client-go/pkg/workloads" + "github.com/newrelic/newrelic-client-go/v2/pkg/common" + "github.com/newrelic/newrelic-client-go/v2/pkg/entities" + "github.com/newrelic/newrelic-client-go/v2/pkg/workloads" "github.com/newrelic/newrelic-cli/internal/client" configAPI "github.com/newrelic/newrelic-cli/internal/config/api"