diff --git a/.cspell.json b/.cspell.json index fd029312359..40829a27020 100644 --- a/.cspell.json +++ b/.cspell.json @@ -28,6 +28,8 @@ "**/*.png", "**/*.sum", "**/*.svg", + "**/.cspell.json", + "**/hack/cspell/.cspell.json", "**/.git/objects/**", "**/cmd/agent/core/faiss/faiss", "**/cmd/agent/core/ngt/ngt", @@ -1424,7 +1426,7 @@ { "filename": "charts/vald/values.yaml", "ignoreWords": [ - "goroutines", + "goroutines" ] }, { @@ -2139,6 +2141,12 @@ "timelimit" ] }, + { + "filename": "internal/circuitbreaker/breaker_test.go", + "ignoreWords": [ + "resetted" + ] + }, { "filename": "internal/client/v1/client/client.go", "ignoreWords": [ @@ -2371,7 +2379,7 @@ "filename": "internal/core/algorithm/ngt/ngt_test.go", "ignoreWords": [ "bulkinsert", - "ospace", + "ospace" ] }, { @@ -2515,7 +2523,7 @@ "filename": "internal/db/rdb/mysql/mysql_test.go", "ignoreWords": [ "insertbysql", - "loadcontext", + "loadcontext" ] }, { @@ -2562,7 +2570,7 @@ "forcepathstyle", "httpclient", "itop", - "maxretries", + "maxretries" ] }, { @@ -2630,6 +2638,7 @@ { "filename": "internal/errors/lb.go", "ignoreWords": [ + "insuffcient", "insufficient" ] }, @@ -2654,7 +2663,7 @@ { "filename": "internal/errors/redis_test.go", "ignoreWords": [ - "kvvk", + "kvvk" ] }, { @@ -2689,7 +2698,7 @@ { "filename": "internal/k8s/job/job.go", "ignoreWords": [ - "batchv", + "batchv" ] }, { @@ -2767,6 +2776,7 @@ "filename": "internal/log/level/level.go", "ignoreWords": [ "debg", + "erro", "fata" ] }, @@ -2840,7 +2850,7 @@ "ignoreWords": [ "copylocks", "govet", - "nums", + "nums" ] }, { @@ -2848,7 +2858,7 @@ "ignoreWords": [ "gbackoff", "parseable", - "rebalancing", + "rebalancing" ] }, { @@ -2974,6 +2984,12 @@ "semconv" ] }, + { + "filename": "internal/observability/metrics/grpc/grpc.go", + "ignoreWords": [ + "desctiption" + ] + }, { "filename": "internal/observability/metrics/mem/index/index.go", "ignoreWords": [ @@ -3067,7 +3083,7 @@ { "filename": "internal/servers/servers_test.go", "ignoreWords": [ - "strg", + "strg" ] }, { @@ -3099,6 +3115,7 @@ { "filename": "internal/sync/semaphore/semaphore_test.go", "ignoreWords": [ + "doesnt", "unacquired" ] }, @@ -3112,6 +3129,7 @@ { "filename": "internal/sync/singleflight/singleflight_test.go", "ignoreWords": [ + "dochan", "unparam" ] }, @@ -3119,7 +3137,8 @@ "filename": "internal/test/data/hdf5/hdf5.go", "ignoreWords": [ "keepalives", - "neighbors" + "neighbors", + "neighors" ] }, { @@ -3349,6 +3368,12 @@ "rolebinding" ] }, + { + "filename": "k8s/tools/benchmark/job/serviceaccount.yaml", + "ignoreWords": [ + "versoin" + ] + }, { "filename": "k8s/tools/benchmark/operator/clusterrole.yaml", "ignoreWords": [ @@ -3431,6 +3456,7 @@ "joind", "nonexistid", "pushinsert", + "testingcase" ] }, { @@ -3536,6 +3562,7 @@ "aggr", "fdist", "fmax", + "insuffcient", "insufficient", "timeoutage" ] @@ -3599,6 +3626,12 @@ "grpcmock" ] }, + { + "filename": "pkg/gateway/mirror/usecase/vald.go", + "ignoreWords": [ + "mirrormetrics" + ] + }, { "filename": "pkg/index/job/creation/service/indexer_test.go", "ignoreWords": [ @@ -3626,10 +3659,17 @@ "jobnamespace" ] }, + { + "filename": "pkg/tools/benchmark/job/service/insert.go", + "ignoreWords": [ + "prometeus" + ] + }, { "filename": "pkg/tools/benchmark/job/service/job.go", "ignoreWords": [ "benchjob", + "neighors", "userdefined" ] }, @@ -3637,6 +3677,7 @@ "filename": "pkg/tools/benchmark/job/service/option.go", "ignoreWords": [ "bjns", + "concurency", "userdefined" ] }, @@ -3644,11 +3685,13 @@ "filename": "pkg/tools/benchmark/job/service/option_test.go", "ignoreWords": [ "bjns", + "concurency" ] }, { "filename": "pkg/tools/benchmark/job/usecase/benchmarkd.go", "ignoreWords": [ + "concurency", "gcli", "unbackupped", "usecases", @@ -3791,6 +3834,12 @@ "peakrate" ] }, + { + "filename": "tests/e2e/crud/crud_test.go", + "ignoreWords": [ + "ecrud" + ] + }, { "filename": "tests/e2e/kubernetes/client/client.go", "ignoreWords": [ @@ -3820,80 +3869,112 @@ "evalidator", "svalidator" ] - }, + } ], "patterns": [ { - "name": "IgnoredurSuffix", - "pattern": ".*dur$" + "name": "IgnoreaddrSuffix", + "pattern": ".*addr$" }, { "name": "IgnoreaddrsSuffix", "pattern": ".*addrs$" }, - { - "name": "IgnoreaddrSuffix", - "pattern": ".*addr$" - }, { "name": "IgnorebufSuffix", "pattern": ".*buf$" }, { - "name": "IgnoregroupSuffix", - "pattern": ".*group$" + "name": "IgnorecfgSuffix", + "pattern": ".*cfg$" }, { - "name": "IgnoreoptSuffix", - "pattern": ".*opt$" + "name": "IgnorecfgSuffix", + "pattern": ".*cfg$" }, { - "name": "IgnoreoptsSuffix", - "pattern": ".*opts$" + "name": "IgnorechSuffix", + "pattern": ".*ch$" + }, + { + "name": "IgnorechSuffix", + "pattern": ".*ch$" + }, + { + "name": "IgnorecntSuffix", + "pattern": ".*cnt$" }, { "name": "IgnoreconfSuffix", "pattern": ".*conf$" }, + { + "name": "IgnoreconfSuffix", + "pattern": ".*conf$" + }, + { + "name": "IgnoreconnSuffix", + "pattern": ".*conn$" + }, + { + "name": "IgnoreconnSuffix", + "pattern": ".*conn$" + }, + { + "name": "IgnorectxSuffix", + "pattern": ".*ctx$" + }, + { + "name": "IgnorectxSuffix", + "pattern": ".*ctx$" + }, + { + "name": "IgnoredurSuffix", + "pattern": ".*dur$" + }, + { + "name": "IgnoredurSuffix", + "pattern": ".*dur$" + }, { "name": "IgnoreerrSuffix", "pattern": ".*err$" }, { - "name": "IgnoreerrsSuffix", - "pattern": ".*errs$" + "name": "IgnoreerrSuffix", + "pattern": ".*err$" }, { "name": "IgnoreerrorsSuffix", "pattern": ".*errors$" }, { - "name": "IgnorectxSuffix", - "pattern": ".*ctx$" + "name": "IgnoreerrsSuffix", + "pattern": ".*errs$" }, { - "name": "IgnorelenSuffix", - "pattern": ".*len$" + "name": "IgnoregroupSuffix", + "pattern": ".*group$" }, { - "name": "IgnorecfgSuffix", - "pattern": ".*cfg$" + "name": "IgnorelenSuffix", + "pattern": ".*len$" }, { - "name": "IgnorecntSuffix", - "pattern": ".*cnt$" + "name": "IgnorelenSuffix", + "pattern": ".*len$" }, { - "name": "IgnoreconnSuffix", - "pattern": ".*conn$" + "name": "IgnoreoptSuffix", + "pattern": ".*opt$" }, { - "name": "IgnoreconnSuffix", - "pattern": ".*conn$" + "name": "IgnoreoptsSuffix", + "pattern": ".*opts$" }, { - "name": "IgnorechSuffix", - "pattern": ".*ch$" + "name": "IgnoreoptsSuffix", + "pattern": ".*opts$" } ] } diff --git a/hack/cspell/main.go b/hack/cspell/main.go index 28a553d0e22..683cb6b748d 100644 --- a/hack/cspell/main.go +++ b/hack/cspell/main.go @@ -13,11 +13,11 @@ import ( ) type CspellConfig struct { - Import []string `json:"import,omitempty"` - IgnorePaths []string `json:"ignorePaths,omitempty"` - IgnoreWords []string `json:"ignoreWords,omitempty"` + Import []string `json:"import,omitempty"` + IgnorePaths []string `json:"ignorePaths,omitempty"` + IgnoreWords []string `json:"ignoreWords,omitempty"` Overrides []Override `json:"overrides,omitempty"` - Patterns []Pattern `json:"patterns,omitempty"` + Patterns []Pattern `json:"patterns,omitempty"` } type Override struct { @@ -293,4 +293,3 @@ func unique(strings []string) []string { sort.Strings(result) // アルファベット順にソート return result } - diff --git a/internal/circuitbreaker/breaker.go b/internal/circuitbreaker/breaker.go index 0098b6e88f8..81f3a455efa 100644 --- a/internal/circuitbreaker/breaker.go +++ b/internal/circuitbreaker/breaker.go @@ -35,7 +35,7 @@ type breaker struct { minSamples int64 openTimeout time.Duration openExp int64 // unix time - closedRefreshTimeout time.Duration + closedRefreshTimeout time.Duration closedRefreshExp int64 // unix time } diff --git a/internal/circuitbreaker/breaker_test.go b/internal/circuitbreaker/breaker_test.go index 1dbca86c0d1..d0fd5ef680d 100644 --- a/internal/circuitbreaker/breaker_test.go +++ b/internal/circuitbreaker/breaker_test.go @@ -35,7 +35,7 @@ func Test_breaker_isReady(t *testing.T) { minSamples int64 openTimeout time.Duration openExp int64 - closedRefreshTimeout time.Duration + closedRefreshTimeout time.Duration closedRefreshExp int64 } type want struct { @@ -162,7 +162,7 @@ func Test_breaker_isReady(t *testing.T) { minSamples: test.fields.minSamples, openTimeout: test.fields.openTimeout, openExp: test.fields.openExp, - closedRefreshTimeout: test.fields.closedRefreshTimeout, + closedRefreshTimeout: test.fields.closedRefreshTimeout, closedRefreshExp: test.fields.closedRefreshExp, } @@ -186,7 +186,7 @@ func Test_breaker_success(t *testing.T) { minSamples int64 openTimeout time.Duration openExp int64 - closedRefreshTimeout time.Duration + closedRefreshTimeout time.Duration closedRefreshExp int64 } type want struct{} @@ -281,7 +281,7 @@ func Test_breaker_success(t *testing.T) { minSamples: test.fields.minSamples, openTimeout: test.fields.openTimeout, openExp: test.fields.openExp, - closedRefreshTimeout: test.fields.closedRefreshTimeout, + closedRefreshTimeout: test.fields.closedRefreshTimeout, closedRefreshExp: test.fields.closedRefreshExp, } if test.afterFunc != nil { @@ -308,7 +308,7 @@ func Test_breaker_fail(t *testing.T) { minSamples int64 openTimeout time.Duration openExp int64 - closedRefreshTimeout time.Duration + closedRefreshTimeout time.Duration closedRefreshExp int64 } type want struct{} @@ -439,7 +439,7 @@ func Test_breaker_fail(t *testing.T) { minSamples: test.fields.minSamples, openTimeout: test.fields.openTimeout, openExp: test.fields.openExp, - closedRefreshTimeout: test.fields.closedRefreshTimeout, + closedRefreshTimeout: test.fields.closedRefreshTimeout, closedRefreshExp: test.fields.closedRefreshExp, } if test.afterFunc != nil { diff --git a/pkg/agent/core/ngt/service/ngt_test.go b/pkg/agent/core/ngt/service/ngt_test.go index 25f6e1cf584..4cc18bbebe5 100644 --- a/pkg/agent/core/ngt/service/ngt_test.go +++ b/pkg/agent/core/ngt/service/ngt_test.go @@ -1370,7 +1370,7 @@ func Test_ngt_InsertUpsert(t *testing.T) { return } type args struct { - indices []index + indices []index poolSize uint32 bulkSize int }