From b05d4e819b1c5f7a449add876ad32070e3ed3b33 Mon Sep 17 00:00:00 2001 From: VajiraPrabuddhaka Date: Mon, 21 Oct 2024 09:20:10 +0530 Subject: [PATCH] fix lint failures --- adapter/config/types.go | 4 ++-- adapter/pkg/messaging/azure_connection.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/adapter/config/types.go b/adapter/config/types.go index 3e3ad0cf94..bf2737e0b5 100644 --- a/adapter/config/types.go +++ b/adapter/config/types.go @@ -543,7 +543,7 @@ type controlPlane struct { SyncApisOnStartUp bool SendRevisionUpdate bool EnvironmentLabels []string - ASBDataplaneTopics []ASBDataplaneTopic `toml:"asbDataplaneTopics"` + ASBDataplaneTopics []asbDataplaneTopic `toml:"asbDataplaneTopics"` DynamicEnvironments dynamicEnvironments RetryInterval time.Duration SkipSSLVerification bool @@ -553,7 +553,7 @@ type controlPlane struct { InitialFetch initialFetch } -type ASBDataplaneTopic struct { +type asbDataplaneTopic struct { Type string `toml:"type"` TopicName string `toml:"topicName"` ConnectionString string `toml:"connectionString"` diff --git a/adapter/pkg/messaging/azure_connection.go b/adapter/pkg/messaging/azure_connection.go index a47ae9d84a..a2541c8d3e 100644 --- a/adapter/pkg/messaging/azure_connection.go +++ b/adapter/pkg/messaging/azure_connection.go @@ -80,7 +80,7 @@ func InitiateBrokerConnectionAndValidate(connectionString string, topic string, logger.LoggerMsg.Debugf("ASB client initialized for connection url: %s", maskSharedAccessKey(connectionString)) for j := 0; j < reconnectRetryCount || reconnectRetryCount == -1; j++ { - sub, err := RetrieveSubscriptionMetadataForTopic(connectionString, topic, + sub, err := retrieveSubscriptionMetadataForTopic(connectionString, topic, clientOptions, componentName, subProps, reconnectInterval) if err != nil { logError(reconnectRetryCount, reconnectInterval, err) @@ -101,7 +101,7 @@ func InitiateConsumer(sub *Subscription, consumerType string) { go startBrokerConsumer(sub, consumerType) } -func RetrieveSubscriptionMetadataForTopic(connectionString string, topicName string, clientOptions *asb.ClientOptions, +func retrieveSubscriptionMetadataForTopic(connectionString string, topicName string, clientOptions *asb.ClientOptions, componentName string, opts *admin.SubscriptionProperties, reconnectInterval time.Duration) (*Subscription, error) { ctx, cancel := context.WithCancel(context.Background()) defer cancel()