Skip to content

Commit

Permalink
chore: lint
Browse files Browse the repository at this point in the history
Signed-off-by: Blake Pettersson <[email protected]>
  • Loading branch information
blakepettersson committed Jul 9, 2024
1 parent 4cf3944 commit 6654416
Show file tree
Hide file tree
Showing 11 changed files with 76 additions and 60 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,20 @@ package commands
import (
"context"
"fmt"
"github.com/argoproj/argo-cd/v2/util/settings"
"math"
"time"

flag "github.com/spf13/pflag"
"k8s.io/client-go/rest"
"k8s.io/client-go/tools/clientcmd"
"math"
"time"

"github.com/argoproj/argo-cd/v2/util/settings"

"github.com/argoproj/pkg/stats"
"github.com/redis/go-redis/v9"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
"k8s.io/client-go/kubernetes"

cmdutil "github.com/argoproj/argo-cd/v2/cmd/util"
"github.com/argoproj/argo-cd/v2/common"
Expand All @@ -27,11 +35,6 @@ import (
kubeutil "github.com/argoproj/argo-cd/v2/util/kube"
"github.com/argoproj/argo-cd/v2/util/tls"
"github.com/argoproj/argo-cd/v2/util/trace"
"github.com/argoproj/pkg/stats"
"github.com/redis/go-redis/v9"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
"k8s.io/client-go/kubernetes"
)

const (
Expand Down Expand Up @@ -93,8 +96,6 @@ func (c *ApplicationControllerConfig) WithDefaultFlags() *ApplicationControllerC
c.flags.IntVar(&c.repoServerTimeoutSeconds, "repo-server-timeout-seconds", env.ParseNumFromEnv("ARGOCD_APPLICATION_CONTROLLER_REPO_SERVER_TIMEOUT_SECONDS", 60, 0, math.MaxInt64), "Repo server RPC call timeout seconds.")
c.flags.IntVar(&c.statusProcessors, "status-processors", env.ParseNumFromEnv("ARGOCD_APPLICATION_CONTROLLER_STATUS_PROCESSORS", 20, 0, math.MaxInt32), "Number of application status processors")
c.flags.IntVar(&c.operationProcessors, "operation-processors", env.ParseNumFromEnv("ARGOCD_APPLICATION_CONTROLLER_OPERATION_PROCESSORS", 10, 0, math.MaxInt32), "Number of application operation processors")
c.flags.StringVar(&cmdutil.LogFormat, "logformat", env.StringFromEnv("ARGOCD_APPLICATION_CONTROLLER_LOGFORMAT", "text"), "Set the logging format. One of: text|json")
c.flags.StringVar(&cmdutil.LogLevel, "loglevel", env.StringFromEnv("ARGOCD_APPLICATION_CONTROLLER_LOGLEVEL", "info"), "Set the logging level. One of: debug|info|warn|error")
c.flags.IntVar(&c.glogLevel, "gloglevel", 0, "Set the glog logging level")
c.flags.IntVar(&c.metricsPort, "metrics-port", common.DefaultPortArgoCDMetrics, "Start metrics server on given port")
c.flags.DurationVar(&c.metricsCacheExpiration, "metrics-cache-expiration", env.ParseDurationFromEnv("ARGOCD_APPLICATION_CONTROLLER_METRICS_CACHE_EXPIRATION", 0*time.Second, 0, math.MaxInt64), "Prometheus metrics cache expiration (disabled by default. e.g. 24h0m0s)")
Expand All @@ -109,10 +110,10 @@ func (c *ApplicationControllerConfig) WithDefaultFlags() *ApplicationControllerC
c.flags.StringSliceVar(&c.otlpAttrs, "otlp-attrs", env.StringsFromEnv("ARGOCD_APPLICATION_CONTROLLER_OTLP_ATTRS", []string{}, ","), "List of OpenTelemetry collector extra attrs when send traces, each attribute is separated by a colon(e.g. key:value)")
c.flags.StringSliceVar(&c.applicationNamespaces, "application-namespaces", env.StringsFromEnv("ARGOCD_APPLICATION_NAMESPACES", []string{}, ","), "List of additional namespaces that applications are allowed to be reconciled from")
c.flags.BoolVar(&c.persistResourceHealth, "persist-resource-health", env.ParseBoolFromEnv("ARGOCD_APPLICATION_CONTROLLER_PERSIST_RESOURCE_HEALTH", true), "Enables storing the managed resources health in the Application CRD")
c.flags.StringVar(&c.shardingAlgorithm, "sharding-method", env.StringFromEnv(common.EnvControllerShardingAlgorithm, common.DefaultShardingAlgorithm), "Enables choice of sharding method. Supported sharding methods are : [legacy, round-robin] ")
c.flags.StringVar(&c.shardingAlgorithm, "sharding-method", env.StringFromEnv(common.EnvControllerShardingAlgorithm, common.DefaultShardingAlgorithm), "Enables choice of sharding method. Supported sharding methods are : [legacy, round-robin, consistent-hashing] ")
// global queue rate limit config
c.flags.Int64Var(&c.workqueueRateLimit.BucketSize, "wq-bucket-size", env.ParseInt64FromEnv("WORKQUEUE_BUCKET_SIZE", 500, 1, math.MaxInt64), "Set Workqueue Rate Limiter Bucket Size, default 500")
c.flags.Float64Var(&c.workqueueRateLimit.BucketQPS, "wq-bucket-qps", env.ParseFloat64FromEnv("WORKQUEUE_BUCKET_QPS", math.MaxFloat64, 1, math.MaxFloat64), "Set Workqueue Rate Limiter Bucket QPS, default c.flags to MaxFloat64 which disables the bucket limiter")
c.flags.Float64Var(&c.workqueueRateLimit.BucketQPS, "wq-bucket-qps", env.ParseFloat64FromEnv("WORKQUEUE_BUCKET_QPS", math.MaxFloat64, 1, math.MaxFloat64), "Set Workqueue Rate Limiter Bucket QPS, default set to MaxFloat64 which disables the bucket limiter")
// individual item rate limit config
// when WORKQUEUE_FAILURE_COOLDOWN is 0 per item rate limiting is disabled(default)
c.flags.DurationVar(&c.workqueueRateLimit.FailureCoolDown, "wq-cooldown-ns", time.Duration(env.ParseInt64FromEnv("WORKQUEUE_FAILURE_COOLDOWN_NS", 0, 0, (24*time.Hour).Nanoseconds())), "Set Workqueue Per Item Rate Limiter Cooldown duration in ns, default 0(per item rate limiter disabled)")
Expand All @@ -121,6 +122,7 @@ func (c *ApplicationControllerConfig) WithDefaultFlags() *ApplicationControllerC
c.flags.Float64Var(&c.workqueueRateLimit.BackoffFactor, "wq-backoff-factor", env.ParseFloat64FromEnv("WORKQUEUE_BACKOFF_FACTOR", 1.5, 0, math.MaxFloat64), "Set Workqueue Per Item Rate Limiter Backoff Factor, default is 1.5")
c.flags.BoolVar(&c.enableDynamicClusterDistribution, "dynamic-cluster-distribution-enabled", env.ParseBoolFromEnv(common.EnvEnableDynamicClusterDistribution, false), "Enables dynamic cluster distribution.")
c.flags.BoolVar(&c.serverSideDiff, "server-side-diff-enabled", env.ParseBoolFromEnv(common.EnvServerSideDiff, false), "Feature flag to enable ServerSide diff. Default (\"false\")")
c.flags.DurationVar(&c.ignoreNormalizerOpts.JQExecutionTimeout, "ignore-normalizer-jq-execution-timeout-seconds", env.ParseDurationFromEnv("ARGOCD_IGNORE_NORMALIZER_JQ_TIMEOUT", 0*time.Second, 0, math.MaxInt64), "Set ignore normalizer JQ execution timeout")
c.cacheSource = appstatecache.AddCacheFlagsToCmd(c.flags, cacheutil.Options{
OnClientCreated: func(client *redis.Client) {
c.redisClient = client
Expand Down Expand Up @@ -258,7 +260,7 @@ func (c *ApplicationControllerConfig) CreateApplicationController(ctx context.Co

func NewCommand() *cobra.Command {
var config *ApplicationControllerConfig
var command = cobra.Command{
command := cobra.Command{
Use: cliName,
Short: "Run ArgoCD Application Controller",
Long: "ArgoCD application controller is a Kubernetes controller that continuously monitors running applications and compares the current, live state against the desired target state (as specified in the repo). This command runs Application Controller in the foreground. It can be configured by following options.",
Expand All @@ -277,5 +279,7 @@ func NewCommand() *cobra.Command {
}

config = NewApplicationControllerConfig(command.Flags(), command.PersistentFlags()).WithDefaultFlags().WithKubectlFlags()
command.Flags().StringVar(&cmdutil.LogFormat, "logformat", env.StringFromEnv("ARGOCD_APPLICATION_CONTROLLER_LOGFORMAT", "text"), "Set the logging format. One of: text|json")
command.Flags().StringVar(&cmdutil.LogLevel, "loglevel", env.StringFromEnv("ARGOCD_APPLICATION_CONTROLLER_LOGLEVEL", "info"), "Set the logging level. One of: debug|info|warn|error")
return &command
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@ package command
import (
"context"
"fmt"
"github.com/argoproj/argo-cd/v2/reposerver/apiclient"
"github.com/argoproj/argo-cd/v2/util/tls"
flag "github.com/spf13/pflag"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/client-go/rest"
"math"
"net/http"
"os"

flag "github.com/spf13/pflag"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/client-go/rest"

"github.com/argoproj/argo-cd/v2/reposerver/apiclient"
"github.com/argoproj/argo-cd/v2/util/tls"

ctrl "sigs.k8s.io/controller-runtime"
"sigs.k8s.io/controller-runtime/pkg/manager"

Expand Down Expand Up @@ -155,7 +158,7 @@ func (c *ApplicationSetControllerConfig) CreateApplicationSetController(ctx cont
}

// By default, watch all namespaces
var watchedNamespace = ""
watchedNamespace := ""

// If the applicationset-namespaces contains only one namespace it corresponds to the current namespace
if len(c.applicationSetNamespaces) == 1 {
Expand Down
8 changes: 4 additions & 4 deletions cmd/argocd-repo-server/commands/argocd_repo_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@ package commands
import (
"context"
"fmt"
flag "github.com/spf13/pflag"
"math"
"net"
"net/http"
"time"

flag "github.com/spf13/pflag"

"github.com/argoproj/pkg/stats"
"github.com/redis/go-redis/v9"
log "github.com/sirupsen/logrus"
Expand Down Expand Up @@ -52,7 +53,6 @@ type RepoServerConfig struct {
otlpHeaders map[string]string
otlpAttrs []string
cacheSrc func() (*reposervercache.Cache, error)
tlsConfigCustomizer tls.ConfigCustomizer
tlsConfigCustomizerSrc func() (tls.ConfigCustomizer, error)
redisClient *redis.Client
disableTLS bool
Expand All @@ -70,7 +70,7 @@ type RepoServerConfig struct {
pauseGenerationOnFailureForMinutes int
pauseGenerationOnFailureForRequests int
gitSubmoduleEnabled bool
includeHiddenDirectories bool
includeHiddenDirectories bool
}

func NewRepoServerConfig(flags *flag.FlagSet) *RepoServerConfig {
Expand Down Expand Up @@ -238,7 +238,7 @@ func (c *RepoServerConfig) CreateRepoServer(ctx context.Context) error {

func NewCommand() *cobra.Command {
var config *RepoServerConfig
var command = cobra.Command{
command := cobra.Command{
Use: cliName,
Short: "Run ArgoCD Repository Server",
Long: "ArgoCD Repository Server is an internal service which maintains a local cache of the Git repository holding the application manifests, and is responsible for generating and returning the Kubernetes manifests. This command runs Repository Server in the foreground. It can be configured by following options.",
Expand Down
11 changes: 7 additions & 4 deletions cmd/argocd-server/commands/argocd_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@ package commands
import (
"context"
"fmt"
cacheutil "github.com/argoproj/argo-cd/v2/util/cache"
flag "github.com/spf13/pflag"
"k8s.io/client-go/rest"
"math"
"strings"
"time"

flag "github.com/spf13/pflag"
"k8s.io/client-go/rest"

cacheutil "github.com/argoproj/argo-cd/v2/util/cache"

"github.com/argoproj/pkg/stats"
"github.com/redis/go-redis/v9"
log "github.com/sirupsen/logrus"
Expand Down Expand Up @@ -128,6 +130,7 @@ func (c *ServerConfig) WithDefaultFlags() *ServerConfig {
c.flags.BoolVar(&c.dexServerStrictTLS, "dex-server-strict-tls", env.ParseBoolFromEnv("ARGOCD_SERVER_DEX_SERVER_STRICT_TLS", false), "Perform strict validation of TLS certificates when connecting to dex server")
c.flags.StringSliceVar(&c.applicationNamespaces, "application-namespaces", env.StringsFromEnv("ARGOCD_APPLICATION_NAMESPACES", []string{}, ","), "List of additional namespaces where application resources can be managed in")
c.flags.BoolVar(&c.enableProxyExtension, "enable-proxy-extension", env.ParseBoolFromEnv("ARGOCD_SERVER_ENABLE_PROXY_EXTENSION", false), "Enable Proxy Extension feature")
c.flags.IntVar(&c.webhookParallelism, "webhook-parallelism-limit", env.ParseNumFromEnv("ARGOCD_SERVER_WEBHOOK_PARALLELISM_LIMIT", 50, 1, 1000), "Number of webhook requests processed concurrently")

// Flags related to the applicationSet component.
c.flags.StringVar(&c.scmRootCAPath, "appset-scm-root-ca-path", env.StringFromEnv("ARGOCD_APPLICATIONSET_CONTROLLER_SCM_ROOT_CA_PATH", ""), "Provide Root CA Path for self-signed TLS Certificates")
Expand Down Expand Up @@ -319,7 +322,7 @@ func (c *ServerConfig) CreateServer(ctx context.Context) *server.ArgoCDServer {
// NewCommand returns a new instance of an argocd command
func NewCommand() *cobra.Command {
var config *ServerConfig
var command = &cobra.Command{
command := &cobra.Command{
Use: cliName,
Short: "Run the ArgoCD API server",
Long: "The API server is a gRPC/REST server which exposes the API consumed by the Web UI, CLI, and CI/CD systems. This command runs API server in the foreground. It can be configured by following options.",
Expand Down
10 changes: 6 additions & 4 deletions reposerver/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,24 @@ import (
"encoding/json"
"errors"
"fmt"
flag "github.com/spf13/pflag"
"hash/fnv"
"math"
"sort"
"strings"
"time"

flag "github.com/spf13/pflag"

"github.com/argoproj/gitops-engine/pkg/utils/text"
"github.com/go-git/go-git/v5/plumbing"
log "github.com/sirupsen/logrus"

appv1 "github.com/argoproj/argo-cd/v2/pkg/apis/application/v1alpha1"
"github.com/argoproj/argo-cd/v2/reposerver/apiclient"
"github.com/argoproj/argo-cd/v2/util/argo"
cacheutil "github.com/argoproj/argo-cd/v2/util/cache"
"github.com/argoproj/argo-cd/v2/util/env"
"github.com/argoproj/argo-cd/v2/util/hash"
"github.com/argoproj/gitops-engine/pkg/utils/text"
"github.com/go-git/go-git/v5/plumbing"
log "github.com/sirupsen/logrus"
)

var (
Expand Down
3 changes: 2 additions & 1 deletion server/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ package cache
import (
"context"
"fmt"
flag "github.com/spf13/pflag"
"math"
"time"

flag "github.com/spf13/pflag"

appv1 "github.com/argoproj/argo-cd/v2/pkg/apis/application/v1alpha1"
cacheutil "github.com/argoproj/argo-cd/v2/util/cache"
appstatecache "github.com/argoproj/argo-cd/v2/util/cache/appstate"
Expand Down
4 changes: 0 additions & 4 deletions server/server_norace_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ func TestUserAgent(t *testing.T) {
defer cancel()
s.Init(ctx)
go s.Run(ctx, lns, cancel, func() {

})
defer func() { time.Sleep(3 * time.Second) }()

Expand Down Expand Up @@ -105,7 +104,6 @@ func Test_StaticHeaders(t *testing.T) {
defer cancel()
s.Init(ctx)
go s.Run(ctx, lns, cancel, func() {

})
defer func() { time.Sleep(3 * time.Second) }()

Expand Down Expand Up @@ -136,7 +134,6 @@ func Test_StaticHeaders(t *testing.T) {
defer cancel()
s.Init(ctx)
go s.Run(ctx, lns, cancel, func() {

})
defer func() { time.Sleep(3 * time.Second) }()

Expand Down Expand Up @@ -167,7 +164,6 @@ func Test_StaticHeaders(t *testing.T) {
defer cancel()
s.Init(ctx)
go s.Run(ctx, lns, cancel, func() {

})
defer func() { time.Sleep(3 * time.Second) }()

Expand Down
43 changes: 23 additions & 20 deletions test/e2e/fixture/fixture.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,30 @@ import (
"context"
goerrors "errors"
"fmt"
appcontrollercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-application-controller/commands"
appsetcontrollercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-applicationset-controller/commands"
reposervercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-repo-server/commands"
servercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-server/commands"
"github.com/argoproj/argo-cd/v2/util/cli"
grpcutil "github.com/argoproj/argo-cd/v2/util/grpc"
"github.com/spf13/pflag"
"github.com/testcontainers/testcontainers-go"
"github.com/testcontainers/testcontainers-go/modules/k3s"
"github.com/testcontainers/testcontainers-go/modules/redis"
"github.com/testcontainers/testcontainers-go/wait"
"os"
"os/user"
"path"
"path/filepath"
ctrl "sigs.k8s.io/controller-runtime"
"strconv"
"strings"
"testing"
"time"

"github.com/spf13/pflag"
"github.com/testcontainers/testcontainers-go"
"github.com/testcontainers/testcontainers-go/modules/k3s"
"github.com/testcontainers/testcontainers-go/modules/redis"
"github.com/testcontainers/testcontainers-go/wait"

appcontrollercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-application-controller/commands"
appsetcontrollercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-applicationset-controller/commands"
reposervercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-repo-server/commands"
servercommand "github.com/argoproj/argo-cd/v2/cmd/argocd-server/commands"
"github.com/argoproj/argo-cd/v2/util/cli"
grpcutil "github.com/argoproj/argo-cd/v2/util/grpc"

ctrl "sigs.k8s.io/controller-runtime"

"github.com/argoproj/pkg/errors"
jsonpatch "github.com/evanphx/json-patch"
log "github.com/sirupsen/logrus"
Expand Down Expand Up @@ -607,8 +610,7 @@ func WithTestData(testdata string) TestOption {
}
}

type testLogConsumer struct {
}
type testLogConsumer struct{}

func (g *testLogConsumer) Accept(l testcontainers.Log) {
log.Info(string(l.Content))
Expand Down Expand Up @@ -644,6 +646,7 @@ func initTestContainers(ctx context.Context) {
},
Started: true,
})
CheckError(err)

c, err := k3s.RunContainer(ctx,
testcontainers.WithImage("rancher/k3s:v1.27.15-k3s1"), // TODO: env var k3s version
Expand Down Expand Up @@ -674,7 +677,7 @@ func initTestContainers(ctx context.Context) {
CheckError(err)
kubeConfigPath := temp + "/kubeconfig.yaml"

CheckError(os.WriteFile(kubeConfigPath, kubeConfigYaml, 0666))
CheckError(os.WriteFile(kubeConfigPath, kubeConfigYaml, 0o666))
CheckError(os.Setenv("REDIS_SERVER", endpoint))
CheckError(os.Setenv("KUBECONFIG", kubeConfigPath))
CheckError(os.Setenv("ARGOCD_FAKE_IN_CLUSTER", "true"))
Expand Down Expand Up @@ -729,9 +732,9 @@ func initTestServices(ctx context.Context) {
serverFlags := pflag.NewFlagSet("", pflag.PanicOnError)
CheckError(serverFlags.Parse([]string{}))
serverRestConfig := rest.CopyConfig(KubeConfig)
//serverRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-server", TestNamespace())
// serverRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-server", TestNamespace())
serverConfig := servercommand.NewServerConfig(serverFlags, serverFlags).WithDefaultFlags().WithK8sSettings(TestNamespace(), serverRestConfig)
//CheckError(serverFlags.Set("loglevel", "debug"))
// CheckError(serverFlags.Set("loglevel", "debug"))
CheckError(serverFlags.Set("insecure", "true"))
CheckError(serverFlags.Set("port", strings.Split(apiServerAddress, ":")[1]))
CheckError(serverFlags.Set("repo-server", "localhost:8081"))
Expand All @@ -742,7 +745,7 @@ func initTestServices(ctx context.Context) {
appControllerFlags := pflag.NewFlagSet("", pflag.PanicOnError)
CheckError(appControllerFlags.Parse([]string{}))
appRestConfig := rest.CopyConfig(KubeConfig)
//appRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-application-controller", TestNamespace())
// appRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-application-controller", TestNamespace())
appControllerConfig := appcontrollercommand.NewApplicationControllerConfig(appControllerFlags, appControllerFlags).WithDefaultFlags().WithK8sSettings(TestNamespace(), appRestConfig)
CheckError(appControllerFlags.Set("loglevel", "debug"))
CheckError(appControllerFlags.Set("repo-server", "localhost:8081"))
Expand All @@ -753,9 +756,9 @@ func initTestServices(ctx context.Context) {
CheckError(appSetControllerFlags.Parse([]string{}))

appsetRestConfig := rest.CopyConfig(KubeConfig)
//appsetRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-applicationset-controller", TestNamespace())
// appsetRestConfig.Impersonate.UserName = fmt.Sprintf("system:serviceaccount:%s:argocd-applicationset-controller", TestNamespace())
appSetControllerConfig := appsetcontrollercommand.NewApplicationSetControllerConfig(appSetControllerFlags, appSetControllerFlags).WithDefaultFlags().WithK8sSettings(TestNamespace(), appsetRestConfig)
//CheckError(appSetControllerFlags.Set("loglevel", "debug"))
// CheckError(appSetControllerFlags.Set("loglevel", "debug"))
CheckError(appSetControllerFlags.Set("probe-addr", ":9999"))
CheckError(appSetControllerFlags.Set("argocd-repo-server", "localhost:8081"))
mgr, err := appSetControllerConfig.CreateApplicationSetController(ctx)
Expand Down
3 changes: 2 additions & 1 deletion util/cache/appstate/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ package appstate
import (
"context"
"fmt"
flag "github.com/spf13/pflag"
"sort"
"time"

flag "github.com/spf13/pflag"

appv1 "github.com/argoproj/argo-cd/v2/pkg/apis/application/v1alpha1"
cacheutil "github.com/argoproj/argo-cd/v2/util/cache"
"github.com/argoproj/argo-cd/v2/util/env"
Expand Down
3 changes: 2 additions & 1 deletion util/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,13 @@ import (
"crypto/tls"
"crypto/x509"
"fmt"
flag "github.com/spf13/pflag"
"math"
"os"
"strings"
"time"

flag "github.com/spf13/pflag"

"github.com/redis/go-redis/v9"
log "github.com/sirupsen/logrus"

Expand Down
Loading

0 comments on commit 6654416

Please sign in to comment.