{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D7","name":"Architectural Integrity","shortDescription":{"text":"Architectural Integrity"},"helpUri":"https://codehealth.canine.dev/dimensions/D7"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"id":"D20","name":"ADR Quality","shortDescription":{"text":"ADR Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D20"},{"id":"D21","name":"Naming Consistency","shortDescription":{"text":"Naming Consistency"},"helpUri":"https://codehealth.canine.dev/dimensions/D21"},{"id":"D25","name":"ADR Conformance","shortDescription":{"text":"ADR Conformance"},"helpUri":"https://codehealth.canine.dev/dimensions/D25"},{"id":"D28","name":"Secrets (history)","shortDescription":{"text":"Secrets (history)"},"helpUri":"https://codehealth.canine.dev/dimensions/D28","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"]}},{"id":"D31","name":"IaC \u0026 Container Security","shortDescription":{"text":"IaC \u0026 Container Security"},"helpUri":"https://codehealth.canine.dev/dimensions/D31","relationships":[{"target":{"id":"CWE-1032","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-732","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-16","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1032","CWE-732","CWE-16"]}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D36","name":"Supply-chain Provenance \u0026 Signing","shortDescription":{"text":"Supply-chain Provenance \u0026 Signing"},"helpUri":"https://codehealth.canine.dev/dimensions/D36","relationships":[{"target":{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1357","CWE-494"]}},{"id":"D38","name":"OSV Dependency Vulnerabilities","shortDescription":{"text":"OSV Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D38","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"]}},{"id":"D40","name":"Network Egress Confinement","shortDescription":{"text":"Network Egress Confinement"},"helpUri":"https://codehealth.canine.dev/dimensions/D40"},{"id":"D41","name":"Kernel \u0026 Syscall Confinement","shortDescription":{"text":"Kernel \u0026 Syscall Confinement"},"helpUri":"https://codehealth.canine.dev/dimensions/D41"},{"id":"D42","name":"Runtime Threat Enforcement","shortDescription":{"text":"Runtime Threat Enforcement"},"helpUri":"https://codehealth.canine.dev/dimensions/D42"}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"testutil.BuildArrayData (cyclomatic 188): testutil.BuildArrayData has cyclomatic complexity 188 (threshold 15). Of this number, 182 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":494}}}],"partialFingerprints":{"codehealthFindingId/v1":"131d4659650d06ae68a1180cfe4983a23078ae79855c65da6d0be8a809e5ce10"}},{"ruleId":"D1","level":"warning","message":{"text":"quotaConfig.init (cyclomatic 180): quotaConfig.init has cyclomatic complexity 180 (threshold 15). Most of this is not in the body itself: 1 of the 180 points is its own statement and the rest belongs to 68 function literals inside it that branch (lines 1605, 1650, 345, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/quota_param.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c61b2cdb374a75c9e86399ffe28e31fa2640a1230af2272e0d198a5b0094800"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.fillDatabase (cyclomatic 150): proxy.fillDatabase has cyclomatic complexity 150 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/database_interceptor.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff30d52195eefce8d0b5dec6bf3041fc05e15858cacf1e6f2abecd413e8e36c9"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.anyToColumns (cyclomatic 131): httpserver.anyToColumns has cyclomatic complexity 131 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1800}}}],"partialFingerprints":{"codehealthFindingId/v1":"2622c4aa17748593226b044bbe9ac3639725860ee1ac71a47abc2a40f08764dd"}},{"ruleId":"D1","level":"warning","message":{"text":"createIndexTask.parseIndexParams (cyclomatic 120): createIndexTask.parseIndexParams has cyclomatic complexity 120 (threshold 15). Of this number, 107 points are the body\u0027s own statements and 13 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a99512f0eaed1ed92497c2df24e2d4633594a23225b3cb10eed029668e50058"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.reorderFieldData (cyclomatic 111): proxy.reorderFieldData has cyclomatic complexity 111 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2707}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc897aa6aac28ab623840c1728f7e4c80b33e6a2ab00901d206e43d2afc3f2a6"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.UpdateFieldData (cyclomatic 99): typeutil.UpdateFieldData has cyclomatic complexity 99 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1641}}}],"partialFingerprints":{"codehealthFindingId/v1":"48adfd8906bbc58081f4c4bbe668fbc90883c2981bae1b912bd854bb52aa761c"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.checkAndSetData (cyclomatic 90): httpserver.checkAndSetData has cyclomatic complexity 90 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dbedbccbe9df95200d29390ccbe612d618453447ed2790bb04c5566acc1bd65"}},{"ruleId":"D1","level":"warning","message":{"text":"upsertTask.queryPreExecute (cyclomatic 85): upsertTask.queryPreExecute has cyclomatic complexity 85 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd18516f0a8cbbab521b76524e7e805ddfb519500f5c69b0e3c0d236eb850ab9"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.ActualSizeInBytes (cyclomatic 85): storage.ActualSizeInBytes has cyclomatic complexity 85 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde.go"},"region":{"startLine":1459}}}],"partialFingerprints":{"codehealthFindingId/v1":"0deb9ce83dfcb3f3210dee3500066649241927ed725616dce4a383e6775a24e4"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.parseEntity (cyclomatic 85): rowParser.parseEntity has cyclomatic complexity 85 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfd09cbe7c56853becc2f0caa5552512a2585b9d2836cc28f50b414214b2ba15"}},{"ruleId":"D1","level":"warning","message":{"text":"column.FieldDataColumn (cyclomatic 83): column.FieldDataColumn has cyclomatic complexity 83 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e58584951f0612e95d54353750c18ce0869f55e024140e0e89f5085b4be4cfa"}},{"ruleId":"D1","level":"warning","message":{"text":"testutil.reconstructStructArrayForJSON (cyclomatic 76): testutil.reconstructStructArrayForJSON has cyclomatic complexity 76 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1290}}}],"partialFingerprints":{"codehealthFindingId/v1":"c964bd2aaff9e1eb0f4b6a73520d6fd240c1b414682b9a11b97312eb8f88dfe8"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.checkAndFlattenStructFieldData (cyclomatic 74): proxy.checkAndFlattenStructFieldData has cyclomatic complexity 74 (threshold 15). Of this number, 52 points are the body\u0027s own statements and 22 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1922}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6656ba508a336def19e64e9101522cf6d4eab2f6fb09b5ce4551a864868467c"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.AppendFieldDataByColumn (cyclomatic 68): typeutil.AppendFieldDataByColumn has cyclomatic complexity 68 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1312}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d3a7b500334d122c4452852eb554e5be2db3029cbe1727836d072cba092414"}},{"ruleId":"D1","level":"warning","message":{"text":"HandlersV2.createCollection (cyclomatic 66): HandlersV2.createCollection has cyclomatic complexity 66 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2329}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac857eb8ce802e421ebfcc14188167c3d43a747ec03061cc0cf63ba3b0e015fd"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.AddInsertData (cyclomatic 64): storage.AddInsertData has cyclomatic complexity 64 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"bce60305a5f8853ebc792bbd68975638f24cd682f1fe8a7268d3b3c47cd07720"}},{"ruleId":"D1","level":"warning","message":{"text":"searchTask.initSearchRequest (cyclomatic 63): searchTask.initSearchRequest has cyclomatic complexity 63 (threshold 15). Of this number, 61 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"c31a47834fc7e9048ca9457faabec01d3951579f687ab1a27b75f716e6dc6007"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.printPayloadValues (cyclomatic 62): storage.printPayloadValues has cyclomatic complexity 62 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce53d0e67c5ce342554e391c7e84e0344929908fb544280d4cdfb5ad01c62c38"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldReader.Next (cyclomatic 62): FieldReader.Next has cyclomatic complexity 62 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"df8eb5d61795fc2e03f86c7f10747bb6d80d4e0b488fb7ba57690e86f54fe098"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.buildMergedVectorField (cyclomatic 62): queryutil.buildMergedVectorField has cyclomatic complexity 62 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbfd7cff742cacac071e48a945963900fe402a3def6ee18c684474b619752283"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.searchResultData (cyclomatic 61): dec.searchResultData has cyclomatic complexity 61 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/searchresult.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"cea684194c42722941e334490852415dfb540c395127e5ccbc2d279ec81b3434"}},{"ruleId":"D1","level":"warning","message":{"text":"validateUtil.checkAligned (cyclomatic 60): validateUtil.checkAligned has cyclomatic complexity 60 (threshold 15). Of this number, 58 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"004c85a8d05c63a61e8df807a8a5a54403df380974afd21b8848c35456c367bd"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineOrBinaryRanges (cyclomatic 59): visitor.combineOrBinaryRanges has cyclomatic complexity 59 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":734}}}],"partialFingerprints":{"codehealthFindingId/v1":"344cac6fddc22a9538d55f88f93b699e6393fac059ef57a6ba920d789e774bfc"}},{"ruleId":"D1","level":"warning","message":{"text":"searchTask.initAdvancedSearchRequest (cyclomatic 59): searchTask.initAdvancedSearchRequest has cyclomatic complexity 59 (threshold 15). Of this number, 57 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a838b0b634ac79228977a1aa733db9ceda8bccaabb9601f48486cdef8fc252"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.ColumnBasedInsertMsgToInsertData (cyclomatic 59): storage.ColumnBasedInsertMsgToInsertData has cyclomatic complexity 59 (threshold 15). Most of this is not in the body itself: 12 of the 59 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 619, 916). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b4bf0ab5b90a7c71eaba8741d52b970fea5f54e78f7524a3adcdb82848da272"}},{"ruleId":"D1","level":"warning","message":{"text":"NativePayloadWriter.AddDataToPayloadForUT (cyclomatic 59): NativePayloadWriter.AddDataToPayloadForUT has cyclomatic complexity 59 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5c243f1507aaf70d7d0a4e64714260e6b4e17a93c10b8925dbe39b848b5db50"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.buildQueryResp (cyclomatic 58): httpserver.buildQueryResp has cyclomatic complexity 58 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2668}}}],"partialFingerprints":{"codehealthFindingId/v1":"05acf361ad4f4ae30a1bee117d6d9d26daec3904fe22720302f3bbbda2220fa1"}},{"ruleId":"D1","level":"warning","message":{"text":"testutil.CreateInsertData (cyclomatic 58): testutil.CreateInsertData has cyclomatic complexity 58 (threshold 15). Of this number, 54 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b664d9bd5a78ad625e9309877ae3c73c3476ef2084d194bf88f5fb37ec671ee"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.AppendFieldData (cyclomatic 58): typeutil.AppendFieldData has cyclomatic complexity 58 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1014}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc58355181a8ebd698583dd7adc477abcdd22243e5e479b1f655c3461267a9aa"}},{"ruleId":"D1","level":"warning","message":{"text":"alterCollectionTask.PreExecute (cyclomatic 56): alterCollectionTask.PreExecute has cyclomatic complexity 56 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":2164}}}],"partialFingerprints":{"codehealthFindingId/v1":"2343c078720ff24bf3890aaa751c38f46c2f529a97bcb1feddd18fbb1e1edbc9"}},{"ruleId":"D1","level":"warning","message":{"text":"queryTask.PreExecute (cyclomatic 56): queryTask.PreExecute has cyclomatic complexity 56 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae9bbea09133d3405f2d74fbe1b760d0b19d534ce089ceeac334ad29f94a00fc"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.parseEntity (cyclomatic 55): rowParser.parseEntity has cyclomatic complexity 55 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb8686d38b6eca7f6d0fd4c56ba0c230d981273d43eb5c47e86e403f0c5c1b96"}},{"ruleId":"D1","level":"warning","message":{"text":"RefreshExternalCollectionTask.balanceFragmentsToSegments (cyclomatic 54): RefreshExternalCollectionTask.balanceFragmentsToSegments has cyclomatic complexity 54 (threshold 15). Of this number, 44 points are the body\u0027s own statements and 10 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2776362b4141134964956aeda9040c9c5c9cfc5d6c4e6fb70683e6e2d3b4da8"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndBinaryRanges (cyclomatic 53): visitor.combineAndBinaryRanges has cyclomatic complexity 53 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2656c973cfd4ef5522700660f9630a3ac6299c476a1c2ce4ccdd53b73e27933"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.UpdateFieldDataByColumn (cyclomatic 53): typeutil.UpdateFieldDataByColumn has cyclomatic complexity 53 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1917}}}],"partialFingerprints":{"codehealthFindingId/v1":"37a46a4bf691a4411e63c7bd58c4595e7a9a4056774f9b9b99cbe9d12e05c460"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndRangePredicates (cyclomatic 50): visitor.combineAndRangePredicates has cyclomatic complexity 50 (threshold 15). Of this number, 47 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c11a82395661d8d83b1f4cb91c1e42b263f6ff9e3f3b62fe64ee05473cd4809"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldReader.Next (cyclomatic 50): FieldReader.Next has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/field_reader.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e3011e97d6165cdd15da940fab393c0b181f54ede022b8b5cfa277bdf495900"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadArrayData (cyclomatic 49): parquet.ReadArrayData has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1777}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae57308927e29f54651ece478433c6c59024e4e90c2b915f4eb6a33a80a2efd3"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.ToCompressedFormatNullable (cyclomatic 48): proxy.ToCompressedFormatNullable has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9f4945342ef060c1b3785694cd12f267656bb373c937bf79b62f561bced4792"}},{"ruleId":"D1","level":"warning","message":{"text":"createCollectionTask.PreExecute (cyclomatic 48): createCollectionTask.PreExecute has cyclomatic complexity 48 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9411d7d613347ca5e5e71d484f0aa61ded0454e6990b2d2ef4cea4380c7d25c"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.AddFieldDataToPayload (cyclomatic 48): storage.AddFieldDataToPayload has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0f8b1b153c245ea777820c582ded81423ce9bfccb075c8566de510c34d3d404"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndInWithRange (cyclomatic 47): visitor.combineAndInWithRange has cyclomatic complexity 47 (threshold 15). Of this number, 44 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"053c9d56d9f25ad415b286d960de01dc6afcb48fcec576de20085dbd90926930"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.broadcastAlterCollectionForAlterCollection (cyclomatic 47): Core.broadcastAlterCollectionForAlterCollection has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_properties.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"583162c21c296f29e74934ffd4a85c8e562dd34f2560feade91a7ffcf19f5d33"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.appendValueAt (cyclomatic 47): storage.appendValueAt has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/arrow_util.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"5324c2b94100908a76f4b10dffeae829ae27ee0550f9f7c9cef9f9b4ca3a7ca4"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadNullableArrayData (cyclomatic 47): parquet.ReadNullableArrayData has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1978}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2f34d10156a35e023017ed244ab62f111c49062fbf788e1372df03aef5e7bfe"}},{"ruleId":"D1","level":"warning","message":{"text":"externalspec.ValidateExtfsComplete (cyclomatic 47): externalspec.ValidateExtfsComplete has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/externalspec/external_spec.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"d81c5f87e87cc28dd408de04201065bad105e5cffd9cb1b8115f4ae51d714a1a"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.applyExternalCollectionSegmentUpdate (cyclomatic 46): datacoord.applyExternalCollectionSegmentUpdate has cyclomatic complexity 46 (threshold 15). Of this number, 33 points are the body\u0027s own statements and 13 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bbd1fa94e7620bb96f819d7bcbc0f39373d96a8458269aedcbf9feb73c17d41"}},{"ruleId":"D1","level":"warning","message":{"text":"HandlersV2.search (cyclomatic 46): HandlersV2.search has cyclomatic complexity 46 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1844}}}],"partialFingerprints":{"codehealthFindingId/v1":"5102d94dadcd69b5c6bece312d2238d60814b65fd2a709d5a82a18ff8069fe54"}},{"ruleId":"D1","level":"warning","message":{"text":"rootcoord.checkFieldSchema (cyclomatic 46): rootcoord.checkFieldSchema has cyclomatic complexity 46 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":340}}}],"partialFingerprints":{"codehealthFindingId/v1":"11e57ec485b2cdefff62301e6a22c98b0ccbc65e849cd1a384e0e6220da0cf78"}},{"ruleId":"D1","level":"warning","message":{"text":"queryNodeConfig.init (cyclomatic 46): queryNodeConfig.init has cyclomatic complexity 46 (threshold 15). Most of this is not in the body itself: 1 of the 46 points is its own statement and the rest belongs to 27 function literals inside it that branch (lines 4321, 4802, 4264, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/component_param.go"},"region":{"startLine":3896}}}],"partialFingerprints":{"codehealthFindingId/v1":"4948cf25ae5b8bd9d736b4ced31316670e331c3151fc7c74f23282f7988dd694"}},{"ruleId":"D1","level":"warning","message":{"text":"importv2.AppendNullableDefaultFieldsData (cyclomatic 45): importv2.AppendNullableDefaultFieldsData has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/util.go"},"region":{"startLine":462}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe45bd49de1a4ef6a581463f29a879ba3ca5d52d430814d3b16491413d1e30ce"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.NewFieldData (cyclomatic 45): storage.NewFieldData has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/insert_data.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"038df5b6785d246c17634138de5a48ca1497467af5bc792313b859c71b16cb70"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.fieldData (cyclomatic 45): dec.fieldData has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"e242fd9245126cdfa2caa0e81d8fcc2f4a24f3cb7d60c0280a9d4bc99db9cc6e"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.MergeFieldData (cyclomatic 45): typeutil.MergeFieldData has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2319}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c1f03b6c05d71ef80b96e21d1bd8e252558f76e001f0efe6f2e7be64e2b02d8"}},{"ruleId":"D1","level":"warning","message":{"text":"StructFieldReader.readArrayField (cyclomatic 44): StructFieldReader.readArrayField has cyclomatic complexity 44 (threshold 15). Of this number, 43 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"009bd89530f8ebe5467d4a6f6081c869ff6868cd6612740addbfe59eb03c2701"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.retrieveResults (cyclomatic 44): dec.retrieveResults has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bad396903f69dcae73194b65c256974cc3101705360fae4765f8c0dd621a15a"}},{"ruleId":"D1","level":"warning","message":{"text":"GroupAggReducer.Reduce (cyclomatic 43): GroupAggReducer.Reduce has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_reducer.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d5bcaf75eaa07500113e0c1cfe09e29be0ba9b6455b1d07e9ae6df47328e943"}},{"ruleId":"D1","level":"warning","message":{"text":"bumpSchemaVersionCompactionTask.runFullSchemaRewrite (cyclomatic 43): bumpSchemaVersionCompactionTask.runFullSchemaRewrite has cyclomatic complexity 43 (threshold 15). Of this number, 42 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"17946ab886a76068528ba76f52dff074267de26444844c8cfd1d8118a44758bc"}},{"ruleId":"D1","level":"warning","message":{"text":"indexcgowrapper.GenDataset (cyclomatic 43): indexcgowrapper.GenDataset has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/indexcgowrapper/dataset.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"b39ef6186c14795416263e3a0ee26260a27a359baf57bd9df76efa949c4aa80a"}},{"ruleId":"D1","level":"warning","message":{"text":"Client.parseSearchResult (cyclomatic 42): Client.parseSearchResult has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ba9c60fd0cea28bde8a70e3c9dc731a125dbb0a53d1eaaf37d2347bff7d163b"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldStats.UnmarshalJSON (cyclomatic 42): FieldStats.UnmarshalJSON has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_stats.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"834853b63512bfd9dbbb8c8bb1c4e08203d5e61641ee5bf68262898ef9b19b73"}},{"ruleId":"D1","level":"warning","message":{"text":"message.marshalSpecializedHeader (cyclomatic 42): message.marshalSpecializedHeader has cyclomatic complexity 42 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/message/marshal_log_object.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8a9d7a5ddd90639fc5edcc573722479c76936bdc303a3b7119a353c0f19ff44"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.updateCompactNullableVectorFieldDataByColumn (cyclomatic 42): typeutil.updateCompactNullableVectorFieldDataByColumn has cyclomatic complexity 42 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 14 belong to 6 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2105}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77d432357a6c04f446c842c3d9eb3450c0f150ee40210474b603a081ed47fd5"}},{"ruleId":"D1","level":"warning","message":{"text":"GrowingSourceSyncTask.Run (cyclomatic 41): GrowingSourceSyncTask.Run has cyclomatic complexity 41 (threshold 15). Of this number, 36 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e52221e29b653a776e8092c1826785864b8ea5c26f69a7ed74d01931c5b3809"}},{"ruleId":"D1","level":"warning","message":{"text":"alterCollectionFieldTask.PreExecute (cyclomatic 41): alterCollectionFieldTask.PreExecute has cyclomatic complexity 41 (threshold 15). Of this number, 39 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":2525}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4338d80fb254b98659fe4c7f0758e24ba4ed907fd5bc28affc495b7dffb5e27"}},{"ruleId":"D1","level":"warning","message":{"text":"validateUtil.Validate (cyclomatic 41): validateUtil.Validate has cyclomatic complexity 41 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"a67c85dc25fc1485094f62372f9fb0da58b6c539cc2381d73062960797305830"}},{"ruleId":"D1","level":"warning","message":{"text":"MilvusRoles.Run (cyclomatic 40): MilvusRoles.Run has cyclomatic complexity 40 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 10 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/roles/roles.go"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"72440cf58fd0d16f0305f6fe81dec39d53af209f2992d17893e388e3cc21a811"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.parseSearchInfo (cyclomatic 40): proxy.parseSearchInfo has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aec87bc91db62416179cfe1cd55bf829cbc65bcb987cad5c566ec2bf4e31d5d"}},{"ruleId":"D1","level":"warning","message":{"text":"validateUtil.checkArrayOfVectorFieldData (cyclomatic 40): validateUtil.checkArrayOfVectorFieldData has cyclomatic complexity 40 (threshold 15). Of this number, 36 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":1176}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc8cc170e0c1b114a76e8596b715d9c0f5851a840a353ca1c14338dbd232e22b"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.CreateFieldReaders (cyclomatic 40): parquet.CreateFieldReaders has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"3da1013ba4240b5377fccbbedea872d84cc4adbb28c06e9950d8dfe068f8ce6d"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.buildMergedScalarField (cyclomatic 40): queryutil.buildMergedScalarField has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd774ed6a58623ea1d899b4ec4d803773673dbdd964b1cd9cba710dc78cfd4e4"}},{"ruleId":"D1","level":"warning","message":{"text":"row.ParseSchema (cyclomatic 39): row.ParseSchema has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/schema.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a55438c55b26062735bacb1e0381c2430bea5a1e748c9d520c917dd3d056286"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.PrivilegeInterceptor (cyclomatic 39): proxy.PrivilegeInterceptor has cyclomatic complexity 39 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/privilege_interceptor.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"e045366ae49cd6a93dc5a646204cc65659b7d5742aa633c8910b26c2febcd73a"}},{"ruleId":"D1","level":"warning","message":{"text":"funcutil.GetNumRowOfFieldDataWithSchema (cyclomatic 39): funcutil.GetNumRowOfFieldDataWithSchema has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"8979ef4d8a619e170472dfe391803a00412c64f2801a315fc74d9387ae0fa942"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineOrRangePredicates (cyclomatic 38): visitor.combineOrRangePredicates has cyclomatic complexity 38 (threshold 15). Of this number, 35 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ff086149134d1c6a200dd0571568bfc846525488ef80809523ab7c7e14d8c2"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.FillWithDefaultValue (cyclomatic 38): proxy.FillWithDefaultValue has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec28500db673b716c1751b7dd1dcd46fb29ee8fdf14b5dd18021aea68bd9a698"}},{"ruleId":"D1","level":"warning","message":{"text":"orderByOperator.reorderResults (cyclomatic 38): orderByOperator.reorderResults has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"eef529e8c6fc6516fc1e2715df171b09af496b6a9b9793f4843a33e6a88e779e"}},{"ruleId":"D1","level":"warning","message":{"text":"searchTask.PreExecute (cyclomatic 38): searchTask.PreExecute has cyclomatic complexity 38 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd0b5838c1f44fd49f196c761f5ee023aea28a86df32a412d350d3feda0eeae2"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldData.AsSchemapb (cyclomatic 37): FieldData.AsSchemapb has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/wrap_request.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"c784bf6d0854fe53d1415a78790df71ddfdf2d5744ebad1c24f30dcbc5a0095a"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.compareFieldDataAt (cyclomatic 37): proxy.compareFieldDataAt has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2426}}}],"partialFingerprints":{"codehealthFindingId/v1":"e936c8e751e65d78402b3299e4e45200a5cf045b2bc8cdc3c874f38f5ec09462"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.FromSearchResultData (cyclomatic 37): chain.FromSearchResultData has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9416295b6326e94c71e6797bc98ff85c0d57474489f17b907277124ad1fb026"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.calcFieldElementSizeWithCompactIndex (cyclomatic 37): queryutil.calcFieldElementSizeWithCompactIndex has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1400}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb72a98a1e4ea8341f4985349d9e17937e63b342b0157231fc64e9eb43aa850"}},{"ruleId":"D1","level":"warning","message":{"text":"fastpb.unmarshalVectorField (cyclomatic 36): fastpb.unmarshalVectorField has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e02de80f85b0ffeddbf7c28e2d7efea037c289d742ad17de92fc9663c5a7de1"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.handleIfSearchByPK (cyclomatic 35): Proxy.handleIfSearchByPK has cyclomatic complexity 35 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":3361}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f0ef992d40cbb5464695e03db11bc8d37eca542c012b83fa00e822ed701899c"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.MergeSort (cyclomatic 35): storage.MergeSort has cyclomatic complexity 35 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 14 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/sort.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"af43306744790dfa6fd137a456f6f623de55afc2e7cd0d5861db6329880000ca"}},{"ruleId":"D1","level":"warning","message":{"text":"testutil.CreateInsertDataForCSV (cyclomatic 35): testutil.CreateInsertDataForCSV has cyclomatic complexity 35 (threshold 15). Of this number, 33 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1611}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eb0b3165c669f24f37f5c39d9432f9521d604b7bc9f051c8cd7209e9983ef08"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.removeArrayRow (cyclomatic 35): typeutil.removeArrayRow has cyclomatic complexity 35 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4253}}}],"partialFingerprints":{"codehealthFindingId/v1":"dae2522135807351f14daf43778cb5564563478f9ed3955050baee482679fff6"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.GetRequestInfo (cyclomatic 34): proxy.GetRequestInfo has cyclomatic complexity 34 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":3040}}}],"partialFingerprints":{"codehealthFindingId/v1":"d93fe72ee78727e957a4753587aac7b6a6e9e4a1db7956744d822501dea9371d"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.Sort (cyclomatic 34): storage.Sort has cyclomatic complexity 34 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 9 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/sort.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b8b2411e8907fbb70707cd68391edac7f7eee99c11bf439097ab58996b4e28"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.Parse (cyclomatic 34): rowParser.Parse has cyclomatic complexity 34 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"33d9a4fb2a75ef45adaeb5b999dc0339c5dc5be0008bf8ae581dcac3afe38d84"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.checkParams (cyclomatic 33): datacoord.checkParams has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f9ce7edf187fa68d5033ddf0bd6aec89cda0c4ae1d87f51eb0343b88de28016"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.validateAddFieldRequest (cyclomatic 33): proxy.validateAddFieldRequest has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":988}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce633847761e937e67a91f4fad0309a97caa8f34226c0c7cec0219665fb8292c"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.translateOutputFields (cyclomatic 33): proxy.translateOutputFields has cyclomatic complexity 33 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1639}}}],"partialFingerprints":{"codehealthFindingId/v1":"f09a1edb57ac8d1ac9b8070cdfa4ecbfd7d34b7bfcb30dd5780b9153b20f7c58"}},{"ruleId":"D1","level":"warning","message":{"text":"search_agg.compareValues (cyclomatic 33): search_agg.compareValues has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"61974bc3990051a90b04bf40985134130db4f0915591cdda080fb2ae1baa31d7"}},{"ruleId":"D1","level":"warning","message":{"text":"validateUtil.checkArrayElement (cyclomatic 33): validateUtil.checkArrayElement has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":1061}}}],"partialFingerprints":{"codehealthFindingId/v1":"de272af5b31326f519724b0f2aa36e5ffecc4a242910dcb40a38be01d12f5809"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.importFieldDataWithName (cyclomatic 33): chain.importFieldDataWithName has cyclomatic complexity 33 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"5131dc69f2d5a62e069ee6836d4f76e6457cf94bcbbd1409509bcb40a79745a3"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.estimateSizeBy (cyclomatic 33): typeutil.estimateSizeBy has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"b455afa794abe3caa3f2c96d45cf9e7c24275dd3317cfb6ae6d92204a12192fa"}},{"ruleId":"D1","level":"warning","message":{"text":"mixCoordImpl.GetMetrics (cyclomatic 32): mixCoordImpl.GetMetrics has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":731}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac91305e6bb0c7fd915fbfa05e5158c0d151931f7742464235d022f4db436e9"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndInWithEqual (cyclomatic 32): visitor.combineAndInWithEqual has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb4ba00576e59b20edf9075255eb5f3b56ddeaf72a386f8c6e66fae032847fd5"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.collapseElementLevelResultWithMetricDirection (cyclomatic 32): proxy.collapseElementLevelResultWithMetricDirection has cyclomatic complexity 32 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b2a3a5fa592d2190e9e7af93587c81a905e49ec6b22b2318aa0c0513628eafb"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.reduceRetrieveResults (cyclomatic 32): proxy.reduceRetrieveResults has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":1163}}}],"partialFingerprints":{"codehealthFindingId/v1":"9606da006d9bf0b48b8d6e4663f365c21238204a59b0ad10511bb19bab93805d"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.mapObjectStorageError (cyclomatic 32): storage.mapObjectStorageError has cyclomatic complexity 32 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/remote_chunk_manager.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"96de21a8113d68de8683bcf8a4615ec29992c7df1ddb166e3f85da057b3bea93"}},{"ruleId":"D1","level":"warning","message":{"text":"ddNode.Operate (cyclomatic 31): ddNode.Operate has cyclomatic complexity 31 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/flow_graph_dd_node.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d27c7168f34add5f328400cfada14863f919bc12b28ac71cfa5d1463307fdba"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.tryOptimizeRegexToLike (cyclomatic 31): planparserv2.tryOptimizeRegexToLike has cyclomatic complexity 31 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":720}}}],"partialFingerprints":{"codehealthFindingId/v1":"5295bcbbc78fecb1b6613911e887209d073ddebc555345002ccbce3021c59b3f"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.NewLexicalHighlighter (cyclomatic 31): proxy.NewLexicalHighlighter has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb8c2e0466a0bb14d1eb06576abce42530c62fc836f0f58354503c6722f9b660"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.checkFieldsDataBySchema (cyclomatic 31): proxy.checkFieldsDataBySchema has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1833}}}],"partialFingerprints":{"codehealthFindingId/v1":"8220c8365ee732700708bfcb9d1877bf1d5e120183d278d1700d4abbdcfe345c"}},{"ruleId":"D1","level":"warning","message":{"text":"insertTask.PreExecute (cyclomatic 31): insertTask.PreExecute has cyclomatic complexity 31 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_insert.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdc0ebd302ae82c335ef4a6de4e4f259653c54081bfffd03f37c356629e1b09f"}},{"ruleId":"D1","level":"warning","message":{"text":"QuotaCenter.collectMetrics (cyclomatic 31): QuotaCenter.collectMetrics has cyclomatic complexity 31 (threshold 15). Most of this is not in the body itself: 4 of the 31 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 473, 428, 559, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"086767c92ec48022ebd408b637b0288ab0f1127bf718e2041a8bd69d2112d8ce"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.printBinlogFile (cyclomatic 31): storage.printBinlogFile has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"1602d84cd560dc93d9366be53ee7ed6c21cbc1c83aafae4b6348fe3faa723ed0"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.BuildStatsFromFieldBinlogs (cyclomatic 31): storage.BuildStatsFromFieldBinlogs has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/statistics.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"da76ae538bccded49680f49d5e76c2a43a7b8146ae5f6500be0b99bbbaceb595"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.Parse (cyclomatic 31): rowParser.Parse has cyclomatic complexity 31 (threshold 15). Of this number, 29 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"951cb940db7e00a711aaf69a8cbef88ac92d117bad36724a83d14b40cc0b75b2"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.arrayToFieldData (cyclomatic 31): rowParser.arrayToFieldData has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcbd181a0188c723d7f719db3ede0f2839cdb513b92475e0a8b0ae07de09d00d"}},{"ruleId":"D1","level":"warning","message":{"text":"objectstorage.NewMinioClient (cyclomatic 31): objectstorage.NewMinioClient has cyclomatic complexity 31 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"59d4079518b636dc538306b599fc6f787b6e680a5a27aac06fa3ed106689387b"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.CreateIndex (cyclomatic 30): Server.CreateIndex has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2bd062ff83853eff8ba7845b87dac1d40f59a66276a5ba7b28e638cc6507ac1"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.fieldDataValueCount (cyclomatic 30): httpserver.fieldDataValueCount has cyclomatic complexity 30 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"d74c76f1eca5acb191a8ac3c1c92eba09a6f59a73e6ea62f2795c17ea3fe4191"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.FillWithNullValue (cyclomatic 30): proxy.FillWithNullValue has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b90590dd652398e0d142e4f491a1413acb27e31f5936045056e21ba6d486ea6"}},{"ruleId":"D1","level":"warning","message":{"text":"segments.getPKsFromRowBasedInsertMsg (cyclomatic 30): segments.getPKsFromRowBasedInsertMsg has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/utils.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"527bba548cb47e4bd208aa8fa9aa0e084a97a666eb1ea3e636f98dae424be411"}},{"ruleId":"D1","level":"warning","message":{"text":"InsertCodec.Serialize (cyclomatic 30): InsertCodec.Serialize has cyclomatic complexity 30 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"95bea653ee3cf9eb69fc55dc522b6cc5120076f3b34f8a5349d63d812cdd57f0"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.isArrowDataTypeConvertible (cyclomatic 30): parquet.isArrowDataTypeConvertible has cyclomatic complexity 30 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"15921d45b28485cc3c79d9347ed49545dc219e06b41b986a412ae182c12a3815"}},{"ruleId":"D1","level":"warning","message":{"text":"testutil.CreateInsertDataRowsForJSON (cyclomatic 30): testutil.CreateInsertDataRowsForJSON has cyclomatic complexity 30 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1484}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1f6ba49d4c05d097a186446588e84f8102c73fd3f1d32bf68d475109d38d63d"}},{"ruleId":"D1","level":"warning","message":{"text":"indexBuildTask.CreateTaskOnWorker (cyclomatic 29): indexBuildTask.CreateTaskOnWorker has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_index.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0e7a6267df810da841734f9297be228afaa94395e578a18b2aa24bc50934a7b"}},{"ruleId":"D1","level":"warning","message":{"text":"DataNode.CompactionV2 (cyclomatic 29): DataNode.CompactionV2 has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a5a8cdbe13e4f7260190a3c3cecbee4fa2b27cfeb8cbcd8c7a6c8cf6200def7"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.validateWholeStructFieldDataForPartialUpdate (cyclomatic 29): proxy.validateWholeStructFieldDataForPartialUpdate has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1193}}}],"partialFingerprints":{"codehealthFindingId/v1":"74944989904f63a6619aa599d8bc9c7e96d143dd4c2fb942cc5aba2376fae7b6"}},{"ruleId":"D1","level":"warning","message":{"text":"search_agg.resolveAggregationSpec (cyclomatic 29): search_agg.resolveAggregationSpec has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 6 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 262). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/context_builder.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdf43ee68b54fa7e483ccef0d05c1755300e0f759f13388b261bac06537068fc"}},{"ruleId":"D1","level":"warning","message":{"text":"searchTask.PostExecute (cyclomatic 29): searchTask.PostExecute has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":1355}}}],"partialFingerprints":{"codehealthFindingId/v1":"3abd90709279e9ac6760ad098e46bc6dc2c74d4fa9a506a2827f74721185395a"}},{"ruleId":"D1","level":"warning","message":{"text":"delegator.PruneSegments (cyclomatic 29): delegator.PruneSegments has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/segment_pruner.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"61572cdcbc845cf066c3ee1558b34febed5c6f338c8e561da05b8b4af9438bec"}},{"ruleId":"D1","level":"warning","message":{"text":"DataSorter.Swap (cyclomatic 29): DataSorter.Swap has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_sorter.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"1060f32ae1c0ba94d76d02667a43bc9b8ea215914019477a0d8e4906bb1246b5"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.sliceVectorField (cyclomatic 29): queryutil.sliceVectorField has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"d972f2e3f1587e633a914824b308f4a677f2ae535d9263709271ca6cbe0a507d"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.scalarField (cyclomatic 29): dec.scalarField has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad0537162db091bded8a7756b1b4c72aa51371ecc9eb3e41897768fc29f1154d"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.insertRequest (cyclomatic 29): dec.insertRequest has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3b302603ca11aef98e52360d9632507f257060656b0a25ecf4f6499bde47909"}},{"ruleId":"D1","level":"warning","message":{"text":"column.parseVectorArrayData (cyclomatic 28): column.parseVectorArrayData has cyclomatic complexity 28 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"af0c687f1ec6897b368ed5e86bf0fd73d21d247c9593976f5027a11e665284dc"}},{"ruleId":"D1","level":"warning","message":{"text":"RefreshExternalCollectionTask.organizeSegments (cyclomatic 28): RefreshExternalCollectionTask.organizeSegments has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"b061b30ef0f17f5a5c262251fb152e34e67d3df66c20d921f7860935e79ea0e7"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.loadStreamDelete (cyclomatic 28): shardDelegator.loadStreamDelete has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1006}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c9466ee73778de9cf132a9ae52ff89e1a7bcc3c26ca3347fa0c112a6ea1d356"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.RowBasedInsertMsgToInsertData (cyclomatic 28): storage.RowBasedInsertMsgToInsertData has cyclomatic complexity 28 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8bb2c68b09ad5c0f0197f9d7f6c0aa7dc7d84193136d1550628a2d8eb8bbc73"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldStats.UpdateByMsgs (cyclomatic 28): FieldStats.UpdateByMsgs has cyclomatic complexity 28 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_stats.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"f851a6c7dab658cb2808e696792178a95fa2f7392f4a07319dfdb99cf9e8d48c"}},{"ruleId":"D1","level":"warning","message":{"text":"numpy.validateHeader (cyclomatic 28): numpy.validateHeader has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/util.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"980d31f021f06445469d110ef905bf18986d200414fee4f845f3209846c8e0e2"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.getRowCount (cyclomatic 28): queryutil.getRowCount has cyclomatic complexity 28 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1560}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d6e5726956b090770dc165db2b50ab31d981a0a66199142353a93bdd7b098c0"}},{"ruleId":"D1","level":"warning","message":{"text":"AdaptiveRateLimitController.backgroundLoop (cyclomatic 28): AdaptiveRateLimitController.backgroundLoop has cyclomatic complexity 28 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/ratelimit/adaptive_rate_limit_controller.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f2b0158c0c1e26783a20ecc8f2b23f6e2fd1065355effea721ef2b4e74e356e"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.EstimateEntitySize (cyclomatic 28): typeutil.EstimateEntitySize has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"7612ef59777ae968f2ad3b0b2624468fd50cb5f9fc8ae444dff98af361081c20"}},{"ruleId":"D1","level":"warning","message":{"text":"SearchAggregation.protoMessage (cyclomatic 27): SearchAggregation.protoMessage has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/search_aggregation.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcbe6d068750968ee4c914e1ca6b537869512a659cffdc186269831b496ffcc9"}},{"ruleId":"D1","level":"warning","message":{"text":"columnBasedDataOption.processInsertColumns (cyclomatic 27): columnBasedDataOption.processInsertColumns has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/write_options.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"36ae18fbc016832311ad11fbb888cc474de3f0f6fc0f9f2ded8a8a717b4ff472"}},{"ruleId":"D1","level":"warning","message":{"text":"externalCollectionRefreshChecker.aggregateJobState (cyclomatic 27): externalCollectionRefreshChecker.aggregateJobState has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_checker.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1fdbeee153549196636558426605fab86c8965fcd491ef97bcf60dde2f9747c"}},{"ruleId":"D1","level":"warning","message":{"text":"clusteringCompactionTask.mappingSegment (cyclomatic 27): clusteringCompactionTask.mappingSegment has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d2a54f284a321e7d5e77b77987cb1b561a56ebc0e67231d4f8f7d4f37375155"}},{"ruleId":"D1","level":"warning","message":{"text":"mixCompactionTask.writeSegment (cyclomatic 27): mixCompactionTask.writeSegment has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"b76f694c647904c7d8f249fe1d454f910f0ea470752f3e245f3a1d6bc3cd179d"}},{"ruleId":"D1","level":"warning","message":{"text":"DataNode.CreateTask (cyclomatic 27): DataNode.CreateTask has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"79d5769e7ed2f6696c28d501df59540b90edb3bf3f4f2e099bb8a15ace2ad0b0"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.FillExpressionValue (cyclomatic 27): planparserv2.FillExpressionValue has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/fill_expression_value.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"367939259590e7709eee51154bd77f5d3a3b2e1f2d380721c357967324e51b1c"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.validateMatchPredicateElementLevel (cyclomatic 27): planparserv2.validateMatchPredicateElementLevel has cyclomatic complexity 27 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1255}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b165081f3f40099171170737d72b077c59051d945dece0f44130ac681e0ed26"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.visitBitwiseBinaryOp (cyclomatic 27): ParserVisitor.visitBitwiseBinaryOp has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1946}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d131c2576754d26ae49b41f04af55b9df3220f1d976c92b1b391bad59c0295e"}},{"ruleId":"D1","level":"warning","message":{"text":"importTask.PreExecute (cyclomatic 27): importTask.PreExecute has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_import.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f774ae03f64467cbf6d4b262be997f04a23de65ac087b0eebd534fe89863ad9"}},{"ruleId":"D1","level":"warning","message":{"text":"upsertTask.PreExecute (cyclomatic 27): upsertTask.PreExecute has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1518}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d431105fbbabfa123142e773ba6696409aaa848de1504b2d7c97e219f21d42d"}},{"ruleId":"D1","level":"warning","message":{"text":"delegator.BatchGetFromSegments (cyclomatic 27): delegator.BatchGetFromSegments has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/distribution.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"24c37d3396edf13131c936f1bfd6625dda5d0dfbac1f6408adbfa44a253647bf"}},{"ruleId":"D1","level":"warning","message":{"text":"rowParser.arrayToFieldData (cyclomatic 27): rowParser.arrayToFieldData has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"5973e5f79c6d38c82a015e8d0e322742042cb60ebd77ca32f1fc75f9faf7c8ed"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.sliceScalarField (cyclomatic 27): queryutil.sliceScalarField has cyclomatic complexity 27 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"c14890747b8565958e829586a10ffc1254ee14c78faa82959c608e79f01c8dbd"}},{"ruleId":"D1","level":"warning","message":{"text":"SliceOperator.applyElementLevelSlice (cyclomatic 27): SliceOperator.applyElementLevelSlice has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/slice_op.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba67a569aed727fecca492ce6d4bbb19cf96235ffcccd2678f9de6ac6429a922"}},{"ruleId":"D1","level":"warning","message":{"text":"optimizers.OptimizeSearchParams (cyclomatic 27): optimizers.OptimizeSearchParams has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/searchutil/optimizers/query_hook.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"1369b0d17838ff32775d837e32e2227141f7caa17345fd1f78da7ab3bf51020b"}},{"ruleId":"D1","level":"warning","message":{"text":"dec.upsertRequest (cyclomatic 27): dec.upsertRequest has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7b6427273a7cee0a3a7d7110c6fc966e8e136dd9fad10895e2fe6aee187cedc"}},{"ruleId":"D1","level":"warning","message":{"text":"funcutil.GetNumRowOfFieldData (cyclomatic 27): funcutil.GetNumRowOfFieldData has cyclomatic complexity 27 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"322c76ab73cc8dbe3bad0aab713efcdf0be71e944219c3b6475b3802aadd4649"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.CreateSparseFloatRowFromMap (cyclomatic 27): typeutil.CreateSparseFloatRowFromMap has cyclomatic complexity 27 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":3871}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f88184c68e8789dbfdd8b88449d343b61d15c1468ebb370ebb441018f2add97"}},{"ruleId":"D1","level":"warning","message":{"text":"row.AnyToColumns (cyclomatic 26): row.AnyToColumns has cyclomatic complexity 26 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/data.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7bb33b1afd4ee3e46cb44bcdb9d6549ffced110c348e6d22ac3391c35767af3"}},{"ruleId":"D1","level":"warning","message":{"text":"row.getColumnCreators (cyclomatic 26): row.getColumnCreators has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 2 of the 26 points are its own statements and the rest belongs to one function literal inside it that branches (line 199). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/data.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"789040414092a2bf3eb707629d95602f83ed366f99df1b3647a8eb126a9ef9df"}},{"ruleId":"D1","level":"warning","message":{"text":"sortCompactionTask.sortSegment (cyclomatic 26): sortCompactionTask.sortSegment has cyclomatic complexity 26 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/sort_compaction.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"69edd68a346674b574bd9547099a394fecc1382027ce4acdbcc77e37fa022252"}},{"ruleId":"D1","level":"warning","message":{"text":"importv2.CheckStructArrayConsistency (cyclomatic 26): importv2.CheckStructArrayConsistency has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/util.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"d845ce7c9ac2e4775af6e20726e59ea0dd05cd2d8c3917f897aa882a5e965827"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.ListGrant (cyclomatic 26): Catalog.ListGrant has cyclomatic complexity 26 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1689}}}],"partialFingerprints":{"codehealthFindingId/v1":"98098b45a456b18b48c58d5dbe4404ddb0be5e31f93b4d58c64f936d0630696d"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.reduceAdvanceGroupBy (cyclomatic 26): proxy.reduceAdvanceGroupBy has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6924ba4d59af6321adf5602d50ff10cec789f4571b1378c371e64d485a59af8"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.parseQueryParams (cyclomatic 26): proxy.parseQueryParams has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"833192be0ee7e7763319bd27d6f334acaf44da898a9f59b383b12f718e841acd"}},{"ruleId":"D1","level":"warning","message":{"text":"deleteRunner.Init (cyclomatic 26): deleteRunner.Init has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_delete.go"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"57ee32bc7ddbdfe8d9d2119c9296ea06ecedd0c0d13f35c395fd3341a2f7c232"}},{"ruleId":"D1","level":"warning","message":{"text":"QuotaCenter.calculateWriteRates (cyclomatic 26): QuotaCenter.calculateWriteRates has cyclomatic complexity 26 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"63ee3286b8b6369ae917521c9d180a362cdee6049a0825262f4bf7c765837709"}},{"ruleId":"D1","level":"warning","message":{"text":"binlog.verify (cyclomatic 26): binlog.verify has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/util.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5767c465db08800c927417fb4d33f061e0db0526e6079a3e71d4f36a007b3e0"}},{"ruleId":"D1","level":"warning","message":{"text":"csv.NewRowParser (cyclomatic 26): csv.NewRowParser has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"a08076058539fa1a359cdbae35de3993bda60dd6de305c703cb9145e08547262"}},{"ruleId":"D1","level":"warning","message":{"text":"MqTtMsgStream.bufMsgPackToChannel (cyclomatic 26): MqTtMsgStream.bufMsgPackToChannel has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"15381f2c55ba117fe11bf43417ddaf79af6c4e47a7322362995be0c547eea855"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.NormalizeAndValidateExternalCollectionSchema (cyclomatic 26): typeutil.NormalizeAndValidateExternalCollectionSchema has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2625}}}],"partialFingerprints":{"codehealthFindingId/v1":"4214178b5719173f971d57fd77c70477db9f289fa2b388a4a0628915fa0e5e84"}},{"ruleId":"D1","level":"warning","message":{"text":"mck.unmarshalTask (cyclomatic 25): mck.unmarshalTask has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":523}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c8e8ea3e0b91832c2df5495d51a8188ff351f013a979617e9bdd1704bf8c8e7"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.generatePlaceholderGroup (cyclomatic 25): httpserver.generatePlaceholderGroup has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1768}}}],"partialFingerprints":{"codehealthFindingId/v1":"57466c3749d24951dd5a0e688952a208fa7977253d04579c87cca8f8aa04ee05"}},{"ruleId":"D1","level":"warning","message":{"text":"writeBufferBase.growingSourceProgressSyncable (cyclomatic 25): writeBufferBase.growingSourceProgressSyncable has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":692}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e7b2940e6604b957300491e089dfba8f68dbe0cd2004117b4d8982bf71c9209"}},{"ruleId":"D1","level":"warning","message":{"text":"writeBufferBase.submitSyncTasks (cyclomatic 25): writeBufferBase.submitSyncTasks has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 4 of the 25 points are its own statements and the rest belongs to one function literal inside it that branches (line 965). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"28abd36eba3fb093b54284372d6ece729377cbea3b381d305613c5c6fcb3632e"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.Update (cyclomatic 25): Catalog.Update has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/update.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca4a141ecf1488e4ba06ae6f5b969c800453df317b1e47633e301f5842aebb64"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.FillBinaryArithOpEvalRangeExpressionValue (cyclomatic 25): planparserv2.FillBinaryArithOpEvalRangeExpressionValue has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/fill_expression_value.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"19073ef666a8538229cf7e8752f79fbf54dc40093b872755d361bb91371c547d"}},{"ruleId":"D1","level":"warning","message":{"text":"rewriter.normalizeTermExpr (cyclomatic 25): rewriter.normalizeTermExpr has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/json_term.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"73193bec98feaad822024c4af7f081446888d16937b5acb651485313bab14db5"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndInWithNotEqual (cyclomatic 25): visitor.combineAndInWithNotEqual has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5973e732ec71516f78f32a92f9d0a188c4f8a183d0e8465d59e5baeb01afc82"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.runMultiFieldGroupByHotLoop (cyclomatic 25): proxy.runMultiFieldGroupByHotLoop has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"97b7e0531baf5308e3c764d144d120ae14a0649dd32c096fa6d112d7bf54b5d4"}},{"ruleId":"D1","level":"warning","message":{"text":"PrimaryKeyStats.UnmarshalJSON (cyclomatic 25): PrimaryKeyStats.UnmarshalJSON has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/stats.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c89bb0711cd6dd4fd94c6761109b54b76f22937fb7eb30f7be3687d7854ce82"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.isSchemaEqual (cyclomatic 25): parquet.isSchemaEqual has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"1176b1ffd6c7e9463d3391c1d688f6c1a7e8c122539d25c20b56fab5249af9e4"}},{"ruleId":"D1","level":"warning","message":{"text":"StructFieldReader.toScalarField (cyclomatic 25): StructFieldReader.toScalarField has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc8fce5715aa1ad0815ba970e79b1efe2b942307622ce0fcc87c46731d18babf"}},{"ruleId":"D1","level":"warning","message":{"text":"indexparamcheck.PrepareFunctionOutputIndexParams (cyclomatic 25): indexparamcheck.PrepareFunctionOutputIndexParams has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/indexparamcheck/index_params_validation.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"39687ce6de4446283ed2215946cf55769ae0d207df7d3a2b16833b908b4ab599"}},{"ruleId":"D1","level":"warning","message":{"text":"GrpcClientConfig.Init (cyclomatic 25): GrpcClientConfig.Init has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 1 of the 25 points is its own statement and the rest belongs to 12 function literals inside it that branch (lines 267, 290, 312, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/grpc_param.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"153d0874d11ef42a6c1d2caff2fc5be488d897669ac4367d18f9302d50a5ac3c"}},{"ruleId":"D1","level":"warning","message":{"text":"Client.handleSearchResult (cyclomatic 24): Client.handleSearchResult has cyclomatic complexity 24 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 12 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ffb51119b8ee57dbaa4f998c3edb40da72c44c81f570a2e37afdda0b26431a7"}},{"ruleId":"D1","level":"warning","message":{"text":"meta.completeBumpSchemaVersionCompactionMutation (cyclomatic 24): meta.completeBumpSchemaVersionCompactionMutation has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":3391}}}],"partialFingerprints":{"codehealthFindingId/v1":"62a06125b87bed6e5cda44c2595d781a146c7c1b618999130edb355258bfa243"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.GetRecoveryInfo (cyclomatic 24): Server.GetRecoveryInfo has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"208a6f0dc7f5422f741e555be0564f38de99d279de6931e20e3bdb894645401d"}},{"ruleId":"D1","level":"warning","message":{"text":"DataNode.QueryTask (cyclomatic 24): DataNode.QueryTask has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":773}}}],"partialFingerprints":{"codehealthFindingId/v1":"050c555e2f31779d94baf4bd14a9e18dbd8bbc36d07996c1123e061ae3223658"}},{"ruleId":"D1","level":"warning","message":{"text":"BulkPackWriterV3.writeBM25Stasts (cyclomatic 24): BulkPackWriterV3.writeBM25Stasts has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc84073d8b3c8ec368c577f2bab6727b1bfc5e047f74c93abd371653d78db834"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitLogicalAnd (cyclomatic 24): ParserVisitor.VisitLogicalAnd has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1849}}}],"partialFingerprints":{"codehealthFindingId/v1":"edd3bac4ed25601f7e31af668aed3aac79d1b55c6294adf59e35c7e0b65026c3"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineOrInWithNotEqual (cyclomatic 24): visitor.combineOrInWithNotEqual has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"56a8742bd1ff8813d362ea96296a5bdd220e42208195aa6f9c31def9e4e34df0"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.reduceSearchResultDataNoGroupBy (cyclomatic 24): proxy.reduceSearchResultDataNoGroupBy has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"192bd868f1c6c6a61aae0227ebac4f2693009a3e11416bd909a36e8ddf70620e"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.validateDropField (cyclomatic 24): proxy.validateDropField has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"2697e5ae1228f04f08099d032d4e5f011bb5113fea7155507c1cbb21a46feeb7"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.validateFieldPartialUpdateOps (cyclomatic 24): proxy.validateFieldPartialUpdateOps has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert_partial_op.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e2161db888ded152d918b748f5ebb3931043d2c51aa78390def25f48e3c1c38"}},{"ruleId":"D1","level":"warning","message":{"text":"MetaCache.update (cyclomatic 24): MetaCache.update has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"42d326db60a35dfa1b01f4bfbb77034760dbed46f7cd52607139b983058dc02e"}},{"ruleId":"D1","level":"warning","message":{"text":"segments.NewMergeByPKWithOffsetsOperator (cyclomatic 24): segments.NewMergeByPKWithOffsetsOperator has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to one function literal inside it that branches (line 65). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/ignore_non_pk_ops.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"109cdeb8365aa9e9b305d6b2fbc4ad5703e8e29353b6a3c8743d291632edf2cb"}},{"ruleId":"D1","level":"warning","message":{"text":"rootcoord.executeOperatePrivilegeGroupTaskSteps (cyclomatic 24): rootcoord.executeOperatePrivilegeGroupTaskSteps has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 4 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 119). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/rbac_task.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dec12db4b2708d2cd32980df25265512e39f6026bb984d98006e6c0c025e0c1"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.broadcastAlterCollectionSchemaAdd (cyclomatic 24): Core.broadcastAlterCollectionSchemaAdd has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"3144f41b8b14e700afd94a5741da5ae1aff55aaa0c7a643742672d4bc50a5871"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.BuildRecord (cyclomatic 24): storage.BuildRecord has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 1374). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde.go"},"region":{"startLine":1369}}}],"partialFingerprints":{"codehealthFindingId/v1":"1227c3e9687328324f861bea6d95ebc93fbb6c08132b02dababba0536147ce8f"}},{"ruleId":"D1","level":"warning","message":{"text":"testutil.BuildSparseVectorData (cyclomatic 24): testutil.BuildSparseVectorData has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd097db7ec549c79252b70cc94c27570affeca94396c114f5aa81da7cfbe4bd3"}},{"ruleId":"D1","level":"warning","message":{"text":"objectstorage.NewGcpObjectStorageClient (cyclomatic 24): objectstorage.NewGcpObjectStorageClient has cyclomatic complexity 24 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a764f5bfa15e64ce1b543bda288e70e1defd819e4d0ed9104406cde75d00836"}},{"ruleId":"D1","level":"warning","message":{"text":"agg.AssembleSingleValue (cyclomatic 23): agg.AssembleSingleValue has cyclomatic complexity 23 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_util.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e33dfad59cebad75068ae50d1b9ba10f6ea398e3c74a712fd64d4f10606562f"}},{"ruleId":"D1","level":"warning","message":{"text":"garbageCollector.recycleSnapshots (cyclomatic 23): garbageCollector.recycleSnapshots has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":2041}}}],"partialFingerprints":{"codehealthFindingId/v1":"94e5ae042954d20422e359c154099dc2b1834cb99578bf9779b06ce385bde496"}},{"ruleId":"D1","level":"warning","message":{"text":"bumpSchemaVersionCompactionTask.runMissingFunctionMaterialization (cyclomatic 23): bumpSchemaVersionCompactionTask.runMissingFunctionMaterialization has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":946}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ffe60d29d4e2d04aa8e10062e666eeefacf57a553a95242df5e5cace6dc19a5"}},{"ruleId":"D1","level":"warning","message":{"text":"compactor.createTextIndex (cyclomatic 23): compactor.createTextIndex has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 9 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 133, 78). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/compactor_common.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d0ae25345f53040b8e4b9ef005a21d3c8470317c9d079f6015fa8b349b19d79"}},{"ruleId":"D1","level":"warning","message":{"text":"compactor.mergeSortMultipleSegments (cyclomatic 23): compactor.mergeSortMultipleSegments has cyclomatic complexity 23 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 6 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/merge_sort.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"606263a2430c97a26c684067944a6c4235e4e13a6aace9d94ef717438b58d92f"}},{"ruleId":"D1","level":"warning","message":{"text":"statsTask.createTextIndex (cyclomatic 23): statsTask.createTextIndex has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 11 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 506, 558). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"41fca5919a02f03f77c503152ffcfcfc8f6db6843a95263e4e303635b251c28a"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitMulDivMod (cyclomatic 23): ParserVisitor.VisitMulDivMod has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeba57c89e7b1accfdfc7aae7263ce28cced24c7f4c96c9acae43be52129aaeb"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitUnary (cyclomatic 23): ParserVisitor.VisitUnary has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1643}}}],"partialFingerprints":{"codehealthFindingId/v1":"a62f8f43ef6e26afb003fd07cd8de6bbd65528b9d7e024c64c98a4372c3bd50f"}},{"ruleId":"D1","level":"warning","message":{"text":"privilegeCache.RefreshPolicyInfo (cyclomatic 23): privilegeCache.RefreshPolicyInfo has cyclomatic complexity 23 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/privilege/cache.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fb604b9cd85741b8b99a77fd59da3a8f5c2544820249ffd33144a770a41958f"}},{"ruleId":"D1","level":"warning","message":{"text":"rerankOperator.run (cyclomatic 23): rerankOperator.run has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1218}}}],"partialFingerprints":{"codehealthFindingId/v1":"69de82bc5eefd4e2b77089398c76af2107b2aa6076c6b66237ffd34c829ac988"}},{"ruleId":"D1","level":"warning","message":{"text":"hybridAssembleOperator.run (cyclomatic 23): hybridAssembleOperator.run has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1648}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eef782df8518c3245b15cf2d2b770f5bed0c655e0a44ec600230807ef352baf"}},{"ruleId":"D1","level":"warning","message":{"text":"upsertTask.insertPreExecute (cyclomatic 23): upsertTask.insertPreExecute has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1323}}}],"partialFingerprints":{"codehealthFindingId/v1":"ada4a529b6c249643a665dc6c43e5b1ef4483d39f8516601390a0f38e52b7194"}},{"ruleId":"D1","level":"warning","message":{"text":"UpdateLoadConfigJob.Execute (cyclomatic 23): UpdateLoadConfigJob.Execute has cyclomatic complexity 23 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/job/job_update.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ab5b530332ab1ef207a90ee12742b12f455cfdc0beb7e333b5c2af2baaac4c8"}},{"ruleId":"D1","level":"warning","message":{"text":"SearchGroupByReduce.ReduceSearchResultData (cyclomatic 23): SearchGroupByReduce.ReduceSearchResultData has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa160e590b9f301bf3d37dc9ceb9886ed4362d207e482a338161289e26412972"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.TransferInsertDataToInsertRecord (cyclomatic 23): storage.TransferInsertDataToInsertRecord has cyclomatic complexity 23 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":1388}}}],"partialFingerprints":{"codehealthFindingId/v1":"c63da7a5d9606f2ef155c4c308d7914a6b90e5f44ee6a53e0a90ccefb2a64672"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadNullableBinaryData (cyclomatic 23): parquet.ReadNullableBinaryData has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":917}}}],"partialFingerprints":{"codehealthFindingId/v1":"f44848bd83aceb114d352de8a3b91c41eaae1496235d808f8f30454544e3fe87"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.readVectorArrayData (cyclomatic 23): parquet.readVectorArrayData has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2193}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2483a6e0bcb58672095cc30de88482e378ea0404e4b8bb5ea7869271e1349ae"}},{"ruleId":"D1","level":"warning","message":{"text":"MqTtMsgStream.Seek (cyclomatic 23): MqTtMsgStream.Seek has cyclomatic complexity 23 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":848}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8b28ddd5d91bc9013a58696bc50c079aa252e9f009da03bc28bd3b6d1889f7f"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.DeleteFieldData (cyclomatic 23): typeutil.DeleteFieldData has cyclomatic complexity 23 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1585}}}],"partialFingerprints":{"codehealthFindingId/v1":"84d8c623376fc37db5db11edc8260c7d4d0571fa82053595ec7c10b28c7863fc"}},{"ruleId":"D1","level":"warning","message":{"text":"clusteringCompactionPolicy.triggerOneCollection (cyclomatic 22): clusteringCompactionPolicy.triggerOneCollection has cyclomatic complexity 22 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_clustering.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8e3f427e1ea9e8e41b20d3806b198d666439b470c120ad1d84c667842ecfa8b"}},{"ruleId":"D1","level":"warning","message":{"text":"storageVersionUpgradePolicy.triggerOneCollection (cyclomatic 22): storageVersionUpgradePolicy.triggerOneCollection has cyclomatic complexity 22 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 11 belong to one function literal inside it that branches. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_storage_version.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"7953ef1f7a5ba85e52e95f6e39cfdde61fa93bc3f5b4e468c3252b5294fb3ae3"}},{"ruleId":"D1","level":"warning","message":{"text":"ServerHandler.GetQueryVChanPositions (cyclomatic 22): ServerHandler.GetQueryVChanPositions has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fcbe4a4731470573620b341c1fc2fc3bef51c88090be68145443617f69b33ab"}},{"ruleId":"D1","level":"warning","message":{"text":"importTask.QueryTaskOnWorker (cyclomatic 22): importTask.QueryTaskOnWorker has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_task_import.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d2fbe120108776f14db984ae2d3d2d019eb185baed8ec1859ef3805157ca9af"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.SaveBinlogPaths (cyclomatic 22): Server.SaveBinlogPaths has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":599}}}],"partialFingerprints":{"codehealthFindingId/v1":"41bd5eeb1dedb526131ef810be702c2c4a011d20e1319af4ce369d0d4e3416f2"}},{"ruleId":"D1","level":"warning","message":{"text":"mixCompactionTask.Compact (cyclomatic 22): mixCompactionTask.Compact has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"93fb6745bdb53c335a11077e6c22609c1fb37d56d7c822565b719dc5a64d3ca4"}},{"ruleId":"D1","level":"warning","message":{"text":"statsTask.createJSONKeyStats (cyclomatic 22): statsTask.createJSONKeyStats has cyclomatic complexity 22 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 10 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"b859ea2d34056e65dd95fdd5a533abc04a969e5701a706667bb6b7011a493027"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.buildStructSubVectorField (cyclomatic 22): httpserver.buildStructSubVectorField has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1007}}}],"partialFingerprints":{"codehealthFindingId/v1":"012f1bf6c57b82da3271e4c4261589bf0a7557ab35cd9ca86f20978417f63a30"}},{"ruleId":"D1","level":"warning","message":{"text":"structArrayRowAccessor.row (cyclomatic 22): structArrayRowAccessor.row has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1451}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf32e82ea618eb08666cce7068a4ede42c03f8af08700f38564959a5fb9869d9"}},{"ruleId":"D1","level":"warning","message":{"text":"writebuffer.PrepareInsert (cyclomatic 22): writebuffer.PrepareInsert has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1704}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d25f8d4b21d0ffe5bf6a80e8eea9d43ed56387dcfd4d8651907576db3a1d744"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.getColumnInfoFromJSONIdentifier (cyclomatic 22): ParserVisitor.getColumnInfoFromJSONIdentifier has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2120}}}],"partialFingerprints":{"codehealthFindingId/v1":"077ca920ec92292ec4acd90915551a754c99d7032791660a857e926181f53e9a"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.newBuiltInPipeline (cyclomatic 22): proxy.newBuiltInPipeline has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":3631}}}],"partialFingerprints":{"codehealthFindingId/v1":"48f20051c54089c279417eebadcf47ce3367c3f0c289dd492645585cbffff57a"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.parseGroupByInfo (cyclomatic 22): proxy.parseGroupByInfo has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":881}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecad040d52674f694a601b86ecca5af71b3f0d3a92f47ee5a0354c4ca3eb0eb9"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.GenNullableFieldData (cyclomatic 22): proxy.GenNullableFieldData has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"be0909fd52701f3beea1c42881ae7d33c04c987606fe1fe1e10ace6b8021c4bc"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.DumpMessages (cyclomatic 22): Proxy.DumpMessages has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":7075}}}],"partialFingerprints":{"codehealthFindingId/v1":"957fd7207be59cae5d755b6412dff2879fa81bf0f82912551f6157f77c02814e"}},{"ruleId":"D1","level":"warning","message":{"text":"SimpleLimiter.Check (cyclomatic 22): SimpleLimiter.Check has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/simple_rate_limiter.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"70aea42418af641ff006e7ad0850831814b75a71f882a7542c6d5d6cf67b11e2"}},{"ruleId":"D1","level":"warning","message":{"text":"SearchCommonReduce.ReduceSearchResultData (cyclomatic 22): SearchCommonReduce.ReduceSearchResultData has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fe0d422cce73e360215ff8ee8f2bc77a420d10611734e7c8b9a44e3ba7507cc"}},{"ruleId":"D1","level":"warning","message":{"text":"rootcoord.CheckTimeTickLagExceeded (cyclomatic 22): rootcoord.CheckTimeTickLagExceeded has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 8 of the 22 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 255, 278, 307). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c27284487005d0a16fedc9fe85edbad6e43a3978075c4648460e3ed8f18935d"}},{"ruleId":"D1","level":"warning","message":{"text":"createCollectionTask.prepareSchema (cyclomatic 22): createCollectionTask.prepareSchema has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c1ac54fb408c1fa6321f9f0d9ffa3933c1fe1fa3e8e63daf39519c40cf19eae"}},{"ruleId":"D1","level":"warning","message":{"text":"MetaTable.reload (cyclomatic 22): MetaTable.reload has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f891e5027815c54567968966a702b995d3e863e29cc434910abb9b6a37bc46f"}},{"ruleId":"D1","level":"warning","message":{"text":"SortOp.Execute (cyclomatic 22): SortOp.Execute has cyclomatic complexity 22 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_sort.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"a203c7af4fc315b6c99b75ffc023c5deacced77dc9715df472019d8e6a9f86f4"}},{"ruleId":"D1","level":"warning","message":{"text":"reader.readDelete (cyclomatic 22): reader.readDelete has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 10 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 206). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/reader.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"87dc0c8103fd09f0b286ccb99f0339a341a26cd99ad58ade3b1366846c3955fb"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.parseSparseFloatVectorStructRow (cyclomatic 22): parquet.parseSparseFloatVectorStructRow has cyclomatic complexity 22 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1023}}}],"partialFingerprints":{"codehealthFindingId/v1":"a55229d2dd474e017e58366af4b1131a2d9edef77c0fc9b2912c0d30409b55a2"}},{"ruleId":"D1","level":"warning","message":{"text":"schemautil.validateKeptEvolutionFields (cyclomatic 22): schemautil.validateKeptEvolutionFields has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/schemautil/schema_evolution.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"f060c89da2d33607c8dd5287333be1827250b1c348a0b73dbbbd9cf07f690fc9"}},{"ruleId":"D1","level":"warning","message":{"text":"Session.ProcessActiveStandBy (cyclomatic 22): Session.ProcessActiveStandBy has cyclomatic complexity 22 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 9 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"68ac2b7293fbbdedb466cec9b8e162c6fcbf2b25903354b673b67558a50d6d79"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.PrepareResultFieldData (cyclomatic 22): typeutil.PrepareResultFieldData has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aa0cb012573e96dd47bf6ecbc41eebd05a0f5054a1174730c852fd1748cc6cc"}},{"ruleId":"D1","level":"warning","message":{"text":"FieldDataBuilder.Build (cyclomatic 22): FieldDataBuilder.Build has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/field_data.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d24c872c58c6ee7be085fb746515d505b00a079d1b779373471a887e75d97a8"}},{"ruleId":"D1","level":"warning","message":{"text":"importChecker.checkGC (cyclomatic 21): importChecker.checkGC has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_checker.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"12f1c6703f26138e2564b071ca3de508a19bb04fb40d797f2e0d1d07ffe5394e"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.completeIndexInfo (cyclomatic 21): Server.completeIndexInfo has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"1198188d0d8fb45fceae8734bf153387b0476f7ec1387ede7bc9a2517ded39a7"}},{"ruleId":"D1","level":"warning","message":{"text":"statsTask.SetJobInfo (cyclomatic 21): statsTask.SetJobInfo has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_stats.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd714dd4fd6723a7cc1054a19d0cb99d811fbe6cccc20615a4d67420c20e09e5"}},{"ruleId":"D1","level":"warning","message":{"text":"external.buildFunctionExecutionSchema (cyclomatic 21): external.buildFunctionExecutionSchema has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/function_executor.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd2ce47b886f023ceb4b013f751b221964cac9332250dec19d0b03368f08f51"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.convertSearchAggregationReq (cyclomatic 21): httpserver.convertSearchAggregationReq has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3639}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2e40ba570021b63afe05db490c9bd3cc1d71d9a0d589e31e94c7cc2c8c09a1d"}},{"ruleId":"D1","level":"warning","message":{"text":"replicateService.overwriteReplicateMessage (cyclomatic 21): replicateService.overwriteReplicateMessage has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/replicate_service.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"529fbdb786fef727ca301d341ba35c5c9cdd6dac09838cccc5119903d1c3dbdb"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.CreateSearchPlanArgs (cyclomatic 21): planparserv2.CreateSearchPlanArgs has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/plan_parser_v2.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"69572c33aa0bae82ed0f3de2dd7efc9487dc51122b5d2be3fe234179dd022b5e"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitLogicalOr (cyclomatic 21): ParserVisitor.VisitLogicalOr has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1785}}}],"partialFingerprints":{"codehealthFindingId/v1":"569310c2e27e94de3bb57cf92adaab175e2d8d8c222d8a3215c142fafd5bc8c5"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.compareJSONValues (cyclomatic 21): proxy.compareJSONValues has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2143}}}],"partialFingerprints":{"codehealthFindingId/v1":"139fc30665ffca8f3adbb5234f8764ebf490663278fd086a86e44f52075ef83b"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.InvalidateCollectionMetaCache (cyclomatic 21): Proxy.InvalidateCollectionMetaCache has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd5c150b99df2027578d5a77afe8fefa8534a88ce75cc4a3ca68c358653bf13d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelLevelScoreBalancer.BalanceReplica (cyclomatic 21): ChannelLevelScoreBalancer.BalanceReplica has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/balance/channel_level_score_balancer.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa3506dd1c16811967c0e8e9b93440922edf1b09558a9b5751ae88a20a563f21"}},{"ruleId":"D1","level":"warning","message":{"text":"CoordinatorBroker.GetCollectionLoadInfo (cyclomatic 21): CoordinatorBroker.GetCollectionLoadInfo has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/coordinator_broker.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"51b07c368de40e79fa42ad541b3b35ae0fb8b84d27c7a81ea6f6c7dfe8638e60"}},{"ruleId":"D1","level":"warning","message":{"text":"MetaTable.CheckIfRBACRestorable (cyclomatic 21): MetaTable.CheckIfRBACRestorable has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":2151}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3a8edb884c8916a93fffdbd456d02cd6f2e2f354a1eae9d518bfa2eb0837f08"}},{"ruleId":"D1","level":"warning","message":{"text":"StatisticsCollector.Digest (cyclomatic 21): StatisticsCollector.Digest has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/statistics.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"29b659e24b47c580e9f9594a351c3d69d8e20a1e806113384e780e2c8c1c8e15"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.exportFieldData (cyclomatic 21): chain.exportFieldData has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d2300c2b1309e3c98d8e3da419e499f74d07c963960641cd3b5b1d55a891a4b"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.buildVectorArrayFieldFromList (cyclomatic 21): parquet.buildVectorArrayFieldFromList has cyclomatic complexity 21 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2398}}}],"partialFingerprints":{"codehealthFindingId/v1":"3033097f08fbf2903e5c7808de360f6d0d76fe8d5e539249e8e24581cc8e4d96"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.compareValues (cyclomatic 21): queryutil.compareValues has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1636}}}],"partialFingerprints":{"codehealthFindingId/v1":"d74a5a1e6c9113e638310e46678c678899d43326b803275364afb175e9ac5c8b"}},{"ruleId":"D1","level":"warning","message":{"text":"ReduceByPKWithTimestampOperator.mergeByPKWithTimestamp (cyclomatic 21): ReduceByPKWithTimestampOperator.mergeByPKWithTimestamp has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/reduce_by_pk_op.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"4074576c730589227f81575788724deb1460139aeb8daeb98982f645477273bb"}},{"ruleId":"D1","level":"warning","message":{"text":"retentionInfo.expiredCleanUp (cyclomatic 21): retentionInfo.expiredCleanUp has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_retention.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6cdce58e48f858f6f3f05e4ee8b4a5da6b2a0d56c78e642fe8afecf8a2d40fe"}},{"ruleId":"D1","level":"warning","message":{"text":"retry.Do (cyclomatic 21): retry.Do has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/retry/retry.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"f43839ef68203f805f1a60cd22caf6bf0c51f9d6a4b811584a35ecb1faa1c4ff"}},{"ruleId":"D1","level":"warning","message":{"text":"compactionTrigger.handleSignal (cyclomatic 20): compactionTrigger.handleSignal has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"3642761e5780886788ddb466b4c2b30de0bff8f2a228dddbfb29c731031075a8"}},{"ruleId":"D1","level":"warning","message":{"text":"meta.UpdateChannelCheckpoints (cyclomatic 20): meta.UpdateChannelCheckpoints has cyclomatic complexity 20 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 8 belong to 3 function literals inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":2885}}}],"partialFingerprints":{"codehealthFindingId/v1":"288f3e5b46fdc497591c20e19476b2bc379755688752163e6a4d5caa78d1437f"}},{"ruleId":"D1","level":"warning","message":{"text":"snapshotManager.RestoreSnapshot (cyclomatic 20): snapshotManager.RestoreSnapshot has cyclomatic complexity 20 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c437ee4aad534b8004063cd0d4a71daa7750362ebf01cb56b2554ffd7730aa6"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.buildStructSubArrayScalar (cyclomatic 20): httpserver.buildStructSubArrayScalar has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":932}}}],"partialFingerprints":{"codehealthFindingId/v1":"76ae269c8dafb54a73e21d49d6396ace1e26a5882d4c3a1e8c88e27398760dfa"}},{"ruleId":"D1","level":"warning","message":{"text":"HandlersV1.upsert (cyclomatic 20): HandlersV1.upsert has cyclomatic complexity 20 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":815}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd5c4f87f20a636d305f25b47defe38767515bb967a4799f54fda636aed7ef4b"}},{"ruleId":"D1","level":"warning","message":{"text":"HandlersV2.advancedSearch (cyclomatic 20): HandlersV2.advancedSearch has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2117}}}],"partialFingerprints":{"codehealthFindingId/v1":"80ee58373fb2325fffc0a0abdf791cf52a7ab10b09588dff0fc6943a98d69068"}},{"ruleId":"D1","level":"warning","message":{"text":"writeNode.Operate (cyclomatic 20): writeNode.Operate has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/flow_graph_write_node.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f3249457b81687d9760c428cdc407b96072e1cfa39ff593ac393168a32f5e31"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.alterModifyCollection (cyclomatic 20): Catalog.alterModifyCollection has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"dddf63df8853652b0859ab6c569e0d427472c299138cf47adb4b603f7bf0cf34"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.convertHanToASCII (cyclomatic 20): planparserv2.convertHanToASCII has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":862}}}],"partialFingerprints":{"codehealthFindingId/v1":"1660756884bc1db93aa84db2379ff7389f220e5ce1a764045805c41b4b8aabcb"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitAddSub (cyclomatic 20): ParserVisitor.VisitAddSub has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed6c9ffc3ab0285e80a478a6d31968e89fa9089d89845056eaf669aeedd7e911"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.visitUnaryExpr (cyclomatic 20): visitor.visitUnaryExpr has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/entry.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"72e806fc92d4e8aa6bcd8a127fb9a6f96fc2ecdee6200908b395fa2dadc845ff"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndInWithIn (cyclomatic 20): visitor.combineAndInWithIn has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"eda4325302db59712b0410a35ba257a37fdb9d8775d1a359b6cde0c30ebc3e7e"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.serializeBucketKey (cyclomatic 20): proxy.serializeBucketKey has cyclomatic complexity 20 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":966}}}],"partialFingerprints":{"codehealthFindingId/v1":"61ca85314624459fe7b2ab0a3fce084798ba735b9afa63d909dfbe604a4346f0"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.runSingleFieldGroupByHotLoop (cyclomatic 20): proxy.runSingleFieldGroupByHotLoop has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"930eb4469773d796b313adc0a31dd2d875015e10c2d6bb77de0c9345fbd4d77e"}},{"ruleId":"D1","level":"warning","message":{"text":"LBPolicyImpl.selectNode (cyclomatic 20): LBPolicyImpl.selectNode has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 3 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 161). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/lb_policy.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"998f4aff46477567be58bc80b1f37e5e7deccac9039cddb1615406056e46b0ae"}},{"ruleId":"D1","level":"warning","message":{"text":"TargetObserver.schedule (cyclomatic 20): TargetObserver.schedule has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/target_observer.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dd350c028a7afaaa129a51bc1001adc9a490d8f65b25828711e3ded5597de0f"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.broadcastAlterCollectionForAddField (cyclomatic 20): Core.broadcastAlterCollectionForAddField has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_add_field.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"257cf25781969c8aeb6f554319e443f281c331ac798dbbe62f728763b5522683"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.broadcastAlterCollectionV2ForAlterCollectionField (cyclomatic 20): Core.broadcastAlterCollectionV2ForAlterCollectionField has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_field.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aab804a312d000aff04d699cb50d78e6373762951c5610d12561e72753f792f"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.getCurrentUserVisibleCollections (cyclomatic 20): Core.getCurrentUserVisibleCollections has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":3310}}}],"partialFingerprints":{"codehealthFindingId/v1":"88c6930b083e1fa848af014a9b2a4aeb77d5b19621598bff549a57ca1a844fae"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.RecordToInsertData (cyclomatic 20): storage.RecordToInsertData has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/record_to_insert.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f80a200fd4af27fed872fe75885612b230fa253966b093e714c1cbdb8de1f6f"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.ValueSerializer (cyclomatic 20): storage.ValueSerializer has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_events.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e2d46035684eff28def93e22cb349f44c286eb157e6b0dc3852ae038e028026"}},{"ruleId":"D1","level":"warning","message":{"text":"balancerImpl.execute (cyclomatic 20): balancerImpl.execute has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/balancer_impl.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fae5b58c03b7960397f1ac0624307a17363ddb330885ad88a049ca28fb76849"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.parseDecayParams (cyclomatic 20): chain.parseDecayParams has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"83c2a717d62e7566b822a969542f4278aa3f46a736e4c945b500a439abdb24a5"}},{"ruleId":"D1","level":"warning","message":{"text":"validator.ValidateFunction (cyclomatic 20): validator.ValidateFunction has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/validator.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e8393dfc8aa50b45c66d6b3c3dd11f8e9b099d47e55a30148795590e62f1622"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadNullableIntegerOrFloatData (cyclomatic 20): parquet.ReadNullableIntegerOrFloatData has cyclomatic complexity 20 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"674d3f0c6a0eca530a67ca92d3f307844626b7efa079571ab9bb2443d3a27007"}},{"ruleId":"D1","level":"warning","message":{"text":"StructFieldReader.readArrayOfVectorField (cyclomatic 20): StructFieldReader.readArrayOfVectorField has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"2212ed8947a8cacc2a783707e8aed7551db1118887b12d9eb0df745899618658"}},{"ruleId":"D1","level":"warning","message":{"text":"retry.Handle (cyclomatic 20): retry.Handle has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/retry/retry.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b2a645c12cc245c4c6ca713c8511ba9b6981bfe1114b7942716ad296c41e29c"}},{"ruleId":"D1","level":"warning","message":{"text":"milvusclient.newStructSubColumn (cyclomatic 19): milvusclient.newStructSubColumn has cyclomatic complexity 19 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/write_options.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"87d3099d98b3a22e85eef8cde9f05a47eaf88820393e5421668d8a401bce4a45"}},{"ruleId":"D1","level":"warning","message":{"text":"mixCoordImpl.HandleReplicaLoadConfigCompliance (cyclomatic 19): mixCoordImpl.HandleReplicaLoadConfigCompliance has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_replica.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8a079807c594b20a870188b3761749d67dfd5994d9569dfdcdad02f58e84a2a"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.retrieveSegment (cyclomatic 19): datacoord.retrieveSegment has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 2 of the 19 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 276, 305, 255). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7f772321c2061796cf3ce022896b196803ec6db8f86ccbfb180e876bb274833"}},{"ruleId":"D1","level":"warning","message":{"text":"compactionInspector.schedule (cyclomatic 19): compactionInspector.schedule has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"90c8acd1a030700471cc880e5ced0cb704497cd6cc4629ec7c4a622c90ad56ae"}},{"ruleId":"D1","level":"warning","message":{"text":"singleCompactionPolicy.triggerOneCollection (cyclomatic 19): singleCompactionPolicy.triggerOneCollection has cyclomatic complexity 19 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_single.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"6eccde9fb0d329e5fa28db4a003f1e63cc5dd9995327c5ac518efe8af3046436"}},{"ruleId":"D1","level":"warning","message":{"text":"bumpSchemaVersionTask.QueryTaskOnWorker (cyclomatic 19): bumpSchemaVersionTask.QueryTaskOnWorker has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"70f263d9beaeb9c2b064a70f066da0fbfdbbcafa3242d1b48c437d386e9e4981"}},{"ruleId":"D1","level":"warning","message":{"text":"clusteringCompactionTask.QueryTaskOnWorker (cyclomatic 19): clusteringCompactionTask.QueryTaskOnWorker has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"1307532874cc5421383a23954e508ce87c9ce0d67424c4f1ad0b2219d57e2172"}},{"ruleId":"D1","level":"warning","message":{"text":"ServerHandler.GenSnapshot (cyclomatic 19): ServerHandler.GenSnapshot has cyclomatic complexity 19 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 3 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":724}}}],"partialFingerprints":{"codehealthFindingId/v1":"11d3297724e94a8715a42ea06a7fc32ff2b9d84d0884c252f20b633e112f8fcb"}},{"ruleId":"D1","level":"warning","message":{"text":"importv2.buildIndexInfoFromSource (cyclomatic 19): importv2.buildIndexInfoFromSource has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6f42ecd7aceace32851b7a7bb40be9446c41167b913c98f436ccb1d2a52fce"}},{"ruleId":"D1","level":"warning","message":{"text":"statsTask.sort (cyclomatic 19): statsTask.sort has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"9afbc25e9dfc4532fca3e7fc99eb310acbafc40919cadcc028c224e017cd2fa6"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.encodeEmbListQuery (cyclomatic 19): httpserver.encodeEmbListQuery has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1221}}}],"partialFingerprints":{"codehealthFindingId/v1":"b348e98f86e33a76952e551407c3f02afed262988d69810d1f5cfd6dfa5aaf32"}},{"ruleId":"D1","level":"warning","message":{"text":"GrowingSourceSyncTask.fillPrimaryKeyStatsConfig (cyclomatic 19): GrowingSourceSyncTask.fillPrimaryKeyStatsConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":940}}}],"partialFingerprints":{"codehealthFindingId/v1":"d13f0dd3bbeb35cde9cd87350598da7132b8c41857bb535b0c5d2da427035c41"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.convertArrayValue (cyclomatic 19): planparserv2.convertArrayValue has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/convert_field_data_to_generic_value.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"758b57ccd7b0b1f6e850729d0025554cc0dd8d33ae2cb01bcc9f588e5fd72306"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.parseElementScope (cyclomatic 19): proxy.parseElementScope has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/struct_hybrid_search.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7c0bc21c84eb15433fea086ff0963ba1519042a8a9ba832b24d52096637f0d8"}},{"ruleId":"D1","level":"warning","message":{"text":"SearchAggregationComputer.compareRowsForTopHits (cyclomatic 19): SearchAggregationComputer.compareRowsForTopHits has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8c072990986a0ff2199e8d81f8d37690af2b23a14f61bfe2595d1e31581e365"}},{"ruleId":"D1","level":"warning","message":{"text":"createCollectionTask.validatePartitionKey (cyclomatic 19): createCollectionTask.validatePartitionKey has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"63a9a86c4ff2c9955fbbddf96b9ae52b21aee7098ce657378a3b44392ca66550"}},{"ruleId":"D1","level":"warning","message":{"text":"alterCollectionSchemaTask.preExecuteAdd (cyclomatic 19): alterCollectionSchemaTask.preExecuteAdd has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1155}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e838fc2385b8d13f3a8e676e6e6869d23b541c404b1c641aebef674ed1b4932"}},{"ruleId":"D1","level":"warning","message":{"text":"task.applyCollectionWarmupSetting (cyclomatic 19): task.applyCollectionWarmupSetting has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/utils.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"182172dde98458d6ce06a3d31eafe664ec2856532520ffc5b4b92f75497342d4"}},{"ruleId":"D1","level":"warning","message":{"text":"tasks.extractSlice (cyclomatic 19): tasks.extractSlice has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/search_task_go_reduce.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"12a50721db066238a487681a9327ac903d853fa28f9ee1da44715b4276172104"}},{"ruleId":"D1","level":"warning","message":{"text":"rootcoord.buildAlterSchemaAddSchema (cyclomatic 19): rootcoord.buildAlterSchemaAddSchema has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"c791b1a6af63caafbf38d5f7bb7b432a908aae53dde187f8f504e2c856dbcdc8"}},{"ruleId":"D1","level":"warning","message":{"text":"QuotaCenter.getTimeTickDelayFactor (cyclomatic 19): QuotaCenter.getTimeTickDelayFactor has cyclomatic complexity 19 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1000}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bd53680572acf47c62beb18e6a5c05d3257df73c284405a8dcbeef517127d67"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.prepareBoundFieldIndex (cyclomatic 19): Core.prepareBoundFieldIndex has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fb7c4394016ab4594d4d30e5a338822090908951d57eea3798259b5b22557df"}},{"ruleId":"D1","level":"warning","message":{"text":"timeTickAppendInterceptor.DoAppend (cyclomatic 19): timeTickAppendInterceptor.DoAppend has cyclomatic complexity 19 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 3 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/interceptors/timetick/timetick_interceptor.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"418d8e10ba3fb052927ad1f4058eeba2f4ea7a75070bce8f094929437265537d"}},{"ruleId":"D1","level":"warning","message":{"text":"FuncChain.ExecuteWithOptions (cyclomatic 19): FuncChain.ExecuteWithOptions has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/chain.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"b843c104a6ab022f55a5891e4df287938984f7cfe87183a7c2b243327b82c3f6"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.ToSearchResultDataWithOptions (cyclomatic 19): chain.ToSearchResultDataWithOptions has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"802a81b205dca51c1604219feca35e24f081d9b807683527d289b28c3b90c977"}},{"ruleId":"D1","level":"warning","message":{"text":"embedding.NewVertexAIEmbeddingProvider (cyclomatic 19): embedding.NewVertexAIEmbeddingProvider has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/vertexai_embedding_provider.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e56174cef479dcf87954189970667f0a535abfa11571a6ae73b4c5315caeed0"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadNullableSparseFloatVectorData (cyclomatic 19): parquet.ReadNullableSparseFloatVectorData has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"783d3a05980a24f98f68c52f0926b4aa6101c91b431ac4a2208df1d20efb0b30"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.buildVectorArrayFieldFromFixedSizeBinary (cyclomatic 19): parquet.buildVectorArrayFieldFromFixedSizeBinary has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2315}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c9eeca3d749a4d433267710c7fb555b2b1a5f55b31f7e5d8301e67859fa7296"}},{"ruleId":"D1","level":"warning","message":{"text":"DeduplicatePKOperator.Run (cyclomatic 19): DeduplicatePKOperator.Run has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/dedup_pk_op.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a877e57991fe714f569554eae1fb5658a27654b5f501d43065772476e028f94"}},{"ruleId":"D1","level":"warning","message":{"text":"schemautil.validateAddedEvolutionFields (cyclomatic 19): schemautil.validateAddedEvolutionFields has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/schemautil/schema_evolution.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d1c83e402a063291aeaa36b6da15d0227311a02fb59ddf173cb21b65cf0364b"}},{"ruleId":"D1","level":"warning","message":{"text":"Dispatcher.work (cyclomatic 19): Dispatcher.work has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/dispatcher.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"122367144354271dbf5c3098ade59d076cf541689a09f3868b62f6765d2252d1"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.appendArrayRow (cyclomatic 19): typeutil.appendArrayRow has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4182}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2c8dde02ce42796b22d13b5bc5f620651b72eeeb51a1b9743679c0f28919c7c"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.updateStatsResultIfManifestMatches (cyclomatic 18): datacoord.updateStatsResultIfManifestMatches has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to one function literal inside it that branches (line 582). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_stats.go"},"region":{"startLine":581}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a61e87410f2a992936194482805ba318c0d25fb97598eb1867635d271360a77"}},{"ruleId":"D1","level":"warning","message":{"text":"clusteringCompactionTask.doClean (cyclomatic 18): clusteringCompactionTask.doClean has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"c32977410ca90235cd2dd448f607c81f0eea65b04197865b1ce9f3caaf386c89"}},{"ruleId":"D1","level":"warning","message":{"text":"compactionTrigger.ShouldRebuildSegmentIndex (cyclomatic 18): compactionTrigger.ShouldRebuildSegmentIndex has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"27bddead6179be1873b21ecc259aed3414c2780e527377be8d7405b44eed1c7a"}},{"ruleId":"D1","level":"warning","message":{"text":"garbageCollector.recycleDroppedSegments (cyclomatic 18): garbageCollector.recycleDroppedSegments has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":847}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a6312120f7e2adc58fe37f955af485cef67f195aae96da0298b864b37e74144"}},{"ruleId":"D1","level":"warning","message":{"text":"compactor.selectFullRewriteRecord (cyclomatic 18): compactor.selectFullRewriteRecord has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"258e203d65c2f94f0f9256b1218dabcd3e3169bae6b4db9087a4f74ab68eeeeb"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.convertDefaultValue (cyclomatic 18): httpserver.convertDefaultValue has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3118}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ac8e93f359acf1182907bf9e780edcfe983ecf83b050145eb0c0b47a492b184"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.AlterGrant (cyclomatic 18): Catalog.AlterGrant has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1611}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f853bc2461fc8865966256e09233942c98f110c7b4e8ac102f5149be2b24e42"}},{"ruleId":"D1","level":"warning","message":{"text":"rewriter.cmpGeneric (cyclomatic 18): rewriter.cmpGeneric has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad2dd2a269d3354427a349d4eb75e4b6bc5b4f5f3d30ff7e17b40c501844c772"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineOrInWithEqual (cyclomatic 18): visitor.combineOrInWithEqual has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"663fb40e4ae99212631772ccb07208ea8dbf4da6c08fa8eae99e021d75bf0b72"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.ValidateFieldsInStruct (cyclomatic 18): proxy.ValidateFieldsInStruct has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":676}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b200b67f939695d498a252304a3ffa01181ab0fd09bcbe93518fd517b851d73"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.LackOfFieldsDataBySchema (cyclomatic 18): proxy.LackOfFieldsDataBySchema has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2300}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e6280c78f2661b761a188c0f0752e2bfcaccc4e4442cb1f59bf20ec928e0169"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.search (cyclomatic 18): Proxy.search has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2883}}}],"partialFingerprints":{"codehealthFindingId/v1":"a78f6eda571612bcc0dad2b2b7bcada39b9d7f54b63e86967849ea2d14dafe7c"}},{"ruleId":"D1","level":"warning","message":{"text":"SearchAggregationComputer.computeLevel (cyclomatic 18): SearchAggregationComputer.computeLevel has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"6899c7aab276d8580a2d69add796de304266c0226d696d450534e7014e94a3be"}},{"ruleId":"D1","level":"warning","message":{"text":"LookAsideBalancer.SelectNode (cyclomatic 18): LookAsideBalancer.SelectNode has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/look_aside_balancer.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"79de1ea042b316532ad408e33aecbab52f0759a4523029bf27f073c94f582da4"}},{"ruleId":"D1","level":"warning","message":{"text":"loadPartitionsTask.Execute (cyclomatic 18): loadPartitionsTask.Execute has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3439}}}],"partialFingerprints":{"codehealthFindingId/v1":"9605bd1c3531c288e4720e6fc6f728cc6f4197f43d37c4e6e2b51920b1cac131"}},{"ruleId":"D1","level":"warning","message":{"text":"IndexChecker.checkReplica (cyclomatic 18): IndexChecker.checkReplica has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/index_checker.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"e54df2d86c25510cf1b3a648d8b4de0652c33f211c55f167a78140dfa868fc17"}},{"ruleId":"D1","level":"warning","message":{"text":"LoadCollectionJob.Execute (cyclomatic 18): LoadCollectionJob.Execute has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/job/job_load.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"398b7fccc46af7b8e39dee4baa7a72605b13193c744ce518aa63fdff232cb86a"}},{"ruleId":"D1","level":"warning","message":{"text":"CollectionManager.Recover (cyclomatic 18): CollectionManager.Recover has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/collection_manager.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae2f94336351dc14e384613bc4b47a758869946f981dbcecb39f382b1ebbb44"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.GetHighlight (cyclomatic 18): shardDelegator.GetHighlight has cyclomatic complexity 18 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1485}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a4bb4e9e2f7364eb55118c17b744310400207812472df0521308c6fbb08895e"}},{"ruleId":"D1","level":"warning","message":{"text":"tasks.heapMergeReduceRange (cyclomatic 18): tasks.heapMergeReduceRange has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/heap_merge_reduce.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"8551e91722590b6f8b995d8b473a02398874953a222b04da6319e44a316d35bf"}},{"ruleId":"D1","level":"warning","message":{"text":"rootcoord.buildSchemaForDropField (cyclomatic 18): rootcoord.buildSchemaForDropField has cyclomatic complexity 18 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"5df0b38a65ee630a46be3bd9a3df444010b3fac31156cd7474c74b9df079f36d"}},{"ruleId":"D1","level":"warning","message":{"text":"createCollectionTask.prepareMilvusTableSnapshotSchema (cyclomatic 18): createCollectionTask.prepareMilvusTableSnapshotSchema has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"06eefa7ed0aaa8860d9c8475d6589b41d20b3b0ba27cba3fb71cfd896dd3d015"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.ConvertToArrowSchemaWithNameResolver (cyclomatic 18): storage.ConvertToArrowSchemaWithNameResolver has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 6 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 34). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/schema.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"7695358c3455d9647e87dd64563e0158ff66b1bbd53c1a33308536763131e08e"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetBinaryVectorFromPayload (cyclomatic 18): PayloadReader.GetBinaryVectorFromPayload has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":682}}}],"partialFingerprints":{"codehealthFindingId/v1":"7581a1ded87523bb2c27b2d3df8e2742be7e4989ead91a5615f97d51bc30dbed"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetFloat16VectorFromPayload (cyclomatic 18): PayloadReader.GetFloat16VectorFromPayload has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"38ab8ef0effe7ee0f5a3b5dc823b791bcabfa18446edff60d95323ee3a39ed4d"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetBFloat16VectorFromPayload (cyclomatic 18): PayloadReader.GetBFloat16VectorFromPayload has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":859}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a90d6683933bff16245b1326190b94031dd2a57134a3159df8c4435aadf2900"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetFloatVectorFromPayload (cyclomatic 18): PayloadReader.GetFloatVectorFromPayload has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":947}}}],"partialFingerprints":{"codehealthFindingId/v1":"baebae1a8e8029e3fad90da0371c6aee7bd4acd179303613900e0d0fb68c597c"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetInt8VectorFromPayload (cyclomatic 18): PayloadReader.GetInt8VectorFromPayload has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1114}}}],"partialFingerprints":{"codehealthFindingId/v1":"695c80f738e4a6e5aced01fbf3688a808635d4e6eddd56db8fb757b452d0b520"}},{"ruleId":"D1","level":"warning","message":{"text":"policy.Balance (cyclomatic 18): policy.Balance has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/policy/vchannelfair/vchannel_fair_policy.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"08dfe8050b3f8f34882bb76fb214c7140f65c31b17a2896fe39ff757c75736ed"}},{"ruleId":"D1","level":"warning","message":{"text":"embedding.NewHuggingFaceEmbeddingProvider (cyclomatic 18): embedding.NewHuggingFaceEmbeddingProvider has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/huggingface_embedding_provider.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3e57253877207f5e77f99634e774399fb9d80de6132ed3314181ef53e7a6675"}},{"ruleId":"D1","level":"warning","message":{"text":"dispatcherManager.tryBuildDispatcher (cyclomatic 18): dispatcherManager.tryBuildDispatcher has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/manager.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"1610a1a3c2c5d5669bef6b461419f98d721c2c0ec71c1bf91d80aebe47440bac"}},{"ruleId":"D1","level":"warning","message":{"text":"objectstorage.NewAzureObjectStorageClient (cyclomatic 18): objectstorage.NewAzureObjectStorageClient has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e80c010756576e8269693c3d2823d68c8aa8260da0ac5fb82179271070d0d29"}},{"ruleId":"D1","level":"warning","message":{"text":"etcd220.Save (cyclomatic 17): etcd220.Save has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd220.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"193dd8c8526d2c755aba4facb472d161f96597cc5c1c0eb20a88b7ecb4c2793a"}},{"ruleId":"D1","level":"warning","message":{"text":"FileResourceObserver.Sync (cyclomatic 17): FileResourceObserver.Sync has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/file_resource_observer.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"93e2e9c5de811f0dccd7ec5dd0b254a089f3bdbea0208886c6c07398308be88e"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.maxFullSegmentsGrouping (cyclomatic 17): datacoord.maxFullSegmentsGrouping has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_view_forcemerge.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"e49b6c828d652ca7ef88e2d2d2043710b30de7c3b46964c3caf8aa49ea44df85"}},{"ruleId":"D1","level":"warning","message":{"text":"metricsNodeMemoryQuerier.GetCollectionTopology (cyclomatic 17): metricsNodeMemoryQuerier.GetCollectionTopology has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_forcemerge.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"736203ba731ef10cdbc06b1cec87f2115e1d483fe26a9bd3a6fce9561e740800"}},{"ruleId":"D1","level":"warning","message":{"text":"compactionTrigger.generatePlans (cyclomatic 17): compactionTrigger.generatePlans has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ab009362373fe08b53a013e6a259e8df1c37f022d395218386b4b79ba37b9ba"}},{"ruleId":"D1","level":"warning","message":{"text":"meta.GetQuotaInfo (cyclomatic 17): meta.GetQuotaInfo has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e888bd603a2e4ee6f6657eba491cf7dc5bf5223ea796faf982d620420e88a6f"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.classifyBackfillSegments (cyclomatic 17): Server.classifyBackfillSegments has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services_commit_backfill.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"147107e4747cc26fad446fa699f0e43d2a9d0aef675c41617fb16fee40cb6f43"}},{"ruleId":"D1","level":"warning","message":{"text":"analyzeTask.CreateTaskOnWorker (cyclomatic 17): analyzeTask.CreateTaskOnWorker has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_analyze.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4564f42d737a562878b290c14fd5ec3aa4acdd09863fa03d33c5f013097c3b7"}},{"ruleId":"D1","level":"warning","message":{"text":"refreshExternalCollectionTask.QueryTaskOnWorker (cyclomatic 17): refreshExternalCollectionTask.QueryTaskOnWorker has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":711}}}],"partialFingerprints":{"codehealthFindingId/v1":"aef59c1c994052ad01926844e64f34dce6e34418cb11892e50900feb59dd614c"}},{"ruleId":"D1","level":"warning","message":{"text":"LevelZeroCompactionTask.splitAndWrite (cyclomatic 17): LevelZeroCompactionTask.splitAndWrite has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 5 of the 17 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 253, 222). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/l0_compactor.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"00cc13217ca6a6203dfad6fd2365ce2ab9147c030737da6b6ba3978d3c97ed34"}},{"ruleId":"D1","level":"warning","message":{"text":"indexBuildTask.PreExecute (cyclomatic 17): indexBuildTask.PreExecute has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_index.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"b53fd280775af1aa0674c23872b901fba80b655d21b5454a6b3accb92dba98e1"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.buildStructArrayFieldDataInternal (cyclomatic 17): httpserver.buildStructArrayFieldDataInternal has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1308}}}],"partialFingerprints":{"codehealthFindingId/v1":"87b04508ecd73998309389573563943751519cda678ef688fe569452b329dfa9"}},{"ruleId":"D1","level":"warning","message":{"text":"grpcproxy.newHTTPListner (cyclomatic 17): grpcproxy.newHTTPListner has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/listener_manager.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c2ace058362364a51192b8d6b5619d306ae8fa4f6dbf2f809ee50b0220b61cc"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.Stop (cyclomatic 17): Server.Stop has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 621). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"272d0af49fd63d92bc47562af19af779b834737edd261cdc17caf9d27ba69085"}},{"ruleId":"D1","level":"warning","message":{"text":"GrowingSourceSyncTask.buildFlushConfig (cyclomatic 17): GrowingSourceSyncTask.buildFlushConfig has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":864}}}],"partialFingerprints":{"codehealthFindingId/v1":"6282c7c8def4c412ec47fa4c6242c702edaa85366b67036021652198426b2427"}},{"ruleId":"D1","level":"warning","message":{"text":"BulkPackWriterV3.writeStats (cyclomatic 17): BulkPackWriterV3.writeStats has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"58a90cdc07d187f5e6fa5b777acc43d14f3b5332c1afa3f9786f638c9ac79b0c"}},{"ruleId":"D1","level":"warning","message":{"text":"SyncTask.Run (cyclomatic 17): SyncTask.Run has cyclomatic complexity 17 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/task.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a1f91c2777c4ff770ccf0057c6dd060e922fdd83cff787e8da21aa9570f7f4d"}},{"ruleId":"D1","level":"warning","message":{"text":"writeBufferBase.getGrowingSourceSyncTask (cyclomatic 17): writeBufferBase.getGrowingSourceSyncTask has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1504}}}],"partialFingerprints":{"codehealthFindingId/v1":"039faa3d993ee2e8e6543c2f4662e0f13e00da7d606de59255371517c3f5f58c"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.ListRole (cyclomatic 17): Catalog.ListRole has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1277}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b186077323ddca86006486e6a7d24c388efc79ee22df7685d1df217d59be09e"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitRange (cyclomatic 17): ParserVisitor.VisitRange has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1482}}}],"partialFingerprints":{"codehealthFindingId/v1":"01269920c817d75db3323f890788d186d9c7c49e497e0cd9932a713eaf76b6c9"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitReverseRange (cyclomatic 17): ParserVisitor.VisitReverseRange has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1562}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bd9376250c09c43cedae782c976cac1f757c46faf095c1e01a35ac38e89d646"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.translateToOutputFieldIDs (cyclomatic 17): proxy.translateToOutputFieldIDs has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"87a9d751053714cc264053e279f4e5e260d8ed1620c55c61a4de2f57772a7bae"}},{"ruleId":"D1","level":"warning","message":{"text":"lexicalHighlightOperator.run (cyclomatic 17): lexicalHighlightOperator.run has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"71582e256de6ea12768a03b2cdf1130384b3b0f9078a52122ea96fad5a4596a4"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.UpdateCredential (cyclomatic 17): Proxy.UpdateCredential has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5081}}}],"partialFingerprints":{"codehealthFindingId/v1":"d076f9d96f5f4c52dd837d0412802f483a05c58d1e5a1ea238990d5dc2c20248"}},{"ruleId":"D1","level":"warning","message":{"text":"elementBestCollapseOperator.run (cyclomatic 17): elementBestCollapseOperator.run has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dfd8fd878430aea52b95c17a6bbd9503cfcd32af0df871c3850ee0ecd5a4150"}},{"ruleId":"D1","level":"warning","message":{"text":"LBPolicyImpl.ExecuteWithRetry (cyclomatic 17): LBPolicyImpl.ExecuteWithRetry has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 270). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/lb_policy.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"5656d6d4e2b98bc33ee8150ec63493597ebf9a2963958e5e4175dccc25da9935"}},{"ruleId":"D1","level":"warning","message":{"text":"queryTask.PostExecute (cyclomatic 17): queryTask.PostExecute has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":974}}}],"partialFingerprints":{"codehealthFindingId/v1":"119e374af6263ef81d3695c66744677647d5fc1ed514ae5226eb8001f3bc650b"}},{"ruleId":"D1","level":"warning","message":{"text":"SegmentChecker.getSealedSegmentDiff (cyclomatic 17): SegmentChecker.getSealedSegmentDiff has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/segment_checker.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef76c4b6f957d22fca6f96b335a4b43d50dc02c59217c837bba2b0643d7ec98f"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.LoadBalance (cyclomatic 17): Server.LoadBalance has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/services.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"6963b0e9744a609067a20fcb7a67879f7e2ce5370bf693edf695f64f394d8662"}},{"ruleId":"D1","level":"warning","message":{"text":"taskScheduler.preAdd (cyclomatic 17): taskScheduler.preAdd has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":763}}}],"partialFingerprints":{"codehealthFindingId/v1":"f95e3e2375d0b294cf13d1a2a6086ad5a9dfa8e7a9b954b1a55fdb317604a7f5"}},{"ruleId":"D1","level":"warning","message":{"text":"delegator.FilterSegmentsByVector (cyclomatic 17): delegator.FilterSegmentsByVector has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/segment_pruner.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"6df93ca19cba89ab12161750c5818fd3eabd5de506fd989a4b4544e9aac7773c"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.Search (cyclomatic 17): shardDelegator.Search has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":563}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c5eb220de6f9a74c68037c7ed26c3e5e5530ee3fc114fdc3ea7f2c666f9b80"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.LoadSegments (cyclomatic 17): shardDelegator.LoadSegments has cyclomatic complexity 17 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5969f7c52a348ba5dc45dd7bfa995cf28f92e32107332a2352bc9c1ff9ccd55"}},{"ruleId":"D1","level":"warning","message":{"text":"QuotaCenter.checkDiskQuota (cyclomatic 17): QuotaCenter.checkDiskQuota has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1463}}}],"partialFingerprints":{"codehealthFindingId/v1":"de3495e9f2e713e6fae6c8eec43e3dfb92bf08fb79ab7f91585affc4a5040a65"}},{"ruleId":"D1","level":"warning","message":{"text":"timetickSync.startWatch (cyclomatic 17): timetickSync.startWatch has cyclomatic complexity 17 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/timeticksync.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"4121a9aa941188785fa5d8fb05f9e104cdad22014317852c2945391af93f9a80"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.GenerateEmptyArrayFromSchema (cyclomatic 17): storage.GenerateEmptyArrayFromSchema has cyclomatic complexity 17 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/arrow_util.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0bb7ce39d83c1f4edc2b9c3ed902be648cc7f7b1e3b40439216676fa23c4ce4"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.NewInsertDataWithCap (cyclomatic 17): storage.NewInsertDataWithCap has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 7 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 73). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/insert_data.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"994e9fff91604087ab0c951e99c9d404d1f26320dd727880e1c5bf31e63b1383"}},{"ruleId":"D1","level":"warning","message":{"text":"PayloadReader.GetSparseFloatVectorFromPayload (cyclomatic 17): PayloadReader.GetSparseFloatVectorFromPayload has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1035}}}],"partialFingerprints":{"codehealthFindingId/v1":"602a326e90f26a6b5e99a27cbfec64b2af5b598c2e65c7230ce70194fac3890c"}},{"ruleId":"D1","level":"warning","message":{"text":"NativePayloadWriter.AddFloatVectorToPayload (cyclomatic 17): NativePayloadWriter.AddFloatVectorToPayload has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"6160e3c7e8a8953605f4f531a6c985f888e1af9edcec9f3b6a5dfc1dc0dbdd15"}},{"ruleId":"D1","level":"warning","message":{"text":"releaseManualFlushPreparer.PrepareReleaseManualFlush (cyclomatic 17): releaseManualFlushPreparer.PrepareReleaseManualFlush has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/service/release_manual_flush_preparer.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"38dc975e8fd3fadc5e855ff42282878a25442cbf845854b1f8cf72c54af4b845"}},{"ruleId":"D1","level":"warning","message":{"text":"SyncManager.Sync (cyclomatic 17): SyncManager.Sync has cyclomatic complexity 17 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/fileresource/manager.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"e95cd4fe6ac79ea9e4456c696d512f353005fbdac340c1528e6a868f9e290c98"}},{"ruleId":"D1","level":"warning","message":{"text":"function.embeddingFunctionMetadata (cyclomatic 17): function.embeddingFunctionMetadata has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/manager.go"},"region":{"startLine":1048}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0abc38e29daf4e1d2fd4b2439021504f8bc328eb205331c2858377a0a4f6d02"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.getTypedValue (cyclomatic 17): chain.getTypedValue has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":970}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0e6b36db9d4596509b02818bd926c48e000cec330e11255c40dddc3c5da19e0"}},{"ruleId":"D1","level":"warning","message":{"text":"chain.buildRerankChainInternal (cyclomatic 17): chain.buildRerankChainInternal has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cc031b924db1e7d7c247a7e1c5d1a15ced163677bf6c5160da702efe3527543"}},{"ruleId":"D1","level":"warning","message":{"text":"functionRunnerCollectionEntry.ensureVersion (cyclomatic 17): functionRunnerCollectionEntry.ensureVersion has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/manager.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"286d22eb003799c90d048bb9830e2dcd5cff1d61d8651725262f3e5b1c8a2eab"}},{"ruleId":"D1","level":"warning","message":{"text":"l0Reader.Read (cyclomatic 17): l0Reader.Read has cyclomatic complexity 17 (threshold 15). Of this number, 9 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/l0_reader.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc216f0b17f1c3b0fff2c4e9c58ed660a72cf9faa4269221c40154b0ca452af1"}},{"ruleId":"D1","level":"warning","message":{"text":"numpy.CreateReaders (cyclomatic 17): numpy.CreateReaders has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/util.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f7cc9132ba84499fe10f377b241a49c4d846a59952f26de1606c5f4f3b991d7"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ReadIntegerOrFloatData (cyclomatic 17): parquet.ReadIntegerOrFloatData has cyclomatic complexity 17 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"f66bcc91028e519ae80d1cb8ca186778095feb4d02506e2a64aa82185f1fa557"}},{"ruleId":"D1","level":"warning","message":{"text":"parquet.ConvertToArrowSchemaForUT (cyclomatic 17): parquet.ConvertToArrowSchemaForUT has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":488}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6ee93b9848657556aef22079a71840a671a4610d970edab1e02e7393cfdee7f"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.rangeSliceVectorField (cyclomatic 17): queryutil.rangeSliceVectorField has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"836e84cb4c0d4d037c325313dfb4f81b5c17e64afecc77f97623ef45a0a669bf"}},{"ruleId":"D1","level":"warning","message":{"text":"rocksmq.updateAckedInfo (cyclomatic 17): rocksmq.updateAckedInfo has cyclomatic complexity 17 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_impl.go"},"region":{"startLine":1129}}}],"partialFingerprints":{"codehealthFindingId/v1":"097f8053ee579f48572651cbdd7129510122eb152f09e9ff194779a2710dda22"}},{"ruleId":"D1","level":"warning","message":{"text":"etcd.HealthCheck (cyclomatic 17): etcd.HealthCheck has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 7 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 345). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/etcd/etcd_util.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"61c81c68ea58d94397a436fbf4c3494a1842a1359d5676f41f2fa543e1febf5f"}},{"ruleId":"D1","level":"warning","message":{"text":"externalspec.DeriveEndpoint (cyclomatic 17): externalspec.DeriveEndpoint has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/externalspec/external_spec.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6dda701532a1cf08c2252b6ab2558f1ec7a1c31cb410a3a8b3e1c6d988e3378"}},{"ruleId":"D1","level":"warning","message":{"text":"fastpb.decodeScalarFallback (cyclomatic 17): fastpb.decodeScalarFallback has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"7844738b7c922f75b3b3b2bba244d3f9b1b287f418aa9e5b11c7f4a97450ad77"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.CalcScalarSize (cyclomatic 17): typeutil.CalcScalarSize has cyclomatic complexity 17 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"41196fef2470ddae8bd37e918ebe2eb5de3aea152d6bbe92e8635968955e2898"}},{"ruleId":"D1","level":"warning","message":{"text":"mck.run (cyclomatic 16): mck.run has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6ce1f672e752872a4baa6f34c67046667a42e5293053133c6254a0bb6a56ea"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.AssembleCopySegmentRequest (cyclomatic 16): datacoord.AssembleCopySegmentRequest has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f4d55e05b8c6982cb8ab48dfdf16c335afcb63e6a3b31e2824f0f9111a39f23"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.FilterInIndexedSegments (cyclomatic 16): datacoord.FilterInIndexedSegments has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/util.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aaea4cf677cdc9830c0d9d41b302cc903a1d0afe536990693c65d9f5e19eff7"}},{"ruleId":"D1","level":"warning","message":{"text":"mixCompactionTask.QueryTaskOnWorker (cyclomatic 16): mixCompactionTask.QueryTaskOnWorker has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_mix.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"a052ba0b8b0a5e55720d428c0a660f15c42486d4b1439e7c666dd653707d8b4f"}},{"ruleId":"D1","level":"warning","message":{"text":"indexInspector.createIndexForSegmentLoop (cyclomatic 16): indexInspector.createIndexForSegmentLoop has cyclomatic complexity 16 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_inspector.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"55b137ea55ac903526039d89a8d06054f83464130b2fc62c31f7b3f23f916b97"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.AlterIndex (cyclomatic 16): Server.AlterIndex has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"26cda21dd0f20beaed5d46596edd635443634fd454616af5b33ac53579f0b2f1"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.countIndexedRows (cyclomatic 16): Server.countIndexedRows has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":633}}}],"partialFingerprints":{"codehealthFindingId/v1":"4403d0141d5f67c93280eb969033e7971963428f5f578f9edee9368dda784425"}},{"ruleId":"D1","level":"warning","message":{"text":"snapshotManager.createRestoreJob (cyclomatic 16): snapshotManager.createRestoreJob has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":1130}}}],"partialFingerprints":{"codehealthFindingId/v1":"14baee6566ea2d392473ad7823ccf9d0f4bceae3ae870f53005b2a2bbdfeda67"}},{"ruleId":"D1","level":"warning","message":{"text":"ImportTask.importFile (cyclomatic 16): ImportTask.importFile has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"d12c729ff58bf97d6fd4f53d6dd4e9435fe6a51449203a4e685fa7777ef0adfb"}},{"ruleId":"D1","level":"warning","message":{"text":"indexBuildTask.Execute (cyclomatic 16): indexBuildTask.Execute has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_index.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f00488ac1d6a9f43b9c6caabb44a67406599f0da3f66e585ea6c50e193b4393"}},{"ruleId":"D1","level":"warning","message":{"text":"httpserver.parseStructArrayRow (cyclomatic 16): httpserver.parseStructArrayRow has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":863}}}],"partialFingerprints":{"codehealthFindingId/v1":"2056381fe456c0f3aee74590c1a0dc71d82fd0e06f3d1db8f8a10c726b5e34f9"}},{"ruleId":"D1","level":"warning","message":{"text":"HandlersV1.insert (cyclomatic 16): HandlersV1.insert has cyclomatic complexity 16 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":715}}}],"partialFingerprints":{"codehealthFindingId/v1":"f61f1ed8a55f1ea31334167745ffaae5c0cec8c1834891e4f2b09a39ca2c689d"}},{"ruleId":"D1","level":"warning","message":{"text":"StructArrayFieldSchema.GetProto (cyclomatic 16): StructArrayFieldSchema.GetProto has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/request_v2.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b49b4e253f3eb1987f303be90c60ad110347e6c7b7e0da03a9553348b5805ec"}},{"ruleId":"D1","level":"warning","message":{"text":"listenerManager.Close (cyclomatic 16): listenerManager.Close has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/listener_manager.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"29d7b596b29b4df78a250781bf64ecc8f3c81337ee3dcdb908e5b2dcf5cdd11d"}},{"ruleId":"D1","level":"warning","message":{"text":"http.CheckPrivilege (cyclomatic 16): http.CheckPrivilege has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/http/rbac.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"8181171bd8a7b95eae1f864cb75f563d7637c0f993376483666ac9ec3a0f1f0a"}},{"ruleId":"D1","level":"warning","message":{"text":"datacoord.buildBinlogKvs (cyclomatic 16): datacoord.buildBinlogKvs has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/util.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"0daae775ab87d026843ad1fb7531111e2d52366fd03ca6db7f575e9f26050bb9"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.getTargetType (cyclomatic 16): planparserv2.getTargetType has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d3e47f99d0ad26d9c91fa8df9afdf74bc04fe6c8e48d75a5ce47f1f9191c58c"}},{"ruleId":"D1","level":"warning","message":{"text":"planparserv2.combineBinaryArithExpr (cyclomatic 16): planparserv2.combineBinaryArithExpr has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"852df3922198139c47b56df96096f22aa7eab460e54d875212b640c2af3693bf"}},{"ruleId":"D1","level":"warning","message":{"text":"ParserVisitor.VisitTerm (cyclomatic 16): ParserVisitor.VisitTerm has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1154}}}],"partialFingerprints":{"codehealthFindingId/v1":"9629c2a71c4ab921b0c0ed9ddc7d49aaf7748411bb5a3928100639011b8b4504"}},{"ruleId":"D1","level":"warning","message":{"text":"visitor.combineAndNotEqualsToNotIn (cyclomatic 16): visitor.combineAndNotEqualsToNotIn has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"5988df352f01567fc7763a6ac74dba9db849af22decddf774d568da81205f8af"}},{"ruleId":"D1","level":"warning","message":{"text":"proxy.parseOrderByFields (cyclomatic 16): proxy.parseOrderByFields has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f01c8388fbdf89a164281e4c88c0c9f415540d17934153369e1e85e17ffb0a7"}},{"ruleId":"D1","level":"warning","message":{"text":"MetaCache.getCollection (cyclomatic 16): MetaCache.getCollection has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"55d5b579653e51afacce9a3daa03956d6c3428e464d4cb9192568fc66b5e48ef"}},{"ruleId":"D1","level":"warning","message":{"text":"Proxy.OperatePrivilege (cyclomatic 16): Proxy.OperatePrivilege has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5529}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f58a1406ac1c429917e329fed67ef9b691e377deb7dc3be16e60bb34ce9460f"}},{"ruleId":"D1","level":"warning","message":{"text":"orderByOperator.sortGroupsByOrderByFields (cyclomatic 16): orderByOperator.sortGroupsByOrderByFields has cyclomatic complexity 16 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2301}}}],"partialFingerprints":{"codehealthFindingId/v1":"d885ccac0413e2e7db78719869f77722a68a6f902b088ba63d39e2bf0e9848ca"}},{"ruleId":"D1","level":"warning","message":{"text":"ScoreBasedAssignPolicy.AssignChannel (cyclomatic 16): ScoreBasedAssignPolicy.AssignChannel has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/assign/assign_policy_score.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"635e6aade69326ac671137f09b81f125b54004e3cce80002927932a3917a6859"}},{"ruleId":"D1","level":"warning","message":{"text":"LoadConfigWatcher.applyLoadConfigChanges (cyclomatic 16): LoadConfigWatcher.applyLoadConfigChanges has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/load_config_watcher.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"70afb68e575fdb7873974ee6cb1244e9e4027e465e6b4bbc97f272c3629c0991"}},{"ruleId":"D1","level":"warning","message":{"text":"ReplicaManager.SpawnWithReplicaConfig (cyclomatic 16): ReplicaManager.SpawnWithReplicaConfig has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bfa8ec11a788162788189f05ddb8971d6ce42e2734203e43bfe77769a1343d1"}},{"ruleId":"D1","level":"warning","message":{"text":"ReplicaObserver.checkStreamingQueryNodesInReplica (cyclomatic 16): ReplicaObserver.checkStreamingQueryNodesInReplica has cyclomatic complexity 16 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/replica_observer.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"c71acfcf4cc3360968b64a67b56dc1d3ce976248791a20f184019f149a455cfb"}},{"ruleId":"D1","level":"warning","message":{"text":"taskScheduler.checkStale (cyclomatic 16): taskScheduler.checkStale has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":1372}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb607bd47a1944a7c5186b0780bb7aba6a04defcc97030ca8148d7f7773be2b"}},{"ruleId":"D1","level":"warning","message":{"text":"delegator.executeSubTasks (cyclomatic 16): delegator.executeSubTasks has cyclomatic complexity 16 (threshold 15). Of this number, 9 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":1041}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fc70a714141b2eb92e2f6322bcf1232cd25aca95de0a69fdeca3a5c9edf0e29"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.ReleaseSegments (cyclomatic 16): shardDelegator.ReleaseSegments has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"12d7a00a7159edf16919582016dbd95c6cec8ce406efab3c43d0996b4be9694c"}},{"ruleId":"D1","level":"warning","message":{"text":"shardDelegator.buildBM25IDF (cyclomatic 16): shardDelegator.buildBM25IDF has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1367}}}],"partialFingerprints":{"codehealthFindingId/v1":"951afe9e75deb3bdd76f1f756b93bdd6f001a8e0a9032409d0180d2d62298868"}},{"ruleId":"D1","level":"warning","message":{"text":"segments.NewFetchFieldsDataOperator (cyclomatic 16): segments.NewFetchFieldsDataOperator has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 196). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/ignore_non_pk_ops.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e7df8454c2ee1c8f98b87c942d12cc09538deab9dd69fd14cc30bc66e340cd2"}},{"ruleId":"D1","level":"warning","message":{"text":"segments.swapFieldData (cyclomatic 16): segments.swapFieldData has cyclomatic complexity 16 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/result_sorter.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"c66e75ff1941f06a702fa6ae6e8ab558994b9dfdc713407526ad05a7f67e0b30"}},{"ruleId":"D1","level":"warning","message":{"text":"tasks.dataFrameFromArrowRecordBatch (cyclomatic 16): tasks.dataFrameFromArrowRecordBatch has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/arrow_import.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"70a4c1d03b685730f64ba85d4ef875e29d09234e476aac455f6b05e30e281712"}},{"ruleId":"D1","level":"warning","message":{"text":"QuotaCenter.forceDenyWriting (cyclomatic 16): QuotaCenter.forceDenyWriting has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed503a28490ee366d3fca6464704d13fe7057e9b8dc146f93e4ba0f1d32dff4d"}},{"ruleId":"D1","level":"warning","message":{"text":"Core.broadcastAlterDatabase (cyclomatic 16): Core.broadcastAlterDatabase has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_database.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"6915f0c8b29090a3ed14732c0450f494337d91e6becc57700e8c9a974a72ee12"}},{"ruleId":"D1","level":"warning","message":{"text":"TelemetryManager.validateAndTruncateMetrics (cyclomatic 16): TelemetryManager.validateAndTruncateMetrics has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/telemetry/manager.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"51afa9135c6bc3ffffd1aba0f7cfadf51c2120dada75366a101dbd3b4b34593c"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.NewScalarFieldValueFromGenericValue (cyclomatic 16): storage.NewScalarFieldValueFromGenericValue has cyclomatic complexity 16 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_value.go"},"region":{"startLine":1035}}}],"partialFingerprints":{"codehealthFindingId/v1":"abda941812622c3190aef1df812b04708268fb1f52e45974e568b6f4cbce944b"}},{"ruleId":"D1","level":"warning","message":{"text":"storage.printDDLPayloadValues (cyclomatic 16): storage.printDDLPayloadValues has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"7aa3e98c9866de0c4c3d772fdff29faf0478a720f9a83d1c8d2fb97dbc719dcf"}},{"ruleId":"D1","level":"warning","message":{"text":"catchupScanner.consumeWithScanner (cyclomatic 16): catchupScanner.consumeWithScanner has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/scanner_switchable.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"60bc41c4b77f5b62bd4a4b97d45350b38032317a3cda33c67ed8dc581dbb6dc7"}},{"ruleId":"D1","level":"warning","message":{"text":"walAdaptorImpl.Append (cyclomatic 16): walAdaptorImpl.Append has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/wal_adaptor.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e5de030745d6af12784a3074b08b3251a3b34a9807a37d9d4c61fe830628cb"}},{"ruleId":"D1","level":"warning","message":{"text":"recoveryStorageImpl.updateCheckpoint (cyclomatic 16): recoveryStorageImpl.updateCheckpoint has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/recovery/recovery_storage_impl.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"29903f39f8c60abc1927d1a916a4f9975bc0b3a0c390ed1fccdf6fc6f42e8609"}},{"ruleId":"D1","level":"warning","message":{"text":"InputNode.Operate (cyclomatic 16): InputNode.Operate has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/flowgraph/input_node.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4d772c3bc1c65ed383d6d5538d2b0c8cba4e9620c332eafed859f58411dc310"}},{"ruleId":"D1","level":"warning","message":{"text":"FilterOp.Execute (cyclomatic 16): FilterOp.Execute has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_filter.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"04987118e8fb4c978f1013a1353c91d26166076aeb9f70a3bd971ca2d8e53bb4"}},{"ruleId":"D1","level":"warning","message":{"text":"highlight.NewSemanticHighlight (cyclomatic 16): highlight.NewSemanticHighlight has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/highlight/semantic_highlight.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"21772bbaf7485e525d4e691341f42310806129dca74c2cfb2beee8344e061623"}},{"ruleId":"D1","level":"warning","message":{"text":"validator.CheckFunctionBasicParams (cyclomatic 16): validator.CheckFunctionBasicParams has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/validator.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"107107d2ac19aedf9a08f2b21a9acc11cb4aefe1969e0611417b788df2efc1f2"}},{"ruleId":"D1","level":"warning","message":{"text":"ClientBase.call (cyclomatic 16): ClientBase.call has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 493, 483). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/grpcclient/client.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"68ec4fa996fa7cdd5b633aee3cc4657a3803169531ac37c83af7553e630db6f4"}},{"ruleId":"D1","level":"warning","message":{"text":"reader.init (cyclomatic 16): reader.init has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/reader.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"70897f340e4efe1977c2cf3727361ae494ccd3ba3d33a976b0bfc0d99cba2043"}},{"ruleId":"D1","level":"warning","message":{"text":"queryutil.getFieldValue (cyclomatic 16): queryutil.getFieldValue has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1500}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ef56466c1e48e9954e367ad40dfbb8e926015daa200e4506369479b3f90158d"}},{"ruleId":"D1","level":"warning","message":{"text":"textEncoder.EncodeEntry (cyclomatic 16): textEncoder.EncodeEntry has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mlog/zap_text_encoder.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"74a0b97681aa825eabe45f4c744d6de7feedf09647dce4ecb5df5569da9679c6"}},{"ruleId":"D1","level":"warning","message":{"text":"rocksmq.Consume (cyclomatic 16): rocksmq.Consume has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_impl.go"},"region":{"startLine":835}}}],"partialFingerprints":{"codehealthFindingId/v1":"82bdfcebc632c050f8f8dfae3d9e4c9ca5f8af945d80ee2cd3e58a790ef78624"}},{"ruleId":"D1","level":"warning","message":{"text":"Dispatcher.groupAndParseMsgs (cyclomatic 16): Dispatcher.groupAndParseMsgs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/dispatcher.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"616a92cfc85d39ce071e6b23cd99ee41fe25bd3d757b39065237acd9d764dee5"}},{"ruleId":"D1","level":"warning","message":{"text":"HuaweiCredentialProvider.Retrieve (cyclomatic 16): HuaweiCredentialProvider.Retrieve has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/huawei/huawei.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"83edbd1bf056e8986d28cd2190d362613529fa70d6f9295b0da2ba058a681c16"}},{"ruleId":"D1","level":"warning","message":{"text":"dataCoordConfig.init (cyclomatic 16): dataCoordConfig.init has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 11 function literals inside it that branch (lines 5915, 5931, 6368, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/component_param.go"},"region":{"startLine":5539}}}],"partialFingerprints":{"codehealthFindingId/v1":"626e8991b65c2af4e65d54f6da7cab98729c9857c8323dcf8b79fb4f26b200d6"}},{"ruleId":"D1","level":"warning","message":{"text":"ReplicateConfigValidator.validateClusterBasic (cyclomatic 16): ReplicateConfigValidator.validateClusterBasic has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/replicateutil/config_validator.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b6c456f498a2f9d66fc96a3c1d2781f19803001b9314f32613aa2a139c9ef2a"}},{"ruleId":"D1","level":"warning","message":{"text":"typeutil.CreateSchemaHelper (cyclomatic 16): typeutil.CreateSchemaHelper has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d28bc77645210e69a9676c61ffbeb00c931093fcf229c8e0ce13e2d27b2fdb7"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.BuildArrayData (cognitive 537): testutil.BuildArrayData has cognitive complexity 537 (threshold 15). Drivers by points: if/else 330, loops 136, match/switch 48, boolean chains 23 (nesting depth added 385). Of this number, 525 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":494}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b3c1f0e4a4e35963a363464db60dafa62419844f5c19f4e316b4e8f232c12a3"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.reconstructStructArrayForJSON (cognitive 299): testutil.reconstructStructArrayForJSON has cognitive complexity 299 (threshold 15). Drivers by points: if/else 260, match/switch 29, boolean chains 6, loops 4 (nesting depth added 242). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1290}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca1d941f2d9adc5182fa6549a29393a5375cc84ce0cc3df5e4e5e0d9f2977a87"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.checkAndSetData (cognitive 252): httpserver.checkAndSetData has cognitive complexity 252 (threshold 15). Drivers by points: if/else 220, match/switch 15, loops 12, boolean chains 5 (nesting depth added 188). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"fded31cc484bc443b697bdfa61a842f0aeeb9af59be44794e58c1296e9b8edbe"}},{"ruleId":"D2","level":"warning","message":{"text":"upsertTask.queryPreExecute (cognitive 241): upsertTask.queryPreExecute has cognitive complexity 241 (threshold 15). Drivers by points: if/else 177, loops 59, boolean chains 5 (nesting depth added 147). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"42fa2f3f023e5d9c71b6cf51dc11ed687e7f5e253cf18591b5e8ac44e31f4030"}},{"ruleId":"D2","level":"warning","message":{"text":"createIndexTask.parseIndexParams (cognitive 238): createIndexTask.parseIndexParams has cognitive complexity 238 (threshold 15). Drivers by points: if/else 178, loops 32, boolean chains 28 (nesting depth added 117). Of this number, 210 points are the body\u0027s own statements and 28 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c1bc375d6802769bd3467c130d6916cb2b740ef76216adcbc52d9d3b5ad72c5"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reorderFieldData (cognitive 235): proxy.reorderFieldData has cognitive complexity 235 (threshold 15). Drivers by points: if/else 164, loops 42, boolean chains 28, match/switch 1 (nesting depth added 138). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2707}}}],"partialFingerprints":{"codehealthFindingId/v1":"2890f6d89013b13a28f64f06b04a447ef9659508eb0391114a20cc45743cf3e8"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.checkAndFlattenStructFieldData (cognitive 199): proxy.checkAndFlattenStructFieldData has cognitive complexity 199 (threshold 15). Drivers by points: if/else 139, loops 41, match/switch 17, boolean chains 2 (nesting depth added 136). Of this number, 147 points are the body\u0027s own statements and 52 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1922}}}],"partialFingerprints":{"codehealthFindingId/v1":"7de157892743efa8ecd8dada933a4ed078294432d9b75d5fc8c056270f89c6d6"}},{"ruleId":"D2","level":"warning","message":{"text":"column.FieldDataColumn (cognitive 179): column.FieldDataColumn has cognitive complexity 179 (threshold 15). Drivers by points: if/else 122, loops 56, match/switch 1 (nesting depth added 111). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3af3aa86f7d0009814ccda0b4c48f4c0b4d0243f37e1401e6ac0eb48ad0966a"}},{"ruleId":"D2","level":"warning","message":{"text":"quotaConfig.init (cognitive 179): quotaConfig.init has cognitive complexity 179 (threshold 15). Drivers by points: if/else 170, boolean chains 9. Most of this is not in the body itself: 0 of the 179 points are its own statements and the rest belongs to 68 function literals inside it that branch (lines 1605, 1650, 345, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/quota_param.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dcdd57a805cc5e3a7c9db09850b514f21fcf9dc6186cc9c91ede21ad13502d6"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.UpdateFieldData (cognitive 167): typeutil.UpdateFieldData has cognitive complexity 167 (threshold 15). Drivers by points: if/else 129, boolean chains 22, loops 8, match/switch 8 (nesting depth added 108). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1641}}}],"partialFingerprints":{"codehealthFindingId/v1":"edf3569af756187c346489cf193940a4902a7fcdafbded808762ba9f8aa18ff6"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.anyToColumns (cognitive 156): httpserver.anyToColumns has cognitive complexity 156 (threshold 15). Drivers by points: if/else 112, loops 16, match/switch 15, boolean chains 13 (nesting depth added 86). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1800}}}],"partialFingerprints":{"codehealthFindingId/v1":"c67a47c7f702db5ed6d1e5c66d769bf7698666abea8346f6828dd67c85c62085"}},{"ruleId":"D2","level":"warning","message":{"text":"validateUtil.checkAligned (cognitive 155): validateUtil.checkAligned has cognitive complexity 155 (threshold 15). Drivers by points: if/else 149, boolean chains 3, match/switch 2, loops 1 (nesting depth added 102). Of this number, 153 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d4af2224df0405c6e8abd1e86a83e77818e50d09d73716ccbaf128e37aec57a"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.AppendFieldData (cognitive 152): typeutil.AppendFieldData has cognitive complexity 152 (threshold 15). Drivers by points: if/else 140, match/switch 8, boolean chains 2, loops 2 (nesting depth added 95). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1014}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b491d20a2ebf5f304f8937453fd2cc99ee288bd0bfbcb7fd8a59cb598e202d7"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.fillDatabase (cognitive 151): proxy.fillDatabase has cognitive complexity 151 (threshold 15). Drivers by points: if/else 146, boolean chains 4, match/switch 1 (nesting depth added 73). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/database_interceptor.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"351c773a5e1ca10df033eb77591cf59113399260e5b0ded6d145e460ece4ae93"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.ToCompressedFormatNullable (cognitive 147): proxy.ToCompressedFormatNullable has cognitive complexity 147 (threshold 15). Drivers by points: if/else 100, loops 44, match/switch 3 (nesting depth added 100). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d1e9bc34154b9fbb5f9bce76b6c9263e22778ca2aa0d9b80e97f0311f51586b"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.parseEntity (cognitive 137): rowParser.parseEntity has cognitive complexity 137 (threshold 15). Drivers by points: if/else 124, loops 10, boolean chains 2, match/switch 1 (nesting depth added 71). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"82582336fbde4b406c292ae0588ba32c02f8273f9c0a427a50354dea630bfd03"}},{"ruleId":"D2","level":"warning","message":{"text":"StructFieldReader.readArrayField (cognitive 134): StructFieldReader.readArrayField has cognitive complexity 134 (threshold 15). Drivers by points: if/else 115, loops 11, match/switch 7, boolean chains 1 (nesting depth added 100). Of this number, 133 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bbd65358849b84b8b53b9a6dddf6b508a6a6fa6f5bdab4d355cebf2730813a1"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.AppendFieldDataByColumn (cognitive 130): typeutil.AppendFieldDataByColumn has cognitive complexity 130 (threshold 15). Drivers by points: if/else 68, loops 56, match/switch 5, boolean chains 1 (nesting depth added 81). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1312}}}],"partialFingerprints":{"codehealthFindingId/v1":"98d7da6074ef8ea055e764aac0b25078c1f18d7ebc696440a4c311856a519389"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV2.createCollection (cognitive 128): HandlersV2.createCollection has cognitive complexity 128 (threshold 15). Drivers by points: if/else 105, loops 16, match/switch 4, boolean chains 3 (nesting depth added 66). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2329}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdd3ee467a503e9c343fe1b8fed435fce75e516ea43cf42242e0ef143f022c0c"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrBinaryRanges (cognitive 128): visitor.combineOrBinaryRanges has cognitive complexity 128 (threshold 15). Drivers by points: if/else 108, boolean chains 14, loops 6 (nesting depth added 72). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":734}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b0c433f40a2591387dd190058508a6ba77a39bd9cc3c4244764b1cc3bb08e81"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.buildQueryResp (cognitive 126): httpserver.buildQueryResp has cognitive complexity 126 (threshold 15). Drivers by points: if/else 93, loops 21, match/switch 10, boolean chains 2 (nesting depth added 84). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2668}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dfac70d60edbcf07e4e983b7c7d730c7ca33cffcd2f9258622c8c6af0fe2a79"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndBinaryRanges (cognitive 124): visitor.combineAndBinaryRanges has cognitive complexity 124 (threshold 15). Drivers by points: if/else 101, loops 12, boolean chains 11 (nesting depth added 71). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"3491202b9e7de9165e63f7afc44d64208784faa64dcd67ccb83b2046f53947a5"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.ActualSizeInBytes (cognitive 124): storage.ActualSizeInBytes has cognitive complexity 124 (threshold 15). Drivers by points: if/else 95, loops 26, boolean chains 2, match/switch 1 (nesting depth added 63). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde.go"},"region":{"startLine":1459}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a6311d72e7554f64c297ce3321a75e61530938065f77f41fb5b73228ed263bb"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupAggReducer.Reduce (cognitive 118): GroupAggReducer.Reduce has cognitive complexity 118 (threshold 15). Drivers by points: if/else 95, loops 21, boolean chains 2 (nesting depth added 67). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_reducer.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"911a830d0e28ba42dac4b386c525df80011982695d690e10f68d9a5768ee9a4f"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.buildMergedVectorField (cognitive 114): queryutil.buildMergedVectorField has cognitive complexity 114 (threshold 15). Drivers by points: if/else 82, loops 18, boolean chains 9, match/switch 5 (nesting depth added 65). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6c5ea641fed17746237f9a57dc154d3e887e7c26544d2be18e641a7ab3b179a"}},{"ruleId":"D2","level":"warning","message":{"text":"alterCollectionTask.PreExecute (cognitive 112): alterCollectionTask.PreExecute has cognitive complexity 112 (threshold 15). Drivers by points: if/else 96, boolean chains 9, loops 7 (nesting depth added 57). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":2164}}}],"partialFingerprints":{"codehealthFindingId/v1":"640d2ed29cd5333b0f8f6ecbe9f07f3642b28513b6284e92e4dd8749257d0f8c"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.checkFieldSchema (cognitive 110): rootcoord.checkFieldSchema has cognitive complexity 110 (threshold 15). Drivers by points: if/else 99, boolean chains 7, match/switch 3, loops 1 (nesting depth added 73). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":340}}}],"partialFingerprints":{"codehealthFindingId/v1":"e75b274510845a928e00e0a008593657e088aa063340f0a3121767d3c3cd9f72"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.searchResultData (cognitive 110): dec.searchResultData has cognitive complexity 110 (threshold 15). Drivers by points: if/else 99, match/switch 8, boolean chains 2, loops 1 (nesting depth added 67). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/searchresult.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"99d10af415dfc6807d634e19923ff537c23c69e0c90b03a3dd4df18107097516"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.MergeFieldData (cognitive 108): typeutil.MergeFieldData has cognitive complexity 108 (threshold 15). Drivers by points: if/else 98, match/switch 8, loops 2 (nesting depth added 64). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2319}}}],"partialFingerprints":{"codehealthFindingId/v1":"68cbab3c997dfb89d884ad02b7f4d0a820cefa476763fa7612c486edf48689b7"}},{"ruleId":"D2","level":"warning","message":{"text":"RefreshExternalCollectionTask.balanceFragmentsToSegments (cognitive 103): RefreshExternalCollectionTask.balanceFragmentsToSegments has cognitive complexity 103 (threshold 15). Drivers by points: if/else 77, loops 22, boolean chains 4 (nesting depth added 48). Of this number, 88 points are the body\u0027s own statements and 15 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c96e162fb8dea76dff15e4557e0fbf30bba9e61fa3fdad875bf92fa4ac48c46"}},{"ruleId":"D2","level":"warning","message":{"text":"searchTask.initAdvancedSearchRequest (cognitive 101): searchTask.initAdvancedSearchRequest has cognitive complexity 101 (threshold 15). Drivers by points: if/else 87, boolean chains 11, loops 2, match/switch 1 (nesting depth added 45). Of this number, 99 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"eec2a5dd25af035a64b4c4b9c3b5fd22e400b5ef54079065e9004b792e645f75"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.translateOutputFields (cognitive 100): proxy.translateOutputFields has cognitive complexity 100 (threshold 15). Drivers by points: if/else 83, loops 17 (nesting depth added 64). Of this number, 85 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1639}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eb46607ee6f62be633cf2a1c2797bf3874939524994e0b5ee026d884e31d0c7"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.UpdateFieldDataByColumn (cognitive 96): typeutil.UpdateFieldDataByColumn has cognitive complexity 96 (threshold 15). Drivers by points: loops 66, if/else 23, match/switch 5, boolean chains 2 (nesting depth added 61). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1917}}}],"partialFingerprints":{"codehealthFindingId/v1":"727f0d1289aaf4ca646ef0c67d24b7da9e0f5e55b4509ec076218b0939be48e3"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.printPayloadValues (cognitive 94): storage.printPayloadValues has cognitive complexity 94 (threshold 15). Drivers by points: loops 53, if/else 40, match/switch 1 (nesting depth added 49). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"86e7f14d9a13958eb717a64034b6b9cbb6962628bfd2aa6c84be3beffa5e8fcf"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.appendValueAt (cognitive 93): storage.appendValueAt has cognitive complexity 93 (threshold 15). Drivers by points: if/else 87, loops 3, match/switch 3 (nesting depth added 46). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/arrow_util.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"a27963013859f58f3539a2e44ac12f4376c578ea9f1734f2beed24f4f4c52863"}},{"ruleId":"D2","level":"warning","message":{"text":"searchTask.initSearchRequest (cognitive 92): searchTask.initSearchRequest has cognitive complexity 92 (threshold 15). Drivers by points: if/else 75, boolean chains 12, loops 3, match/switch 2 (nesting depth added 31). Of this number, 90 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"b82b6ae92234d9fefa06e9ee3cef3efd24e030b9b906980a551aeb493743d9a6"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.AddInsertData (cognitive 89): storage.AddInsertData has cognitive complexity 89 (threshold 15). Drivers by points: if/else 82, boolean chains 6, match/switch 1 (nesting depth added 44). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a742fceab1547d7d03fe1f4c5f494dd97b75adf1e182e2b97f91404cc40c861"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadArrayData (cognitive 89): parquet.ReadArrayData has cognitive complexity 89 (threshold 15). Drivers by points: if/else 70, loops 18, match/switch 1 (nesting depth added 49). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1777}}}],"partialFingerprints":{"codehealthFindingId/v1":"04c7981bb19461d8f60f712013800b54e675422ac009f16101fc109070192094"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.Sort (cognitive 87): storage.Sort has cognitive complexity 87 (threshold 15). Drivers by points: if/else 47, loops 32, match/switch 7, boolean chains 1 (nesting depth added 54). Of this number, 56 points are the body\u0027s own statements and 31 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/sort.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b7086d128640e3046d9c2eed1c000326913a71a57ebbb672ec68c2c1ac776a7"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV2.search (cognitive 86): HandlersV2.search has cognitive complexity 86 (threshold 15). Drivers by points: if/else 78, boolean chains 8 (nesting depth added 35). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1844}}}],"partialFingerprints":{"codehealthFindingId/v1":"380e3f983f84d0566cb740ca934014aab4aff42cab24589a06b92a8ffda4a329"}},{"ruleId":"D2","level":"warning","message":{"text":"alterCollectionFieldTask.PreExecute (cognitive 86): alterCollectionFieldTask.PreExecute has cognitive complexity 86 (threshold 15). Drivers by points: if/else 71, loops 8, boolean chains 5, match/switch 2 (nesting depth added 50). Of this number, 84 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":2525}}}],"partialFingerprints":{"codehealthFindingId/v1":"c185be49d27a173a2b407cecad9973cf62d20e5f2d37dab9c2a3515700af311e"}},{"ruleId":"D2","level":"warning","message":{"text":"validateUtil.checkArrayOfVectorFieldData (cognitive 86): validateUtil.checkArrayOfVectorFieldData has cognitive complexity 86 (threshold 15). Drivers by points: if/else 74, loops 10, boolean chains 1, match/switch 1 (nesting depth added 51). Of this number, 82 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":1176}}}],"partialFingerprints":{"codehealthFindingId/v1":"f49fddf7ebc34568c061b37037748522d6e49e31bcec7b5f755bffd5ed331f17"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.CreateFieldReaders (cognitive 85): parquet.CreateFieldReaders has cognitive complexity 85 (threshold 15). Drivers by points: if/else 65, loops 18, boolean chains 2 (nesting depth added 49). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e9664b8e34e0e08fc7df54388147cfa110079c8702c401ada4e12465e85cc37"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableArrayData (cognitive 83): parquet.ReadNullableArrayData has cognitive complexity 83 (threshold 15). Drivers by points: if/else 64, loops 18, match/switch 1 (nesting depth added 45). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1978}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bde6e3bde05220ff9191e24b11a54c2ee870fda384cd2cb150ebe0cf44ce7ea"}},{"ruleId":"D2","level":"warning","message":{"text":"MqTtMsgStream.bufMsgPackToChannel (cognitive 82): MqTtMsgStream.bufMsgPackToChannel has cognitive complexity 82 (threshold 15). Drivers by points: if/else 53, loops 20, match/switch 6, boolean chains 3 (nesting depth added 57). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f5c313e009d84b023870caa2888438ad6ad9bf3574ef25ee7b76240b3473d4e"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.retrieveResults (cognitive 82): dec.retrieveResults has cognitive complexity 82 (threshold 15). Drivers by points: if/else 76, match/switch 5, loops 1 (nesting depth added 50). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc1248e6f2c156a2ac69207cecd4bf43e613d8576882e8eba353a3483823c132"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.parseSearchResult (cognitive 81): Client.parseSearchResult has cognitive complexity 81 (threshold 15). Drivers by points: if/else 63, loops 10, boolean chains 8 (nesting depth added 43). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"085abefbf1905a2c906c240355203f08a7f31dd321ec52d02345fe5954fecc1c"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndRangePredicates (cognitive 81): visitor.combineAndRangePredicates has cognitive complexity 81 (threshold 15). Drivers by points: if/else 49, loops 20, boolean chains 12 (nesting depth added 37). Of this number, 80 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"6658ba40742d23726f27fb6de46a04d7a7eddeea5a751dc98bd58bde8bca38ff"}},{"ruleId":"D2","level":"warning","message":{"text":"validateUtil.checkArrayElement (cognitive 81): validateUtil.checkArrayElement has cognitive complexity 81 (threshold 15). Drivers by points: if/else 68, loops 12, match/switch 1 (nesting depth added 54). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":1061}}}],"partialFingerprints":{"codehealthFindingId/v1":"a363c18a55b9e50325de1cc0f3853bbd5a98ee4b0f41819b532cbd348cc7240a"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldReader.Next (cognitive 81): FieldReader.Next has cognitive complexity 81 (threshold 15). Drivers by points: if/else 70, boolean chains 10, match/switch 1 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"23b1ef6d86a87759ad2a10e816ac12fdb7dd4e71231ecb98aa909fadd9efda97"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddDataToPayloadForUT (cognitive 79): NativePayloadWriter.AddDataToPayloadForUT has cognitive complexity 79 (threshold 15). Drivers by points: if/else 74, boolean chains 4, match/switch 1 (nesting depth added 39). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"a01d00de650cdbe4065f08fcd218a750cd686f8ad99de22485b8febb31ae99bb"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.fieldData (cognitive 77): dec.fieldData has cognitive complexity 77 (threshold 15). Drivers by points: if/else 68, boolean chains 6, match/switch 2, loops 1 (nesting depth added 44). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b17ae13c7b5d61bf5beb67fcc34c6ccc836d9c5dc22b9cd45b3f842df23d887"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.applyExternalCollectionSegmentUpdate (cognitive 75): datacoord.applyExternalCollectionSegmentUpdate has cognitive complexity 75 (threshold 15). Drivers by points: if/else 63, loops 8, boolean chains 4 (nesting depth added 29). Of this number, 50 points are the body\u0027s own statements and 25 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b2116f70371d511ff8ba05c819fe4ff124c62dbf1dd8ae143e0c72bbaec2752"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.FillWithDefaultValue (cognitive 75): proxy.FillWithDefaultValue has cognitive complexity 75 (threshold 15). Drivers by points: if/else 69, loops 3, match/switch 3 (nesting depth added 47). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca306db846635979aa095402eb3898e3645e3832011cfdcf741926cf5f766ced"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldReader.Next (cognitive 75): FieldReader.Next has cognitive complexity 75 (threshold 15). Drivers by points: if/else 60, loops 11, match/switch 3, boolean chains 1 (nesting depth added 41). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/field_reader.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"c74d54c0fed0c3004e6c67671dee5ad34dec746b5f17cd751b0956e5ccc46dc9"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.AppendNullableDefaultFieldsData (cognitive 73): importv2.AppendNullableDefaultFieldsData has cognitive complexity 73 (threshold 15). Drivers by points: if/else 64, loops 5, boolean chains 2, match/switch 2 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/util.go"},"region":{"startLine":462}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e3421a7304a73684567719cd7825d0bb572bcd863be3bdeca48395ff0e225ea"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.Parse (cognitive 72): rowParser.Parse has cognitive complexity 72 (threshold 15). Drivers by points: if/else 57, loops 13, boolean chains 2 (nesting depth added 38). Of this number, 59 points are the body\u0027s own statements and 13 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"f23b180d904bf4799dea6bcfeddf210a4b35790d554f79d12e2f6ad00fe8dd6f"}},{"ruleId":"D2","level":"warning","message":{"text":"writeBufferBase.submitSyncTasks (cognitive 71): writeBufferBase.submitSyncTasks has cognitive complexity 71 (threshold 15). Drivers by points: if/else 67, boolean chains 3, loops 1 (nesting depth added 46). Most of this is not in the body itself: 6 of the 71 points are its own statements and the rest belongs to one function literal inside it that branches (line 965). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"76190b87ddd06f5ccae10718d588f9e7ccbc56727b8694e8b4912831eeea4e10"}},{"ruleId":"D2","level":"warning","message":{"text":"queryTask.PreExecute (cognitive 70): queryTask.PreExecute has cognitive complexity 70 (threshold 15). Drivers by points: if/else 57, boolean chains 10, loops 3 (nesting depth added 14). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f57845088ea9c90c51eafb1811e60fd63a8309efe1b60e4104998cda21b2b2d"}},{"ruleId":"D2","level":"warning","message":{"text":"delegator.PruneSegments (cognitive 69): delegator.PruneSegments has cognitive complexity 69 (threshold 15). Drivers by points: if/else 43, loops 23, boolean chains 3 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/segment_pruner.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"896b67cea0c94f2a58f7314507d4b8326561f53b05535be175ca3df92517d25d"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.estimateSizeBy (cognitive 69): typeutil.estimateSizeBy has cognitive complexity 69 (threshold 15). Drivers by points: if/else 48, loops 16, match/switch 5 (nesting depth added 50). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c9dd92a2dbe0465812af4e99937682a5d7fb5dce4283e75748379ca08b9aa5a"}},{"ruleId":"D2","level":"warning","message":{"text":"indexBuildTask.CreateTaskOnWorker (cognitive 68): indexBuildTask.CreateTaskOnWorker has cognitive complexity 68 (threshold 15). Drivers by points: if/else 57, boolean chains 8, loops 3 (nesting depth added 40). Of this number, 67 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_index.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"2763abf457ccaf45c8901736215c7236923eb56c237f610f697c6331010ce5ff"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.CheckStructArrayConsistency (cognitive 68): importv2.CheckStructArrayConsistency has cognitive complexity 68 (threshold 15). Drivers by points: if/else 51, loops 10, match/switch 4, boolean chains 3 (nesting depth added 44). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/util.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"18f1ade7988a3349afc0f00a18d46cfba505df0f3718e73ced010b0525e6aa96"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.ColumnBasedInsertMsgToInsertData (cognitive 68): storage.ColumnBasedInsertMsgToInsertData has cognitive complexity 68 (threshold 15). Drivers by points: if/else 58, loops 5, match/switch 3, boolean chains 2 (nesting depth added 29). Of this number, 20 points are the body\u0027s own statements and 48 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"91f5dfb07a6915053d17484308cb8c776ee024e46da7b6d68fc121d748c73bd3"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.Parse (cognitive 68): rowParser.Parse has cognitive complexity 68 (threshold 15). Drivers by points: if/else 60, loops 6, boolean chains 2 (nesting depth added 38). Of this number, 66 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"f642aa4794e76c120991119a152d577b31b6f70c8667716a6759ab1193771b48"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndInWithRange (cognitive 66): visitor.combineAndInWithRange has cognitive complexity 66 (threshold 15). Drivers by points: if/else 43, boolean chains 14, loops 9 (nesting depth added 28). Of this number, 65 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc3352d4f8f6fe61c32a06d25d5219285eca14aab81bc3ec60c0317e688636fc"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.broadcastAlterCollectionForAlterCollection (cognitive 66): Core.broadcastAlterCollectionForAlterCollection has cognitive complexity 66 (threshold 15). Drivers by points: if/else 51, boolean chains 8, loops 5, match/switch 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_properties.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"22b9a20d85a36ea1d35331bcf60fab168a0c92ed30785dcf8775e5ef656cfd78"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.BuildStatsFromFieldBinlogs (cognitive 66): storage.BuildStatsFromFieldBinlogs has cognitive complexity 66 (threshold 15). Drivers by points: if/else 38, loops 26, boolean chains 2 (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/statistics.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"75ec27eb0596a8d5323be5079e5befcd4e1cad8a0ac0dacfa10e9d1942036db1"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.parseEntity (cognitive 66): rowParser.parseEntity has cognitive complexity 66 (threshold 15). Drivers by points: if/else 59, loops 4, boolean chains 2, match/switch 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d512b125038e2d3725ff6df9c399aab6bca88f10b0238fdaab250e4ad0fa6e9"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableBinaryData (cognitive 66): parquet.ReadNullableBinaryData has cognitive complexity 66 (threshold 15). Drivers by points: if/else 44, loops 19, match/switch 2, boolean chains 1 (nesting depth added 43). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":917}}}],"partialFingerprints":{"codehealthFindingId/v1":"8476ae145fda82045809e2f8f248e1f80ffb325ecbcb2cee00b1474fbf716d0a"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.buildMergedScalarField (cognitive 66): queryutil.buildMergedScalarField has cognitive complexity 66 (threshold 15). Drivers by points: if/else 39, loops 26, match/switch 1 (nesting depth added 39). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ef876f160d2098475db66aae42b2c00f8adef473f6fa6abdf5b6607c72923bf"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCompactionTask.writeSegment (cognitive 65): mixCompactionTask.writeSegment has cognitive complexity 65 (threshold 15). Drivers by points: if/else 58, loops 3, match/switch 3, boolean chains 1 (nesting depth added 38). Of this number, 61 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a28ab412083645ebae834be9d493624823adfbab48253afa622f89f00aa1b4d"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.AddFieldDataToPayload (cognitive 65): storage.AddFieldDataToPayload has cognitive complexity 65 (threshold 15). Drivers by points: if/else 56, loops 8, match/switch 1 (nesting depth added 36). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"134d0e0cfe04584c61b92af596766f0d7f632d6d16fe6a674542eca82189d4c9"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.mappingSegment (cognitive 64): clusteringCompactionTask.mappingSegment has cognitive complexity 64 (threshold 15). Drivers by points: if/else 58, loops 6 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f29080efc0493eb93239a43d7a951f5386f10610ed82a9ec193cf403f46937"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndInWithEqual (cognitive 64): visitor.combineAndInWithEqual has cognitive complexity 64 (threshold 15). Drivers by points: if/else 40, loops 21, boolean chains 3 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"60873a0850859dee4e3dcf7fe4cd898a8bffeaebaf32ebb6046d19ca0114be27"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.MergeSort (cognitive 64): storage.MergeSort has cognitive complexity 64 (threshold 15). Drivers by points: if/else 56, loops 6, match/switch 2 (nesting depth added 31). Of this number, 37 points are the body\u0027s own statements and 27 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/sort.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b244f53439f79f0504e637523fe334fba168db5b6a065a4969ee0ede3a714fe"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.PrivilegeInterceptor (cognitive 63): proxy.PrivilegeInterceptor has cognitive complexity 63 (threshold 15). Drivers by points: if/else 50, boolean chains 7, loops 6 (nesting depth added 26). Of this number, 59 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/privilege_interceptor.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"744d2c8d47b1133cb92261b4c951ed7e3afdde17d37f424ca22135f643ff7bdb"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseSearchInfo (cognitive 63): proxy.parseSearchInfo has cognitive complexity 63 (threshold 15). Drivers by points: if/else 54, boolean chains 9 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"233d6fd34939024b82eceb6fb4e7b77127ea4a1f4071ddd59cfe4b32f3f9c21e"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.CreateInsertData (cognitive 63): testutil.CreateInsertData has cognitive complexity 63 (threshold 15). Drivers by points: if/else 42, match/switch 9, loops 7, boolean chains 5 (nesting depth added 30). Of this number, 58 points are the body\u0027s own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ad0022492c700688ec69836af49f45b0045b90f03252d23b790009f75ff7d8a"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.NewLexicalHighlighter (cognitive 62): proxy.NewLexicalHighlighter has cognitive complexity 62 (threshold 15). Drivers by points: if/else 53, loops 6, boolean chains 3 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"f771c18ca82113e8066e918b2f38df9f731003c30b6692914a2792e6078bf776"}},{"ruleId":"D2","level":"warning","message":{"text":"bumpSchemaVersionCompactionTask.runFullSchemaRewrite (cognitive 61): bumpSchemaVersionCompactionTask.runFullSchemaRewrite has cognitive complexity 61 (threshold 15). Drivers by points: if/else 52, boolean chains 7, loops 2 (nesting depth added 20). Of this number, 60 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"310ad5dc1964354b76d9893f51a539c5813fc6b632b9366be420d3d71803dddc"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.runMultiFieldGroupByHotLoop (cognitive 61): proxy.runMultiFieldGroupByHotLoop has cognitive complexity 61 (threshold 15). Drivers by points: if/else 46, loops 9, boolean chains 3, match/switch 3 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"b53d574fbe64479ec07aeb08f44fca29606c0b003ce2842b36cffc808a001426"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.arrayToFieldData (cognitive 61): rowParser.arrayToFieldData has cognitive complexity 61 (threshold 15). Drivers by points: if/else 46, loops 14, match/switch 1 (nesting depth added 37). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"c40fde67d90c7fc214d5d88a42a251d65851b003458c0651d5c358a57e2a4903"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateWholeStructFieldDataForPartialUpdate (cognitive 60): proxy.validateWholeStructFieldDataForPartialUpdate has cognitive complexity 60 (threshold 15). Drivers by points: if/else 46, loops 12, boolean chains 2 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1193}}}],"partialFingerprints":{"codehealthFindingId/v1":"09f8c8a739aedc8e82c0973cec8a1cfb3262d99d564059cabea7e631aeb93236"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.FromSearchResultData (cognitive 60): chain.FromSearchResultData has cognitive complexity 60 (threshold 15). Drivers by points: if/else 46, boolean chains 7, loops 7 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"8606e2e9e0b26b50085965211276ca470d2b3ee838ee79bac03db7852c78131c"}},{"ruleId":"D2","level":"warning","message":{"text":"AdaptiveRateLimitController.backgroundLoop (cognitive 60): AdaptiveRateLimitController.backgroundLoop has cognitive complexity 60 (threshold 15). Drivers by points: if/else 45, match/switch 11, boolean chains 3, loops 1 (nesting depth added 38). Of this number, 58 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/ratelimit/adaptive_rate_limit_controller.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb45062dbf309a459f32460ca41bad5a21904354b2ac8b23fedcbb505b3bcd40"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrRangePredicates (cognitive 59): visitor.combineOrRangePredicates has cognitive complexity 59 (threshold 15). Drivers by points: if/else 34, loops 16, boolean chains 9 (nesting depth added 28). Of this number, 58 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1d2b210d97c5bb38dff8df1990a3d41d7328d5466aff35e60f0b3fb44595b73"}},{"ruleId":"D2","level":"warning","message":{"text":"validateUtil.Validate (cognitive 59): validateUtil.Validate has cognitive complexity 59 (threshold 15). Drivers by points: if/else 56, match/switch 2, loops 1 (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f4dc3941cc9e91c6f55f906f72067769d12b248269ec189a06949ec53970745"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reduceAdvanceGroupBy (cognitive 58): proxy.reduceAdvanceGroupBy has cognitive complexity 58 (threshold 15). Drivers by points: if/else 36, loops 22 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdcef335e7281e821888123f7f704ca1108401f45a763535a49e9ce62adb34b6"}},{"ruleId":"D2","level":"warning","message":{"text":"orderByOperator.reorderResults (cognitive 58): orderByOperator.reorderResults has cognitive complexity 58 (threshold 15). Drivers by points: if/else 49, boolean chains 7, loops 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"890e39501a5975a102565481e1d9bf921cf33c0e085fbc9536795a1a4fe5581c"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.PreExecute (cognitive 58): createCollectionTask.PreExecute has cognitive complexity 58 (threshold 15). Drivers by points: if/else 50, boolean chains 4, loops 4 (nesting depth added 11). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e902708a36e4f1786ccf14d53403de493dfb6ed10db876aef0823274e6d926c"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldStats.UnmarshalJSON (cognitive 58): FieldStats.UnmarshalJSON has cognitive complexity 58 (threshold 15). Drivers by points: if/else 46, boolean chains 9, match/switch 3 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_stats.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2cd10264d2ffc502e2a8df3654c1c764b7b209937981c0771a37784cf0c70bf"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.CreateInsertDataForCSV (cognitive 58): testutil.CreateInsertDataForCSV has cognitive complexity 58 (threshold 15). Drivers by points: if/else 38, loops 11, match/switch 7, boolean chains 2 (nesting depth added 38). Of this number, 57 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1611}}}],"partialFingerprints":{"codehealthFindingId/v1":"96a586328f9cf2c8dbaa7c79b816f83e8488c83f2f0613d9b124575b9bbcb747"}},{"ruleId":"D2","level":"warning","message":{"text":"externalCollectionRefreshChecker.aggregateJobState (cognitive 57): externalCollectionRefreshChecker.aggregateJobState has cognitive complexity 57 (threshold 15). Drivers by points: if/else 49, boolean chains 5, loops 3 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_checker.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"97210d1580029dcb4e15af0804deb9d4a28875b7f103b7068f3bb3b20d82f6f5"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reduceSearchResultDataNoGroupBy (cognitive 57): proxy.reduceSearchResultDataNoGroupBy has cognitive complexity 57 (threshold 15). Drivers by points: if/else 37, loops 18, boolean chains 2 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc80e49bc0803f24fb77b30ab098f5bb2c6cf6b01632feb45786ed648b201dc9"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.loadStreamDelete (cognitive 57): shardDelegator.loadStreamDelete has cognitive complexity 57 (threshold 15). Drivers by points: if/else 41, loops 14, match/switch 2 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1006}}}],"partialFingerprints":{"codehealthFindingId/v1":"98fe44d318c0307faf192117ef5c56b2066c43e2df7444755419a2d1e6721b0a"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.getPKsFromRowBasedInsertMsg (cognitive 57): segments.getPKsFromRowBasedInsertMsg has cognitive complexity 57 (threshold 15). Drivers by points: if/else 40, loops 15, match/switch 2 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/utils.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f64b11192f647b624ec0b8ccc824c64cf2b20267ea9d0a1c5d4d6b65ad195cc"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.printBinlogFile (cognitive 57): storage.printBinlogFile has cognitive complexity 57 (threshold 15). Drivers by points: if/else 54, match/switch 2, loops 1 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"5240397b4d9d18fc66508b721528d5e19d2913d42667399f62c635a95166467c"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.unmarshalVectorField (cognitive 57): fastpb.unmarshalVectorField has cognitive complexity 57 (threshold 15). Drivers by points: if/else 48, boolean chains 6, match/switch 2, loops 1 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"12434acfadded0c8a1b46d6046c55f53c3b63771c9a307041eb9f33709c214c6"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.removeArrayRow (cognitive 57): typeutil.removeArrayRow has cognitive complexity 57 (threshold 15). Drivers by points: if/else 30, loops 20, boolean chains 6, match/switch 1 (nesting depth added 28). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4253}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a554626fa6d1d9247c5d1a69ec1941be24a3a648bf03d9a75ef41dfaba9e645"}},{"ruleId":"D2","level":"warning","message":{"text":"row.AnyToColumns (cognitive 56): row.AnyToColumns has cognitive complexity 56 (threshold 15). Drivers by points: if/else 48, loops 7, boolean chains 1 (nesting depth added 28). Of this number, 54 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/data.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"7be9f777c09cfb30279684f2a366e974a92dd225c1bec778d0d2019804873b5b"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.checkParams (cognitive 56): datacoord.checkParams has cognitive complexity 56 (threshold 15). Drivers by points: if/else 32, loops 17, boolean chains 7 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"95fa9ecceb6dbccc6c5972a89941d84d8dea2c844fe813816ae313ee8915b52e"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.generatePlaceholderGroup (cognitive 56): httpserver.generatePlaceholderGroup has cognitive complexity 56 (threshold 15). Drivers by points: if/else 40, loops 13, boolean chains 3 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1768}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c5e32fd1e6e1bde2161fafd494c662a9de176d5c98f087d9530f7436c0ddc22"}},{"ruleId":"D2","level":"warning","message":{"text":"RefreshExternalCollectionTask.organizeSegments (cognitive 55): RefreshExternalCollectionTask.organizeSegments has cognitive complexity 55 (threshold 15). Drivers by points: if/else 47, loops 8 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"504833dca300de28d28063533a2f7cd3b59b9c305d974ca38f741905ddaebdcf"}},{"ruleId":"D2","level":"warning","message":{"text":"writebuffer.PrepareInsert (cognitive 55): writebuffer.PrepareInsert has cognitive complexity 55 (threshold 15). Drivers by points: if/else 37, loops 11, match/switch 5, boolean chains 2 (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1704}}}],"partialFingerprints":{"codehealthFindingId/v1":"70d79ee3e3c9ca49fa9e3ed0e88f9239b92d3d4363ce3d10d369f03f12a24e73"}},{"ruleId":"D2","level":"warning","message":{"text":"GrowingSourceSyncTask.Run (cognitive 54): GrowingSourceSyncTask.Run has cognitive complexity 54 (threshold 15). Drivers by points: if/else 48, boolean chains 6 (nesting depth added 16). Of this number, 50 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"a94a0e0345c751477be90da98a8242fdedd17cc4851acdbc36fc30fd8748cd39"}},{"ruleId":"D2","level":"warning","message":{"text":"externalspec.ValidateExtfsComplete (cognitive 54): externalspec.ValidateExtfsComplete has cognitive complexity 54 (threshold 15). Drivers by points: if/else 37, boolean chains 14, loops 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/externalspec/external_spec.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"183fa675eb647a796986e6b04cca2a990eb6904606c29eaa12fc77af2e0f54fa"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldData.AsSchemapb (cognitive 53): FieldData.AsSchemapb has cognitive complexity 53 (threshold 15). Drivers by points: if/else 40, loops 12, match/switch 1 (nesting depth added 28). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/wrap_request.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f6deee881ced739f1a1c556cc45499afadbfb2e8a8f4353555dc3b9a4dcfcbf"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.handleIfSearchByPK (cognitive 53): Proxy.handleIfSearchByPK has cognitive complexity 53 (threshold 15). Drivers by points: if/else 33, loops 12, boolean chains 4, match/switch 4 (nesting depth added 20). Of this number, 52 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":3361}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9b04160e9c752b658a215185f67d3649c7807fac9ac3f1d96548c35444307e1"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.arrayToFieldData (cognitive 53): rowParser.arrayToFieldData has cognitive complexity 53 (threshold 15). Drivers by points: if/else 40, loops 12, match/switch 1 (nesting depth added 32). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"26f9ed81ae200fda001f6db38a7d9b2231ec896db78a494afc4f008e3aa89119"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.insertRequest (cognitive 52): dec.insertRequest has cognitive complexity 52 (threshold 15). Drivers by points: if/else 46, match/switch 5, loops 1 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdb933598edfa2d9bfdd5cc6a6cc3246c334ec6e71eac5ac51bfd4054bb7af3a"}},{"ruleId":"D2","level":"warning","message":{"text":"funcutil.GetNumRowOfFieldDataWithSchema (cognitive 52): funcutil.GetNumRowOfFieldDataWithSchema has cognitive complexity 52 (threshold 15). Drivers by points: if/else 49, boolean chains 2, match/switch 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"4697a6fadffa4b018b544f88d10c0dbe2ff9cccd06c06bc3f57cef39d96b8f32"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.updateCompactNullableVectorFieldDataByColumn (cognitive 52): typeutil.updateCompactNullableVectorFieldDataByColumn has cognitive complexity 52 (threshold 15). Drivers by points: if/else 40, boolean chains 9, loops 2, match/switch 1 (nesting depth added 17). Of this number, 32 points are the body\u0027s own statements and 20 belong to 6 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2105}}}],"partialFingerprints":{"codehealthFindingId/v1":"efab516cb1dbd5943f4673cd8db0f0ba39f161316798423b38dc4ac1691058b7"}},{"ruleId":"D2","level":"warning","message":{"text":"TargetObserver.schedule (cognitive 51): TargetObserver.schedule has cognitive complexity 51 (threshold 15). Drivers by points: if/else 31, loops 11, match/switch 9 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/target_observer.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b5c205fb6dc9dc091c40250340d6bef49dbd48dcd8049482e38a955f5f9f7f5"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewFieldData (cognitive 51): storage.NewFieldData has cognitive complexity 51 (threshold 15). Drivers by points: if/else 50, match/switch 1 (nesting depth added 25). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/insert_data.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c5afa377ea8edfb184ad60929ac1cb6010fe386b805fe014d70d541b1db683b"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.scalarField (cognitive 51): dec.scalarField has cognitive complexity 51 (threshold 15). Drivers by points: if/else 47, match/switch 2, boolean chains 1, loops 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f80f2f0844e97bee0b540eb2198d46f2bfd61c7659a26c8bac1b2eefb187d0b"}},{"ruleId":"D2","level":"warning","message":{"text":"row.ParseSchema (cognitive 50): row.ParseSchema has cognitive complexity 50 (threshold 15). Drivers by points: if/else 34, match/switch 12, boolean chains 3, loops 1 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/schema.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"82d1fc1683bc8bcf349f83ed9c56b0e3917448aa37deb180be0a1c96bf669067"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleSnapshots (cognitive 50): garbageCollector.recycleSnapshots has cognitive complexity 50 (threshold 15). Drivers by points: if/else 38, loops 12 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":2041}}}],"partialFingerprints":{"codehealthFindingId/v1":"b893ff3a3a6a7b894eaa57a28f303c0afab833e195289df98656d40171a493f3"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.translateToOutputFieldIDs (cognitive 50): proxy.translateToOutputFieldIDs has cognitive complexity 50 (threshold 15). Drivers by points: if/else 29, loops 20, jumps 1 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"406e13ce1f4bab0afd5e7ecb3cc8662a3b98b49ac226bf6403eec343e0ed9b8a"}},{"ruleId":"D2","level":"warning","message":{"text":"importTask.PreExecute (cognitive 50): importTask.PreExecute has cognitive complexity 50 (threshold 15). Drivers by points: if/else 46, boolean chains 2, loops 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_import.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"a65ce95b149ce00961fac625456f726917084ceb7eb69c5e24db608cc0932539"}},{"ruleId":"D2","level":"warning","message":{"text":"delegator.BatchGetFromSegments (cognitive 50): delegator.BatchGetFromSegments has cognitive complexity 50 (threshold 15). Drivers by points: if/else 30, loops 12, boolean chains 8 (nesting depth added 24). Of this number, 49 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/distribution.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"72abf4a94819b37fc5aaacbea5b5b534ec6d8f77fd24147ea8505808e218c250"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.isSchemaEqual (cognitive 50): parquet.isSchemaEqual has cognitive complexity 50 (threshold 15). Drivers by points: if/else 39, loops 6, match/switch 3, boolean chains 2 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"9007ee665833c96e9c2c0d9f838896a5425dae08b879677fb49fb97b7aabd5b5"}},{"ruleId":"D2","level":"warning","message":{"text":"StructFieldReader.readArrayOfVectorField (cognitive 50): StructFieldReader.readArrayOfVectorField has cognitive complexity 50 (threshold 15). Drivers by points: if/else 36, loops 11, match/switch 2, boolean chains 1 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ad2434f543208e8a481f3726ba33024d67b898eb25d39657056d118702ab8f7"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.CreateInsertDataRowsForJSON (cognitive 50): testutil.CreateInsertDataRowsForJSON has cognitive complexity 50 (threshold 15). Drivers by points: if/else 24, loops 18, match/switch 7, boolean chains 1 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1484}}}],"partialFingerprints":{"codehealthFindingId/v1":"df9f3b2296cbdc0b5fa6fad8686415fb5ec19da03d987507557ee3d0b72c9400"}},{"ruleId":"D2","level":"warning","message":{"text":"MilvusRoles.Run (cognitive 49): MilvusRoles.Run has cognitive complexity 49 (threshold 15). Drivers by points: if/else 39, boolean chains 8, loops 2 (nesting depth added 9). Of this number, 38 points are the body\u0027s own statements and 11 belong to 4 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/roles/roles.go"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3ab5bdecf247c976742a2a40946168bd539e992fd656751cd326fc9e2e2bcc"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.doClean (cognitive 49): clusteringCompactionTask.doClean has cognitive complexity 49 (threshold 15). Drivers by points: if/else 26, loops 23 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"85b7f22b7b47da4a964de5a18a7b245c6d86b9464a60066f41f0cf2dd76edfc8"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.CreateIndex (cognitive 49): Server.CreateIndex has cognitive complexity 49 (threshold 15). Drivers by points: if/else 48, boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ab32be0a0d1146eed66b9f65e08379c4a52dc14e3a75a40494c02a231785f23"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reduceRetrieveResults (cognitive 49): proxy.reduceRetrieveResults has cognitive complexity 49 (threshold 15). Drivers by points: if/else 32, boolean chains 12, loops 5 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":1163}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1321f55bea41ca1c7ae9c7b3cc86609f1fc1653de5278c6d8852b2cbc72def8"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.sliceVectorField (cognitive 49): queryutil.sliceVectorField has cognitive complexity 49 (threshold 15). Drivers by points: if/else 32, loops 15, boolean chains 1, match/switch 1 (nesting depth added 27). Of this number, 48 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"47b56037f524b1c2d2fb1e1d50bf32ec7358e0a2076c62bebbed63d9cff2e0ce"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.upsertRequest (cognitive 49): dec.upsertRequest has cognitive complexity 49 (threshold 15). Drivers by points: if/else 43, match/switch 5, loops 1 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/query_insert.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"da3046f2ce28c38052c2d524f7920093a80e846efd957c08e473d46e1f5892cb"}},{"ruleId":"D2","level":"warning","message":{"text":"ddNode.Operate (cognitive 48): ddNode.Operate has cognitive complexity 48 (threshold 15). Drivers by points: if/else 42, loops 3, match/switch 2, boolean chains 1 (nesting depth added 23). Of this number, 47 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/flow_graph_dd_node.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"3faa2081ae2c724e44a325c4d534c32eef054f12333eae33de62edb064def6da"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.Update (cognitive 47): Catalog.Update has cognitive complexity 47 (threshold 15). Drivers by points: if/else 35, match/switch 11, loops 1 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/update.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b85d096b422514468feff8f0f33f239476fe8e5c50edbcbab83467dd95764ed"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrInWithNotEqual (cognitive 47): visitor.combineOrInWithNotEqual has cognitive complexity 47 (threshold 15). Drivers by points: if/else 33, loops 12, boolean chains 2 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddf2df51b42141b06559b6e8429c33c962f33acf525ff7f6dd8bb39a456821b0"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.collapseElementLevelResultWithMetricDirection (cognitive 47): proxy.collapseElementLevelResultWithMetricDirection has cognitive complexity 47 (threshold 15). Drivers by points: if/else 32, loops 11, boolean chains 4 (nesting depth added 18). Of this number, 45 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"de459cc0795ae50fd196bc4244853e82c77412e5d2a4a27abb98c19fd10cb49a"}},{"ruleId":"D2","level":"warning","message":{"text":"Dispatcher.work (cognitive 47): Dispatcher.work has cognitive complexity 47 (threshold 15). Drivers by points: if/else 25, loops 14, boolean chains 6, match/switch 2 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/dispatcher.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"028496d3d65bec1d3057da1d621d45bb7e02a6dbf79cf4403a864e4e61dd5bf3"}},{"ruleId":"D2","level":"warning","message":{"text":"MqTtMsgStream.Seek (cognitive 47): MqTtMsgStream.Seek has cognitive complexity 47 (threshold 15). Drivers by points: if/else 40, loops 3, match/switch 3, boolean chains 1 (nesting depth added 26). Of this number, 35 points are the body\u0027s own statements and 12 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":848}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad5e297b769d83772711cdbf7cf5f028549cfc371cb9e05f36748c89dca72b0f"}},{"ruleId":"D2","level":"warning","message":{"text":"queryNodeConfig.init (cognitive 47): queryNodeConfig.init has cognitive complexity 47 (threshold 15). Drivers by points: if/else 39, boolean chains 8 (nesting depth added 4). Most of this is not in the body itself: 0 of the 47 points are its own statements and the rest belongs to 27 function literals inside it that branch (lines 4802, 4264, 4283, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/component_param.go"},"region":{"startLine":3896}}}],"partialFingerprints":{"codehealthFindingId/v1":"53a4cb1965d703cf45e434ec1b8e293baa8cf75723553fd53f1e1eb1eeec8ed8"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.buildIndexInfoFromSource (cognitive 46): importv2.buildIndexInfoFromSource has cognitive complexity 46 (threshold 15). Drivers by points: if/else 29, loops 17 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"5137f45c42d7d2cb8a040a5031ab590afac9c958e11d509db4dc787ecd06b487"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndInWithIn (cognitive 46): visitor.combineAndInWithIn has cognitive complexity 46 (threshold 15). Drivers by points: if/else 29, loops 15, boolean chains 1, jumps 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d9e2ca784e74cfc75094b5cef4141fc897f32f94a8429534b223907ba74c925"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndInWithNotEqual (cognitive 46): visitor.combineAndInWithNotEqual has cognitive complexity 46 (threshold 15). Drivers by points: if/else 32, loops 11, boolean chains 3 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"520385ae1a3a44f830c642bc1770a28b91a5102fe65666166e6430a7e50d934e"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.FillWithNullValue (cognitive 46): proxy.FillWithNullValue has cognitive complexity 46 (threshold 15). Drivers by points: if/else 43, match/switch 3 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"b41d77a46e5d1e0ef04416558114727bafd49989332207352dd89f3741573530"}},{"ruleId":"D2","level":"warning","message":{"text":"searchTask.PreExecute (cognitive 46): searchTask.PreExecute has cognitive complexity 46 (threshold 15). Drivers by points: if/else 41, boolean chains 5 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a566746ac92218033182ee0f3f1255c15b7727439f0ad89a77df33b6af5a879"}},{"ruleId":"D2","level":"warning","message":{"text":"InsertCodec.Serialize (cognitive 46): InsertCodec.Serialize has cognitive complexity 46 (threshold 15). Drivers by points: if/else 34, loops 9, boolean chains 3 (nesting depth added 17). Of this number, 27 points are the body\u0027s own statements and 19 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"684c68dc701858d55e6a69d56bb8c053d67773f7d4ae109df25df62620b83986"}},{"ruleId":"D2","level":"warning","message":{"text":"SortOp.Execute (cognitive 46): SortOp.Execute has cognitive complexity 46 (threshold 15). Drivers by points: if/else 38, loops 6, boolean chains 2 (nesting depth added 24). Of this number, 22 points are the body\u0027s own statements and 24 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_sort.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fbc039b998fc9d72a4989b09360f9ae8265e9f9710c0eef803d1c9794f50097"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.handleSearchResult (cognitive 45): Client.handleSearchResult has cognitive complexity 45 (threshold 15). Drivers by points: if/else 37, boolean chains 5, loops 3 (nesting depth added 20). Most of this is not in the body itself: 15 of the 45 points are its own statements and the rest belongs to one function literal inside it that branches (line 105). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"f785e7d4729dff1f9d03b5bee1b162c857464bdd3858665a1fae80252681383e"}},{"ruleId":"D2","level":"warning","message":{"text":"importTask.QueryTaskOnWorker (cognitive 45): importTask.QueryTaskOnWorker has cognitive complexity 45 (threshold 15). Drivers by points: if/else 39, loops 4, boolean chains 2 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_task_import.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"a39176d19a309e00551cd7e29f6b64024c0b33ab4f6ca18ddd8ae0d9e2d8a590"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.buildStructSubVectorField (cognitive 45): httpserver.buildStructSubVectorField has cognitive complexity 45 (threshold 15). Drivers by points: if/else 33, loops 11, match/switch 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1007}}}],"partialFingerprints":{"codehealthFindingId/v1":"81698064b6c5c867ad3ce112bd305884d64a7a2647c5d4a516cc444874cfbead"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.ListGrant (cognitive 45): Catalog.ListGrant has cognitive complexity 45 (threshold 15). Drivers by points: if/else 38, boolean chains 4, loops 3 (nesting depth added 22). Of this number, 36 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1689}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f1bfb99c034f66bbbe9c921b0a7635b834347e4447293277458c7c21dae6776"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.GetHighlight (cognitive 45): shardDelegator.GetHighlight has cognitive complexity 45 (threshold 15). Drivers by points: if/else 25, loops 19, boolean chains 1 (nesting depth added 28). Of this number, 38 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1485}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef82b02af84e30e5816d6a1a8844f0846d42f69d2d0291b225d3fc8bff543481"}},{"ruleId":"D2","level":"warning","message":{"text":"binlog.verify (cognitive 45): binlog.verify has cognitive complexity 45 (threshold 15). Drivers by points: if/else 32, loops 9, boolean chains 3, match/switch 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/util.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dbed772a73e028ec65f33dc12ae06b9cddbabb1e3f4ee0340794c2e5e077f67"}},{"ruleId":"D2","level":"warning","message":{"text":"objectstorage.NewMinioClient (cognitive 45): objectstorage.NewMinioClient has cognitive complexity 45 (threshold 15). Drivers by points: if/else 40, match/switch 3, boolean chains 2 (nesting depth added 16). Of this number, 37 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"14b8652543117141246de95e8470c66dd248ba17779ebd29788c0cff12494a3b"}},{"ruleId":"D2","level":"warning","message":{"text":"search_agg.resolveAggregationSpec (cognitive 44): search_agg.resolveAggregationSpec has cognitive complexity 44 (threshold 15). Drivers by points: if/else 36, loops 7, boolean chains 1 (nesting depth added 16). Most of this is not in the body itself: 6 of the 44 points are its own statements and the rest belongs to one function literal inside it that branches (line 262). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/context_builder.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"16d493243888928800f0e5649363e4a8ac86ca237213e212400b596d13c45844"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.processDeleteRecords (cognitive 44): shardDelegator.processDeleteRecords has cognitive complexity 44 (threshold 15). Drivers by points: if/else 28, loops 15, boolean chains 1 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":953}}}],"partialFingerprints":{"codehealthFindingId/v1":"61f7baf17c041f0f9d2428ae7110846e962993b9b26ac6cef355e2b1cb4658ca"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.calculateWriteRates (cognitive 44): QuotaCenter.calculateWriteRates has cognitive complexity 44 (threshold 15). Drivers by points: if/else 36, boolean chains 4, loops 4 (nesting depth added 18). Of this number, 40 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"b08b44e59b416f518ed6bf0f8e3338cfb488456b7019dfc0af3f4253855a33fd"}},{"ruleId":"D2","level":"warning","message":{"text":"reader.readDelete (cognitive 44): reader.readDelete has cognitive complexity 44 (threshold 15). Drivers by points: if/else 27, loops 10, boolean chains 4, match/switch 3 (nesting depth added 23). Of this number, 23 points are the body\u0027s own statements and 21 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/reader.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"49cbafd6ca0768fb885cdb1cbf89709b7272b1cb923370b4efc72bdbb2367a1a"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.readVectorArrayData (cognitive 44): parquet.readVectorArrayData has cognitive complexity 44 (threshold 15). Drivers by points: if/else 29, loops 7, match/switch 6, boolean chains 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2193}}}],"partialFingerprints":{"codehealthFindingId/v1":"379a6dfeb72cbf0f947de4d191028dcd2f9aa083cbf237deac99e76319a8fa52"}},{"ruleId":"D2","level":"warning","message":{"text":"SliceOperator.applyElementLevelSlice (cognitive 44): SliceOperator.applyElementLevelSlice has cognitive complexity 44 (threshold 15). Drivers by points: if/else 33, boolean chains 7, loops 4 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/slice_op.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"629cf82bebb768967525123cd358e93d14a9723cc1979a1a59b01d7953894059"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.compareFieldDataAt (cognitive 43): proxy.compareFieldDataAt has cognitive complexity 43 (threshold 15). Drivers by points: if/else 33, boolean chains 9, match/switch 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2426}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5168bc210f20844e4d39cf255963f5d39e137b1c1ec2eb3e978e3076e99d398"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.runSingleFieldGroupByHotLoop (cognitive 43): proxy.runSingleFieldGroupByHotLoop has cognitive complexity 43 (threshold 15). Drivers by points: if/else 30, loops 9, boolean chains 4 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"c21823f3e95e2ac4a2cfdd693ea45158076a6df358a98520c96d6f22d55a14c9"}},{"ruleId":"D2","level":"warning","message":{"text":"searchTask.PostExecute (cognitive 43): searchTask.PostExecute has cognitive complexity 43 (threshold 15). Drivers by points: if/else 34, loops 5, boolean chains 4 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":1355}}}],"partialFingerprints":{"codehealthFindingId/v1":"a864581b02936cf03fc90c8b8654efa3f2491cf45bdea740fff8d995146b808f"}},{"ruleId":"D2","level":"warning","message":{"text":"SearchCommonReduce.ReduceSearchResultData (cognitive 43): SearchCommonReduce.ReduceSearchResultData has cognitive complexity 43 (threshold 15). Drivers by points: if/else 30, loops 11, boolean chains 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d67d6375df0b6c0bbf9871c3f94cc519b30601b13e03ba65092b90189d9b981"}},{"ruleId":"D2","level":"warning","message":{"text":"indexcgowrapper.GenDataset (cognitive 43): indexcgowrapper.GenDataset has cognitive complexity 43 (threshold 15). Drivers by points: if/else 28, boolean chains 14, match/switch 1 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/indexcgowrapper/dataset.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"28b574bcc10bf9f81698eb17bbdee636321bd66cc15e9e26ca7b97aa88c75ca8"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetRecoveryInfo (cognitive 42): Server.GetRecoveryInfo has cognitive complexity 42 (threshold 15). Drivers by points: if/else 27, loops 11, boolean chains 4 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bc40f358c10ba0907e1fc9d033cd180c2dafb2df21e155bd4ae94999c3d9f1d"}},{"ruleId":"D2","level":"warning","message":{"text":"DataNode.CompactionV2 (cognitive 42): DataNode.CompactionV2 has cognitive complexity 42 (threshold 15). Drivers by points: if/else 37, boolean chains 4, match/switch 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee90343c913b80871f94a3305d2e22f00692c6d8c1431bcdc258853b61d3867"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateFieldPartialUpdateOps (cognitive 42): proxy.validateFieldPartialUpdateOps has cognitive complexity 42 (threshold 15). Drivers by points: if/else 35, loops 3, boolean chains 2, match/switch 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert_partial_op.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"b64c42af68c0fd75118469e35d3ee6922a3689e7b79a0d0dbf2df994651c6f4b"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.importFieldDataWithName (cognitive 42): chain.importFieldDataWithName has cognitive complexity 42 (threshold 15). Drivers by points: if/else 40, boolean chains 1, match/switch 1 (nesting depth added 18). Of this number, 40 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ef41f32a1ad0768ccf964571735233702b61b1ed1cde55bdebfffb47ad3717b"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.calcFieldElementSizeWithCompactIndex (cognitive 42): queryutil.calcFieldElementSizeWithCompactIndex has cognitive complexity 42 (threshold 15). Drivers by points: if/else 37, match/switch 4, boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1400}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd4f0f53c068848dc92a0946b3f46bbf3dedafd709804fbacfd4d45d9a7ab5ee"}},{"ruleId":"D2","level":"warning","message":{"text":"config.flattenAndMergeMap (cognitive 42): config.flattenAndMergeMap has cognitive complexity 42 (threshold 15). Drivers by points: if/else 28, loops 8, match/switch 6 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/config/config.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2b657e184ced191d165a58375bd42a868eaa8106bcdcee75b6fc7128fa18efe"}},{"ruleId":"D2","level":"warning","message":{"text":"retry.Do (cognitive 42): retry.Do has cognitive complexity 42 (threshold 15). Drivers by points: if/else 33, boolean chains 4, match/switch 3, loops 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/retry/retry.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c7942d0dd9845ce80faa2ca721cb84211e5c9103f966a382506059899ae8395"}},{"ruleId":"D2","level":"warning","message":{"text":"structArrayRowAccessor.row (cognitive 41): structArrayRowAccessor.row has cognitive complexity 41 (threshold 15). Drivers by points: if/else 29, loops 9, match/switch 2, boolean chains 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1451}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bf7f2a5a0b419005ac93f4671a5b91ff493ac95dc005dab28bcef17dd4e0148"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseQueryParams (cognitive 41): proxy.parseQueryParams has cognitive complexity 41 (threshold 15). Drivers by points: if/else 35, loops 4, boolean chains 2 (nesting depth added 15). Of this number, 40 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"986823e11ebe6d1178d8a0f8d489447937040cbb705a4e2558aa2cd658a17061"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.validatePartitionKey (cognitive 41): createCollectionTask.validatePartitionKey has cognitive complexity 41 (threshold 15). Drivers by points: if/else 35, loops 4, boolean chains 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0f931ad17ea6420c0651e1b9c8a88e86b75ef63f96e39a07bf5d9fa4b0ff331"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelLevelScoreBalancer.BalanceReplica (cognitive 41): ChannelLevelScoreBalancer.BalanceReplica has cognitive complexity 41 (threshold 15). Drivers by points: if/else 33, loops 6, boolean chains 2 (nesting depth added 19). Of this number, 38 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/balance/channel_level_score_balancer.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"647f919a4ff98f91293b85545b687fa23d02858d5172950399410b54fc703c72"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.rangeHitL0Deletions (cognitive 41): shardDelegator.rangeHitL0Deletions has cognitive complexity 41 (threshold 15). Drivers by points: if/else 27, loops 13, boolean chains 1 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":840}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4b74d0b6ca440eb280c1f9a64a9fd2f46a1d49728a13c30efeb047ab934c3c0"}},{"ruleId":"D2","level":"warning","message":{"text":"catchupScanner.consumeWithScanner (cognitive 41): catchupScanner.consumeWithScanner has cognitive complexity 41 (threshold 15). Drivers by points: if/else 37, match/switch 2, boolean chains 1, loops 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/scanner_switchable.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"71cc69539c37f718770518b730155fc45567bca266c3ca751caf12d5fc86ed36"}},{"ruleId":"D2","level":"warning","message":{"text":"validator.ValidateFunction (cognitive 41): validator.ValidateFunction has cognitive complexity 41 (threshold 15). Drivers by points: if/else 32, loops 8, boolean chains 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/validator.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e456039e06d28b89050a1d57cd0b764000a8f5506ba871879f8fe4aab7181e7"}},{"ruleId":"D2","level":"warning","message":{"text":"StructFieldReader.toScalarField (cognitive 41): StructFieldReader.toScalarField has cognitive complexity 41 (threshold 15). Drivers by points: if/else 24, loops 16, match/switch 1 (nesting depth added 24). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/struct_field_reader.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fdac6d15c5e05feeb548ef80876c39291edf59c9635645dd89a310a75bfef5c"}},{"ruleId":"D2","level":"warning","message":{"text":"resolverWithDiscoverer.doDiscover (cognitive 41): resolverWithDiscoverer.doDiscover has cognitive complexity 41 (threshold 15). Drivers by points: if/else 28, loops 8, match/switch 3, boolean chains 1, jumps 1 (nesting depth added 27). Of this number, 38 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/streamingutil/service/resolver/resolver_with_discoverer.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"1916c0d4ea18470da57209a2b7570b250501403d20353bf2b9c636934f31aa39"}},{"ruleId":"D2","level":"warning","message":{"text":"SearchAggregation.protoMessage (cognitive 40): SearchAggregation.protoMessage has cognitive complexity 40 (threshold 15). Drivers by points: if/else 35, loops 3, boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/search_aggregation.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3b50adf70505beecb5c5078f456ec81acb97831866e81e1a2106af1ff200ab1"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedJSONStatsFiles (cognitive 40): garbageCollector.recycleUnusedJSONStatsFiles has cognitive complexity 40 (threshold 15). Drivers by points: if/else 30, loops 9, boolean chains 1 (nesting depth added 26). Of this number, 32 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1820}}}],"partialFingerprints":{"codehealthFindingId/v1":"047fa1817fc5b2411b35158817b04bb24f7063e3971cee20c2614ea66d787960"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.NewMergeByPKWithOffsetsOperator (cognitive 40): segments.NewMergeByPKWithOffsetsOperator has cognitive complexity 40 (threshold 15). Drivers by points: if/else 29, boolean chains 6, loops 5 (nesting depth added 16). Most of this is not in the body itself: 0 of the 40 points are its own statements and the rest belongs to one function literal inside it that branches (line 65). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/ignore_non_pk_ops.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cc8373bfb418bd0a93cdd64073ad24b5473daf1dc4e34946c3f116d27ce48ff"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaTable.reload (cognitive 40): MetaTable.reload has cognitive complexity 40 (threshold 15). Drivers by points: if/else 23, loops 16, boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"60ee83bc7c1a98c56eb201f4640621c2249deca393f5f36c571985b2090f866d"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.collectMetrics (cognitive 40): QuotaCenter.collectMetrics has cognitive complexity 40 (threshold 15). Drivers by points: if/else 29, loops 11 (nesting depth added 10). Most of this is not in the body itself: 3 of the 40 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 473, 428, 559, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"98792186ac99d381ac59abf7a2eb434bd194385d9f4217bd3abae994e77fed34"}},{"ruleId":"D2","level":"warning","message":{"text":"TelemetryManager.validateAndTruncateMetrics (cognitive 40): TelemetryManager.validateAndTruncateMetrics has cognitive complexity 40 (threshold 15). Drivers by points: if/else 28, loops 11, boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/telemetry/manager.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"33bdb9f575eebb756bacdcfc7e05f7a44f8bac8671b28ecef5bbc25de575aac2"}},{"ruleId":"D2","level":"warning","message":{"text":"FuncChain.ExecuteWithOptions (cognitive 40): FuncChain.ExecuteWithOptions has cognitive complexity 40 (threshold 15). Drivers by points: if/else 37, match/switch 2, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/chain.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4bdd8f48097837b4c2a925692455c04317a574e50ddca019d297bad4482bf5c"}},{"ruleId":"D2","level":"warning","message":{"text":"objectstorage.NewGcpObjectStorageClient (cognitive 40): objectstorage.NewGcpObjectStorageClient has cognitive complexity 40 (threshold 15). Drivers by points: if/else 38, boolean chains 2 (nesting depth added 15). Of this number, 36 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f140e2f98d89c0f15c767080e9f18eaefe43df2c4d1a16403ce8e2b6abe9012"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.NormalizeAndValidateExternalCollectionSchema (cognitive 40): typeutil.NormalizeAndValidateExternalCollectionSchema has cognitive complexity 40 (threshold 15). Drivers by points: if/else 36, boolean chains 2, loops 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2625}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd192ed35a6da9ef7c5e7fcc2b35698f5474963e103f5fc1b4841810f1d2fd7e"}},{"ruleId":"D2","level":"warning","message":{"text":"column.parseVectorArrayData (cognitive 39): column.parseVectorArrayData has cognitive complexity 39 (threshold 15). Drivers by points: if/else 34, loops 4, match/switch 1 (nesting depth added 14). Of this number, 34 points are the body\u0027s own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0c2fa546fa4435461c1710687133f6bb7350ba9c829f46d67e74e485119b224"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.GetMetrics (cognitive 39): mixCoordImpl.GetMetrics has cognitive complexity 39 (threshold 15). Drivers by points: if/else 21, boolean chains 14, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":731}}}],"partialFingerprints":{"codehealthFindingId/v1":"7761968aa2b03ee955699e38004e739109c52a12388772c7f38d46f5ed10da99"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionTrigger.ShouldRebuildSegmentIndex (cognitive 39): compactionTrigger.ShouldRebuildSegmentIndex has cognitive complexity 39 (threshold 15). Drivers by points: if/else 31, loops 6, boolean chains 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae42841e395f336b7d4068af3abbaad7a7d6492f45bf0e29c9ed5fca8b002317"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.encodeEmbListQuery (cognitive 39): httpserver.encodeEmbListQuery has cognitive complexity 39 (threshold 15). Drivers by points: if/else 30, loops 8, match/switch 1 (nesting depth added 24). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1221}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ac1e9c69e50282fd56e846177c0ecf4148c3ec2c37b2532ea289402b300eae0"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.FillBinaryArithOpEvalRangeExpressionValue (cognitive 39): planparserv2.FillBinaryArithOpEvalRangeExpressionValue has cognitive complexity 39 (threshold 15). Drivers by points: if/else 31, boolean chains 8 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/fill_expression_value.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd4baa992c6291e68cd49ec96b53149dec1632b8e733385ff3d302be91d0bd9f"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseGroupByInfo (cognitive 39): proxy.parseGroupByInfo has cognitive complexity 39 (threshold 15). Drivers by points: if/else 35, loops 4 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":881}}}],"partialFingerprints":{"codehealthFindingId/v1":"55886e8284ecd95c74dcd8e263290049348a7df9f02662fb294954ba9f7dd1a5"}},{"ruleId":"D2","level":"warning","message":{"text":"delegator.FilterSegmentsByVector (cognitive 39): delegator.FilterSegmentsByVector has cognitive complexity 39 (threshold 15). Drivers by points: if/else 21, loops 9, match/switch 7, boolean chains 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/segment_pruner.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbab411e5f9acfa793435c8c431b535fd51e6b1c2e54a72ef27c2fba995e5f34"}},{"ruleId":"D2","level":"warning","message":{"text":"testutil.BuildSparseVectorData (cognitive 39): testutil.BuildSparseVectorData has cognitive complexity 39 (threshold 15). Drivers by points: if/else 23, loops 7, boolean chains 5, match/switch 4 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"8af9ffeaef3cf964ae100b1c67bd5823bd40c6a255cb4b9efc75426f0aa8dd02"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.CreateSparseFloatRowFromMap (cognitive 39): typeutil.CreateSparseFloatRowFromMap has cognitive complexity 39 (threshold 15). Drivers by points: if/else 29, loops 6, boolean chains 2, match/switch 2 (nesting depth added 14). Of this number, 26 points are the body\u0027s own statements and 13 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":3871}}}],"partialFingerprints":{"codehealthFindingId/v1":"175b3a51d5ad5dc4f59caedac983d8ae8abeeb45e69f4464eba499cc5779880b"}},{"ruleId":"D2","level":"warning","message":{"text":"FileResourceObserver.Sync (cognitive 38): FileResourceObserver.Sync has cognitive complexity 38 (threshold 15). Drivers by points: if/else 30, loops 6, boolean chains 2 (nesting depth added 22). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/file_resource_observer.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"52eca6f64a3879a7773d98803e107a197e01941683432beeb06236574bc09bf6"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.buildStructArrayFieldDataInternal (cognitive 38): httpserver.buildStructArrayFieldDataInternal has cognitive complexity 38 (threshold 15). Drivers by points: if/else 26, loops 9, match/switch 2, boolean chains 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1308}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6f9f8757f1b8998910410082b4cd3229953161f4f53504573871fcca04cf63"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.alterModifyCollection (cognitive 38): Catalog.alterModifyCollection has cognitive complexity 38 (threshold 15). Drivers by points: if/else 25, loops 12, boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"760b51e7c84aefcce94908c46326dde780e58401b8a1978c243ffda4ece8521f"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.visitBitwiseBinaryOp (cognitive 38): ParserVisitor.visitBitwiseBinaryOp has cognitive complexity 38 (threshold 15). Drivers by points: if/else 32, boolean chains 4, match/switch 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1946}}}],"partialFingerprints":{"codehealthFindingId/v1":"be37c1aab880f60068ba11ed94f115a90ec2692eb38b59ee9a3a3e5546b7d9ba"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.visitUnaryExpr (cognitive 38): visitor.visitUnaryExpr has cognitive complexity 38 (threshold 15). Drivers by points: if/else 34, boolean chains 4 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/entry.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"94f8e0ed517a62b0d668faaca7fe1e1b4663e9080972cc7a7c60428ccfe93e83"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateAddFieldRequest (cognitive 38): proxy.validateAddFieldRequest has cognitive complexity 38 (threshold 15). Drivers by points: if/else 29, boolean chains 5, loops 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":988}}}],"partialFingerprints":{"codehealthFindingId/v1":"32ebc86c052d40d565e7190b374dd16477cd2ee7e058046a7f5b9e24e5786aa1"}},{"ruleId":"D2","level":"warning","message":{"text":"hybridAssembleOperator.run (cognitive 38): hybridAssembleOperator.run has cognitive complexity 38 (threshold 15). Drivers by points: if/else 26, loops 12 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1648}}}],"partialFingerprints":{"codehealthFindingId/v1":"183757d3ea10c9530e7c4817b1b26db263283dd39ec06033ba1eb461bafc758d"}},{"ruleId":"D2","level":"warning","message":{"text":"insertTask.PreExecute (cognitive 38): insertTask.PreExecute has cognitive complexity 38 (threshold 15). Drivers by points: if/else 34, loops 3, boolean chains 1 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_insert.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"824e766e2e16e91758d43dface4460fc4f1646194a6e493b820ccc43c01c457a"}},{"ruleId":"D2","level":"warning","message":{"text":"UpdateLoadConfigJob.Execute (cognitive 38): UpdateLoadConfigJob.Execute has cognitive complexity 38 (threshold 15). Drivers by points: if/else 26, loops 11, boolean chains 1 (nesting depth added 16). Of this number, 20 points are the body\u0027s own statements and 18 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/job/job_update.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ba37a1fbe36765d8689e6c5c24eb5ef0bbd47be8c32432b42ced91ff0efa442"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectionManager.Recover (cognitive 38): CollectionManager.Recover has cognitive complexity 38 (threshold 15). Drivers by points: if/else 34, loops 4 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/collection_manager.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8b32b590fd6c41a51c55cdc5a81931239be1db7ab7c95c10fb4a7d7277d945e"}},{"ruleId":"D2","level":"warning","message":{"text":"timetickSync.startWatch (cognitive 38): timetickSync.startWatch has cognitive complexity 38 (threshold 15). Drivers by points: if/else 28, loops 8, match/switch 2 (nesting depth added 23). Of this number, 24 points are the body\u0027s own statements and 14 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/timeticksync.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a42cebe61f699777669f63d85374d03634fe2c931bba34237df397a6e21b127"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.ValueSerializer (cognitive 38): storage.ValueSerializer has cognitive complexity 38 (threshold 15). Drivers by points: if/else 23, loops 12, match/switch 3 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_events.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"71a26af203918de9e7d592160a916e09e7a0e61b6b88d070d892216c4b26bdc1"}},{"ruleId":"D2","level":"warning","message":{"text":"csv.NewRowParser (cognitive 38): csv.NewRowParser has cognitive complexity 38 (threshold 15). Drivers by points: if/else 26, loops 7, boolean chains 5 (nesting depth added 15). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9812c4bad5e7c83dafac9f09cae79f94f8d4209102480acd4536b9c20aa7216"}},{"ruleId":"D2","level":"warning","message":{"text":"numpy.validateHeader (cognitive 38): numpy.validateHeader has cognitive complexity 38 (threshold 15). Drivers by points: if/else 35, boolean chains 2, match/switch 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/util.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"4676e42cbab44306ad6e9daa6bced0b10c6977b9712cc0b97ee6bfb92cbadc80"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableSparseFloatVectorData (cognitive 38): parquet.ReadNullableSparseFloatVectorData has cognitive complexity 38 (threshold 15). Drivers by points: if/else 30, loops 7, boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc8d3e041d6c13eb9d2fb7a68d80e428f8cbc642e2a9e0e7f3a0ba96b0a40593"}},{"ruleId":"D2","level":"warning","message":{"text":"ReduceByPKWithTimestampOperator.mergeByPKWithTimestamp (cognitive 38): ReduceByPKWithTimestampOperator.mergeByPKWithTimestamp has cognitive complexity 38 (threshold 15). Drivers by points: if/else 30, boolean chains 5, loops 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/reduce_by_pk_op.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"77c643e2d4eb6a4cdb5b3e7edab5a55ce10a665d11e9a9e8088c64c4056dc4a9"}},{"ruleId":"D2","level":"warning","message":{"text":"schemautil.validateKeptEvolutionFields (cognitive 38): schemautil.validateKeptEvolutionFields has cognitive complexity 38 (threshold 15). Drivers by points: if/else 24, loops 12, boolean chains 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/schemautil/schema_evolution.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca02e2bbfa3583fc1a2c78ba3de4698c2aaf0ad154a7abb0fb6fb9a15cf6ffe6"}},{"ruleId":"D2","level":"warning","message":{"text":"retentionInfo.expiredCleanUp (cognitive 38): retentionInfo.expiredCleanUp has cognitive complexity 38 (threshold 15). Drivers by points: if/else 36, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_retention.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"560f059876e6fad08b88e51394a78fb35716d6c794302033633ebb49bdc18f4a"}},{"ruleId":"D2","level":"warning","message":{"text":"retry.Handle (cognitive 38): retry.Handle has cognitive complexity 38 (threshold 15). Drivers by points: if/else 28, boolean chains 5, match/switch 3, loops 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/retry/retry.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2d199ff227b22b1c6ba861dea6201a4f120164607d0661b6304f51a60295412"}},{"ruleId":"D2","level":"warning","message":{"text":"columnBasedDataOption.processInsertColumns (cognitive 37): columnBasedDataOption.processInsertColumns has cognitive complexity 37 (threshold 15). Drivers by points: if/else 30, loops 3, match/switch 3, boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/write_options.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"4973fd7d249427cc1619742777e09d3008d26707e759448900a00e9677156701"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.combineToCollectionIndexesMeta220 (cognitive 37): meta.combineToCollectionIndexesMeta220 has cognitive complexity 37 (threshold 15). Drivers by points: if/else 23, loops 14 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/210_to_220.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc1f00e7b566de7cd3b2a4c735103fdab7768d4c73c7de71f1cb6aef7e359e32"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetFlushAllState (cognitive 37): Server.GetFlushAllState has cognitive complexity 37 (threshold 15). Drivers by points: if/else 29, loops 6, jumps 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9663ab114165a1c1660bcbf727d3272c1775003dec811ffc5889db273cfdf86"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.classifyBackfillSegments (cognitive 37): Server.classifyBackfillSegments has cognitive complexity 37 (threshold 15). Drivers by points: if/else 34, loops 2, boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services_commit_backfill.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac6d2f423d84018f6067d98263717ad0feb33d455320f495c70a1ffa5fdb122f"}},{"ruleId":"D2","level":"warning","message":{"text":"bumpSchemaVersionCompactionTask.runMissingFunctionMaterialization (cognitive 37): bumpSchemaVersionCompactionTask.runMissingFunctionMaterialization has cognitive complexity 37 (threshold 15). Drivers by points: if/else 32, loops 5 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":946}}}],"partialFingerprints":{"codehealthFindingId/v1":"93ce9f0c2a719950d870fc091358beb39ce9140cbe52e62669b567dab5ce030b"}},{"ruleId":"D2","level":"warning","message":{"text":"BulkPackWriterV3.writeBM25Stasts (cognitive 37): BulkPackWriterV3.writeBM25Stasts has cognitive complexity 37 (threshold 15). Drivers by points: if/else 29, loops 6, boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8a51676f59e8e6d0af86239983ba895d40cd7be13340212bacd219f166e1afb"}},{"ruleId":"D2","level":"warning","message":{"text":"SearchGroupByReduce.ReduceSearchResultData (cognitive 37): SearchGroupByReduce.ReduceSearchResultData has cognitive complexity 37 (threshold 15). Drivers by points: if/else 27, loops 9, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d8216f8790866494a5ec7e0a051a5ae609867205a7b1410ed494e453adc0d97"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.extractSlice (cognitive 37): tasks.extractSlice has cognitive complexity 37 (threshold 15). Drivers by points: if/else 25, loops 11, boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/search_task_go_reduce.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f6a7f1592fece415950fefb17cc130b9f76b620d5742bcbbfe2c1ee566b6149"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.buildAlterSchemaAddSchema (cognitive 37): rootcoord.buildAlterSchemaAddSchema has cognitive complexity 37 (threshold 15). Drivers by points: if/else 21, loops 14, boolean chains 1, match/switch 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"12acfb6e8852571eeebf9878a2d888a5f8933cbad9edea03da47fa48ea999cc8"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.prepareSchema (cognitive 37): createCollectionTask.prepareSchema has cognitive complexity 37 (threshold 15). Drivers by points: if/else 30, loops 4, boolean chains 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"44058e7043885be77a3b2b0e568ea5c8cd1b29b8870400d08edd97a5e9f217d1"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldStats.UpdateByMsgs (cognitive 37): FieldStats.UpdateByMsgs has cognitive complexity 37 (threshold 15). Drivers by points: if/else 18, loops 18, match/switch 1 (nesting depth added 18). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_stats.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"616acbd37a98d7012b8cde607161bd86989ea49adc68c2e5d2e1568f1deb0d77"}},{"ruleId":"D2","level":"warning","message":{"text":"IndexFileBinlogCodec.DeserializeImpl (cognitive 37): IndexFileBinlogCodec.DeserializeImpl has cognitive complexity 37 (threshold 15). Drivers by points: if/else 31, loops 3, match/switch 3 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/index_data_codec.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ec7aca5780888fe03411b987e1d10fa00f84843311023cf4b18c52e517da7c4"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetSparseFloatVectorFromPayload (cognitive 37): PayloadReader.GetSparseFloatVectorFromPayload has cognitive complexity 37 (threshold 15). Drivers by points: if/else 31, loops 6 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1035}}}],"partialFingerprints":{"codehealthFindingId/v1":"19baf948530b773895eeb0e73d21d1f84bf5c3e17204ce3ee3bfa19640387687"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.buildVectorArrayFieldFromList (cognitive 37): parquet.buildVectorArrayFieldFromList has cognitive complexity 37 (threshold 15). Drivers by points: if/else 24, loops 10, match/switch 3 (nesting depth added 23). Of this number, 29 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2398}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca6ff2f32045b4c9f1c4be1f092c9ff6b4a30229e31f0bdccf40c26c539eca6b"}},{"ruleId":"D2","level":"warning","message":{"text":"Session.ProcessActiveStandBy (cognitive 37): Session.ProcessActiveStandBy has cognitive complexity 37 (threshold 15). Drivers by points: if/else 25, loops 6, match/switch 6 (nesting depth added 17). Of this number, 24 points are the body\u0027s own statements and 13 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"f09fa5fd3e043d089c451cf0a6424bd14540c364a693e6683c1041757a2a1d6a"}},{"ruleId":"D2","level":"warning","message":{"text":"DataNode.CreateTask (cognitive 36): DataNode.CreateTask has cognitive complexity 36 (threshold 15). Drivers by points: if/else 35, match/switch 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b07212771521d7baea19ac48aad7d4306ab1db4eb42b86481ce9d8155e2d2c1"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.AlterGrant (cognitive 36): Catalog.AlterGrant has cognitive complexity 36 (threshold 15). Drivers by points: if/else 36 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1611}}}],"partialFingerprints":{"codehealthFindingId/v1":"5425ae5c795ce857abf53ae6d3c897cdaeb4458c244e187a1d499787f83fc124"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineAndNotEqualsToNotIn (cognitive 36): visitor.combineAndNotEqualsToNotIn has cognitive complexity 36 (threshold 15). Drivers by points: if/else 22, loops 13, boolean chains 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b997ac3b5dec2f5a10584eabdc29dad9c501ed88eaf1184c8867e75e3ca886"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateDropField (cognitive 36): proxy.validateDropField has cognitive complexity 36 (threshold 15). Drivers by points: if/else 25, loops 10, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"88e469ee7ee9f0a626c645d2ad2275d714882c23db7a2d503cb8265a5e50f934"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.broadcastAlterCollectionSchemaAdd (cognitive 36): Core.broadcastAlterCollectionSchemaAdd has cognitive complexity 36 (threshold 15). Drivers by points: if/else 27, loops 9 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"52a59b1e17fb6119e4aad1259dbfe7370017ac5ee68d5c892e02b9eab8fd1c5e"}},{"ruleId":"D2","level":"warning","message":{"text":"nodeCtxManager.workNodeStart (cognitive 36): nodeCtxManager.workNodeStart has cognitive complexity 36 (threshold 15). Drivers by points: if/else 29, loops 4, match/switch 2, boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/flowgraph/node.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5f4b6fa56516fc605ff58a2bf155335ebc73e7d61772367dd2389ec9ec65743"}},{"ruleId":"D2","level":"warning","message":{"text":"replicateStreamClient.recvLoop (cognitive 35): replicateStreamClient.recvLoop has cognitive complexity 35 (threshold 15). Drivers by points: if/else 27, loops 5, match/switch 2, boolean chains 1 (nesting depth added 21). Of this number, 29 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cdc/replication/replicatestream/replicate_stream_client_impl.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"21236b2b527bfccf04b8417c470cd71dea7ed6bb2eb01c3706f79596f0777607"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionTrigger.handleSignal (cognitive 35): compactionTrigger.handleSignal has cognitive complexity 35 (threshold 15). Drivers by points: if/else 28, boolean chains 4, loops 3 (nesting depth added 16). Of this number, 32 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"98c3073ef7154ac5fce82d9459233b9959e600a4c2c45883a6903b291f345c7c"}},{"ruleId":"D2","level":"warning","message":{"text":"importChecker.checkGC (cognitive 35): importChecker.checkGC has cognitive complexity 35 (threshold 15). Drivers by points: if/else 25, boolean chains 5, match/switch 3, loops 2 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_checker.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed9e7d5ecd5532ded2a6038e9f9bd9708219c06f315f4c2d068896462331c338"}},{"ruleId":"D2","level":"warning","message":{"text":"analyzeTask.CreateTaskOnWorker (cognitive 35): analyzeTask.CreateTaskOnWorker has cognitive complexity 35 (threshold 15). Drivers by points: if/else 31, loops 3, boolean chains 1 (nesting depth added 19). Of this number, 33 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_analyze.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffc75af16ea54075446ca3a469896844903433451058f0d4104dd98a2b245395"}},{"ruleId":"D2","level":"warning","message":{"text":"compactor.createTextIndex (cognitive 35): compactor.createTextIndex has cognitive complexity 35 (threshold 15). Drivers by points: if/else 27, loops 6, boolean chains 2 (nesting depth added 13). Most of this is not in the body itself: 11 of the 35 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 133, 78). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/compactor_common.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0d732ba2c2fd45eeeed17a269fab93dd993c066dddbe63e3db034c8b8dab123"}},{"ruleId":"D2","level":"warning","message":{"text":"rewriter.normalizeTermExpr (cognitive 35): rewriter.normalizeTermExpr has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22, loops 10, boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/json_term.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3433ecb21a064f81ebf2d76236eb0f2ebb88278bd309317e12547ccd96a00fe"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.CheckTimeTickLagExceeded (cognitive 35): rootcoord.CheckTimeTickLagExceeded has cognitive complexity 35 (threshold 15). Drivers by points: if/else 28, boolean chains 4, loops 3 (nesting depth added 14). Most of this is not in the body itself: 8 of the 35 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 255, 278, 307). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"e82fcd5954851c52ff1c646f549b83143f7c76b5817d866c278fc24c46c2e54b"}},{"ruleId":"D2","level":"warning","message":{"text":"ConsumeServer.sendLoop (cognitive 35): ConsumeServer.sendLoop has cognitive complexity 35 (threshold 15). Drivers by points: if/else 32, match/switch 2, loops 1 (nesting depth added 22). Of this number, 29 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/service/handler/consumer/consume_server.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"2813eccfcb3f9554b823e822883c701a3af1453d2330a09fa06a6d85c1e3219f"}},{"ruleId":"D2","level":"warning","message":{"text":"l0Reader.Read (cognitive 35): l0Reader.Read has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22, loops 10, match/switch 3 (nesting depth added 19). Of this number, 20 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/l0_reader.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c07d80156e9c6a71d5444e0dab845a9b3a8a2f17c907d404147f78cfec8f5b3"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadBinaryData (cognitive 35): parquet.ReadBinaryData has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22, loops 11, match/switch 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":864}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc08cd3f0e6d5749f2bad9e0b7da842d048b05b8a507223039a3225042a9c65d"}},{"ruleId":"D2","level":"warning","message":{"text":"ProxyWatcher.startWatchEtcd (cognitive 35): ProxyWatcher.startWatchEtcd has cognitive complexity 35 (threshold 15). Drivers by points: if/else 25, match/switch 6, loops 4 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/proxyutil/proxy_watcher.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"4384429eded75407d32e5ddc689d84a57bac7da3cdd0c0965a2b07f8fd50cd5d"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.AssembleCopySegmentRequest (cognitive 34): datacoord.AssembleCopySegmentRequest has cognitive complexity 34 (threshold 15). Drivers by points: if/else 26, loops 8 (nesting depth added 19). Of this number, 29 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b2049f204e25749181bb1e5a9b9fd2154ceeab5b471a8d71510944fc29ed99d"}},{"ruleId":"D2","level":"warning","message":{"text":"LevelZeroCompactionTask.splitAndWrite (cognitive 34): LevelZeroCompactionTask.splitAndWrite has cognitive complexity 34 (threshold 15). Drivers by points: if/else 30, loops 4 (nesting depth added 17). Most of this is not in the body itself: 6 of the 34 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 222, 253). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/l0_compactor.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d077a642eaa6b73990ae413df2d91f8ed0c3423980978a3cac6d77c24d5665c"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCompactionTask.Compact (cognitive 34): mixCompactionTask.Compact has cognitive complexity 34 (threshold 15). Drivers by points: if/else 28, boolean chains 3, loops 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"60ebe2235de65d91c2f9c9682d57114c49dd4f872041c1410d7857b1247cab7f"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.checkFieldsDataBySchema (cognitive 34): proxy.checkFieldsDataBySchema has cognitive complexity 34 (threshold 15). Drivers by points: if/else 23, boolean chains 9, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1833}}}],"partialFingerprints":{"codehealthFindingId/v1":"68d098fab2b4c4458eef5dfda5973299238b10a90b2d69c803f41c422cbc4927"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaCache.update (cognitive 34): MetaCache.update has cognitive complexity 34 (threshold 15). Drivers by points: if/else 25, boolean chains 7, loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd40f6020da73a8fa59635275ae11d66484f3f67c81e298f9fb886ba99807621"}},{"ruleId":"D2","level":"warning","message":{"text":"SimpleLimiter.Check (cognitive 34): SimpleLimiter.Check has cognitive complexity 34 (threshold 15). Drivers by points: if/else 22, loops 8, boolean chains 4 (nesting depth added 15). Of this number, 33 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/simple_rate_limiter.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3037f9f654e781f01c1a137d70a00b5019d0768de23d6a92582fba454c4edd8"}},{"ruleId":"D2","level":"warning","message":{"text":"deleteRunner.Init (cognitive 34): deleteRunner.Init has cognitive complexity 34 (threshold 15). Drivers by points: if/else 33, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_delete.go"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"90aab64a959a07d9653a4f8d35919dffaf4aa71ba7de316bb6bf716e7ba067aa"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.RecordToInsertData (cognitive 34): storage.RecordToInsertData has cognitive complexity 34 (threshold 15). Drivers by points: if/else 27, loops 4, boolean chains 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/record_to_insert.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb00567c5b49636cfe74bc1f0edb46d6fd33e279c39d2bf6e4af89bae733ebb3"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.BuildRecord (cognitive 34): storage.BuildRecord has cognitive complexity 34 (threshold 15). Drivers by points: if/else 23, loops 8, match/switch 2, boolean chains 1 (nesting depth added 14). Most of this is not in the body itself: 10 of the 34 points are its own statements and the rest belongs to one function literal inside it that branches (line 1374). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde.go"},"region":{"startLine":1369}}}],"partialFingerprints":{"codehealthFindingId/v1":"8770d7ec64ce774d6ff9f0232b2fc8ef9002e6fb8bfa38dff630174abdf9a300"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.valueDeserializer (cognitive 34): storage.valueDeserializer has cognitive complexity 34 (threshold 15). Drivers by points: if/else 30, loops 4 (nesting depth added 19). Of this number, 31 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_events.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c178ce46b0b71a3f8aa657d73c20c32b04400a810364c92af4dcb4b75e4544"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddFloatVectorToPayload (cognitive 34): NativePayloadWriter.AddFloatVectorToPayload has cognitive complexity 34 (threshold 15). Drivers by points: if/else 21, loops 11, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"18814b947c098cde014b9138592859c12cac799ebe25334537ecba4b4cce5a6d"}},{"ruleId":"D2","level":"warning","message":{"text":"StatisticsCollector.Digest (cognitive 34): StatisticsCollector.Digest has cognitive complexity 34 (threshold 15). Drivers by points: if/else 19, loops 10, boolean chains 5 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/statistics.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"05bfdcee84eca4ec0fdf52ed6ba426c243066b6e27fea32e16feda95e82e54f9"}},{"ruleId":"D2","level":"warning","message":{"text":"common.FieldHasWarmupKey (cognitive 34): common.FieldHasWarmupKey has cognitive complexity 34 (threshold 15). Drivers by points: if/else 20, loops 14 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/common/common.go"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"430d774b709bf2d5b654ff9bd4836a195ea49d3dfc3989e7c968ad24494dad7c"}},{"ruleId":"D2","level":"warning","message":{"text":"common.FieldHasMmapKey (cognitive 34): common.FieldHasMmapKey has cognitive complexity 34 (threshold 15). Drivers by points: if/else 20, loops 14 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/common/common.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"8afdb2c723442c1846c35f1cac7291d245c52060d3b690376a95c387930d6563"}},{"ruleId":"D2","level":"warning","message":{"text":"CreateIndexTask.Await (cognitive 33): CreateIndexTask.Await has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16, match/switch 11, loops 4, boolean chains 2 (nesting depth added 21). Of this number, 16 points are the body\u0027s own statements and 17 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/index.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d7f5cff980425cb5961c66ac90dae91c35d78b1a0269b67dfd212ecdb56ccd9"}},{"ruleId":"D2","level":"warning","message":{"text":"bumpSchemaVersionTask.QueryTaskOnWorker (cognitive 33): bumpSchemaVersionTask.QueryTaskOnWorker has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 1, match/switch 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfaeaa4e38b72e8c26728e154e836efddce00a43ec1abe09ae16cff441c3d0eb"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.GetQuotaInfo (cognitive 33): meta.GetQuotaInfo has cognitive complexity 33 (threshold 15). Drivers by points: if/else 22, loops 10, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb46553bcbbc8f9338a0819085695b6956d329a2c0d3dd5207318ec66a8dcb43"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.SaveBinlogPaths (cognitive 33): Server.SaveBinlogPaths has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":599}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2379118a0b628b535f82dc38bfad97847f9ad9a061096d15d7ed9ae80dfdd52"}},{"ruleId":"D2","level":"warning","message":{"text":"compactor.mergeSortMultipleSegments (cognitive 33): compactor.mergeSortMultipleSegments has cognitive complexity 33 (threshold 15). Drivers by points: if/else 25, loops 6, boolean chains 1, match/switch 1 (nesting depth added 12). Of this number, 20 points are the body\u0027s own statements and 13 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/merge_sort.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0c8375ef2ae9d278b6bfd5fb42ee109d7821630c6018aad5f424544574f457c"}},{"ruleId":"D2","level":"warning","message":{"text":"statsTask.createTextIndex (cognitive 33): statsTask.createTextIndex has cognitive complexity 33 (threshold 15). Drivers by points: if/else 24, loops 6, boolean chains 3 (nesting depth added 11). Most of this is not in the body itself: 14 of the 33 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 506, 558). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"a007949260d1786c274c79d0306ac63d182dbca133693ecdf3b3b50d045c3e92"}},{"ruleId":"D2","level":"warning","message":{"text":"statsTask.createJSONKeyStats (cognitive 33): statsTask.createJSONKeyStats has cognitive complexity 33 (threshold 15). Drivers by points: if/else 19, loops 11, boolean chains 3 (nesting depth added 12). Of this number, 18 points are the body\u0027s own statements and 15 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"13d55696baa06921c001fcc45f35baaef1217c8d94c11ac490463276d9eecdf1"}},{"ruleId":"D2","level":"warning","message":{"text":"writeBufferBase.growingSourceProgressSyncable (cognitive 33): writeBufferBase.growingSourceProgressSyncable has cognitive complexity 33 (threshold 15). Drivers by points: if/else 25, boolean chains 8 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":692}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5cffd18c583b1fe3e4bc725e4325391c9facb010adf3b8d3921baddd21e66f5"}},{"ruleId":"D2","level":"warning","message":{"text":"rewriter.cmpGeneric (cognitive 33): rewriter.cmpGeneric has cognitive complexity 33 (threshold 15). Drivers by points: if/else 24, match/switch 9 (nesting depth added 21). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"580bdf7e3dc10f869428c4e1c489f27bc912d9ae539bffeebb8965c2607cc3cd"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseOrderByFieldSpec (cognitive 33): proxy.parseOrderByFieldSpec has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"015add375c5cbc3e3951c6a25a94176641a81568bcb3d6bd4f181ce51c48ea68"}},{"ruleId":"D2","level":"warning","message":{"text":"search_agg.compareValues (cognitive 33): search_agg.compareValues has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 1, match/switch 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"10827e347bf9e8f21f6bc72dbb258cc09ca4616986a60fbfd52c4fb44b41ecab"}},{"ruleId":"D2","level":"warning","message":{"text":"rerankOperator.run (cognitive 33): rerankOperator.run has cognitive complexity 33 (threshold 15). Drivers by points: if/else 18, loops 13, boolean chains 2 (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1218}}}],"partialFingerprints":{"codehealthFindingId/v1":"893c22c2cc216db19c3c63e59f0c6bd31fe015d2a9b842041c72e7a5004c7fb5"}},{"ruleId":"D2","level":"warning","message":{"text":"upsertTask.PreExecute (cognitive 33): upsertTask.PreExecute has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, boolean chains 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1518}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3ae9db292cf836b387e5a8f7cf4df41d1c0ab0c220877c3f773620c5735f50b"}},{"ruleId":"D2","level":"warning","message":{"text":"IndexChecker.checkReplica (cognitive 33): IndexChecker.checkReplica has cognitive complexity 33 (threshold 15). Drivers by points: if/else 19, loops 13, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/index_checker.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"84139b9fc11f0f4abcc7e3dd529a5f74fe4762ebf742b44af4607fcb1570fe41"}},{"ruleId":"D2","level":"warning","message":{"text":"CoordinatorBroker.GetCollectionLoadInfo (cognitive 33): CoordinatorBroker.GetCollectionLoadInfo has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/coordinator_broker.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"977c38f4d63ca8bbc7a7ffa430e5c562d95ad567ff1d0e9637ad843e560ec4c8"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.getCurrentUserVisibleCollections (cognitive 33): Core.getCurrentUserVisibleCollections has cognitive complexity 33 (threshold 15). Drivers by points: if/else 26, boolean chains 4, loops 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":3310}}}],"partialFingerprints":{"codehealthFindingId/v1":"9667d47fabace8bae557066221645daff12586ff294e4627241961faab92bf36"}},{"ruleId":"D2","level":"warning","message":{"text":"AzureObjectStorage.WalkWithObjects (cognitive 33): AzureObjectStorage.WalkWithObjects has cognitive complexity 33 (threshold 15). Drivers by points: if/else 20, loops 13 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/azure_object_storage.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c7d98b86af425a86ce064ef239ae19f44b6839eb47266f98f7cc4aa58c35146"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetBinaryVectorFromPayload (cognitive 33): PayloadReader.GetBinaryVectorFromPayload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":682}}}],"partialFingerprints":{"codehealthFindingId/v1":"8311c157d4e0fe7036cb25526fde861988a229d383c861c730b9ca9bc34dd4be"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetFloat16VectorFromPayload (cognitive 33): PayloadReader.GetFloat16VectorFromPayload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0a87174359951c61834533d699335a982d68216a5a187257da0e19ce8ea55f9"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetBFloat16VectorFromPayload (cognitive 33): PayloadReader.GetBFloat16VectorFromPayload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":859}}}],"partialFingerprints":{"codehealthFindingId/v1":"80db9ce8739dbd8522f1aa18e155475265faff6a6844ed4f938e3e1aca252939"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetFloatVectorFromPayload (cognitive 33): PayloadReader.GetFloatVectorFromPayload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":947}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe6613952407d554be6ff2dd1e98f8076682b0e12348284013e2647f9541e65a"}},{"ruleId":"D2","level":"warning","message":{"text":"PayloadReader.GetInt8VectorFromPayload (cognitive 33): PayloadReader.GetInt8VectorFromPayload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1114}}}],"partialFingerprints":{"codehealthFindingId/v1":"35ae4a13f85dd57b973eddc31fdf795cbb160f50571861dc1ba6b772b4a4d00f"}},{"ruleId":"D2","level":"warning","message":{"text":"PrimaryKeyStats.UnmarshalJSON (cognitive 33): PrimaryKeyStats.UnmarshalJSON has cognitive complexity 33 (threshold 15). Drivers by points: if/else 27, boolean chains 5, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/stats.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"35e076d1a4dd0cf0d98469a522daffb53a263259de2e0e5273f643f22752d4f9"}},{"ruleId":"D2","level":"warning","message":{"text":"optimizers.OptimizeSearchParams (cognitive 33): optimizers.OptimizeSearchParams has cognitive complexity 33 (threshold 15). Drivers by points: if/else 21, boolean chains 11, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/searchutil/optimizers/query_hook.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"84d81874cf25c25ffb462f7a72ad33fcbf396cdb4f32fa064a1373b660787199"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.FilterInIndexedSegments (cognitive 32): datacoord.FilterInIndexedSegments has cognitive complexity 32 (threshold 15). Drivers by points: if/else 21, loops 9, boolean chains 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/util.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"76a12e4961e73bdddad3691a3735b42b6949a952a043aadbfdc6ee28a115ff4f"}},{"ruleId":"D2","level":"warning","message":{"text":"bumpSchemaVersionPolicy.Trigger (cognitive 32): bumpSchemaVersionPolicy.Trigger has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25, loops 6, jumps 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_bump_schema_version.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"d125ba5bff96c0e5c10dcf967eafa53d15af84d29455bb8ba91d9ab01c29a2e6"}},{"ruleId":"D2","level":"warning","message":{"text":"statsTask.SetJobInfo (cognitive 32): statsTask.SetJobInfo has cognitive complexity 32 (threshold 15). Drivers by points: if/else 28, boolean chains 3, match/switch 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_stats.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdb9f069282a7fb3e763c1130ef90d526e3b397da06c01281bd9c5eb200d96cf"}},{"ruleId":"D2","level":"warning","message":{"text":"sortCompactionTask.sortSegment (cognitive 32): sortCompactionTask.sortSegment has cognitive complexity 32 (threshold 15). Drivers by points: if/else 29, boolean chains 2, match/switch 1 (nesting depth added 8). Of this number, 22 points are the body\u0027s own statements and 10 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/sort_compaction.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a68a904dbf4615b5afcb51580c1dc85d9cb243168171ae26b2aaf7ba269f074"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.buildStructSubArrayScalar (cognitive 32): httpserver.buildStructSubArrayScalar has cognitive complexity 32 (threshold 15). Drivers by points: if/else 18, loops 12, boolean chains 1, match/switch 1 (nesting depth added 18). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":932}}}],"partialFingerprints":{"codehealthFindingId/v1":"2651297e0eb5018c2caf31834241438ec5c1f45acea46d95146bc9101fc1a00b"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV2.advancedSearch (cognitive 32): HandlersV2.advancedSearch has cognitive complexity 32 (threshold 15). Drivers by points: if/else 28, boolean chains 2, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2117}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3661027bdc0759fb71d7e7f9615ca6dd4b1ad8820c4f5a78069f31d2c592476"}},{"ruleId":"D2","level":"warning","message":{"text":"BulkPackWriter.writeBM25Stasts (cognitive 32): BulkPackWriter.writeBM25Stasts has cognitive complexity 32 (threshold 15). Drivers by points: if/else 27, loops 5 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"275e9eaf6d71fcad08bdf80765d965f50c95c36407c4ca00ec1c6cf045327b32"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.MigrateGrantCollectionName (cognitive 32): Catalog.MigrateGrantCollectionName has cognitive complexity 32 (threshold 15). Drivers by points: if/else 27, loops 4, boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1856}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe43790e9aaa2dbd4b0c73406ef1e2121cd4d4f74989d8f8da57f707c388986d"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitMulDivMod (cognitive 32): ParserVisitor.VisitMulDivMod has cognitive complexity 32 (threshold 15). Drivers by points: if/else 26, boolean chains 4, match/switch 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f57079650253bcb9d827812f39a9556e7802f5851d5010223169255a573a2e7"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.verifyDynamicFieldData (cognitive 32): proxy.verifyDynamicFieldData has cognitive complexity 32 (threshold 15). Drivers by points: if/else 23, loops 9 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2700}}}],"partialFingerprints":{"codehealthFindingId/v1":"72125b31f71af939215f0380f1e871379aeb090ae587ead045229aa02d257433"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.DumpMessages (cognitive 32): Proxy.DumpMessages has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25, boolean chains 4, match/switch 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":7075}}}],"partialFingerprints":{"codehealthFindingId/v1":"726668d9d556b31bc1bc5f554b4254ecb41a62cbb18fd124a98b3475caa08089"}},{"ruleId":"D2","level":"warning","message":{"text":"taskScheduler.preAdd (cognitive 32): taskScheduler.preAdd has cognitive complexity 32 (threshold 15). Drivers by points: if/else 29, match/switch 3 (nesting depth added 19). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":763}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a0670d74a853e6767f4ffc78051d929d95c1bbe334bdc14bd0f0ed19f9a69c2"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.fillMissingFields (cognitive 32): storage.fillMissingFields has cognitive complexity 32 (threshold 15). Drivers by points: if/else 22, loops 9, boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"61281631433b1ad718ca3e21335d51117d5823a527da33558c39bb56b8c15056"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ConvertToArrowSchemaForUT (cognitive 32): parquet.ConvertToArrowSchemaForUT has cognitive complexity 32 (threshold 15). Drivers by points: if/else 22, loops 4, boolean chains 3, match/switch 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/util.go"},"region":{"startLine":488}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba6250c5527709b5dc2382ef77ae389051899132ebf7b6dd6b71e35e2c11db6"}},{"ruleId":"D2","level":"warning","message":{"text":"kafka.newKafkaConsumer (cognitive 32): kafka.newKafkaConsumer has cognitive complexity 32 (threshold 15). Drivers by points: if/else 27, match/switch 4, boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mqwrapper/kafka/kafka_consumer.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bfd324331c1dba90f5cfdab3c028fedf5ebccadad4490164a5f65bab798c3d4"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldDataBuilder.Build (cognitive 32): FieldDataBuilder.Build has cognitive complexity 32 (threshold 15). Drivers by points: if/else 21, loops 10, match/switch 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/field_data.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaa783f626f368caf410e5423a0efb87b28b34aa15f0977b9de6f45b1146c5fc"}},{"ruleId":"D2","level":"warning","message":{"text":"copySegmentChecker.checkGC (cognitive 31): copySegmentChecker.checkGC has cognitive complexity 31 (threshold 15). Drivers by points: if/else 24, loops 6, boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_checker.go"},"region":{"startLine":714}}}],"partialFingerprints":{"codehealthFindingId/v1":"c13298ca0a71ab196d959cc07970b8dd13a2e123abea19d37f98fe74f553515b"}},{"ruleId":"D2","level":"warning","message":{"text":"replicateService.overwriteReplicateMessage (cognitive 31): replicateService.overwriteReplicateMessage has cognitive complexity 31 (threshold 15). Drivers by points: if/else 28, loops 2, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/replicate_service.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6b99a067350f230dbb3fea61aaac207468cf892e0576d22aa56ae5deb464f77"}},{"ruleId":"D2","level":"warning","message":{"text":"lexicalHighlightOperator.run (cognitive 31): lexicalHighlightOperator.run has cognitive complexity 31 (threshold 15). Drivers by points: if/else 25, loops 6 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f121aac7d4bda0e7558830bffbffd767c0742a4666105caca2fd9e712f8e4ce"}},{"ruleId":"D2","level":"warning","message":{"text":"SearchAggregationComputer.computeLevel (cognitive 31): SearchAggregationComputer.computeLevel has cognitive complexity 31 (threshold 15). Drivers by points: if/else 25, loops 5, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"aac1081c4b56f49b02f50f66b4dc27c55c6b737e8dfe6cfaf7ef3b4b04cfc05c"}},{"ruleId":"D2","level":"warning","message":{"text":"upsertTask.insertPreExecute (cognitive 31): upsertTask.insertPreExecute has cognitive complexity 31 (threshold 15). Drivers by points: if/else 26, loops 5 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1323}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d477c0a6e6cf6a72131bbd10411cd130be9aeaf9bd618d3a1212ed8512cb08d"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.checkStructArrayFieldSchema (cognitive 31): rootcoord.checkStructArrayFieldSchema has cognitive complexity 31 (threshold 15). Drivers by points: if/else 25, boolean chains 3, loops 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a5e85a67b9daebfee81b9a0ff1bef5da527c447f549544e7eb35a9e6711afbc"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.getTimeTickDelayFactor (cognitive 31): QuotaCenter.getTimeTickDelayFactor has cognitive complexity 31 (threshold 15). Drivers by points: if/else 21, loops 7, boolean chains 3 (nesting depth added 13). Of this number, 27 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1000}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5dc58ba6d328cbaed441f4b6b3df6b6c35dcba92a935792ccb105c9c0fcd10d"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.ToSearchResultDataWithOptions (cognitive 31): chain.ToSearchResultDataWithOptions has cognitive complexity 31 (threshold 15). Drivers by points: if/else 23, loops 7, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"93495227167f642ff2a05ccaffc94c5ea7b914fd45c29907bbca4d63bb5b9f7e"}},{"ruleId":"D2","level":"warning","message":{"text":"VoyageAIEmbeddingProvider.CallEmbedding (cognitive 31): VoyageAIEmbeddingProvider.CallEmbedding has cognitive complexity 31 (threshold 15). Drivers by points: if/else 24, loops 7 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/voyageai_embedding_provider.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ada380a53adb4d35acd21fc910ea92088918dbd96eaafcebf0e1ad8d0941b10"}},{"ruleId":"D2","level":"warning","message":{"text":"numpy.decodeUtf32 (cognitive 31): numpy.decodeUtf32 has cognitive complexity 31 (threshold 15). Drivers by points: if/else 27, boolean chains 3, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/util.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"7393443a8773047ddc6c605cff34b21723be975997dcdeaa0dcd58351f4cc8a7"}},{"ruleId":"D2","level":"warning","message":{"text":"rocksmq.updateAckedInfo (cognitive 31): rocksmq.updateAckedInfo has cognitive complexity 31 (threshold 15). Drivers by points: if/else 27, loops 3, boolean chains 1 (nesting depth added 14). Of this number, 23 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_impl.go"},"region":{"startLine":1129}}}],"partialFingerprints":{"codehealthFindingId/v1":"605986897137eeefd8595dc652327799e0ec1bb3bbd4c7360c0d75ba1d31f8cd"}},{"ruleId":"D2","level":"warning","message":{"text":"Dispatcher.groupAndParseMsgs (cognitive 31): Dispatcher.groupAndParseMsgs has cognitive complexity 31 (threshold 15). Drivers by points: if/else 21, loops 8, boolean chains 2 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/dispatcher.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eaa5cddf8090d087978e0abeddd55ea628d4712cfa1d70bfb3a723899d561ec"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.EstimateEntitySize (cognitive 31): typeutil.EstimateEntitySize has cognitive complexity 31 (threshold 15). Drivers by points: if/else 24, match/switch 5, boolean chains 1, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"71fae6bc021c86b277fd42027857263d48a226e733cfc472d1b34e343e67b193"}},{"ruleId":"D2","level":"warning","message":{"text":"mck.handleUserEnter (cognitive 30): mck.handleUserEnter has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, loops 6 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b9bbb84dbccc16e75e0c774a9700ff4eb92f5a0d959bf5011235dde7c82dddc"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.countIndexedRows (cognitive 30): Server.countIndexedRows has cognitive complexity 30 (threshold 15). Drivers by points: if/else 17, loops 8, boolean chains 3, match/switch 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":633}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fe7dd294f38938b164723489caa5b300e8d01e7bdc5bf729fdebcf2bc3e4492"}},{"ruleId":"D2","level":"warning","message":{"text":"RefreshExternalCollectionTask.addMilvusTableL0DeltalogsToManifest (cognitive 30): RefreshExternalCollectionTask.addMilvusTableL0DeltalogsToManifest has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, loops 6 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/milvus_table_deltalog.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2e2766872355937bc4d4a24632b4da8c946e1158a1a2fd6433c7405a89731b0"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.convertHanToASCII (cognitive 30): planparserv2.convertHanToASCII has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21, boolean chains 4, match/switch 3, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":862}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0667c1ece68eb333fcc8d0d400eaf36b3947d6a6456858f01da6378dac12671"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.getColumnInfoFromJSONIdentifier (cognitive 30): ParserVisitor.getColumnInfoFromJSONIdentifier has cognitive complexity 30 (threshold 15). Drivers by points: if/else 22, boolean chains 7, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2120}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf60ef387b44befa4f85df2bcbd8ea14f35c332f2728ab9ef4a3c62e10296860"}},{"ruleId":"D2","level":"warning","message":{"text":"privilegeCache.RefreshPolicyInfo (cognitive 30): privilegeCache.RefreshPolicyInfo has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21, loops 8, match/switch 1 (nesting depth added 14). Of this number, 27 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/privilege/cache.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8ea467e2c803415fddeaf52f4e7ecae186240747db99359b6bec865b0b69af7"}},{"ruleId":"D2","level":"warning","message":{"text":"alterCollectionSchemaTask.preExecuteAdd (cognitive 30): alterCollectionSchemaTask.preExecuteAdd has cognitive complexity 30 (threshold 15). Drivers by points: if/else 30 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1155}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fccd58faeb9e4a4e2b7616cce55f823eb086c20d0c4729ffd941657fe20f11d"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentChecker.getSealedSegmentDiff (cognitive 30): SegmentChecker.getSealedSegmentDiff has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, boolean chains 3, loops 3 (nesting depth added 12). Of this number, 26 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/segment_checker.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eb3b1fd05bb69667f6af82c97ff08135d5b1d9bd3682a98ad5ce51a1bf874c6"}},{"ruleId":"D2","level":"warning","message":{"text":"delegator.executeSubTasks (cognitive 30): delegator.executeSubTasks has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, loops 2, boolean chains 1 (nesting depth added 11). Most of this is not in the body itself: 12 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 1066). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":1041}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dabcbb8f9a15d339fb60ea24717eb43fc37a6c9dee050f2921a2d481e05492d"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.getNeedChanNum (cognitive 30): rootcoord.getNeedChanNum has cognitive complexity 30 (threshold 15). Drivers by points: if/else 18, loops 12 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/dml_channels.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"847ecd232ba7d6365df5d772e2d0b2d255660f465e8d9c9e39e8d9614a12954f"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.printDDLPayloadValues (cognitive 30): storage.printDDLPayloadValues has cognitive complexity 30 (threshold 15). Drivers by points: if/else 22, loops 4, match/switch 4 (nesting depth added 19). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"3224005a6bbe08b8d0ef7178cb84655c9e5c4cd4699a0efa1e8137c192ed6af4"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.RowBasedInsertMsgToInsertData (cognitive 30): storage.RowBasedInsertMsgToInsertData has cognitive complexity 30 (threshold 15). Drivers by points: if/else 18, loops 6, match/switch 5, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"331e548eac408434b2c6d2e51e910dc548f524787da211f57bbfa1f3fee68f57"}},{"ruleId":"D2","level":"warning","message":{"text":"DataSorter.Swap (cognitive 30): DataSorter.Swap has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, match/switch 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_sorter.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38307ce65fe358ef493bce6534274a936462bcd55e34b0f9307555e55d6a525"}},{"ruleId":"D2","level":"warning","message":{"text":"timeTickAppendInterceptor.DoAppend (cognitive 30): timeTickAppendInterceptor.DoAppend has cognitive complexity 30 (threshold 15). Drivers by points: if/else 29, match/switch 1 (nesting depth added 14). Of this number, 24 points are the body\u0027s own statements and 6 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/interceptors/timetick/timetick_interceptor.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0e0a43a58590e0f2f4c14c83bb838cf5106668ce2f2c0b7da9f0f435e94528b"}},{"ruleId":"D2","level":"warning","message":{"text":"SyncManager.Sync (cognitive 30): SyncManager.Sync has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, loops 3 (nesting depth added 13). Of this number, 24 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/fileresource/manager.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"d170200745292e3c812e8d89bd300fc582216a41254fb1b4c7c2b5f7e51f0ba1"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldReader.ReadString (cognitive 30): FieldReader.ReadString has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, boolean chains 2, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/field_reader.go"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb7b88005d205a8e98be7f8b18ebba5ea107282edc8fe2210818d09e3fec24bb"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.readRawStringDataFromParquet (cognitive 30): parquet.readRawStringDataFromParquet has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, loops 4, boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"31c5eacce5177ed3100a44e179168de7e58ff43a900042817e3fef6d44f32355"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.buildVectorArrayFieldFromFixedSizeBinary (cognitive 30): parquet.buildVectorArrayFieldFromFixedSizeBinary has cognitive complexity 30 (threshold 15). Drivers by points: if/else 19, loops 10, match/switch 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":2315}}}],"partialFingerprints":{"codehealthFindingId/v1":"568a9f7ea697475ada8d3e2c6442f780254dee332079519f0a45144e25b88994"}},{"ruleId":"D2","level":"warning","message":{"text":"objectstorage.NewAzureObjectStorageClient (cognitive 30): objectstorage.NewAzureObjectStorageClient has cognitive complexity 30 (threshold 15). Drivers by points: if/else 26, boolean chains 2, match/switch 2 (nesting depth added 12). Of this number, 19 points are the body\u0027s own statements and 11 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/util.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc77757808c0939a02602243cca7d5c685392525ac468715dc8b5c60ec986f20"}},{"ruleId":"D2","level":"warning","message":{"text":"etcd.HealthCheck (cognitive 30): etcd.HealthCheck has cognitive complexity 30 (threshold 15). Drivers by points: if/else 17, loops 6, match/switch 5, boolean chains 2 (nesting depth added 13). Most of this is not in the body itself: 8 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 345). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/etcd/etcd_util.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d033594c47bdff4e02e0fd1278785d9ed0326f426168df1178ad886d3344de3"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicateConfigValidator.validateClusterBasic (cognitive 30): ReplicateConfigValidator.validateClusterBasic has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, loops 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/replicateutil/config_validator.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"90c0b9166c4902f04caf28807b22342bd48068bc9ec61dd50cb6002fb1d38bf5"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.CreateSchemaHelper (cognitive 30): typeutil.CreateSchemaHelper has cognitive complexity 30 (threshold 15). Drivers by points: if/else 28, loops 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"8db5aae20e2a384c1a7b2de919c5f3dd701879091fc14f34d4ebace67346757c"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetIndexInfos (cognitive 29): Server.GetIndexInfos has cognitive complexity 29 (threshold 15). Drivers by points: if/else 18, loops 9, boolean chains 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":1056}}}],"partialFingerprints":{"codehealthFindingId/v1":"a976f6abe005e0659594515864401268846012213bf243c939b44ab79dee41d2"}},{"ruleId":"D2","level":"warning","message":{"text":"ImportTask.importFile (cognitive 29): ImportTask.importFile has cognitive complexity 29 (threshold 15). Drivers by points: if/else 27, loops 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fea24bee9aef78b5dd6c92d625eeb9a78e1f7ad9691704607ef988a323df1db"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitLogicalAnd (cognitive 29): ParserVisitor.VisitLogicalAnd has cognitive complexity 29 (threshold 15). Drivers by points: if/else 22, boolean chains 7 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1849}}}],"partialFingerprints":{"codehealthFindingId/v1":"df73295ee4d7e82a847a3574d1ccbd64b1fd584aa39ad38b2c3514af2926dadc"}},{"ruleId":"D2","level":"warning","message":{"text":"task.applyCollectionWarmupSetting (cognitive 29): task.applyCollectionWarmupSetting has cognitive complexity 29 (threshold 15). Drivers by points: if/else 19, boolean chains 6, loops 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/utils.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a1472d5202db97f30d1eb3c783c625f5a91cfc679359217235bb5fd9ffaf77c"}},{"ruleId":"D2","level":"warning","message":{"text":"policy.Balance (cognitive 29): policy.Balance has cognitive complexity 29 (threshold 15). Drivers by points: if/else 21, loops 6, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/policy/vchannelfair/vchannel_fair_policy.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d76390c0e2bc6979c22e4487188fdd0b8a7a9563e71318390b201ff4dfee7ad"}},{"ruleId":"D2","level":"warning","message":{"text":"consumerImpl.recvLoop (cognitive 29): consumerImpl.recvLoop has cognitive complexity 29 (threshold 15). Drivers by points: if/else 26, match/switch 2, loops 1 (nesting depth added 16). Of this number, 27 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/client/handler/consumer/consumer_impl.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"63389f2ed84d9cd0673f3ee83db6f7a79068ade674fa43c836672830a3de5a4d"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.convertLegacyParams (cognitive 29): chain.convertLegacyParams has cognitive complexity 29 (threshold 15). Drivers by points: if/else 22, match/switch 6, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae41329eec98587e22cf052af44ea1d51df285621526ae999aacdcb347a7bdc9"}},{"ruleId":"D2","level":"warning","message":{"text":"CohereEmbeddingProvider.CallEmbedding (cognitive 29): CohereEmbeddingProvider.CallEmbedding has cognitive complexity 29 (threshold 15). Drivers by points: if/else 22, loops 7 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/cohere_embedding_provider.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee591939aaf4fe8148fd35a3e737aec78775343ed922c8c2cdaadcb80992722"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupAggReducer.validateAggregationResults (cognitive 28): GroupAggReducer.validateAggregationResults has cognitive complexity 28 (threshold 15). Drivers by points: if/else 23, loops 5 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_reducer.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"62d6d9bfa4411adfd9a9495127823cdb6879cb285637f1160cf07da1038d3805"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.HandleReplicaLoadConfigCompliance (cognitive 28): mixCoordImpl.HandleReplicaLoadConfigCompliance has cognitive complexity 28 (threshold 15). Drivers by points: if/else 18, loops 6, boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_replica.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"01d4a56b1366464072616deab0440ecc7b4486c21f774ad484a5309b6f5f8478"}},{"ruleId":"D2","level":"warning","message":{"text":"importChecker.checkSortingJob (cognitive 28): importChecker.checkSortingJob has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, loops 3, boolean chains 1 (nesting depth added 16). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_checker.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ad3a7f8c9c8d01a114bb1e5c4519f222f90731afe7b3262bee7086ca76dcf63"}},{"ruleId":"D2","level":"warning","message":{"text":"RefreshExternalCollectionTask.translateMilvusTableDeltalogsToVirtualPKManifest (cognitive 28): RefreshExternalCollectionTask.translateMilvusTableDeltalogsToVirtualPKManifest has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20, loops 8 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/milvus_table_deltalog.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb62a5bdc5a6ef3ffc71adb58303ffcaf12dee66089ba251671c93707b5d5f43"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.convertSearchAggregationReq (cognitive 28): httpserver.convertSearchAggregationReq has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, loops 3, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3639}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f299763052bb0a9f0c061ea81d42b47ec73570a5756b08932ce7f9791f2ed6"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV2.upsert (cognitive 28): HandlersV2.upsert has cognitive complexity 28 (threshold 15). Drivers by points: if/else 23, boolean chains 3, match/switch 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1650}}}],"partialFingerprints":{"codehealthFindingId/v1":"1edc9575bb73651401a471a5b27a84c16a1b2f89705c0da24b055c50e5bde4e0"}},{"ruleId":"D2","level":"warning","message":{"text":"ResumableProducer.produceInternal (cognitive 28): ResumableProducer.produceInternal has cognitive complexity 28 (threshold 15). Drivers by points: if/else 27, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/internal/producer/producer.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"770a55832c5b03aad403d0c3e1d0d4a4d460dfff643d6594eb8f8b5653641d7e"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.batchAppendPartitionAndFieldsInfo (cognitive 28): Catalog.batchAppendPartitionAndFieldsInfo has cognitive complexity 28 (threshold 15). Drivers by points: if/else 26, boolean chains 1, loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2bfabb12fe3ccdf313a3a8ea0d98e7f886cf85cae763b6a6cd45508c6edd9b4"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.ListRole (cognitive 28): Catalog.ListRole has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 2 (nesting depth added 12). Of this number, 26 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1277}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac44fdcc92893fee89b6267a5de35e7db4b7f2b32e8d1136b58fc1248515a750"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitUnary (cognitive 28): ParserVisitor.VisitUnary has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, match/switch 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1643}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8401e83e4259dc50431a1d102063329e523425c5725047b835cd2493fbae2ce"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrInWithEqual (cognitive 28): visitor.combineOrInWithEqual has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20, loops 6, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"c51a2a9c42032fb2c52c4d13e3cfd7857d238a3ba017c3b74d8399974352f08a"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateDropStructArrayField (cognitive 28): proxy.validateDropStructArrayField has cognitive complexity 28 (threshold 15). Drivers by points: if/else 19, loops 9 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1368}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d319700cc9ea86f6baca31a0dcf1964744332b4b493f55d70daf927ea5c3cd3"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateLoadFieldsList (cognitive 28): proxy.validateLoadFieldsList has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, loops 4 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":981}}}],"partialFingerprints":{"codehealthFindingId/v1":"968c469bef03ebef0c208bd48f34dcdb928dfb91013391aeb3f8628ba285a963"}},{"ruleId":"D2","level":"warning","message":{"text":"LookAsideBalancer.SelectNode (cognitive 28): LookAsideBalancer.SelectNode has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, boolean chains 4, loops 3 (nesting depth added 11). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/look_aside_balancer.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"6709c9b000e635fa3c5fe9b297f1c7c95321ff2033fced0a4a228ae02890a667"}},{"ruleId":"D2","level":"warning","message":{"text":"ScoreBasedAssignPolicy.AssignChannel (cognitive 28): ScoreBasedAssignPolicy.AssignChannel has cognitive complexity 28 (threshold 15). Drivers by points: if/else 25, loops 2, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/assign/assign_policy_score.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"65a412488433591e241eeaf91bc9fed48fbf3fb9edd1cf24d5802b754dc5ab16"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentChecker.Check (cognitive 28): SegmentChecker.Check has cognitive complexity 28 (threshold 15). Drivers by points: if/else 17, loops 11 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/segment_checker.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"40bba76ac96fe2947d1dfab9acba42417df28eb0910bdb1a04dcaa76d786121d"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelDistManager.GetShardLeader (cognitive 28): ChannelDistManager.GetShardLeader has cognitive complexity 28 (threshold 15). Drivers by points: if/else 17, match/switch 5, boolean chains 3, loops 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/channel_dist_manager.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"be3ce9bd7166be835772733c83a03876be4a1a54e15b855e04a9ecb824c55be6"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.TransferSegment (cognitive 28): Server.TransferSegment has cognitive complexity 28 (threshold 15). Drivers by points: if/else 27, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/ops_services.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0e12765039c92fb4fe588b42982317f2167c3d08d1d14b4393e756cd592f86a"}},{"ruleId":"D2","level":"warning","message":{"text":"InputNode.Operate (cognitive 28): InputNode.Operate has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, boolean chains 2, loops 2 (nesting depth added 11). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/flowgraph/input_node.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"688e744507d091255257b9f2e3ea8c97748b2892ae6da9e6129eef1726c3768c"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 27): main.main has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, match/switch 3, loops 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/main.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a2531c2ef6947faf139ef5024ce36da7337b7feebb4e5c27e322653be45888"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.GetStreamingNodeDistribution (cognitive 27): mixCoordImpl.GetStreamingNodeDistribution has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, loops 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_mgr_routes.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"92b10d10df8c6c6f89e9b890a01a15363f5a202e212374c4263154dc09c506de"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.QueryTaskOnWorker (cognitive 27): clusteringCompactionTask.QueryTaskOnWorker has cognitive complexity 27 (threshold 15). Drivers by points: if/else 25, boolean chains 1, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"477ac28d175142677723491ec91a5899e0fc480ada3faa2eec9d536b448a4f53"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleDroppedSegments (cognitive 27): garbageCollector.recycleDroppedSegments has cognitive complexity 27 (threshold 15). Drivers by points: if/else 19, loops 8 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":847}}}],"partialFingerprints":{"codehealthFindingId/v1":"96c5f4a1b7f3729a283cac869b8256c4a72f44107bd9bc6717d5d2f556f01d5d"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedSegIndexes (cognitive 27): garbageCollector.recycleUnusedSegIndexes has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, boolean chains 2, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1361}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0e3514e7be3cd774094b3ad3eaebbf61c6268a65b6137adb781b90c8e49de6c"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedJSONIndexFiles (cognitive 27): garbageCollector.recycleUnusedJSONIndexFiles has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 6 (nesting depth added 17). Of this number, 23 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1942}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba0268d335f3eedf5ac634d6c517c7a4c05494a35af7e3a83f23e65c6a7e7ef"}},{"ruleId":"D2","level":"warning","message":{"text":"ServerHandler.GetQueryVChanPositions (cognitive 27): ServerHandler.GetQueryVChanPositions has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14, boolean chains 8, loops 3, match/switch 2 (nesting depth added 8). Of this number, 24 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"83cbfcd3b359fa570588d5f78c8b07a22b82e1d4b9849ce96c22fff37cbcf98b"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.completeBumpSchemaVersionCompactionMutation (cognitive 27): meta.completeBumpSchemaVersionCompactionMutation has cognitive complexity 27 (threshold 15). Drivers by points: if/else 25, boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":3391}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd5353af0f10075866048727fbc1f4910c43b75ab239acda4663e0901fd5fd22"}},{"ruleId":"D2","level":"warning","message":{"text":"DataNode.QueryTask (cognitive 27): DataNode.QueryTask has cognitive complexity 27 (threshold 15). Drivers by points: if/else 26, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":773}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f192ce548c84b77ac04c678b4f0871395cda56e0583f92d882a9b3c4f2b8399"}},{"ruleId":"D2","level":"warning","message":{"text":"external.buildFunctionExecutionSchema (cognitive 27): external.buildFunctionExecutionSchema has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17, loops 7, boolean chains 3 (nesting depth added 8). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/function_executor.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbb923217ec8ad03185b95e9d06de9abb8e7d33c771ebfac1c5aa92c81e8cb0e"}},{"ruleId":"D2","level":"warning","message":{"text":"indexBuildTask.PreExecute (cognitive 27): indexBuildTask.PreExecute has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16, loops 10, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_index.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea848417069e7c7266b82a171c14bc4cdaa8530fc4865fd9d63295e97061364d"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.parseStructArrayRow (cognitive 27): httpserver.parseStructArrayRow has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, loops 6, match/switch 2, boolean chains 1 (nesting depth added 13). Of this number, 25 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":863}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f91832d807796c11d573bf0517392124fcde2958808bcd13088c1c62253ae9"}},{"ruleId":"D2","level":"warning","message":{"text":"txnTiKV.MultiSaveAndRemoveWithPrefix (cognitive 27): txnTiKV.MultiSaveAndRemoveWithPrefix has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 5 (nesting depth added 13). Most of this is not in the body itself: 1 of the 27 points is its own statement and the rest belongs to one function literal inside it that branches (line 545). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"05d23efc01beb42e4d531959116c7cea122aa0ed0b6cae30b9c31aa4ae8a2fe6"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.convertArrayValue (cognitive 27): planparserv2.convertArrayValue has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13, loops 12, boolean chains 1, match/switch 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/convert_field_data_to_generic_value.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"6832e9464fc6f5780d2fad4a99fc6f2e73a7bc711bb56ce295d6d65508066842"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitAddSub (cognitive 27): ParserVisitor.VisitAddSub has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, boolean chains 4, match/switch 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0a9676b6fa88ecba07588d5dd4889de4b46969147b36e6659159a0d8fae1739"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.repackInsertDataWithPartitionKeyForStreamingService (cognitive 27): proxy.repackInsertDataWithPartitionKeyForStreamingService has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17, loops 9, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_insert_streaming.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"2426d6bb8233d840f8ab115a122bd067bbd1682f2a7aa5dcb372cc01f24b802b"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaCache.getCollection (cognitive 27): MetaCache.getCollection has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, boolean chains 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"689b8cd2b5b69f7484318a130befd1127a9d7b7d0aad463c245905abd780d233"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.UpdateCredential (cognitive 27): Proxy.UpdateCredential has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 3, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5081}}}],"partialFingerprints":{"codehealthFindingId/v1":"c94875118b137bb0b50b0028319daf6e74bca9324e1fedd571ac5f3f2a8c9567"}},{"ruleId":"D2","level":"warning","message":{"text":"LBPolicyImpl.selectNode (cognitive 27): LBPolicyImpl.selectNode has cognitive complexity 27 (threshold 15). Drivers by points: if/else 23, loops 3, boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 3 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 161). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/lb_policy.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e3781d342ae462beda13b627c21bfb3169af02e7b40ba64ce3846aefc4de2a"}},{"ruleId":"D2","level":"warning","message":{"text":"LBPolicyImpl.ExecuteWithRetry (cognitive 27): LBPolicyImpl.ExecuteWithRetry has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, loops 2, boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 2 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 270). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/lb_policy.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6ce782106684ee43956f14444286a0dd3c1e640ff987f6c7e371e64e3edec62"}},{"ruleId":"D2","level":"warning","message":{"text":"showCollectionsTask.Execute (cognitive 27): showCollectionsTask.Execute has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, loops 9 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1858}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ca400d8fabc4e4bd95064a165ff2d7fcd90358d5ce42b9674c61a7293d2fd1a"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaObserver.checkStreamingQueryNodesInReplica (cognitive 27): ReplicaObserver.checkStreamingQueryNodesInReplica has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, loops 7, boolean chains 2 (nesting depth added 12). Of this number, 23 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/replica_observer.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b5464c43af3a30196654cc60db0d894958e59a3ccab8371e6dc821960c501b6"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaObserver.checkNodesInReplica (cognitive 27): ReplicaObserver.checkNodesInReplica has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, loops 7, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/replica_observer.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba4600138d3efb05177349a584b73006e10f6b39bb38685f1cd86794fdb7f4d"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.LoadBalance (cognitive 27): Server.LoadBalance has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/services.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"06503279928e52bc6fec6baecd901b625948c729f4f98f4d1faf7213fb935b2d"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaTable.CheckIfRBACRestorable (cognitive 27): MetaTable.CheckIfRBACRestorable has cognitive complexity 27 (threshold 15). Drivers by points: if/else 19, loops 6, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":2151}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4efa05d0baa61b79c1090be17693e4790f0894085b65e6bf743e84ccade8b28"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddBinaryVectorToPayload (cognitive 27): NativePayloadWriter.AddBinaryVectorToPayload has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"91462e57c7fac4f92d5917144a72465a007c1fd0f3868a2b9828d1c3b6e44001"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddFloat16VectorToPayload (cognitive 27): NativePayloadWriter.AddFloat16VectorToPayload has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":805}}}],"partialFingerprints":{"codehealthFindingId/v1":"b81486e8733f10d113deacefecd84d47d797ff65d77d653c3266ba038a555194"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddBFloat16VectorToPayload (cognitive 27): NativePayloadWriter.AddBFloat16VectorToPayload has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":865}}}],"partialFingerprints":{"codehealthFindingId/v1":"6efd3981dc91a56b4c7a5cf39485588e07b37de89dc6eaa0acfffa92708b3033"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddInt8VectorToPayload (cognitive 27): NativePayloadWriter.AddInt8VectorToPayload has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5ab09735564686902f36c1874f7e29beb9fd3d7873e7303a8b27add4209299f"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableIntegerOrFloatData (cognitive 27): parquet.ReadNullableIntegerOrFloatData has cognitive complexity 27 (threshold 15). Drivers by points: loops 19, if/else 6, match/switch 2 (nesting depth added 14). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"46476d0cbf733d545adade10e708b6ff00b2c82f37c3a50279cb9cdaddd8a094"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.rangeSliceVectorField (cognitive 27): queryutil.rangeSliceVectorField has cognitive complexity 27 (threshold 15). Drivers by points: if/else 19, loops 7, match/switch 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"2be3520ca0bb74a6b0fb47433c27b73674e2ef91d974e2995cae1a41a78dc8cf"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.sliceScalarField (cognitive 27): queryutil.sliceScalarField has cognitive complexity 27 (threshold 15). Drivers by points: loops 26, match/switch 1 (nesting depth added 13). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"43a60ebdb8bef22cfb53fd1976ffca906e77e697b76245483bd64c8abf22441c"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.compareValues (cognitive 27): queryutil.compareValues has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, boolean chains 2, match/switch 1 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1636}}}],"partialFingerprints":{"codehealthFindingId/v1":"e559da0e6d4b433062df8c68874401268b48c1d2dcbba308a18d08110e58c6a5"}},{"ruleId":"D2","level":"warning","message":{"text":"schemautil.validateAddedEvolutionFields (cognitive 27): schemautil.validateAddedEvolutionFields has cognitive complexity 27 (threshold 15). Drivers by points: if/else 23, boolean chains 2, loops 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/schemautil/schema_evolution.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"d52d5f1633982032b386632fd5e8261e4d7c29a79ea37734faa783391c4cde89"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.ids (cognitive 27): dec.ids has cognitive complexity 27 (threshold 15). Drivers by points: if/else 23, match/switch 2, boolean chains 1, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/searchresult.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d46131b622d86b2a2249a008fb203f6f2cf9b3d955c4bbe55f1675d4d930ba8"}},{"ruleId":"D2","level":"warning","message":{"text":"indexparams.NewBigDataExtraParamsFromMap (cognitive 27): indexparams.NewBigDataExtraParamsFromMap has cognitive complexity 27 (threshold 15). Drivers by points: if/else 26, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/indexparams/index_params.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"5daae3ea25c61ca053efc95f77be9f59a04f8ebac3bbe45e2a5c80e7c1e618fd"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.GetNeedProcessFunctions (cognitive 27): typeutil.GetNeedProcessFunctions has cognitive complexity 27 (threshold 15). Drivers by points: if/else 19, loops 8 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4010}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1d4e39b9a8e26f1c4d60121f88d9e349c37d685d6631ec97a62d3a794ec349e"}},{"ruleId":"D2","level":"warning","message":{"text":"row.getColumnCreators (cognitive 26): row.getColumnCreators has cognitive complexity 26 (threshold 15). Drivers by points: if/else 23, match/switch 2, loops 1 (nesting depth added 16). Most of this is not in the body itself: 1 of the 26 points is its own statement and the rest belongs to one function literal inside it that branches (line 199). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/data.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"59c04f06301b6f5501eae9f0ef8af1c8b19fc6e7258485c5bb2ca01c982e40c4"}},{"ruleId":"D2","level":"warning","message":{"text":"row.getStructReflectCandidates (cognitive 26): row.getStructReflectCandidates has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/row/data.go"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7e377894d64f5b20fe319f779c98c9700884828774610b6ae5bd457ab8e44b6"}},{"ruleId":"D2","level":"warning","message":{"text":"mck.unmarshalTask (cognitive 26): mck.unmarshalTask has cognitive complexity 26 (threshold 15). Drivers by points: if/else 23, loops 2, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":523}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ff99a70ced87e75ae597b005c704e471caa5ad360b6b253a0a3dce6152e43ba"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.SyncCopySegmentTask (cognitive 26): datacoord.SyncCopySegmentTask has cognitive complexity 26 (threshold 15). Drivers by points: if/else 23, loops 2, match/switch 1 (nesting depth added 17). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":744}}}],"partialFingerprints":{"codehealthFindingId/v1":"34d2ef29d6a6cd771d4752bc6347ca8629cd7574e6e512b843763fe4d4c80fe6"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.reloadFromKV (cognitive 26): meta.reloadFromKV has cognitive complexity 26 (threshold 15). Drivers by points: loops 17, if/else 9 (nesting depth added 14). Of this number, 24 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3e8625e5d1e8e1cf1b2e652e01a66e4fcce2d052bba8457f62ffaa47eee02cb"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.completeIndexInfo (cognitive 26): Server.completeIndexInfo has cognitive complexity 26 (threshold 15). Drivers by points: if/else 19, boolean chains 3, match/switch 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"11b43deffecb80939120e3ba43a1d685570699993eb684ab20c5d36d6e9e45fd"}},{"ruleId":"D2","level":"warning","message":{"text":"snapshotManager.RestoreSnapshot (cognitive 26): snapshotManager.RestoreSnapshot has cognitive complexity 26 (threshold 15). Drivers by points: if/else 26 (nesting depth added 7). Of this number, 20 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"99059d58df6f0e002f1d014cd5d1fe0ec0194e7fd61a1fee14cb171958366f6e"}},{"ruleId":"D2","level":"warning","message":{"text":"listenerManager.Close (cognitive 26): listenerManager.Close has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21, boolean chains 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/listener_manager.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3f1e7182b1a1248365fec210b0add4434b731cf2d294972ce7e1d44a84a8ff8"}},{"ruleId":"D2","level":"warning","message":{"text":"GrowingSourceSyncTask.buildFlushConfig (cognitive 26): GrowingSourceSyncTask.buildFlushConfig has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, loops 4, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":864}}}],"partialFingerprints":{"codehealthFindingId/v1":"cddc1d99595c0d0f5ad1e4aab930a05124c61057be427405f2211eb4b0ce528b"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitLogicalOr (cognitive 26): ParserVisitor.VisitLogicalOr has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, boolean chains 6 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1785}}}],"partialFingerprints":{"codehealthFindingId/v1":"77eec1a9b28522971ac10bc45bf391dd0680c25912eaa9bc6d3c91ffb5950bbf"}},{"ruleId":"D2","level":"warning","message":{"text":"SearchAggregationComputer.compareRowsForTopHits (cognitive 26): SearchAggregationComputer.compareRowsForTopHits has cognitive complexity 26 (threshold 15). Drivers by points: if/else 24, boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/computer.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"e47f5ec5ceae5be45ce0a6d6edd81da4c4b4070e548e2c93f8c480ef12ac5039"}},{"ruleId":"D2","level":"warning","message":{"text":"queryTask.PostExecute (cognitive 26): queryTask.PostExecute has cognitive complexity 26 (threshold 15). Drivers by points: if/else 23, boolean chains 1, loops 1, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":974}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc08d7c11465844eabd4219a291dc0f4bf902fb7558548306df8f194b42d7975"}},{"ruleId":"D2","level":"warning","message":{"text":"taskScheduler.preProcess (cognitive 26): taskScheduler.preProcess has cognitive complexity 26 (threshold 15). Drivers by points: if/else 19, boolean chains 3, match/switch 3, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":1119}}}],"partialFingerprints":{"codehealthFindingId/v1":"f82e53ba6f579eee513cd4fbebb91d472efa9088e14b72c4e1c391e1297f3934"}},{"ruleId":"D2","level":"warning","message":{"text":"utils.ReassignReplicaToRG (cognitive 26): utils.ReassignReplicaToRG has cognitive complexity 26 (threshold 15). Drivers by points: if/else 16, loops 9, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/utils/meta.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ba3569f34fed7d22ff3b76e279f546714de27e3ecc438c09bea2bea11420a39"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.Search (cognitive 26): shardDelegator.Search has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 1 (nesting depth added 9). Of this number, 20 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":563}}}],"partialFingerprints":{"codehealthFindingId/v1":"1054bab4618f9447f506446835370ddbaaf4b5826910807baa5424e693e30590"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.checkDiskQuota (cognitive 26): QuotaCenter.checkDiskQuota has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21, loops 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1463}}}],"partialFingerprints":{"codehealthFindingId/v1":"b48f0d85242ebaa226699452ece2e38c24b69d6e446f0752d62a930753cf4a17"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.broadcastAlterCollectionV2ForAlterCollectionField (cognitive 26): Core.broadcastAlterCollectionV2ForAlterCollectionField has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, loops 3, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_field.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed74e51355abf00e82a999e8d235903ce1b6974be7a7966bf3642bb578d246c5"}},{"ruleId":"D2","level":"warning","message":{"text":"CommandStore.PushCommand (cognitive 26): CommandStore.PushCommand has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, loops 4, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/telemetry/command_store.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aafab127a8ce503c2fc233d370e3c4e0b1c28b45c928bb7923ae48c26917e4f"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.parseDecayParams (cognitive 26): chain.parseDecayParams has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, match/switch 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"5951489caa07d6051bacc91a3831cb4bf0f4ddcc5ee08c3e0e19f2ea38940a48"}},{"ruleId":"D2","level":"warning","message":{"text":"FilterOp.Execute (cognitive 26): FilterOp.Execute has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17, loops 8, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_filter.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"6959a52272503065f4656897a3d7edfebeda99dec0639dfa10330a91137b8bc0"}},{"ruleId":"D2","level":"warning","message":{"text":"highlight.NewSemanticHighlight (cognitive 26): highlight.NewSemanticHighlight has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, loops 3, match/switch 2, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/highlight/semantic_highlight.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eb3c6bc43cf432bfe95dca810edf53b945d1c7a168b125c6e1545a32b517ba5"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableFloatVectorData (cognitive 26): parquet.ReadNullableFloatVectorData has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18, loops 7, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1481}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ba8f115afb041ae47eef8c44890d5cc99ad8d7854b7dc9cbee5baeb02a0ab00"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableInt8VectorData (cognitive 26): parquet.ReadNullableInt8VectorData has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18, loops 7, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1646}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9630eed31b2635b9755d01c4656698b951af1800380641b77fe5239c6f540a9"}},{"ruleId":"D2","level":"warning","message":{"text":"dispatcherManager.tryBuildDispatcher (cognitive 26): dispatcherManager.tryBuildDispatcher has cognitive complexity 26 (threshold 15). Drivers by points: if/else 16, loops 7, boolean chains 2, jumps 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgdispatcher/manager.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ffb264bdb23ec08a68d7760029a259c37c04641c4a6fc70a49f9be15aeb0d33"}},{"ruleId":"D2","level":"warning","message":{"text":"retry.Handle (cognitive 25): retry.Handle has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15, match/switch 6, boolean chains 3, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/internal/retry/retry.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e4c5c6488112d869df8a49070307a86f28b1b7074b75af9a04c91691fec824a"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientTelemetryManager.handleShowErrors (cognitive 25): ClientTelemetryManager.handleShowErrors has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, loops 3, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1563}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7403df6e59709dd155eb054918209b641faf62d309bc97244fc536411b06eb3"}},{"ruleId":"D2","level":"warning","message":{"text":"LOBCompactionContext.GetReuseAllLobFilesWithUpdatedStats (cognitive 25): LOBCompactionContext.GetReuseAllLobFilesWithUpdatedStats has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 7 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compaction/lob_compaction.go"},"region":{"startLine":581}}}],"partialFingerprints":{"codehealthFindingId/v1":"befe8b38a8437a3f8cd7ecfd125180c78e4edc35405b8678b66d5997a26a5158"}},{"ruleId":"D2","level":"warning","message":{"text":"metricsNodeMemoryQuerier.GetCollectionTopology (cognitive 25): metricsNodeMemoryQuerier.GetCollectionTopology has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_forcemerge.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"2763b4ba2ecf7dda3f2df6a3c78c706b6f3e8925c321b80802ba64ac045c31c3"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedTextIndexFiles (cognitive 25): garbageCollector.recycleUnusedTextIndexFiles has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 6, boolean chains 1 (nesting depth added 15). Of this number, 21 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1735}}}],"partialFingerprints":{"codehealthFindingId/v1":"332e475c507fce891ae33ab14a0dd535e006a3756598a92a96c75cfc2e0951e2"}},{"ruleId":"D2","level":"warning","message":{"text":"ServerHandler.GenSnapshot (cognitive 25): ServerHandler.GenSnapshot has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, loops 4, boolean chains 2 (nesting depth added 7). Of this number, 22 points are the body\u0027s own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":724}}}],"partialFingerprints":{"codehealthFindingId/v1":"74cf9285c32a8c81fa0f6c0dedb74c270b0d783a2ba79f76573941a19df7b42c"}},{"ruleId":"D2","level":"warning","message":{"text":"indexInspector.createIndexForSegmentLoop (cognitive 25): indexInspector.createIndexForSegmentLoop has cognitive complexity 25 (threshold 15). Drivers by points: if/else 14, loops 7, boolean chains 2, match/switch 2 (nesting depth added 15). Of this number, 23 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_inspector.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"9699a7fc816940ee1006513c19d252a60f54a0788b0e5ea162fd9d7b38d42555"}},{"ruleId":"D2","level":"warning","message":{"text":"snapshotManager.createRestoreJob (cognitive 25): snapshotManager.createRestoreJob has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, loops 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":1130}}}],"partialFingerprints":{"codehealthFindingId/v1":"845ada4aaee6f32ae15226c5016cdef3c2b3b3ff3da1d996651c8470fd1e25be"}},{"ruleId":"D2","level":"warning","message":{"text":"compactor.selectFullRewriteRecord (cognitive 25): compactor.selectFullRewriteRecord has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, boolean chains 2, loops 1, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"f47673bce0eaf31250721e13d6407e65380fa8c196759bd7cd895605bf99921c"}},{"ruleId":"D2","level":"warning","message":{"text":"external.functionOutputFields (cognitive 25): external.functionOutputFields has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 7 (nesting depth added 12). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/function_executor.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"17597f0753c3a27e9fe16580b716d31337e1ff21e2eb32618cbf006c390a6c1f"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV1.upsert (cognitive 25): HandlersV1.upsert has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, boolean chains 3, match/switch 2, loops 1 (nesting depth added 5). Of this number, 16 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":815}}}],"partialFingerprints":{"codehealthFindingId/v1":"814c74c9552375e9f7bfbeb003603c66069e9e3631237e55de30de507f670332"}},{"ruleId":"D2","level":"warning","message":{"text":"pipeline.initMetaCache (cognitive 25): pipeline.initMetaCache has cognitive complexity 25 (threshold 15). Drivers by points: if/else 23, boolean chains 1, loops 1 (nesting depth added 12). Most of this is not in the body itself: 3 of the 25 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 151, 220). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/data_sync_service.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"20d782ed27f4493ce5808e0f5325f805525e87f4edd5759399b61da2ddb4da14"}},{"ruleId":"D2","level":"warning","message":{"text":"writeNode.Operate (cognitive 25): writeNode.Operate has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 6, boolean chains 1 (nesting depth added 6). Of this number, 23 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/flow_graph_write_node.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"7edb08e5044aac597e73b11ba54799e9a8984380de767769580568174466b67a"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.buildBinlogKvs (cognitive 25): datacoord.buildBinlogKvs has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, loops 5 (nesting depth added 10). Of this number, 20 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/util.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"01a8f0e2d65ef62d9026e0d251ffff076eeaaa5849202963bceefe80a27997f7"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseElementScope (cognitive 25): proxy.parseElementScope has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, loops 2, boolean chains 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/struct_hybrid_search.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1c52eb7c9c46f848a9ed3897c1e657379085c21784bbf56171bd441ecef4e5b"}},{"ruleId":"D2","level":"warning","message":{"text":"describeIndexTask.Execute (cognitive 25): describeIndexTask.Execute has cognitive complexity 25 (threshold 15). Drivers by points: if/else 23, boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"779979a036ae68aa17fffcf3906a471ff270f05afc801ebed994cf67b0f8549b"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaManager.SpawnWithReplicaConfig (cognitive 25): ReplicaManager.SpawnWithReplicaConfig has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15, loops 9, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b4753fef698429c9e31026203075ba00a9c67442ec4c5aea7cb93d0a72ba9dd"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.TransferChannel (cognitive 25): Server.TransferChannel has cognitive complexity 25 (threshold 15). Drivers by points: if/else 24, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/ops_services.go"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"448e6492b0363829dd5bb3ad389d45451089eaf6c577ed21f0b636c8d8749b0b"}},{"ruleId":"D2","level":"warning","message":{"text":"taskScheduler.checkStale (cognitive 25): taskScheduler.checkStale has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, boolean chains 3, match/switch 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":1372}}}],"partialFingerprints":{"codehealthFindingId/v1":"93137c9660896ddad9461d46ec7478bf33e76ad98d9a1651489620f658873f16"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.ProcessInsert (cognitive 25): shardDelegator.ProcessInsert has cognitive complexity 25 (threshold 15). Drivers by points: if/else 24, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"347098749b55eb58ec51797c13b2cfa813ed51387aff0674d030f6bc73ebfe66"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.dataFrameFromArrowRecordBatch (cognitive 25): tasks.dataFrameFromArrowRecordBatch has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, loops 6 (nesting depth added 10). Of this number, 20 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/arrow_import.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"971dcd76eb6448863f8cc14fe6a19c43bdd26d54eaf6b721d7e47bfeea7ef0bc"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.heapMergeReduceRange (cognitive 25): tasks.heapMergeReduceRange has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, loops 6, boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/heap_merge_reduce.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c4290fbb7168559d04e4abcf320ec142f7d27e656e670c1b54183d2904f8f17"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.executeOperatePrivilegeGroupTaskSteps (cognitive 25): rootcoord.executeOperatePrivilegeGroupTaskSteps has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, boolean chains 3, loops 2, match/switch 2 (nesting depth added 7). Most of this is not in the body itself: 3 of the 25 points are its own statements and the rest belongs to one function literal inside it that branches (line 119). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/rbac_task.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c2c1612218e6e032c801d5bf1ae9c3e1836b7d90119ec9e65ccdefd0dee9c3e"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.ConvertToArrowSchemaWithNameResolver (cognitive 25): storage.ConvertToArrowSchemaWithNameResolver has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, match/switch 5, loops 4 (nesting depth added 8). Most of this is not in the body itself: 9 of the 25 points are its own statements and the rest belongs to one function literal inside it that branches (line 34). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/schema.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d4c742e2b115f4ca2f99945955e2614aec84587e7065ea16ccc3103c88c47f8"}},{"ruleId":"D2","level":"warning","message":{"text":"balancerImpl.execute (cognitive 25): balancerImpl.execute has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, match/switch 2, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/balancer_impl.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7e0fddaa45198722310188479628eb27b7c784f0e06f971b7227c4fffd58ddf"}},{"ruleId":"D2","level":"warning","message":{"text":"vchannelfair.newPChannelAffinity (cognitive 25): vchannelfair.newPChannelAffinity has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13, loops 12 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/policy/vchannelfair/pchannel_affinity.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"975ed195afca93999359df3bf491b11b7b4aa303fec161f66c75cadd8bcd0fc1"}},{"ruleId":"D2","level":"warning","message":{"text":"reader.Read (cognitive 25): reader.Read has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, loops 3, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/reader.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdc7d25894895173fc358a0e357fe54d0efc36544ba3ddfd138f84d87c0cbbf0"}},{"ruleId":"D2","level":"warning","message":{"text":"numpy.CreateReaders (cognitive 25): numpy.CreateReaders has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, loops 2, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/numpy/util.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"314b1c1d3a32dd986eba1be0dd81b2c28cea6e604f1bb86ad44ac27a22d55173"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadIntegerOrFloatData (cognitive 25): parquet.ReadIntegerOrFloatData has cognitive complexity 25 (threshold 15). Drivers by points: loops 19, if/else 4, match/switch 2 (nesting depth added 14). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"a70ee05088c02a8dbd4e96e4644e0b1235131983ce50aa0afc204168ae783f00"}},{"ruleId":"D2","level":"warning","message":{"text":"indexparamcheck.PrepareFunctionOutputIndexParams (cognitive 25): indexparamcheck.PrepareFunctionOutputIndexParams has cognitive complexity 25 (threshold 15). Drivers by points: if/else 17, boolean chains 6, loops 1, match/switch 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/indexparamcheck/index_params_validation.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6879b62b0ff3fe326c569ecf99319e7fbb31048687c78b0617b22440f0765b8"}},{"ruleId":"D2","level":"warning","message":{"text":"DeduplicatePKOperator.Run (cognitive 25): DeduplicatePKOperator.Run has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15, boolean chains 5, loops 5 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/dedup_pk_op.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c5d6263141f6902845ea56d47e23a88d0b24a366282afbf026577c02ed68552"}},{"ruleId":"D2","level":"warning","message":{"text":"sessionWatcher.handleWatchResponse (cognitive 25): sessionWatcher.handleWatchResponse has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, match/switch 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3e496110bbed643dd0e841c1ffbf4fc57a4a163c00cafb2fe38bd3d3573c973"}},{"ruleId":"D2","level":"warning","message":{"text":"funcutil.GetNumRowOfFieldData (cognitive 25): funcutil.GetNumRowOfFieldData has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, match/switch 5 (nesting depth added 15). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"249088fc86aa95ff7fbd24945d0c2217fdec2527218e7aa6bb034d97cf1cfc87"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientTelemetryManager.handleCollectionMetrics (cognitive 24): ClientTelemetryManager.handleCollectionMetrics has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14, loops 9, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1468}}}],"partialFingerprints":{"codehealthFindingId/v1":"c98cc7f78ce0fd7a3e5d782a6baaf12d1eb7c32d87626f5de198aed285ab2b1b"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.maxFullSegmentsGrouping (cognitive 24): datacoord.maxFullSegmentsGrouping has cognitive complexity 24 (threshold 15). Drivers by points: if/else 17, loops 5, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_view_forcemerge.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5703aa1589578af5c5764f7fa3e1c0e7df4d1bc9f5a18fa995babc1cc7732b2"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.retrieveSegment (cognitive 24): datacoord.retrieveSegment has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12, loops 7, boolean chains 5 (nesting depth added 6). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 305, 276, 255). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f6389e9516e34be3e8ecb4aa1bfbf240a27d1621d51d9b24593029a39dd85e6"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.AssignSegments (cognitive 24): datacoord.AssignSegments has cognitive complexity 24 (threshold 15). Drivers by points: if/else 13, loops 10, boolean chains 1 (nesting depth added 11). Of this number, 21 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_util.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"427c99985579e528ce0853ee0e20d0eab556967633542f6b6439f60e395cafa9"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCompactionTask.QueryTaskOnWorker (cognitive 24): mixCompactionTask.QueryTaskOnWorker has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 1, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_mix.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae0c9243f66fd9128aa836045deec7406f7dd543fe60a4e47fc1cfad9171cd31"}},{"ruleId":"D2","level":"warning","message":{"text":"indexMeta.reloadFromKV (cognitive 24): indexMeta.reloadFromKV has cognitive complexity 24 (threshold 15). Drivers by points: if/else 15, loops 9 (nesting depth added 9). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 198, 241, 187). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"20c24eb30e28d235c0cf5e6a3216f51c7b4df25071d116fadc2280a4d5d5a78f"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentManager.DropSegmentsOfPartition (cognitive 24): SegmentManager.DropSegmentsOfPartition has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14, loops 10 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_manager.go"},"region":{"startLine":718}}}],"partialFingerprints":{"codehealthFindingId/v1":"230c60e877ea2e274758fb3be73750cd7b9be18289b809a5fb236bddf056e3c2"}},{"ruleId":"D2","level":"warning","message":{"text":"statsTask.sort (cognitive 24): statsTask.sort has cognitive complexity 24 (threshold 15). Drivers by points: if/else 21, loops 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"07693b80b0be24544858aa367985042fc9ee5dcf216b984901f63912bf5fa86d"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.wrapperPost (cognitive 24): httpserver.wrapperPost has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 2 (nesting depth added 8). Most of this is not in the body itself: 0 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 374). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fa6cb4b451901bafea728e6730b1c5092cd035b2ce5f40672115416f4cade39"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV1.search (cognitive 24): HandlersV1.search has cognitive complexity 24 (threshold 15). Drivers by points: if/else 23, boolean chains 1 (nesting depth added 7). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":934}}}],"partialFingerprints":{"codehealthFindingId/v1":"23ac77d16ca767127e1e281ee2d95be58a78a4ea58c74ceba5ce564fc396e012"}},{"ruleId":"D2","level":"warning","message":{"text":"BulkPackWriterV3.writeStats (cognitive 24): BulkPackWriterV3.writeStats has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"c846c30a3d5f895d9452c41a718d1077582b3f7ac9fdb458c0afcdc942bd53ca"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.FillExpressionValue (cognitive 24): planparserv2.FillExpressionValue has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, match/switch 3, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/fill_expression_value.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"31642568285239b0fd4b9ff8eec518a6cce87e365fc6dbbc3e69b02a81c007f1"}},{"ruleId":"D2","level":"warning","message":{"text":"rewriter.foldBinary (cognitive 24): rewriter.foldBinary has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, loops 5, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/entry.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e60062e47da8402eb551e1e280d99d953a0531909b68b42c014136d3f2760bd"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseOrderByFields (cognitive 24): proxy.parseOrderByFields has cognitive complexity 24 (threshold 15). Drivers by points: if/else 15, match/switch 6, loops 2, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6b0ab1dbb53a3021c19eaa3765b598937fd145492c525dd3c225aacb2e3fa76"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.getPartitionIDs (cognitive 24): proxy.getPartitionIDs has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, loops 5 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":690}}}],"partialFingerprints":{"codehealthFindingId/v1":"1869ed500a3206cee8d785ee7fd8d2fd14d3b5e85a6641ef4918573daa4cfa50"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseGroupByField (cognitive 24): proxy.parseGroupByField has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4b0d2dae6e415c2d7d7c98445e45c5d01882073cfa261636af7a8d1ded536f6"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.ToCompressedFormatNullableStructField (cognitive 24): proxy.ToCompressedFormatNullableStructField has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, loops 4, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1141}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0e056c14db0de78873b7be7abec825ab00befe8d2367a64b64f62a5a06a9eb3"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.addNamespaceData (cognitive 24): proxy.addNamespaceData has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, loops 5 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2872}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f6948e2234613a06348d81cf463cbfa4f716968f3271a5a6608ae7fca9b9668"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.InvalidateCollectionMetaCache (cognitive 24): Proxy.InvalidateCollectionMetaCache has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16, boolean chains 3, match/switch 3, loops 2 (nesting depth added 11). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0f9a08b633d91d75ed5707d656083f0a9e2fbed6a482d73c3e5ff86ec2650e9"}},{"ruleId":"D2","level":"warning","message":{"text":"elementBestCollapseOperator.run (cognitive 24): elementBestCollapseOperator.run has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, loops 4, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4a5e5806dd9d8cd3ba0ebdd33657addcd0720eb591ac3d628b473368964c036"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.DescribeResourceGroup (cognitive 24): Server.DescribeResourceGroup has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14, loops 10 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/services.go"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"82bfb0afa514890fa028943b521435867536ef98f3cd89a9bf430206dd5ec06f"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.normalizeAndCheckAddedStructField (cognitive 24): rootcoord.normalizeAndCheckAddedStructField has cognitive complexity 24 (threshold 15). Drivers by points: if/else 23, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_add_struct_field.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8a1a055b428abe267af8cae6441b70a94ad66e63dc535461090dd6aee1cdd17"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.buildSchemaForDropField (cognitive 24): rootcoord.buildSchemaForDropField has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14, loops 6, boolean chains 4 (nesting depth added 7). Of this number, 20 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77ac2f5be0e1a36b91a4485848c483ae8991bbd9a611e877c55582f7ca4f070"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.prepareBoundFieldIndex (cognitive 24): Core.prepareBoundFieldIndex has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, boolean chains 3, loops 2 (nesting depth added 5). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a7a87388fadccb9f8ff6e2a5b88a1f4f0d3bb41436e586928561b0f84696fea"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewBinlogRecordReader (cognitive 24): storage.NewBinlogRecordReader has cognitive complexity 24 (threshold 15). Drivers by points: if/else 17, loops 6, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/rw.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"181360c8b4fdb7b7b82987f7363f0cf52fd8f142f21a0a18da7378100a2668bd"}},{"ruleId":"D2","level":"warning","message":{"text":"producerImpl.recvLoop (cognitive 24): producerImpl.recvLoop has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, match/switch 5, loops 1 (nesting depth added 14). Of this number, 22 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/client/handler/producer/producer_impl.go"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8c01bf837b2dcf76b02d5f1076070ef2824da18798cdaa164ddc9b258bf6895"}},{"ruleId":"D2","level":"warning","message":{"text":"reduce.WriteGroupByFieldValues (cognitive 24): reduce.WriteGroupByFieldValues has cognitive complexity 24 (threshold 15). Drivers by points: if/else 17, loops 5, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/reduce/field_data.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b7eb0e0290dee25075c67735dc4c14f9d65749c34065afde2bfb59f95b6f9fa"}},{"ruleId":"D2","level":"warning","message":{"text":"reduce.EqualGroupValues (cognitive 24): reduce.EqualGroupValues has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, boolean chains 3, match/switch 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/reduce/group_key.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"e86410fd9179a3fe8335d846dfdfe6392ce4e649f9dbc80618ecc7ba0614f429"}},{"ruleId":"D2","level":"warning","message":{"text":"options.GetFilterFunc (cognitive 24): options.GetFilterFunc has cognitive complexity 24 (threshold 15). Drivers by points: if/else 15, loops 5, boolean chains 2, match/switch 2 (nesting depth added 13). Most of this is not in the body itself: 3 of the 24 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 142, 158, 124, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/options/deliver.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e9655bd94a8f6b23c88046ecf804a1c49e53f7dba8daffa21f29da9a2e8dc9a"}},{"ruleId":"D2","level":"warning","message":{"text":"GrpcClientConfig.Init (cognitive 24): GrpcClientConfig.Init has cognitive complexity 24 (threshold 15). Drivers by points: if/else 24. Most of this is not in the body itself: 0 of the 24 points are its own statements and the rest belongs to 12 function literals inside it that branch (lines 267, 290, 312, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/grpc_param.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfb6188382095954ddb474f633f88f4386b37c681a1cdf305c67ad563738a5a4"}},{"ruleId":"D2","level":"warning","message":{"text":"columnStructArray.ValidateNullable (cognitive 23): columnStructArray.ValidateNullable has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17, loops 5, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/struct.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"98bfaf5c5e7bf3e2c1649768413f4f283f9c5f3cc9b7ac37c429c2a5450879f1"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionPolicy.triggerOneCollection (cognitive 23): clusteringCompactionPolicy.triggerOneCollection has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 2, loops 1 (nesting depth added 8). Of this number, 21 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_clustering.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"823ab53b564b1ba25ea125d967d63f79bb526bc7ff200066c7fcc10c49170f76"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.watchService (cognitive 23): Server.watchService has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, match/switch 2, loops 1 (nesting depth added 15). Of this number, 15 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/server.go"},"region":{"startLine":801}}}],"partialFingerprints":{"codehealthFindingId/v1":"14fa3510445840d301c139e15b4a6f9535cfab6ffa5414f3bc99576df38d1562"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.iterAndGetScalarAnalyzeResult (cognitive 23): clusteringCompactionTask.iterAndGetScalarAnalyzeResult has cognitive complexity 23 (threshold 15). Drivers by points: if/else 22, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":946}}}],"partialFingerprints":{"codehealthFindingId/v1":"24da45a15d081f0a4167d1ccaaa9b27a82175c510f58c990a855fcd3c168f299"}},{"ruleId":"D2","level":"warning","message":{"text":"DataNode.DropJobsV2 (cognitive 23): DataNode.DropJobsV2 has cognitive complexity 23 (threshold 15). Drivers by points: loops 12, if/else 10, match/switch 1 (nesting depth added 12). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index_services.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"93b089457be02739175f9a49e6e8d73bdb7c8a40b0d0e6bb4c7af6474677f46b"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.convertIDsToSchemapbIDs (cognitive 23): httpserver.convertIDsToSchemapbIDs has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12, match/switch 7, loops 4 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"8db406bca616463490ef19d4ddc7923b52fdda255241bf64a3f0d6cf6a54cc5d"}},{"ruleId":"D2","level":"warning","message":{"text":"GrowingSourceSyncTask.fillPrimaryKeyStatsConfig (cognitive 23): GrowingSourceSyncTask.fillPrimaryKeyStatsConfig has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, loops 2, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":940}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bb559747ef5ae6c4b4ff31346187ca9cacc3cd3512a910a9a5cde811bc13678"}},{"ruleId":"D2","level":"warning","message":{"text":"writeBufferBase.getGrowingSourceSyncTask (cognitive 23): writeBufferBase.getGrowingSourceSyncTask has cognitive complexity 23 (threshold 15). Drivers by points: if/else 23 (nesting depth added 6). Of this number, 19 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1504}}}],"partialFingerprints":{"codehealthFindingId/v1":"f87d8ff88a5f88243aea0ec26ce894e230c96f9736359d04ffb42916d49b9c87"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.applySegmentEntry (cognitive 23): Catalog.applySegmentEntry has cognitive complexity 23 (threshold 15). Drivers by points: loops 12, if/else 10, match/switch 1 (nesting depth added 12). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/update.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"33dae5449e30e679b2d13234d50366a38d0776a2c7e0dc689b81d56edddc40cc"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.tryOptimizeRegexToLike (cognitive 23): planparserv2.tryOptimizeRegexToLike has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12, boolean chains 6, match/switch 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":720}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba851ec07154ee987ec41a3baf5003b1dbf8402c716ee288aecf90b351bb1311"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.getTargetType (cognitive 23): planparserv2.getTargetType has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f2535712608300a3e864b82f3bc6d3cef0ca829014fcaa86ce7f3676af140c6"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.ValidateFieldsInStruct (cognitive 23): proxy.ValidateFieldsInStruct has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":676}}}],"partialFingerprints":{"codehealthFindingId/v1":"c640ff65d652b4dffc3b7123c93747971b08f6e43fe41187f8689c66322cc72b"}},{"ruleId":"D2","level":"warning","message":{"text":"channelsTimeTickerImpl.tick (cognitive 23): channelsTimeTickerImpl.tick has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/channels_time_ticker.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"7baed037447c79f065b3e229a93e2135122aa639b84daa00c008a87f35b55726"}},{"ruleId":"D2","level":"warning","message":{"text":"LookAsideBalancer.checkQueryNodeHealthLoop (cognitive 23): LookAsideBalancer.checkQueryNodeHealthLoop has cognitive complexity 23 (threshold 15). Drivers by points: if/else 19, match/switch 2, boolean chains 1, loops 1 (nesting depth added 15). Most of this is not in the body itself: 3 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 245). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/shardclient/look_aside_balancer.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"41063ebcd3d6dcbcb4a9baab1d87855cf8289b28fc881f6304c6f1a512cb2383"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelChecker.Check (cognitive 23): ChannelChecker.Check has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16, loops 7 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/channel_checker.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd9970da773a857cdd7ad0c98b33d2903d440445d9b95e7d1ab5c1044446fb36"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentChecker.getGrowingSegmentDiff (cognitive 23): SegmentChecker.getGrowingSegmentDiff has cognitive complexity 23 (threshold 15). Drivers by points: if/else 19, loops 3, boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/segment_checker.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"74fe99b5982993216a7e586450736d6382880243695e9ac2922a2235b6f5dc35"}},{"ruleId":"D2","level":"warning","message":{"text":"LoadCollectionJob.Execute (cognitive 23): LoadCollectionJob.Execute has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/job/job_load.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"646dd915cc93bc3f11c8bffc48e5f5618a6f7aa3fe445c5034c51f5951bf92a5"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.checkAddStructFieldDuplicate (cognitive 23): rootcoord.checkAddStructFieldDuplicate has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18, loops 5 (nesting depth added 11). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_add_struct_field.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"2567821b88847362b80e344de14d305d6e7221d05d96e9e7ef7da7fb813c2deb"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewInsertDataWithCap (cognitive 23): storage.NewInsertDataWithCap has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16, loops 4, boolean chains 3 (nesting depth added 7). Most of this is not in the body itself: 10 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 73). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/insert_data.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f203da5d7a8f69dae80150db3458db5376df27baa5cff9279dd58260eb6d578"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewPayloadReader (cognitive 23): storage.NewPayloadReader has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, match/switch 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f24b46e1b1ade0f20be07b9fbaec0e9c0b599a920545e8109232fce06a019b6"}},{"ruleId":"D2","level":"warning","message":{"text":"LocalChunkManager.WalkWithPrefix (cognitive 23): LocalChunkManager.WalkWithPrefix has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, boolean chains 1, loops 1 (nesting depth added 10). Of this number, 12 points are the body\u0027s own statements and 11 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/local_chunk_manager.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"3841e0aa029870e3017728cbd0737f721002d1e88e38781bfae99668c08a6d72"}},{"ruleId":"D2","level":"warning","message":{"text":"CompositeBinlogRecordWriter.Write (cognitive 23): CompositeBinlogRecordWriter.Write has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_events.go"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b78fc964a6b80c46dabe19d167fcad9471573896d96a40cfda0d0adf2963819"}},{"ruleId":"D2","level":"warning","message":{"text":"recoveryStorageImpl.updateCheckpoint (cognitive 23): recoveryStorageImpl.updateCheckpoint has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16, boolean chains 4, match/switch 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/recovery/recovery_storage_impl.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"40ab21a4818506b4fb3d57e2e8f90750a9fbbf42591582f1f280782eb4262ac9"}},{"ruleId":"D2","level":"warning","message":{"text":"mqMsgStream.receiveMsg (cognitive 23): mqMsgStream.receiveMsg has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17, match/switch 5, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab9d681ce064f27ea10cd673c19889c387a743996283fa3555d8db1c0e10b4de"}},{"ruleId":"D2","level":"warning","message":{"text":"Consumer.Chan (cognitive 23): Consumer.Chan has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12, match/switch 8, loops 2, boolean chains 1 (nesting depth added 14). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to one function literal inside it that branches (line 54). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mqwrapper/pulsar/pulsar_consumer.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc4ea5f83de64e47beb231829afbba2a05df7c9db5aa6ed4a22a629af0ff2fea"}},{"ruleId":"D2","level":"warning","message":{"text":"LoadTask.Await (cognitive 22): LoadTask.Await has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12, match/switch 6, boolean chains 3, loops 1 (nesting depth added 12). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/maintenance.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"e45cdae197ea1301ced8f1f430b323f904e7917eff5972210e9858dce2f30bf2"}},{"ruleId":"D2","level":"warning","message":{"text":"ResultSet.fillPKEntry (cognitive 22): ResultSet.fillPKEntry has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13, loops 7, boolean chains 1, match/switch 1 (nesting depth added 10). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/results.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"eceaebccd1fbdc8b5bee2079d4ad069691171292e60cf896082d8b7496fcb570"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.HandleStreamingNodes (cognitive 22): mixCoordImpl.HandleStreamingNodes has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_mgr_routes.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"108f28a6fa40acc2329c7d9b212c62fc229350516732fff66596e7b797ddd561"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionInspector.schedule (cognitive 22): compactionInspector.schedule has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13, match/switch 4, loops 3, boolean chains 2 (nesting depth added 9). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"b40f6f5c5d614a042974c9d65dd13026c43e61edc6be2312cb94b7f54582e949"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionTrigger.generatePlans (cognitive 22): compactionTrigger.generatePlans has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13, loops 8, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"d06f88bf19ce0fc52065ec32b6bde5e3cec61495831c12b696167782fbf42e16"}},{"ruleId":"D2","level":"warning","message":{"text":"statsInspector.triggerJSONKeyIndexStatsTask (cognitive 22): statsInspector.triggerJSONKeyIndexStatsTask has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15, loops 5, boolean chains 2 (nesting depth added 11). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_inspector.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"824ca2f72948171bfb127288f8e28683d288c9febce22579d1b3bfe17b0b89ae"}},{"ruleId":"D2","level":"warning","message":{"text":"refreshExternalCollectionTask.QueryTaskOnWorker (cognitive 22): refreshExternalCollectionTask.QueryTaskOnWorker has cognitive complexity 22 (threshold 15). Drivers by points: if/else 21, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":711}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bd594f7e92c35d12deeeabc984ca7846d4cad74c8f95031ae91366c07a8e391"}},{"ruleId":"D2","level":"warning","message":{"text":"bumpSchemaVersionCompactionTask.missingFunctionInputSchema (cognitive 22): bumpSchemaVersionCompactionTask.missingFunctionInputSchema has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 6 (nesting depth added 13). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"6571714ddbb7d53e11fc233c9b3537e23badbfce873bde424abcf522832f6abd"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.CopySegmentAndIndexFiles (cognitive 22): importv2.CopySegmentAndIndexFiles has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2f962d9b2cfd1c9c3b89506bc4c2a03f34a137fabec3363ba271189b46d07dc"}},{"ruleId":"D2","level":"warning","message":{"text":"ImportTask.sync (cognitive 22): ImportTask.sync has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 6 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"e52933acb778fab929b1dece1a579a84d83427157630803395ca559e22029cf9"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.generateSearchParams (cognitive 22): httpserver.generateSearchParams has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, loops 2, match/switch 1 (nesting depth added 9). Of this number, 17 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3582}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac5e95dba8fcac279977269ca2df431839cbee65b30959d1893735373fcdc2a4"}},{"ruleId":"D2","level":"warning","message":{"text":"StructArrayFieldSchema.GetProto (cognitive 22): StructArrayFieldSchema.GetProto has cognitive complexity 22 (threshold 15). Drivers by points: if/else 17, boolean chains 3, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/request_v2.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"31433137c15668d9e698edf07ab7bcc46d72a1d20dcb5661455e86aa1be757f2"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.compareJSONValues (cognitive 22): proxy.compareJSONValues has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13, boolean chains 8, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2143}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f2e65218549232542926ebed8232fb942b4177f8642c5b90d03b441b9b3b413"}},{"ruleId":"D2","level":"warning","message":{"text":"semanticHighlightOperator.run (cognitive 22): semanticHighlightOperator.run has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 1 (nesting depth added 9). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1dc0553b213a5fa468c5e484e152a67f820fe7ad442eb76aee519ae51161fc8"}},{"ruleId":"D2","level":"warning","message":{"text":"orderByOperator.sortGroupsByOrderByFields (cognitive 22): orderByOperator.sortGroupsByOrderByFields has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 1 (nesting depth added 7). Of this number, 14 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2301}}}],"partialFingerprints":{"codehealthFindingId/v1":"ede157b88b8885673264544f1bf101ac44d7317ea3262f993fce525cdcfb710f"}},{"ruleId":"D2","level":"warning","message":{"text":"showPartitionsTask.Execute (cognitive 22): showPartitionsTask.Execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 6 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3015}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf73aad6185592e9aaa1dd179f5def317a3c66367b4e044fb0da63929d0118c2"}},{"ruleId":"D2","level":"warning","message":{"text":"loadPartitionsTask.Execute (cognitive 22): loadPartitionsTask.Execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3439}}}],"partialFingerprints":{"codehealthFindingId/v1":"9094702353fa41389d1f11ae8421cdcde9211ca8d3f192470aee3e6d4b974747"}},{"ruleId":"D2","level":"warning","message":{"text":"ResourceManager.transferNodesOnRGSwap (cognitive 22): ResourceManager.transferNodesOnRGSwap has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12, loops 6, boolean chains 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/resource_manager.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bc2ddcb893a8f9c1c356cfe091d89a901350dcfbdfb45756d3e0335836bdad8"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.reduceGroupByMultiPerNq (cognitive 22): segments.reduceGroupByMultiPerNq has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15, boolean chains 3, match/switch 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a63fd27bebc2ba66b55f015699fea0c28fa29ccb01b6de0e90fc2536db6c43c"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.buildMergeEntries (cognitive 22): tasks.buildMergeEntries has cognitive complexity 22 (threshold 15). Drivers by points: if/else 17, loops 4, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/heap_merge_reduce.go"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"441d58c3b332c14990b8e900c7ebf26fc6a50af61d00fc7ea009e7f93dc6ab7c"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.broadcastAlterCollectionForAddField (cognitive 22): Core.broadcastAlterCollectionForAddField has cognitive complexity 22 (threshold 15). Drivers by points: if/else 17, loops 4, boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_add_field.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4e9ef65874da8ae82617200a8961c6dd6645f097472e8be9b284cc99cc72255"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.printIndexFilePayloadValues (cognitive 22): storage.printIndexFilePayloadValues has cognitive complexity 22 (threshold 15). Drivers by points: if/else 22 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/print_binlog.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"a66c4dfe58c4575bf5d5000387a1dd1d6fb95ee0eefa2204b4ccaed0a1ef4f40"}},{"ruleId":"D2","level":"warning","message":{"text":"PackedBinlogRecordWriter.Write (cognitive 22): PackedBinlogRecordWriter.Write has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/binlog_record_writer.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"df778454a2be378c4b083147dd3e4513d52b42cb955837f407a3a345129c9448"}},{"ruleId":"D2","level":"warning","message":{"text":"CompositeBinlogRecordReader.Next (cognitive 22): CompositeBinlogRecordReader.Next has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 4 (nesting depth added 11). Of this number, 16 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/record_reader.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"15c373ec85989f0bfa85c297889de76d076038f361aadd08b203064515ea68dc"}},{"ruleId":"D2","level":"warning","message":{"text":"function.embeddingFunctionMetadata (cognitive 22): function.embeddingFunctionMetadata has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 4, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/manager.go"},"region":{"startLine":1048}}}],"partialFingerprints":{"codehealthFindingId/v1":"8982eac002ba73f37663c1e17451c45b06429894b97854298ad34aee905d7c1b"}},{"ruleId":"D2","level":"warning","message":{"text":"FuncChain.validateOperators (cognitive 22): FuncChain.validateOperators has cognitive complexity 22 (threshold 15). Drivers by points: if/else 20, boolean chains 1, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/chain.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"49cda75142387b375c71deb8ca2b0f65f7edb0301adc4a85468c22e6cee4b135"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.exportFieldData (cognitive 22): chain.exportFieldData has cognitive complexity 22 (threshold 15). Drivers by points: if/else 21, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"054a1de6ec4a08b32b1c26d647f38a619a08753ba66bdd6ac5ff522fcd0ab2b9"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.NewVertexAIEmbeddingProvider (cognitive 22): embedding.NewVertexAIEmbeddingProvider has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/vertexai_embedding_provider.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"de81fef7e6c7ab588c2af71dc97a6f158616968060f31fb4d654f2181cd3e1cb"}},{"ruleId":"D2","level":"warning","message":{"text":"functionRunnerCollectionEntry.ensureVersion (cognitive 22): functionRunnerCollectionEntry.ensureVersion has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15, loops 4, boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/manager.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f658642484921712ba7475dd1119a10e29f8f06b4b264906096177163615b58"}},{"ruleId":"D2","level":"warning","message":{"text":"OrderByLimitOperator.Run (cognitive 22): OrderByLimitOperator.Run has cognitive complexity 22 (threshold 15). Drivers by points: if/else 14, loops 6, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/order_op.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d3576f83445d1a58304a332c30b6cea243714b86f040e23306c5122bccaa03c"}},{"ruleId":"D2","level":"warning","message":{"text":"mqMsgStream.Produce (cognitive 22): mqMsgStream.Produce has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 3, match/switch 2, boolean chains 1 (nesting depth added 9). Most of this is not in the body itself: 9 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 280). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"97c2a71524c04aceef72728da9a48b5c71ec7a288dee3a923bb560d51f9453df"}},{"ruleId":"D2","level":"warning","message":{"text":"MqTtMsgStream.consumeToTtMsg (cognitive 22): MqTtMsgStream.consumeToTtMsg has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ab9bbc2d48904f3b4505ab22a99f6f0a0a84d22f8ed19cb9b70ed8c8e23248c"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodePackedBool (cognitive 22): fastpb.decodePackedBool has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 4, match/switch 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"227b74674e4aef41cf2dd8dcfbbfe20578cd197497779d5c10cf3fbfb569a48d"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodePackedI32 (cognitive 22): fastpb.decodePackedI32 has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 4, match/switch 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"14d884dd6c5bc5f968a222ce2834d41b4df501c99bbb7df46e4481648c7b4040"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodePackedI64 (cognitive 22): fastpb.decodePackedI64 has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 4, match/switch 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"b12a3484f78bbba793867aab1a81a131cdabcdc6b61f6713d32e8ce03153e91b"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodePackedF32 (cognitive 22): fastpb.decodePackedF32 has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"61cfca462018b0d6eea54440d06ef30aaf7052922645a60a1717f01147f137ce"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodePackedF64 (cognitive 22): fastpb.decodePackedF64 has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"e83d6edcef61cae135bd39ce9bdcf644053c3a4d5dd6a2eab13720b15323972f"}},{"ruleId":"D2","level":"warning","message":{"text":"IDsChecker.ContainsAny (cognitive 22): IDsChecker.ContainsAny has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 4, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/ids_checker.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7134db3a2b006491d4bc1c0cd27b3f4094b2d236391d25ad6a4ca5fa4a7d41a"}},{"ruleId":"D2","level":"warning","message":{"text":"controller.watchLoop (cognitive 21): controller.watchLoop has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11, match/switch 6, loops 4 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cdc/controller/controller.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0766dc29a1d0113c49ac1c43e938fed713908a435879d932854a9b4e295bb7f"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionInspector.loadMeta (cognitive 21): compactionInspector.loadMeta has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, loops 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"4243627b85cea69c4725070851b0b807c473680784bf3a35397cccea4ded54e0"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleChannelCPMeta (cognitive 21): garbageCollector.recycleChannelCPMeta has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1117}}}],"partialFingerprints":{"codehealthFindingId/v1":"d86f88e5cf9742c0e67e5202de74ef93acc74b1717b82cd5fa5c69a94b0745ab"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedAnalyzeFiles (cognitive 21): garbageCollector.recycleUnusedAnalyzeFiles has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, loops 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1661}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf60a8de0895e16d3b00e072594be6dad4c5479f16e1c1a07852a52c6faa9c3"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.AlterIndex (cognitive 21): Server.AlterIndex has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b5bfdb5366cf02c462edcf2a1d239cb77a903aa3ef3dc1a37a670d6108c5410"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.fieldDataValueCount (cognitive 21): httpserver.fieldDataValueCount has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, match/switch 3 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc1aa3652b9f2c5ddb7194a41b6eb5b4dd9631def9289397134b2e917e041a6"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitTerm (cognitive 21): ParserVisitor.VisitTerm has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1154}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ba4a27c85929ac49c4f058a4ed5e7130b74d886144a95e568778a9d700a5de4"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrTextMatchToMerged (cognitive 21): visitor.combineOrTextMatchToMerged has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12, loops 8, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/text_match.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"592facff9f779a2f6a2f80186cb578b1767dc7085366ae4b75c60927b93e895d"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.getCollectionAndPartitionID (cognitive 21): proxy.getCollectionAndPartitionID has cognitive complexity 21 (threshold 15). Drivers by points: if/else 21 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/rate_limit_interceptor.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"cea812138951e737b7a4c7f7c0919312573c67f8e07d32e80c1fe01e20ad1544"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.checkFullLoaded (cognitive 21): proxy.checkFullLoaded has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, loops 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_statistic.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d1489c21d73ea1bf70890a0bc73c80c53bae16df5c7306017fe94fc55b7bba8"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateDimension (cognitive 21): proxy.validateDimension has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f326510e929265e150a93fc676ee1facfad2ef7c7862c614dd9c2c17f07f50e"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaCache.InvalidateCollectionMeta (cognitive 21): MetaCache.InvalidateCollectionMeta has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, boolean chains 2, loops 1 (nesting depth added 8). Of this number, 19 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":1352}}}],"partialFingerprints":{"codehealthFindingId/v1":"991739d3a3a9df5875f49ffcca645f132965a9b388b0c4af93c0a90eef5d0a2c"}},{"ruleId":"D2","level":"warning","message":{"text":"search_agg.resolveFieldID (cognitive 21): search_agg.resolveFieldID has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/context_builder.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"df7ef543052158c21eae4ff4dc73cff9a4fd0fdf7906eb37e31c0b453ad12205"}},{"ruleId":"D2","level":"warning","message":{"text":"ScoreBasedAssignPolicy.AssignSegment (cognitive 21): ScoreBasedAssignPolicy.AssignSegment has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, boolean chains 2, loops 2 (nesting depth added 7). Of this number, 17 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/assign/assign_policy_score.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c46b41101fbb2c1af14b50f32953d2eb0c8b2e37f1b91e561d817b29f4c4500"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaManager.buildSQNodeAssignmentHelpers (cognitive 21): ReplicaManager.buildSQNodeAssignmentHelpers has cognitive complexity 21 (threshold 15). Drivers by points: loops 11, if/else 8, boolean chains 2 (nesting depth added 8). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":1038}}}],"partialFingerprints":{"codehealthFindingId/v1":"544f8edfa3a1f38f96616061962893a8b5b69bcdcf8868e6207cff1be7b89cf6"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.ClearReadTaskQueue (cognitive 21): Server.ClearReadTaskQueue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15, loops 5, boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 543). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/ops_services.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e02e9fa75b02437678d2e5c36fce3a3f95dc09d510210551ae0760e8a19895d"}},{"ruleId":"D2","level":"warning","message":{"text":"utils.AssignReplica (cognitive 21): utils.AssignReplica has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/utils/meta.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7bdd1b90671bb908d3f28f9a89e2b1adec5c019fe6d3232fd9a6493e496b338"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.NewFetchFieldsDataOperator (cognitive 21): segments.NewFetchFieldsDataOperator has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14, loops 6, boolean chains 1 (nesting depth added 6). Most of this is not in the body itself: 0 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 196). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/ignore_non_pk_ops.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f53d82a5ffab4acf8a0b577ef82751ab30fef19accbc45f99a82b0294545b32"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.prepareQueryNodeFunctionChainsFromPlan (cognitive 21): tasks.prepareQueryNodeFunctionChainsFromPlan has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/l0_function_chain.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"599ba018e0a3e48bd734652fdc471b58067ae4437a870e378b0bfafe10b900bc"}},{"ruleId":"D2","level":"warning","message":{"text":"DDLCallback.alterCollectionV2AckCallback (cognitive 21): DDLCallback.alterCollectionV2AckCallback has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_properties.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d5ec4b672bd49680b0f0a40f1e656d2df536eec0d03b01b50112cdba2c53995"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.forceDenyWriting (cognitive 21): QuotaCenter.forceDenyWriting has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15, loops 5, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"035e6a03f223e7fbbe2d1879fa28cc46bc92672ad82643caaabde4a6e510e09d"}},{"ruleId":"D2","level":"warning","message":{"text":"InsertCodec.DeserializeInto (cognitive 21): InsertCodec.DeserializeInto has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, loops 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b1c3614d8cdebc48599e019bf5399445bdcf7d412c71a570b23f428c8234619"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.buildRerankChainInternal (cognitive 21): chain.buildRerankChainInternal has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"126dc72941ed39a76bc9e77a1e727e8e11946c51bd26ef0291241635d3f21092"}},{"ruleId":"D2","level":"warning","message":{"text":"ChainRepr.RefreshInfo (cognitive 21): ChainRepr.RefreshInfo has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, loops 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/repr.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"28be2b6b52bc1fdb175c4e5a1df137b7475d45887620dca5954075ce7c27e69a"}},{"ruleId":"D2","level":"warning","message":{"text":"mlog.extractPropagated (cognitive 21): mlog.extractPropagated has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13, match/switch 4, boolean chains 2, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mlog/interceptor.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"4be469e72ea21e0f4aca3a20b99ec5136d7b8c8fc57c915d9cfda1a08e6e0d73"}},{"ruleId":"D2","level":"warning","message":{"text":"funcutil.ProcessFuncParallel (cognitive 21): funcutil.ProcessFuncParallel has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11, match/switch 6, loops 4 (nesting depth added 9). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 72, 61). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/parallel.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"e775b973d8c65ddd1c3f3ca541b9421f3e8390759ad7ac1588b22d4927558b18"}},{"ruleId":"D2","level":"warning","message":{"text":"funcutil.ProcessTaskParallel (cognitive 21): funcutil.ProcessTaskParallel has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11, match/switch 6, loops 4 (nesting depth added 9). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 176, 155). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/parallel.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c5754c04b87a35616f6ab580b61ceea4b132595d11104079da3bc06bfc75317"}},{"ruleId":"D2","level":"warning","message":{"text":"replicateutil.NewConfigHelper (cognitive 21): replicateutil.NewConfigHelper has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15, loops 6 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/replicateutil/config_helper.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"dafd2df29fe5e0dd30e4eedbb69a4dd7d8d62f5a979bb164c91e18ba6c1f6dd2"}},{"ruleId":"D2","level":"warning","message":{"text":"AnnRequest.searchRequest (cognitive 20): AnnRequest.searchRequest has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 4 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read_options.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"75931a2dc2d6c62f7b562aa4463c4251cb8d4603d86073cd2afd077a1fd9da25"}},{"ruleId":"D2","level":"warning","message":{"text":"mck.run (cognitive 20): mck.run has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10, loops 10 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"64d3daa81baf7b2669305fc33bd585122dcc943af9f5ca7526feece0fd1e5859"}},{"ruleId":"D2","level":"warning","message":{"text":"replicateStreamClient.sendLoop (cognitive 20): replicateStreamClient.sendLoop has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, match/switch 2, loops 1 (nesting depth added 11). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cdc/replication/replicatestream/replicate_stream_client_impl.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"982fa4af39b54a268f05b0358e480fe537c5d5b5d13130e0f2ba264e4bf97041"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.checkExpiredPOSIXDIR (cognitive 20): mixCoordImpl.checkExpiredPOSIXDIR has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c98535c85a0055c270788f677ab269854b47f4812396cf6c4ff7f10690b60d8"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCoordImpl.HandleAlterConfig (cognitive 20): mixCoordImpl.HandleAlterConfig has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_mgr_routes.go"},"region":{"startLine":1259}}}],"partialFingerprints":{"codehealthFindingId/v1":"cba01a9eccc3998a7e607acebac634b9c9f078558a14f535f8bf1e0c130206d6"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.buildV2Groups (cognitive 20): datacoord.buildV2Groups has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/backfill_result.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5e85f550c75c1aeb898bcf7c91b2f33a737ad079449d0a3e56522d2bd29f5c2"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.updateStatsResultIfManifestMatches (cognitive 20): datacoord.updateStatsResultIfManifestMatches has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11, boolean chains 5, loops 4 (nesting depth added 4). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 582). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_stats.go"},"region":{"startLine":581}}}],"partialFingerprints":{"codehealthFindingId/v1":"a18063ddbf957486734d65e6a76087c13f8616c194df2d3c6265a553299c5d74"}},{"ruleId":"D2","level":"warning","message":{"text":"indexMeta.canCreateIndex (cognitive 20): indexMeta.canCreateIndex has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 2, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"61fbb668e4d3b3b226eb72c4fbce25a3b6fa6fd83728c865bfda98ff8a81db29"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentInfo.getFieldBinlogSize (cognitive 20): SegmentInfo.getFieldBinlogSize has cognitive complexity 20 (threshold 15). Drivers by points: loops 12, if/else 8 (nesting depth added 12). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_info.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"52086048c82bf9c7f1e1700ef401099e3da6968c0bebef7bd2b99879b31c8a9f"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.DropIndex (cognitive 20): Server.DropIndex has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":967}}}],"partialFingerprints":{"codehealthFindingId/v1":"9aec070d7701f009e6197bcd8c16d4dce0cbb50e3ca42404ddfcda9832bf767b"}},{"ruleId":"D2","level":"warning","message":{"text":"SnapshotReader.ReadSnapshot (cognitive 20): SnapshotReader.ReadSnapshot has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12, loops 8 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot.go"},"region":{"startLine":488}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ca4a3cac92320ca369d18d72d4413e4e246b971f414f0fde3a5c597274dae27"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.joinArray (cognitive 20): httpserver.joinArray has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12, loops 6, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3dc45f8d4f9736ab99f9ce9595840969e66720f2fb5bc7ed2e3fbdd3376d946"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.convertRange (cognitive 20): httpserver.convertRange has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 4, match/switch 1 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"c16cf52ddc9281d2362080d868a8cc59f57b6cfcf2c0910ca4880e5710cc2866"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV1.insert (cognitive 20): HandlersV1.insert has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, boolean chains 2, match/switch 2 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":715}}}],"partialFingerprints":{"codehealthFindingId/v1":"decfdab740e731e4c5fd2691fe4532f8287edeb7888d576c63097aee4a0937a5"}},{"ruleId":"D2","level":"warning","message":{"text":"grpcproxy.newHTTPListner (cognitive 20): grpcproxy.newHTTPListner has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, boolean chains 3, match/switch 1 (nesting depth added 6). Of this number, 17 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/listener_manager.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"f10fcf92630c56448b710083cc62b1fa79f80883b42b872a4dfd616481d93663"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.DeleteGrantByCollectionName (cognitive 20): Catalog.DeleteGrantByCollectionName has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1785}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7e54a574ba551c085aa975d3b53d9a0ec581531e95aa83722bfbe06a15fbeb8"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.Update (cognitive 20): Catalog.Update has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11, loops 7, match/switch 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/update.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"c47b77125de929f9a90a13d19d9e012eb343093cb54892d0a06d5280e657a38d"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrInWithIn (cognitive 20): visitor.combineOrInWithIn has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12, loops 8 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":471}}}],"partialFingerprints":{"codehealthFindingId/v1":"7765cd2faecc6a51c500fec0de8b3698c33c4db6ef9c650334dff858903d627c"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.LackOfFieldsDataBySchema (cognitive 20): proxy.LackOfFieldsDataBySchema has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, boolean chains 4, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2300}}}],"partialFingerprints":{"codehealthFindingId/v1":"242c93e67862a5c112d5c31431daec5bfd2fb01e1fbc9fab69d5c66c40d847eb"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.validateClusteringKey (cognitive 20): createCollectionTask.validateClusteringKey has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 4, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba62d651a5d8448899fa88d2ee51bbbde4854992f4d76460fa52a3c1fa787155"}},{"ruleId":"D2","level":"warning","message":{"text":"alterIndexTask.PreExecute (cognitive 20): alterIndexTask.PreExecute has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 4, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":699}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0bcecec355bd1113bed9d93220e4e4695653a9a08e0bd1989d7d4e59a1b46ab"}},{"ruleId":"D2","level":"warning","message":{"text":"rowCountBasedPlanGenerator.generatePlans (cognitive 20): rowCountBasedPlanGenerator.generatePlans has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 7 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/balance/multi_target_balance.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"01d8ba59ce39a870becadf0d676f415e9b82f75068ee2e64c1c43cda4b9d5ec0"}},{"ruleId":"D2","level":"warning","message":{"text":"IndexChecker.checkSegmentStats (cognitive 20): IndexChecker.checkSegmentStats has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 4, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/index_checker.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"11da7cc69b70c3d65f49055b1a724a158775d58556cf282750484003a0b5345c"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectionObserver.observeTimeout (cognitive 20): CollectionObserver.observeTimeout has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 5, boolean chains 1, match/switch 1 (nesting depth added 10). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 176). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/collection_observer.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"eef1928a423d8804be88301f601377ca2a12548ac91fb32dc79523151bb2d94f"}},{"ruleId":"D2","level":"warning","message":{"text":"Executor.releaseSegment (cognitive 20): Executor.releaseSegment has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, boolean chains 1 (nesting depth added 9). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/executor.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"9952422fc411bebf2d2b8aa540e707a8e80969a6d023b9b6a690e560d2ad0736"}},{"ruleId":"D2","level":"warning","message":{"text":"distribution.AddDistributions (cognitive 20): distribution.AddDistributions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/distribution.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9a4a0789ae914e44eb9f45e7f2bd864ef215d9700f4e57ac0c3afb5751bb3be"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.executeL0RerankChains (cognitive 20): tasks.executeL0RerankChains has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, loops 6 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/l0_function_chain.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"911d1f39c87613365de690a971beb1de1dc8115150f49c27a68b24d87b88151e"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.getCurrentUserVisibleDatabases (cognitive 20): Core.getCurrentUserVisibleDatabases has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":3243}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0648dd0caff849fac90a06f6a99a6d286cb64684f66f59b0da3dc421a1bf48f"}},{"ruleId":"D2","level":"warning","message":{"text":"baseBinlogWriter.Finish (cognitive 20): baseBinlogWriter.Finish has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/binlog_writer.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"00ce21e73a172309e4876134c93ff9a54f423774964ca49457df12e9d67955dc"}},{"ruleId":"D2","level":"warning","message":{"text":"packed.buildMilvusTableFileInfosFromSnapshotMetadata (cognitive 20): packed.buildMilvusTableFileInfosFromSnapshotMetadata has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storagev2/packed/milvus_table.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"93913737999aeb606546ca7b87f5f0ed81f5cc0d6f4027ae8180cb22c25ca045"}},{"ruleId":"D2","level":"warning","message":{"text":"packed.FetchFragmentsFromExternalSourceWithRange (cognitive 20): packed.FetchFragmentsFromExternalSourceWithRange has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 3 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storagev2/packed/utils.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"0abe6786dd46be7a8e8c17e844b5998611831f8276246713087de96fc076a6ca"}},{"ruleId":"D2","level":"warning","message":{"text":"releaseManualFlushPreparer.PrepareReleaseManualFlush (cognitive 20): releaseManualFlushPreparer.PrepareReleaseManualFlush has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, boolean chains 1 (nesting depth added 4). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/service/release_manual_flush_preparer.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1bb348ef16e0ec2f8e8362cfd5d5e34d9606823758b7eca70c838361d357187"}},{"ruleId":"D2","level":"warning","message":{"text":"scannerAdaptorImpl.handleUpstream (cognitive 20): scannerAdaptorImpl.handleUpstream has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 4, boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/scanner_adaptor.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"19e28a26196cdf172821aef537e751f128372738ac0a55e964ef29a41361997d"}},{"ruleId":"D2","level":"warning","message":{"text":"shardInterceptor.handleInsertMessage (cognitive 20): shardInterceptor.handleInsertMessage has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/interceptors/shard/shard_interceptor.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"45f51460cc9fba73f7c5afdb667d5b129eedaabf9141f1ff02078f593c3b821d"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupByOp.Execute (cognitive 20): GroupByOp.Execute has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, loops 6 (nesting depth added 8). Of this number, 14 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_group_by.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"d803465bf021a678a8916da97d381d72fd646b9c3734e80b7bd0ed3e2009a37e"}},{"ruleId":"D2","level":"warning","message":{"text":"MergeOp.mergeWithScoreCollector (cognitive 20): MergeOp.mergeWithScoreCollector has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 4 (nesting depth added 8). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6e40dc5510b04b86e520afb1fb5c30bd65340e30fa898baef0fb547fc39a4c5"}},{"ruleId":"D2","level":"warning","message":{"text":"validator.CheckFunctionBasicParams (cognitive 20): validator.CheckFunctionBasicParams has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/validator.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e8821e257c8ed7d3ae9182550665cb7add6b6e190e7a9f8e91ffd2132aa7b02"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableIntegerOrFloatArrayData (cognitive 20): parquet.ReadNullableIntegerOrFloatArrayData has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1439}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ad4cf472119be0fe9d21fe7f219a9af6ac731efce126002b7479bb3ffac992d"}},{"ruleId":"D2","level":"warning","message":{"text":"textEncoder.EncodeEntry (cognitive 20): textEncoder.EncodeEntry has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mlog/zap_text_encoder.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"08ee131b6d2b9caa1027b866458e8549887de5d1795b6c4848426e45afd5bd05"}},{"ruleId":"D2","level":"warning","message":{"text":"Consumer.Chan (cognitive 20): Consumer.Chan has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10, match/switch 8, loops 2 (nesting depth added 13). Most of this is not in the body itself: 1 of the 20 points is its own statement and the rest belongs to one function literal inside it that branches (line 46). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mqwrapper/rmq/rmq_consumer.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb470af4b4f14e28bc928498a507bdb459a0dcd2bf5f6d74dd37bed77b425a26"}},{"ruleId":"D2","level":"warning","message":{"text":"externalspec.DeriveEndpoint (cognitive 20): externalspec.DeriveEndpoint has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 1, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/externalspec/external_spec.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cc7f29b10e2fa06ffea9da5ec5c0c4fc6599436c76ac0d99979acce4545756e"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.ValidateSparseFloatRows (cognitive 20): typeutil.ValidateSparseFloatRows has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":3772}}}],"partialFingerprints":{"codehealthFindingId/v1":"79a8168c2d3329a1c33eb62351b693f9b096233fca3e7530960ac21cb6eae773"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.isFunctionInputFieldOfType (cognitive 20): typeutil.isFunctionInputFieldOfType has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12, loops 6, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4076}}}],"partialFingerprints":{"codehealthFindingId/v1":"121fc9cbf90c7cdb9a62a83722f20db8a0c72bbfb13312c3f4b914e5744af7b8"}},{"ruleId":"D2","level":"warning","message":{"text":"FlushTask.Await (cognitive 19): FlushTask.Await has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, match/switch 6, loops 1 (nesting depth added 12). Of this number, 16 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/maintenance.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"a274cbf418330543fe040123fa43c7f1da05716f4d48b1f322e9a3d7a2c02fac"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientTelemetryManager.handleShowLatencyHistory (cognitive 19): ClientTelemetryManager.handleShowLatencyHistory has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 5 (nesting depth added 6). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1687}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b462c5645952b1326379008b880ecbba95dd741d9cb648053525c02f7185275"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupAggReducer.EmptyAggResult (cognitive 19): GroupAggReducer.EmptyAggResult has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, loops 2 (nesting depth added 8). Of this number, 17 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_reducer.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b606d30b1a41ebdd26c8e261b67494dc8423a09c5cb421a45ddef79eb6ec929"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionInspector.cleanPartitionStats (cognitive 19): compactionInspector.cleanPartitionStats has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"8353bb43ce2ef0561cda96b4a65d7c400a41f505e3b6cfdc8f65c78dd4014f03"}},{"ruleId":"D2","level":"warning","message":{"text":"copySegmentChecker.finishJob (cognitive 19): copySegmentChecker.finishJob has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 5, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_checker.go"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0ac8235b9dc0fb1b3d6bdce34a61d29df5676a2523904005f910192c7ee691e"}},{"ruleId":"D2","level":"warning","message":{"text":"externalCollectionRefreshManager.applyFinishedJobSegments (cognitive 19): externalCollectionRefreshManager.applyFinishedJobSegments has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_manager.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"35a6ee711c7e1aca17f4c591bf027412ce81dbbef5b9a93ab54cc6146a435fb6"}},{"ruleId":"D2","level":"warning","message":{"text":"lobGCContext.collectUsedLOBFiles (cognitive 19): lobGCContext.collectUsedLOBFiles has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, loops 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector_lob.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"633b43ae042a116f066e277f57745795387a1a142ca214d7d2be31a8743522bf"}},{"ruleId":"D2","level":"warning","message":{"text":"indexMeta.MarkIndexAsDeleted (cognitive 19): indexMeta.MarkIndexAsDeleted has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, loops 5, boolean chains 2 (nesting depth added 5). Of this number, 15 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f5c9d97bb1978cb90049ab7f1c4956117f8d98e2458bf4ea61e2eb8810bdfd2"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.UpdateChannelCheckpoints (cognitive 19): meta.UpdateChannelCheckpoints has cognitive complexity 19 (threshold 15). Drivers by points: loops 7, boolean chains 6, if/else 6 (nesting depth added 2). Of this number, 13 points are the body\u0027s own statements and 6 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":2885}}}],"partialFingerprints":{"codehealthFindingId/v1":"a24b99ff8bfa0d387b66c266fcb097d6717b1f91d61d6fa3957b8511da2963af"}},{"ruleId":"D2","level":"warning","message":{"text":"statsInspector.triggerTextStatsTask (cognitive 19): statsInspector.triggerTextStatsTask has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 5, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_inspector.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"5acf373f2c7293d20ea53c4c1b51ad7a32b8903ca8aa65f399a433a07662a3eb"}},{"ruleId":"D2","level":"warning","message":{"text":"external.targetOwnedDeltalogIdentitySet (cognitive 19): external.targetOwnedDeltalogIdentitySet has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/milvus_table_refresh.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f74767b816b6555822220feaabe03498e5ae8c15c5363995c1e06c68fa708ed"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.transformFieldBinlogs (cognitive 19): importv2.transformFieldBinlogs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, loops 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"217d1d5983171b0b3dc2cc34f62a1e9aae08a4151820bfa0043d3c805a5dcb16"}},{"ruleId":"D2","level":"warning","message":{"text":"resumableConsumerImpl.resumeLoop (cognitive 19): resumableConsumerImpl.resumeLoop has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 4 (nesting depth added 10). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/internal/consumer/consumer_impl.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"5599f3a1448c26cb658b5a9642db22ff2bea02cc406bdd539865193b48e76b1f"}},{"ruleId":"D2","level":"warning","message":{"text":"SyncTask.Run (cognitive 19): SyncTask.Run has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 3, match/switch 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/task.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"68377806ed3dd50d12870a8a3ba24c02832c4a3174f79757761b17494ba2784f"}},{"ruleId":"D2","level":"warning","message":{"text":"http.CheckPrivilege (cognitive 19): http.CheckPrivilege has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/http/rbac.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"908fcf964d077515376982cc2649cb4ddec7aab3dec977f4f31ddcaa6eb99e7e"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.loadGranteeIDPrefixWithLoadedGrantees (cognitive 19): Catalog.loadGranteeIDPrefixWithLoadedGrantees has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1517}}}],"partialFingerprints":{"codehealthFindingId/v1":"790a86d2d957b4775e75e907b5383fb2dc2baddb7b12ab35e204e4cc21a802b7"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.RestoreRBAC (cognitive 19): Catalog.RestoreRBAC has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, loops 6, match/switch 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":2138}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d730fd15a1857ff372d17332348a1959e6d39e73086fcfc88a4f5bc8332d0ee"}},{"ruleId":"D2","level":"warning","message":{"text":"catalog.SaveRecoverySnapshot (cognitive 19): catalog.SaveRecoverySnapshot has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/streamingnode/update.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"01e4613b5ec251db9ae6f0a44f8e86fbf993c23a5583813912b7b01bf56fc9fb"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitRange (cognitive 19): ParserVisitor.VisitRange has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1482}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c448bce5c9546af596439c12bfb463b91bf912c76a8498db7d6738559f13b63"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitReverseRange (cognitive 19): ParserVisitor.VisitReverseRange has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1562}}}],"partialFingerprints":{"codehealthFindingId/v1":"6363a2bf7ee3412cc35f3f88ff3c3a33d7391e3199fa3dc41d5d5f4072069175"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.newBuiltInPipeline (cognitive 19): proxy.newBuiltInPipeline has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, boolean chains 8 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":3631}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1b714a3423cd692461810bff7347eb45c5e4edec76242d665dffd2de0baacbe"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.ValidateField (cognitive 19): proxy.ValidateField has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"71398fe0c9ca076d05bd18185f7e405ecaa342f6781b3258678b4590cb150f5f"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validatePrimaryKey (cognitive 19): proxy.validatePrimaryKey has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 4, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f9f2e546a51ceffd2b5735957df0bd758e7f48a51ae8125d41ab6af0d13b6d0"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.checkUpsertPrimaryFieldData (cognitive 19): proxy.checkUpsertPrimaryFieldData has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2386}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6473e1467a28da2c29cfbb84ec979cd6a7986d0944121e26eae3570745be1e1"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reconstructStructFieldData (cognitive 19): proxy.reconstructStructFieldData has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10, loops 8, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":3248}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ce0ba2635f717e56bef4f3cf39fe3c90728d75369103f563b567580ffc9ffd0"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.GetLoadState (cognitive 19): Proxy.GetLoadState has cognitive complexity 19 (threshold 15). Drivers by points: if/else 19 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1939}}}],"partialFingerprints":{"codehealthFindingId/v1":"b11a5f5c01dbcfa2ded1d745f1e7bd4a7eabddc84061ce4439646200f3864fb7"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.search (cognitive 19): Proxy.search has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 3). Of this number, 12 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2883}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bd8d906871ed648c0b2f927cc6e7b769ca08c1c3b61a10bd4cec6bc7750fd2f"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.LoadSegments (cognitive 19): shardDelegator.LoadSegments has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, loops 8 (nesting depth added 2). Of this number, 13 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c98803e1a529539f7507e759d526d129536124a378d3c7cb95ae4a7defb26ad"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.ReleaseSegments (cognitive 19): shardDelegator.ReleaseSegments has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 3, boolean chains 1, match/switch 1 (nesting depth added 5). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"1928543be71c58d9a8442751fb0b448510f145fd2ca597ce9a048e2dd7cf70ef"}},{"ruleId":"D2","level":"warning","message":{"text":"UnaryRangeExpr.Eval (cognitive 19): UnaryRangeExpr.Eval has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, match/switch 2, boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/scalar_pruner.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"96ea22a69098a6c3417f99e205e94892a700679cbcdce24d51a74524e102d653"}},{"ruleId":"D2","level":"warning","message":{"text":"filterNode.filtrate (cognitive 19): filterNode.filtrate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 4, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/pipeline/filter_node.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0cade66a14a4fe7577537afd6cba41edd7d14a8a6848a0ddb61b7f908402296"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.validateMultiAnalyzerParams (cognitive 19): rootcoord.validateMultiAnalyzerParams has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":865}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7d6e00793522ccdb4779973062fc4ccb6ce8c6cd7ba5ad142f5d024429d1db7"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.prepareMilvusTableSnapshotSchema (cognitive 19): createCollectionTask.prepareMilvusTableSnapshotSchema has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, boolean chains 2, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"f18e77680f338b439e8475fe5aaa8577832c446e4e08afa6a304d799d7fcaee6"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaTable.RecoverFileResourceRefCnt (cognitive 19): MetaTable.RecoverFileResourceRefCnt has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":2538}}}],"partialFingerprints":{"codehealthFindingId/v1":"55ba8dfcf1e17bceae2e11cf5e6a427fa018c7cb3508603e191504e847777561"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.resetAllCurrentRates (cognitive 19): QuotaCenter.resetAllCurrentRates has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, loops 7 (nesting depth added 9). Most of this is not in the body itself: 3 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1376, 1363). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1349}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7c3724d2a8076b6d34d580892c6ceef400b419f7b667ed661dfe2b58381a535"}},{"ruleId":"D2","level":"warning","message":{"text":"TelemetryManager.GetClientTelemetry (cognitive 19): TelemetryManager.GetClientTelemetry has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, loops 1 (nesting depth added 5). Most of this is not in the body itself: 0 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 742). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/telemetry/manager.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f5cae4f14bd415e1c1283af5d672eaa9fbd5a69127beb0a412595189283e08c"}},{"ruleId":"D2","level":"warning","message":{"text":"RefManager.Download (cognitive 19): RefManager.Download has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, boolean chains 2, loops 2 (nesting depth added 7). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 298, 285). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/fileresource/manager.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9a8209adbc05f2b8b8cfd90c485f83834074131cf5db1bff0a9e099a19f169b"}},{"ruleId":"D2","level":"warning","message":{"text":"functionChainPlanner.validateOperatorMetadata (cognitive 19): functionChainPlanner.validateOperatorMetadata has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/optimization_plan.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"7971091cf7a3caf487ff5292eebb269109f5d92b3d78ca1a4c22768c6afbfa03"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.assignBM25Output (cognitive 19): embedding.assignBM25Output has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, match/switch 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/runner.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeacd203758e982a8602ac21498995bf6b6fd82ab24f3c90b76e58278d9d9763"}},{"ruleId":"D2","level":"warning","message":{"text":"validator.NormalizeFunctionOutputFields (cognitive 19): validator.NormalizeFunctionOutputFields has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 6 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/validator.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"0504921075365db31b548602277003c3cd8c9a31719ce9f8f9c1f7894c8f89f8"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientBase.call (cognitive 19): ClientBase.call has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, match/switch 1 (nesting depth added 5). Most of this is not in the body itself: 4 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 493, 483). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/grpcclient/client.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"055101742104c8f8969aeebb31405044ee937323fd97c62fad3e09493ad8907c"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadStringData (cognitive 19): parquet.ReadStringData has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e2366a18731cd139ca1bcfbcff003a0a135b25d0065380b2bc1b00f70917aae"}},{"ruleId":"D2","level":"warning","message":{"text":"reader.Read (cognitive 19): reader.Read has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, loops 4, jumps 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/reader.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff9bf4a9068809a8f2c8a9e73a3d6a4525c33f535d3e84d21d76dc9243e76b74"}},{"ruleId":"D2","level":"warning","message":{"text":"orderby.ParseOrderByFields (cognitive 19): orderby.ParseOrderByFields has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, match/switch 6, loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/reduce/orderby/types.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"30d08d17df612195f93cb4a6c0340b6a1eae153cb30cf2e28fcfb27ee3a3032e"}},{"ruleId":"D2","level":"warning","message":{"text":"schemautil.buildEvolutionFieldMaps (cognitive 19): schemautil.buildEvolutionFieldMaps has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 4 (nesting depth added 9). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/schemautil/schema_evolution.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"894a965e4444a3f06a685578b422c33b604778e36135414e41b95b57f0a64dd6"}},{"ruleId":"D2","level":"warning","message":{"text":"Session.processKeepAliveResponse (cognitive 19): Session.processKeepAliveResponse has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13, loops 3, match/switch 3 (nesting depth added 10). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":577}}}],"partialFingerprints":{"codehealthFindingId/v1":"b21637b40db803a262b98bfda7e5d3acf1b93fea50d235d5e0c6e51872eeb9da"}},{"ruleId":"D2","level":"warning","message":{"text":"rocksmq.Consume (cognitive 19): rocksmq.Consume has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_impl.go"},"region":{"startLine":835}}}],"partialFingerprints":{"codehealthFindingId/v1":"21fbf775f3350b3647456ae7ab0237fdbd4b56de262534b2f66224c6c97b2c42"}},{"ruleId":"D2","level":"warning","message":{"text":"Consumer.Chan (cognitive 19): Consumer.Chan has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, match/switch 6, loops 1 (nesting depth added 11). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to one function literal inside it that branches (line 122). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mqwrapper/kafka/kafka_consumer.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecf1af046e0cebf1298e847abf6a92bbd9819af6521d86114022625bdbd46300"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.GetDataIterator (cognitive 19): typeutil.GetDataIterator has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, loops 2 (nesting depth added 10). Of this number, 11 points are the body\u0027s own statements and 8 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":3476}}}],"partialFingerprints":{"codehealthFindingId/v1":"d761116f61d260b1ee97f1342dd5f7587af944faf6c7c95ce317ce8473d0e8d3"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.appendArrayRow (cognitive 19): typeutil.appendArrayRow has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, boolean chains 6, match/switch 1 (nesting depth added 6). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":4182}}}],"partialFingerprints":{"codehealthFindingId/v1":"67d02ec855cc9115f54f9ae72e6d27d9c22a9e698c7595dcbecf8ee6e6fd9a0f"}},{"ruleId":"D2","level":"warning","message":{"text":"DataSet.fillData (cognitive 18): DataSet.fillData has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/results.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"99947872ae54c49ccc98a877c26d41a8725a30463b84017145fb4348be79775c"}},{"ruleId":"D2","level":"warning","message":{"text":"YamlMarshaller.writeYamlRecursive (cognitive 18): YamlMarshaller.writeYamlRecursive has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/config/generate.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c56cccadc307cb123dd80e91a1b295ee688e7c07a3fe69efd2ce1041674b6bd"}},{"ruleId":"D2","level":"warning","message":{"text":"agg.AssembleSingleValue (cognitive 18): agg.AssembleSingleValue has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_util.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"24f47a27bc9e63894d568a5def10ce2a5bdf7ec82162d74f315635e69f3b8782"}},{"ruleId":"D2","level":"warning","message":{"text":"agg.ComputeAvgFromSumAndCount (cognitive 18): agg.ComputeAvgFromSumAndCount has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 4, boolean chains 1, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_util.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6dfe876fe85c93bb24dc74a20543c9877da20804f42eeaf41dcc51c78ed2a03"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.estimateVectorArrayElementCount (cognitive 18): datacoord.estimateVectorArrayElementCount has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_index.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c7e4cc941a25ca80074851f503565333e51f0536771101b26a5863a45d2f739"}},{"ruleId":"D2","level":"warning","message":{"text":"storageVersionUpgradePolicy.triggerOneCollection (cognitive 18): storageVersionUpgradePolicy.triggerOneCollection has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, boolean chains 4, loops 3 (nesting depth added 4). Of this number, 14 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_storage_version.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"545431aec2fe4d05253262d990bc5b57429a217366597695734d74d0b1cded85"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.processStats (cognitive 18): clusteringCompactionTask.processStats has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, match/switch 4, loops 2, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"dabd6d7246077b43a2ee877824a762b02a3fba311e7b69a3d6d69ab07c0830bc"}},{"ruleId":"D2","level":"warning","message":{"text":"compactionTrigger.ShouldDoSingleCompaction (cognitive 18): compactionTrigger.ShouldDoSingleCompaction has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":739}}}],"partialFingerprints":{"codehealthFindingId/v1":"138ee39608da34e6c0269fac47d19607e5b787b2dd7b0e08ec95d6018179c7dc"}},{"ruleId":"D2","level":"warning","message":{"text":"SegmentManager.tryToSealSegment (cognitive 18): SegmentManager.tryToSealSegment has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, loops 4 (nesting depth added 8). Of this number, 11 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_manager.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"9698b089985b292e0d1d40560f3ef54f69da4c07679114602038671563c3bddb"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleSessionEvent (cognitive 18): Server.handleSessionEvent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, match/switch 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/server.go"},"region":{"startLine":840}}}],"partialFingerprints":{"codehealthFindingId/v1":"77f1da0e24f7e1cf528dd059ca42562095410d7ee60d8f0342ebb4c129d5efe4"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetRecoveryInfoV2 (cognitive 18): Server.GetRecoveryInfoV2 has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":1031}}}],"partialFingerprints":{"codehealthFindingId/v1":"f01e81ae97241c2e3e84efc6959f079d137f1c12a055e661b778abdd44bd43b8"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetFlushState (cognitive 18): Server.GetFlushState has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":1463}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dcb345b39829f5c3a20693e0d186e190428a1fe961af8fbd23f00052e929f2c"}},{"ruleId":"D2","level":"warning","message":{"text":"indexBuildTask.prepareJobRequest (cognitive 18): indexBuildTask.prepareJobRequest has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_index.go"},"region":{"startLine":449}}}],"partialFingerprints":{"codehealthFindingId/v1":"689f27902ca51b6929a52ad553e0271d00859263f3989ad9faf0526ca1a975cc"}},{"ruleId":"D2","level":"warning","message":{"text":"external.collectMilvusTableDeltalogRefs (cognitive 18): external.collectMilvusTableDeltalogRefs has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 6 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/milvus_table_deltalog.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeb22756446273bf447f42002b110b7da0e45a5bac57c9aa3fed23ac882206a0"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.generateTargetIndexPath (cognitive 18): importv2.generateTargetIndexPath has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 1, loops 1, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":867}}}],"partialFingerprints":{"codehealthFindingId/v1":"a50d283988d0f8f65a677abbf63125eeded8d9ea827e78284b364330eebce8c1"}},{"ruleId":"D2","level":"warning","message":{"text":"statsTask.Execute (cognitive 18): statsTask.Execute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 4 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"44988be8777bcd386ccf66d2b1e6174b92f67a36f4c9c3a6468b7d71a7385801"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.convertDefaultValue (cognitive 18): httpserver.convertDefaultValue has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3118}}}],"partialFingerprints":{"codehealthFindingId/v1":"e253d347ab12f721c2040d952077233f230285085fc911a5774056188fd7c097"}},{"ruleId":"D2","level":"warning","message":{"text":"syncmgr.buildV3ColumnGroupFieldBinlogs (cognitive 18): syncmgr.buildV3ColumnGroupFieldBinlogs has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"e25f6dad45d04e61e29ec210e4a9bc994e5e1b6a2984cf0dc10e487402aaa841"}},{"ruleId":"D2","level":"warning","message":{"text":"etcdKV.executeTxn (cognitive 18): etcdKV.executeTxn has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9, loops 8, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":779}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa9261cb8525843da4450e04222bdbf295d8729c3795147f3791449071211784"}},{"ruleId":"D2","level":"warning","message":{"text":"catalog.newVChannelMetaFromKV (cognitive 18): catalog.newVChannelMetaFromKV has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, loops 2, match/switch 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/streamingnode/kv_catalog.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"59117791e3091a21ecc09ea2d75701ebfb636a523d8686734e62244c17897192"}},{"ruleId":"D2","level":"warning","message":{"text":"ParserVisitor.VisitArrayLength (cognitive 18): ParserVisitor.VisitArrayLength has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2629}}}],"partialFingerprints":{"codehealthFindingId/v1":"547a53f85603faef93e9ecb3a0874e5158e9da963f9a1bb29c31864da1cc7a46"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateL2RerankSystemNames (cognitive 18): proxy.validateL2RerankSystemNames has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, loops 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/function_chain_validator.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a4b0649817468cd0c3d847754c7892db696bfa79bb6dc3b246ad2e1ac24d40d"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.reduceSearchResultDataWithGroupBy (cognitive 18): proxy.reduceSearchResultDataWithGroupBy has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 7 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"1499ec2409d0fb8737cc1be503a2448fa11c1d7e5a6ce7311b18a055aadbf3f4"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.parseSearchIteratorV2Info (cognitive 18): proxy.parseSearchIteratorV2Info has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8abcd178976967dd4673fca2f65531c70f607a7aaefe591a2751ae555779ed0"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.OperatePrivilegeV2 (cognitive 18): Proxy.OperatePrivilegeV2 has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5459}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ddf3f2127444f64dabaac67ce7e4261eae41b819b409875d096f2372f29e740"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.OperatePrivilege (cognitive 18): Proxy.OperatePrivilege has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5529}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e5f2ee435ffa0a36b81d7dd1c2ee042d6b8abdfb4fc28386a82c54364f65a2a"}},{"ruleId":"D2","level":"warning","message":{"text":"search_agg.NewContext (cognitive 18): search_agg.NewContext has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 6, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/context_builder.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba64bea3f2c4ba7ca55311e96d4a9bcb5c726046ec42ea1fd079f47c2700f6ce"}},{"ruleId":"D2","level":"warning","message":{"text":"alterCollectionSchemaTask.preExecuteDrop (cognitive 18): alterCollectionSchemaTask.preExecuteDrop has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, loops 7, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"b25ed3eaf6fd66fdbed4f3daa38359002638e8b827f88ce9ffba6e0ed89d29c0"}},{"ruleId":"D2","level":"warning","message":{"text":"loadCollectionTask.Execute (cognitive 18): loadCollectionTask.Execute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3172}}}],"partialFingerprints":{"codehealthFindingId/v1":"51f9e8f71df7994782f1cbc724179643e4d2e1d66e69470330d82318436ba8c8"}},{"ruleId":"D2","level":"warning","message":{"text":"segmentCountBasedPlanGenerator.generatePlans (cognitive 18): segmentCountBasedPlanGenerator.generatePlans has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, loops 5 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/balance/multi_target_balance.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"69935f281a45ea2ce22fd93d189475f7edc6de018ff00370d1e2b2d4916d80aa"}},{"ruleId":"D2","level":"warning","message":{"text":"LeaderChecker.Check (cognitive 18): LeaderChecker.Check has cognitive complexity 18 (threshold 15). Drivers by points: loops 10, if/else 8 (nesting depth added 10). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/checkers/leader_checker.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"136170e66525b764d7a1c76c74738447befc988209293c2fc2d6630fab808399"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaManager.RemoveSQNodesInCollections (cognitive 18): ReplicaManager.RemoveSQNodesInCollections has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, loops 7, boolean chains 1 (nesting depth added 5). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bdf2c5b725ad3dcc59f3ca6ddbca01ab1e1c3729b684a21e5185c29d23586c5"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectionObserver.observeLoadStatus (cognitive 18): CollectionObserver.observeLoadStatus has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 1, match/switch 1 (nesting depth added 5). Most of this is not in the body itself: 2 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 256). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/observers/collection_observer.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe21a87e9f52c990a74ad2688fdc7fa53eb9e60f612576a68f659d78b375053f"}},{"ruleId":"D2","level":"warning","message":{"text":"utils.GetShardLeadersWithChannelsAndReplicaFilter (cognitive 18): utils.GetShardLeadersWithChannelsAndReplicaFilter has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, boolean chains 4, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/utils/util.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"761eca1ae84cd6f15fadf8e90bee8c7f0f6a17a92a485d6ef9ee8963129d8426"}},{"ruleId":"D2","level":"warning","message":{"text":"delegator.PruneSealedSegmentsByPKFilter (cognitive 18): delegator.PruneSealedSegmentsByPKFilter has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 5, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/segment_pruner.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"4acf5dba5aae67877fc290746a468cdf96871e173789c9eb6206ab2f2a7c97f9"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.reduceGroupBySinglePerNq (cognitive 18): segments.reduceGroupBySinglePerNq has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, boolean chains 3, match/switch 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/search_reduce.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb1275032d8cf818abec2379705ac7753382b8ebf71b5bf6e9330479dc659a31"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.buildSchemaForDropFunctionField (cognitive 18): rootcoord.buildSchemaForDropFunctionField has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 5, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_collection_schema.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd7487b502e7b740825b8212d219326886c357c3bffe0e9b92605e2e2756c66e"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.maxAssignedFieldIDFromSchema (cognitive 18): rootcoord.maxAssignedFieldIDFromSchema has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, loops 5 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":614}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bea8975b6da3951196f7ea348a43dcecd1da08c6d0dc05a604e72f10066a310"}},{"ruleId":"D2","level":"warning","message":{"text":"DDLCallback.dropCollectionV1AckCallback (cognitive 18): DDLCallback.dropCollectionV1AckCallback has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_drop_collection.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbcdbc234e653f5f1bcad8bb2c311105b08dbc4f1d2deddebe0d9a03ab5f0418"}},{"ruleId":"D2","level":"warning","message":{"text":"MetaTable.AlterCollection (cognitive 18): MetaTable.AlterCollection has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, match/switch 2, boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":1063}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eff68c9b6beb19c884f1ae752559dd021dacde95c59ef42b9baed87d8c1868d"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.restore (cognitive 18): Core.restore has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, loops 6, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":680}}}],"partialFingerprints":{"codehealthFindingId/v1":"72f1917e2c2968649ce81d3a467fef77c244b616c51b0d3bd067c98995f25d37"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewPayloadWriter (cognitive 18): storage.NewPayloadWriter has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0c4e87ac5395e2b738e14b1609c7063b3b6d722af9a47bf8e52bcd02c8d70d0"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.NewBinlogRecordWriter (cognitive 18): storage.NewBinlogRecordWriter has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, match/switch 1 (nesting depth added 7). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/rw.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"38ac88df7d3a014c4818b2ae7a83843c28e1b17589f620ee93d1e637266782b2"}},{"ruleId":"D2","level":"warning","message":{"text":"StatsResolver.TextAndJSONIndexStatsWithBasePaths (cognitive 18): StatsResolver.TextAndJSONIndexStatsWithBasePaths has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, boolean chains 2, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storagev2/packed/stats_resolver.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b45e8b2581e7d1fe5f149aa9a38cc5e0a34963ee98fce77093eda5d5a6cc3f7"}},{"ruleId":"D2","level":"warning","message":{"text":"WALFlusherImpl.Execute (cognitive 18): WALFlusherImpl.Execute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 2, loops 1 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/flusher/flusherimpl/wal_flusher.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c8924477631d998016cdba78d786daf67584cb741b89ead1ca28fe7e3835a0"}},{"ruleId":"D2","level":"warning","message":{"text":"WALFlusherImpl.dispatch (cognitive 18): WALFlusherImpl.dispatch has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, match/switch 1 (nesting depth added 5). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/flusher/flusherimpl/wal_flusher.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eb07beda0087ea3d7e6698751b3d7912709528696b4620c7907c0af256ac335"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.parseWeightedParams (cognitive 18): chain.parseWeightedParams has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 2, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/rerank_builder.go"},"region":{"startLine":425}}}],"partialFingerprints":{"codehealthFindingId/v1":"e42a2baf55d5210a665abf8b0b3e5e6d64875eb22bda9b5738b1ea48492c9c79"}},{"ruleId":"D2","level":"warning","message":{"text":"expr.validateXGBoostInputChunks (cognitive 18): expr.validateXGBoostInputChunks has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/expr/xgboost_expr.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"1111dc62fd7ae6ed1a7071da39b856691ca151f6405247f67e6fe47d2dd9eb34"}},{"ruleId":"D2","level":"warning","message":{"text":"MergeOp.collectWeightedScores (cognitive 18): MergeOp.collectWeightedScores has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"d030d713f96b77a162d30f340ea85ea773aa67af9ca0594175fea5dc65d3a096"}},{"ruleId":"D2","level":"warning","message":{"text":"MergeOp.collectCombinedScores (cognitive 18): MergeOp.collectCombinedScores has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9528cbd50673075a28eaed09d3362937e5c57098d1e01f4e970e534f988348d"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.HasNonBM25AndMinHashFunctions (cognitive 18): embedding.HasNonBM25AndMinHashFunctions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8, loops 8, match/switch 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/function_util.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"d18465168f888ca6c77851c6a9750a737f5eb436d90c87c136b9835d06e5608a"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.NewHuggingFaceEmbeddingProvider (cognitive 18): embedding.NewHuggingFaceEmbeddingProvider has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/huggingface_embedding_provider.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"2030af2a76ad09b5130188eef7ea9c93733dd7e363422d6266d8826816fa2004"}},{"ruleId":"D2","level":"warning","message":{"text":"retryableReader.Read (cognitive 18): retryableReader.Read has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 2 (nesting depth added 5). Most of this is not in the body itself: 0 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 149). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/common/retryable_reader.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7316ca0ecdc3f5fd367466a05c6896ea3272f029fafb8dea2eb0664d5cf8aa2"}},{"ruleId":"D2","level":"warning","message":{"text":"json.NewRowParser (cognitive 18): json.NewRowParser has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 5, boolean chains 2 (nesting depth added 6). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"c51db2304253558b430accd041378545b5f824c6be0fc5d6506eafeb6cff3dd8"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.selectMinPKWithTimestamp (cognitive 18): queryutil.selectMinPKWithTimestamp has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, boolean chains 5, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/reduce_by_pk_op.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ef569a859153f86d53e75bff222b539b76b02e5f7933738629a591cbd6030db"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.updateEvent (cognitive 18): Manager.updateEvent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/config/manager.go"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"48886aae8ac893127c8cacec10e85a643f0f3d53490fb481cecd62b638e00f8e"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.ProcessImmutableConfigs (cognitive 18): Manager.ProcessImmutableConfigs has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 4). Most of this is not in the body itself: 7 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 524). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/config/manager.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"c556828a1f32214be4984bf9d11fb2625545b7bab4f537a91ae23024be4bdb35"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.unmarshalSparseFloatArray (cognitive 18): fastpb.unmarshalSparseFloatArray has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, boolean chains 3, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/fielddata.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"22ae4b29b8d41828640968c0b679c504076e1acf96011e2efd50ce5587c1ded9"}},{"ruleId":"D2","level":"warning","message":{"text":"FieldDataIdxComputer.Compute (cognitive 18): FieldDataIdxComputer.Compute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, loops 6, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":984}}}],"partialFingerprints":{"codehealthFindingId/v1":"e877941b2eeca8f4ecd850faa9e3099600675420b5a625dd5a02aea070f0ffb8"}},{"ruleId":"D2","level":"warning","message":{"text":"milvus.addActiveKeySuffix (cognitive 17): milvus.addActiveKeySuffix has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/util.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"329af0dacf34b2f1c9c2d6d6f83cdf636473582c7000cc34e6e483c397c0ab8b"}},{"ruleId":"D2","level":"warning","message":{"text":"main.flattenYaml (cognitive 17): main.flattenYaml has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/config/printer.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"a73cb47657892cd1d6e4792f8d05dfe1952338e4e34e968fcc3bd5861914eb66"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 17): main.main has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/datameta/main.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"85b548bd7184c45e5fee61a226c96e433522a8e6d27180cdf6b247f7c205f0f5"}},{"ruleId":"D2","level":"warning","message":{"text":"channelReplicator.startConsumeLoop (cognitive 17): channelReplicator.startConsumeLoop has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, match/switch 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cdc/replication/replicatemanager/channel_replicator.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"1117af1fb8a319c3fd010059edf5f3e8d542b5a10e97674b61106c03de9ca8dd"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.largerGroupingSegments (cognitive 17): datacoord.largerGroupingSegments has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_view_forcemerge.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"e15ae2e13c1f53217467a5612159f006fd7e4978805ce5a4dac6b2e0b20088f7"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.filterDuplicateFieldBinlogs (cognitive 17): datacoord.filterDuplicateFieldBinlogs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 6, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/util.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d5cd3398e9f579ea5ebec7a85a49f801e7333885f31f8be5a07c10c9b6a701c"}},{"ruleId":"D2","level":"warning","message":{"text":"singleCompactionPolicy.triggerOneCollection (cognitive 17): singleCompactionPolicy.triggerOneCollection has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 4). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_policy_single.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"726a987af10c1c36effd80343bdcd759f06995ccfb6cc2a78bf1849373192976"}},{"ruleId":"D2","level":"warning","message":{"text":"l0CompactionTask.QueryTaskOnWorker (cognitive 17): l0CompactionTask.QueryTaskOnWorker has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_l0.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf5d12f53f8583b0fd709888bb714787b6dfff279128498c0c990ccf54abfe3e"}},{"ruleId":"D2","level":"warning","message":{"text":"copySegmentChecker.checkCopyingJob (cognitive 17): copySegmentChecker.checkCopyingJob has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_checker.go"},"region":{"startLine":448}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ae7ff703ef086e37a767a42927048f2e7d72cc3d2eaabe99e66f50bb114f7b0"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedBinLogWithChecker (cognitive 17): garbageCollector.recycleUnusedBinLogWithChecker has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 699, 691). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"686557e6ca08c666464ea7efc66782962a79fe21eb4fbe665250d740000e82fc"}},{"ruleId":"D2","level":"warning","message":{"text":"garbageCollector.recycleUnusedIndexFilesV0 (cognitive 17): garbageCollector.recycleUnusedIndexFilesV0 has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 1474). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1461}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac4102940a6ccfc9c38670c5df2361c855b22bf8d1ea874f6795534735147d7e"}},{"ruleId":"D2","level":"warning","message":{"text":"ServerHandler.getEarliestSegmentDMLPos (cognitive 17): ServerHandler.getEarliestSegmentDMLPos has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2897e4207bdc70e753230b2fa773686ee1095c01c4795991f1327d3e4d9c53d"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetSegmentInfo (cognitive 17): Server.GetSegmentInfo has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aa5ff018ecfb5bafd81d34b9decaec6ee21dca25dfefa9f1227239ad0522ea9"}},{"ruleId":"D2","level":"warning","message":{"text":"mixCompactionTask.initLOBCompactionContext (cognitive 17): mixCompactionTask.initLOBCompactionContext has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, loops 5 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":687}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e83f4811258b1b70c8a99e1a31e328db1de7376ab3da056e10216b64658538a"}},{"ruleId":"D2","level":"warning","message":{"text":"external.streamBatches (cognitive 17): external.streamBatches has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/function_executor.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d7dd6db32c87449491e732a09c86957ea887b82b2384c08af6a11219d696753"}},{"ruleId":"D2","level":"warning","message":{"text":"importv2.GetRowsStats (cognitive 17): importv2.GetRowsStats has cognitive complexity 17 (threshold 15). Drivers by points: loops 14, if/else 3 (nesting depth added 6). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/hash.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"90124eae5e68d2f9a36e69aa0fce9a0c446db3136777b3228a17a108efaa4a3f"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.genFunctionParamValue (cognitive 17): httpserver.genFunctionParamValue has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 1, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3932}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3a1b16fec8c4e56903fe2597462ecc95f1b874d357fc2865b37d21729e8ae8b"}},{"ruleId":"D2","level":"warning","message":{"text":"HandlersV2.query (cognitive 17): HandlersV2.query has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1391}}}],"partialFingerprints":{"codehealthFindingId/v1":"6071eba1603b9ca0e2f6e2814943835c0be1ed32bb842540937ee4fb5c61325c"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.startExternalGrpc (cognitive 17): Server.startExternalGrpc has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"9950ad3df4d5503224136fddc3a71d3a0a3412375017dcb4e6fcb6ea7bfa5148"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.Stop (cognitive 17): Server.Stop has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 4 (nesting depth added 2). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 621). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9f312d83aee6e3ad039d50960c72bf995f9a465a99f9a2ad9b803badfb7c259"}},{"ruleId":"D2","level":"warning","message":{"text":"ttNode.Operate (cognitive 17): ttNode.Operate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/flow_graph_time_tick_node.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"bff28a52aa987db3bab4ecc358fdef36e19abf9b55493be8955ccbcc69a5e4f3"}},{"ruleId":"D2","level":"warning","message":{"text":"syncmgr.resolveColumnGroups (cognitive 17): syncmgr.resolveColumnGroups has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, loops 6, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/task.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6883b097ef50b07b7a2e9d05d34de22c509b68afd3cea36db2930f6d000e491"}},{"ruleId":"D2","level":"warning","message":{"text":"txnTiKV.MultiSaveAndRemove (cognitive 17): txnTiKV.MultiSaveAndRemove has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 3 (nesting depth added 7). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 494). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":481}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a40e5302f6632336c3aebedd34f3188dcbceecc5d9cb20cba57c88e651dd98f"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.applyBinlogInfo (cognitive 17): Catalog.applyBinlogInfo has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"e507c7d714254364ec3823324dc5b3d5b05006ce38c5c965741b2395db7f2e04"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.buildAlterSegmentsKvs (cognitive 17): Catalog.buildAlterSegmentsKvs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0664115f35f4bcfcf0178456d94fc4da3662e3e11fd21c36f479f0f6c65ea9c"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.ListPolicy (cognitive 17): Catalog.ListPolicy has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, loops 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1998}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac983f283f8cbdd07d046db384d2877c53cf646638fd6ecbdd5357aa80665cdc"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.FillUnaryRangeExpressionValue (cognitive 17): planparserv2.FillUnaryRangeExpressionValue has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/fill_expression_value.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"89217b0775338ff728b81c6156bcaaf4fb3aeaf8000b4c48b5ec8774e1b7c2c9"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.combineBinaryArithExpr (cognitive 17): planparserv2.combineBinaryArithExpr has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, boolean chains 8 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"c22aabf5572d2d8f673132f7e1517d73cbd18273065aa52d8850e7044b9c6410"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.combineOrEqualsToIn (cognitive 17): visitor.combineOrEqualsToIn has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 5, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"52229a039432e534e01f334c8de9e603fc14f3ab7eba28ca265fb32b6223c89f"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.validateAddStructSubFieldProperties (cognitive 17): proxy.validateAddStructSubFieldProperties has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":908}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f6ef56b0bba90b65c6bd2bb6c01106c24b36c56432169f46b30838bfd1790f9"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.ValidateStructArrayField (cognitive 17): proxy.ValidateStructArrayField has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, loops 5 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ba274187a5cb130ff93614ecb3ca24015305071703b5d8aa11766da878a17ff"}},{"ruleId":"D2","level":"warning","message":{"text":"alterCollectionFunctionTask.PreExecute (cognitive 17): alterCollectionFunctionTask.PreExecute has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/function_task.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"17b74d544f1d740434b712895acf205740cdb9a3379095ce619479da01d04643"}},{"ruleId":"D2","level":"warning","message":{"text":"search_agg.buildTopHitsConfig (cognitive 17): search_agg.buildTopHitsConfig has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_agg/context_builder.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"f96bbc5d308d01e703121125709f481daa19a7ae15d34ecdb0a68c2e22b0bdc9"}},{"ruleId":"D2","level":"warning","message":{"text":"elementKeyRestoreOperator.run (cognitive 17): elementKeyRestoreOperator.run has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 2, loops 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":699}}}],"partialFingerprints":{"codehealthFindingId/v1":"02a1f6169d7f4d3c6485ffd509d2474889e1de08169a8054056555fb5ba8a47f"}},{"ruleId":"D2","level":"warning","message":{"text":"flushTask.Execute (cognitive 17): flushTask.Execute has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, loops 5 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_flush_streaming.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"f06054ce28a151bfe08eb6517bbbed49ed45b05b68138d7faccd0e825ea22f8a"}},{"ruleId":"D2","level":"warning","message":{"text":"Scheduler.schedule (cognitive 17): Scheduler.schedule has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8, loops 7, match/switch 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/job/scheduler.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"2742c331e21e6a694c7bea742f6d7178dd41159d8f4c39a01476f18e71d3c2ac"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelDistManager.Patch (cognitive 17): ChannelDistManager.Patch has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/channel_dist_manager.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2da67e2e4c4e57075560bb52b042637d1f88e795361930c0255f2c481ec6b4e"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicaManager.Spawn (cognitive 17): ReplicaManager.Spawn has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cd201a16189f0d14aff5310b6c23fa57de984a922c581a8f8d23bd0aecf58b1"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.watchNodes (cognitive 17): Server.watchNodes has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, match/switch 5, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/server.go"},"region":{"startLine":639}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9510258a3931e21cff23239a72a84d9113a913c8b0671711fbc5ab04fab403a"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.GetPartitionStates (cognitive 17): Server.GetPartitionStates has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, loops 4, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/services.go"},"region":{"startLine":340}}}],"partialFingerprints":{"codehealthFindingId/v1":"496d022e3e9cbdd983a597eb5220cc46d0ac5eec48ad4fd21c706091a73c4bdb"}},{"ruleId":"D2","level":"warning","message":{"text":"QueryCluster.updateLoop (cognitive 17): QueryCluster.updateLoop has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7, match/switch 6, loops 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/session/cluster.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"c230e8e075c5ea13dd0638b24cd959cc377dd327fb91a102c0509f70e2d2aa4e"}},{"ruleId":"D2","level":"warning","message":{"text":"task.applyCollectionMmapSetting (cognitive 17): task.applyCollectionMmapSetting has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/utils.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f48d8b8f9ae1d5b21f2e37e7be520c2256c1f0c5f26f2cbdee802bed2d14ce5"}},{"ruleId":"D2","level":"warning","message":{"text":"task.applyIndexWarmupSetting (cognitive 17): task.applyIndexWarmupSetting has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, loops 5, boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/utils.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"5295903f50b38457fe2047edcd5a66ea7aae4ce863b16c3fdf4e39b378eb736a"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.buildBM25IDF (cognitive 17): shardDelegator.buildBM25IDF has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1367}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9acfb87c70d117f8c295566c8e52095b439ee045536f7742962b83966ff9691"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.ReduceSearchResults (cognitive 17): segments.ReduceSearchResults has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 2 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/result.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"4498a2f2cee061baef480748c8085b9d032665ecf0bc074c9e47bb980b0fac81"}},{"ruleId":"D2","level":"warning","message":{"text":"tasks.heapMergeReduceImpl (cognitive 17): tasks.heapMergeReduceImpl has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/heap_merge_reduce.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4bfec1541007e5006dd6c433f241e908294eadf72571d145cbf887e3feaf790"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.validateStructArrayFieldDataType (cognitive 17): rootcoord.validateStructArrayFieldDataType has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, boolean chains 3, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/util.go"},"region":{"startLine":593}}}],"partialFingerprints":{"codehealthFindingId/v1":"218ea56b9bb43cb08bb32bbd456c524e87ba28af39d21a0087e4029ed5ec8332"}},{"ruleId":"D2","level":"warning","message":{"text":"Core.broadcastAlterDatabase (cognitive 17): Core.broadcastAlterDatabase has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 3 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks_alter_database.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebf9c51a81634e68c5e7764d94e550e5c7936a981db732ed5f7a7ca0b64c1f80"}},{"ruleId":"D2","level":"warning","message":{"text":"storage.readNullableVectorData (cognitive 17): storage.readNullableVectorData has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 7 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1389}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e7b8fff4872e743c5e11b513f5cbe4d7c44eb04c4cd5d6eaa339b78fe7236f7"}},{"ruleId":"D2","level":"warning","message":{"text":"deleteLogToRecordReader.Next (cognitive 17): deleteLogToRecordReader.Next has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 6, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_delta.go"},"region":{"startLine":607}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4fef8b3df223e7c8288cbb96f9a6b6eb0258c786be7fe1d1fe31ec27b407204"}},{"ruleId":"D2","level":"warning","message":{"text":"assignmentDiscoverClient.recvLoop (cognitive 17): assignmentDiscoverClient.recvLoop has cognitive complexity 17 (threshold 15). Drivers by points: loops 8, if/else 7, match/switch 2 (nesting depth added 10). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/client/assignment/discoverer.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"b71710d0eae42d083ffcc9977487483d7ed3026c7805f535f7c264f525051ea7"}},{"ruleId":"D2","level":"warning","message":{"text":"walAdaptorImpl.Append (cognitive 17): walAdaptorImpl.Append has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, match/switch 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/wal_adaptor.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"93408d4f3afdcc5030fede07297f7940bed9ade20351dc812c4b4dc374033a59"}},{"ruleId":"D2","level":"warning","message":{"text":"AppendMetrics.IntoLogFields (cognitive 17): AppendMetrics.IntoLogFields has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, jumps 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/metricsutil/append.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dc191acb2c76616dce0a3a35f1bd478f3faf77d735c8679d975214315c99cc3"}},{"ruleId":"D2","level":"warning","message":{"text":"recoveryStorageImpl.initializeRecoverInfo (cognitive 17): recoveryStorageImpl.initializeRecoverInfo has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/recovery/recovery_persisted.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c52fb776665e8f1794b8a14a762eba21e5528d6abe814ade7f25bc454b8916e"}},{"ruleId":"D2","level":"warning","message":{"text":"chain.getTypedValue (cognitive 17): chain.getTypedValue has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":970}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa792ac6c3966d7012d0345349a9a0ffa39a2e420d9ed1ed71f016fc95de1a7d"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.newOpenAIEmbeddingProvider (cognitive 17): embedding.newOpenAIEmbeddingProvider has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/openai_embedding_provider.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"4826a6ceb6a723dc693dc3ab4e8cad33bb2441d4daa9d4641316530bb963b98a"}},{"ruleId":"D2","level":"warning","message":{"text":"rerank.newTeiProvider (cognitive 17): rerank.newTeiProvider has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, match/switch 2, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/rerank/tei_rerank_provider.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb09afb64f4fdfca47bf942fcbae688d0d47d48a3ca086bb7b6ff468607d990"}},{"ruleId":"D2","level":"warning","message":{"text":"validator.CheckFunctionAlterAllowed (cognitive 17): validator.CheckFunctionAlterAllowed has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/validator/alter_whitelist.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"183facaf930ac1167ca2e62d9e4ec5cde5d8d386b463fc8b28c445b50f585a65"}},{"ruleId":"D2","level":"warning","message":{"text":"reader.init (cognitive 17): reader.init has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/binlog/reader.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"37a3b6ff5ea5f04eb56f9a4b998b461d9b627d461d6b8059c79f42f512255ce8"}},{"ruleId":"D2","level":"warning","message":{"text":"common.ArrayOfVectorToFieldData (cognitive 17): common.ArrayOfVectorToFieldData has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/common/vector_array.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"97f1a801993fb1c10c0a9cb0eab26491fb09d1227d04aac97e58f5dce7a9885e"}},{"ruleId":"D2","level":"warning","message":{"text":"importutilv2.ParseTimeRange (cognitive 17): importutilv2.ParseTimeRange has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 3 (nesting depth added 9). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 95). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/option.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc4420777be0d95f18e806a45c4fa76680139a683ee5cc59aff648029bd90895"}},{"ruleId":"D2","level":"warning","message":{"text":"importutilv2.GetFileType (cognitive 17): importutilv2.GetFileType has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/util.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"51c84203e7250adf7c04696aa77eacaf710469754f1f250429ea7f5890f70d3e"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.parseSparseFloatVectorStructRow (cognitive 17): parquet.parseSparseFloatVectorStructRow has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, boolean chains 5, match/switch 2, loops 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1023}}}],"partialFingerprints":{"codehealthFindingId/v1":"124ac05f5b122e518653f10186e0c66e7d529c66978151f6bc5025cf9f3f1699"}},{"ruleId":"D2","level":"warning","message":{"text":"ConcatAndCheckPKOperator.Run (cognitive 17): ConcatAndCheckPKOperator.Run has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 4, boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/dedup_pk_op.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5b3045f9832d5913db511df3e1f5352848e251522de7ead52dc3e81efe7b671"}},{"ruleId":"D2","level":"warning","message":{"text":"ResultCacheServer.Send (cognitive 17): ResultCacheServer.Send has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/streamrpc/streamer.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"00d623deac24cf23db2273482b2cd1ef3be5b95d5efffa04bed93906fe977929"}},{"ruleId":"D2","level":"warning","message":{"text":"SimpleMsgDispatcher.filterAndParase (cognitive 17): SimpleMsgDispatcher.filterAndParase has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/msgstream.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"103371bc8b919933042b9a5f5da1966384f5da435f0ce89d5db92a66d0f38a1b"}},{"ruleId":"D2","level":"warning","message":{"text":"HuaweiCredentialProvider.Retrieve (cognitive 17): HuaweiCredentialProvider.Retrieve has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/objectstorage/huawei/huawei.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"70a69aca6f7894a397adc8b43fd03d0d21f47f5119f4519f661f53331492f7c4"}},{"ruleId":"D2","level":"warning","message":{"text":"scannerImpl.executeConsume (cognitive 17): scannerImpl.executeConsume has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 3, boolean chains 2, match/switch 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/walimpls/impls/kafka/scanner.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"da574b21dba5048705e6961843dbaa31aeeab9b58a723e03e298b97e8603cc0c"}},{"ruleId":"D2","level":"warning","message":{"text":"lruCache.peekAndPin (cognitive 17): lruCache.peekAndPin has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/cache/cache.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"fea45df634af087b46c6a207d344c011687eafe1a76ff4d0fbe79f19d2e554ce"}},{"ruleId":"D2","level":"warning","message":{"text":"fastpb.decodeScalarFallback (cognitive 17): fastpb.decodeScalarFallback has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/helpers.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"229e16f0cf5d66ea2b8891f36b6d36a016bdb09b1adfe755e4da394443875121"}},{"ruleId":"D2","level":"warning","message":{"text":"ReplicateConfigValidator.validateTopologyTypeConstraint (cognitive 17): ReplicateConfigValidator.validateTopologyTypeConstraint has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/replicateutil/config_validator.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"19343697748a86a2b0902a71e72d354c817f14df8e6f331c5c1cbbaf9c61640b"}},{"ruleId":"D2","level":"warning","message":{"text":"manager.gc (cognitive 17): manager.gc has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, loops 3, match/switch 3, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/resource/resource_manager.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b6e93228ea41e85e8f297260f04e1eefcaac336eee39b7e4ea0089fdd34d620"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.DeleteFieldData (cognitive 17): typeutil.DeleteFieldData has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 8, if/else 6, boolean chains 2, loops 1 (nesting depth added 9). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1585}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9f2e518ceabb142ae2baed55d4e4004113a4c93dd86e127edc7b8730dcb1559"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.ValidateMilvusTableSchemaIdentity (cognitive 17): typeutil.ValidateMilvusTableSchemaIdentity has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 2, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":2850}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7363e294cf38d39c70efd37c93e39b04acfe2e99ff617916e67b3cc5b85a7ad"}},{"ruleId":"D2","level":"warning","message":{"text":"searchOption.Request (cognitive 16): searchOption.Request has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read_options.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"14b9ceda339aa4f70189635c2cf7be8a9ac43cd811e6611dd766d5da763ea49f"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientTelemetryManager.aggregateSnapshots (cognitive 16): ClientTelemetryManager.aggregateSnapshots has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1808}}}],"partialFingerprints":{"codehealthFindingId/v1":"2771de2229c698b24fd8ef22490ac1cf87b06a437fb148e911676dcf190f78b9"}},{"ruleId":"D2","level":"warning","message":{"text":"etcd220.Save (cognitive 16): etcd220.Save has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd220.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"16b6e913444e1f2dbd0d14bd36d89875b6e6235183035765f1f12ab1c0404e68"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.combineToLoadInfo220 (cognitive 16): meta.combineToLoadInfo220 has cognitive complexity 16 (threshold 15). Drivers by points: loops 10, if/else 4, boolean chains 2 (nesting depth added 6). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/210_to_220.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"e54cbd87a6238e3c60cfbedf34a75a37c9632b68b0ed227f1e0c100a8c6d8c1a"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.syncVectorScalarIndexes (cognitive 16): datacoord.syncVectorScalarIndexes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":865}}}],"partialFingerprints":{"codehealthFindingId/v1":"150a2f3ae6daa2add0b2ad08515f7b9d8deafcd8cf0d2f6c02364cfeea4f6d50"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.reviseVChannelInfo (cognitive 16): datacoord.reviseVChannelInfo has cognitive complexity 16 (threshold 15). Drivers by points: loops 7, if/else 6, boolean chains 3 (nesting depth added 4). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta_util.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"816ef6e1bd80b67a293e30fb71df102a776d7b665db9c9862b75ed7c0d3615e6"}},{"ruleId":"D2","level":"warning","message":{"text":"datacoord.getCompactedSegmentSize (cognitive 16): datacoord.getCompactedSegmentSize has cognitive complexity 16 (threshold 15). Drivers by points: loops 15, if/else 1 (nesting depth added 9). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/util.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"75da7b9d93509d1afd97f512ebc92b6ff021f4ecd6f9c0e77ba865739cc87116"}},{"ruleId":"D2","level":"warning","message":{"text":"indexMeta.getSegmentsIndexStates (cognitive 16): indexMeta.getSegmentsIndexStates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 4, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7727960fcfca9193d2ab7d4730834aa3de16ea76389a06e3c37b2e2d1779ae6"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.GetMinGrowingSegmentCheckpoint (cognitive 16): meta.GetMinGrowingSegmentCheckpoint has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":2756}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba4da9cdb4dd6d1f2cdd50786518187c04f8ab43ba30ad0a69138388d0dec05d"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.validateRestoreSnapshotResources (cognitive 16): Server.validateRestoreSnapshotResources has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 5, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/ddl_callbacks.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc41a65bd224764695548913afdb0319b55306385abce8d598a80346daa76f6"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.flushCollection (cognitive 16): Server.flushCollection has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, loops 7, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb53111dad4020d268a2456c3f44fd2c910e28eac19a0e45ad34daa0109cc45f"}},{"ruleId":"D2","level":"warning","message":{"text":"snapshotManager.RestoreIndexes (cognitive 16): snapshotManager.RestoreIndexes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":853}}}],"partialFingerprints":{"codehealthFindingId/v1":"dced8d0d33f3d40857df2960297aa57e0c36f3ab57cfc3a1e13dd3cbedc5f161"}},{"ruleId":"D2","level":"warning","message":{"text":"snapshotMeta.SaveSnapshot (cognitive 16): snapshotMeta.SaveSnapshot has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, loops 7 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_meta.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"63b255d8b080580b144897ed062a091589b345fa5e144c3ecd3dd6c643401bb6"}},{"ruleId":"D2","level":"warning","message":{"text":"statsInspector.triggerBM25StatsTask (cognitive 16): statsInspector.triggerBM25StatsTask has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, loops 5, boolean chains 3 (nesting depth added 7). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_inspector.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ff489542474680a33badc6428585d163a97861728b1b761ab9e5970cd6cc928"}},{"ruleId":"D2","level":"warning","message":{"text":"compactor.newMinHashFunctionMaterializer (cognitive 16): compactor.newMinHashFunctionMaterializer has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/record_materializer.go"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"09027a7ac84f3692fc9121dc6e3aeb496723f752c492a70c8fb89bbddc39d24e"}},{"ruleId":"D2","level":"warning","message":{"text":"compactor.newBM25FunctionMaterializer (cognitive 16): compactor.newBM25FunctionMaterializer has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/record_materializer.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff68408f029fe3d6192ec5b84396e9d7d358e60969250036e5a202577a75ebd7"}},{"ruleId":"D2","level":"warning","message":{"text":"clusteringCompactionTask.getScalarAnalyzeResult (cognitive 16): clusteringCompactionTask.getScalarAnalyzeResult has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 5 (nesting depth added 6). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"48fb085f0f999cba003a14c324d0d89eab25dbdf65361996fa2e55c8a256af08"}},{"ruleId":"D2","level":"warning","message":{"text":"sortCompactionTask.Compact (cognitive 16): sortCompactionTask.Compact has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/sort_compaction.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"6439840fb0043ac2bb8a72e89f9a0d39933cc8fade65d00f679d6c607f792697"}},{"ruleId":"D2","level":"warning","message":{"text":"TaskScheduler.processTask (cognitive 16): TaskScheduler.processTask has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 1, loops 1, match/switch 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/scheduler.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"772bac48c408ecae2cd0621c8987b275947b2e44d199b0e1bf280fb7ff94fb9b"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.wrapperProxyWithLimit (cognitive 16): httpserver.wrapperProxyWithLimit has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5839bdfb4d5f00a041b12a0e0867850e9727268be912f7cf4f1f10a79bf463c"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.printFieldDetail (cognitive 16): httpserver.printFieldDetail has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"e367fd5a2a2860192c80d78dae961dc933c3b34c2c66f0ab22549b50673d5209"}},{"ruleId":"D2","level":"warning","message":{"text":"httpserver.generateTemplateArrayData (cognitive 16): httpserver.generateTemplateArrayData has cognitive complexity 16 (threshold 15). Drivers by points: loops 12, if/else 3, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3382}}}],"partialFingerprints":{"codehealthFindingId/v1":"556f6dd609fc9488f535505e4fed8e6b17b1e97d78f741d4b5ac56e62c4d368d"}},{"ruleId":"D2","level":"warning","message":{"text":"BulkPackWriterV2.Write (cognitive 16): BulkPackWriterV2.Write has cognitive complexity 16 (threshold 15). Drivers by points: loops 10, if/else 5, boolean chains 1 (nesting depth added 6). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v2.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd444831e3dbb91a49776399550e62197ff1fc15eadb6ab9e8b0ce3ef8564ec5"}},{"ruleId":"D2","level":"warning","message":{"text":"l0WriteBuffer.BufferData (cognitive 16): l0WriteBuffer.BufferData has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/l0_write_buffer.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0e1aed4ed5a4121a64a944b4d98721742a23468b6f4a8055560b649b654b504"}},{"ruleId":"D2","level":"warning","message":{"text":"txn.flushRun (cognitive 16): txn.flushRun has cognitive complexity 16 (threshold 15). Drivers by points: loops 10, if/else 4, match/switch 2 (nesting depth added 9). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/txn/commit.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ced4522ca3a38c57b6aa81631b5bba063ac2b8d39bdfca99174cfc85d90ea4f"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.prepareBoostRandomParams (cognitive 16): planparserv2.prepareBoostRandomParams has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, match/switch 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/plan_parser_v2.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4efd234f5c3ecd2ce8c5298007d44ca32ea1ad573eb658cd8feda36b5dafdf1"}},{"ruleId":"D2","level":"warning","message":{"text":"planparserv2.castValue (cognitive 16): planparserv2.castValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"637ec06069225442466b22118e98f3e0aaa5b59b709b91a2328712e919e8bc92"}},{"ruleId":"D2","level":"warning","message":{"text":"visitor.visitTermExpr (cognitive 16): visitor.visitTermExpr has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/entry.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"c543b4dce3d51f585f9a51f659bb5cea247fdfc4b073a1ed9ea29ac735e634fe"}},{"ruleId":"D2","level":"warning","message":{"text":"accesslog.newMinioClient (cognitive 16): accesslog.newMinioClient has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 4). Of this number, 8 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/minio_handler.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e16a78277eccd0b9da52369568f0e787f1021b512d2d0a4a0ffc46d7b981ed5"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.AuthenticationInterceptor (cognitive 16): proxy.AuthenticationInterceptor has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/authentication_interceptor.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"24dd512c7016d30a42aa7e84642697fb1af5727664cd61062a8752ee5dad4f0a"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.repackDeleteMsgByHash (cognitive 16): proxy.repackDeleteMsgByHash has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 6 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_delete.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ffe552aae4367038b0dc66dcd219bb7160bb9112efdb3ebb96898ead8d5498e"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.checkPrimaryFieldData (cognitive 16): proxy.checkPrimaryFieldData has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":2240}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6c8fb535d3ca34e9f4aa9f98c17dc5294e00cd304bfae74c48cf5d26f951486"}},{"ruleId":"D2","level":"warning","message":{"text":"proxy.extractFieldsFromResults (cognitive 16): proxy.extractFieldsFromResults has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":3432}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad22790813a4c7c83aa3c55b7945f367a6f0a0ae81fc57c26b0ff789c5878995"}},{"ruleId":"D2","level":"warning","message":{"text":"Proxy.TransferSegment (cognitive 16): Proxy.TransferSegment has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/management.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5485bed29419a69ca32d70a1aa66991705c0d192acd307ac1205863d2a609cb"}},{"ruleId":"D2","level":"warning","message":{"text":"orderByOperator.run (cognitive 16): orderByOperator.run has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1891}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d0c7dabff8d79c4d41f54a74008542d913abd7677379608f0bb5ee32b9614a3"}},{"ruleId":"D2","level":"warning","message":{"text":"SimpleLimiter.updateRateLimiter (cognitive 16): SimpleLimiter.updateRateLimiter has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 6 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/simple_rate_limiter.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"72e310c58b2b9db493d2d51b4fb969be081c07edebaad3b6aa6302a7e12ada25"}},{"ruleId":"D2","level":"warning","message":{"text":"deleteRunner.receiveQueryResult (cognitive 16): deleteRunner.receiveQueryResult has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_delete.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0a87e182729d30a24d7d7f27de1f4866c07b31f97bdb577380adebb9b769936"}},{"ruleId":"D2","level":"warning","message":{"text":"dmTaskQueue.popPChanStats (cognitive 16): dmTaskQueue.popPChanStats has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 5 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_scheduler.go"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ac071c09e6b0ccd1b429df745a2d1c531e2cb086e70040bbe01fcab8220d8ba"}},{"ruleId":"D2","level":"warning","message":{"text":"searchTask.checkNq (cognitive 16): searchTask.checkNq has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"2261e19a5245bcbdec193436f301bb290b08fc9948038bdf9f48f94909381956"}},{"ruleId":"D2","level":"warning","message":{"text":"validateUtil.fillWithValue (cognitive 16): validateUtil.fillWithValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd22d7f519163f0efbf68b47a3077475f999454664a60250a3e31a0c0d6e2754"}},{"ruleId":"D2","level":"warning","message":{"text":"meta.FromPbCollectionTarget (cognitive 16): meta.FromPbCollectionTarget has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 6 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/target.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fcb4d05599522664cd66a48c9c0bb4aab62eb37e4e60cf0ecf9529513f98592"}},{"ruleId":"D2","level":"warning","message":{"text":"ResourceManager.selectNodeForRedundantRecover (cognitive 16): ResourceManager.selectNodeForRedundantRecover has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1 (nesting depth added 6). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/resource_manager.go"},"region":{"startLine":835}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cccc068e37e63ee24517710cb954589c3946321493bc11f4d8dc53a43f3f7db"}},{"ruleId":"D2","level":"warning","message":{"text":"ResourceManager.validateResourceGroupIsDeletable (cognitive 16): ResourceManager.validateResourceGroupIsDeletable has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 6 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/resource_manager.go"},"region":{"startLine":1141}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed3799c8d98a8392a2005c01228b1450b4dc510d800d65f8a704df058d650585"}},{"ruleId":"D2","level":"warning","message":{"text":"utils.CheckSegmentDataReady (cognitive 16): utils.CheckSegmentDataReady has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/utils/util.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"74722b6b8d2a926f2ff652d0e320f7db9d6ba0ff4c60d5daba1fc96c2d510c5a"}},{"ruleId":"D2","level":"warning","message":{"text":"shardDelegator.updateDelegatorSchemaLocked (cognitive 16): shardDelegator.updateDelegatorSchemaLocked has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"79b6042ffad67c2c30e7303b2b9a4e43eb00526ae009dd1d44ba3de442a6aa3f"}},{"ruleId":"D2","level":"warning","message":{"text":"segments.NewCollection (cognitive 16): segments.NewCollection has cognitive complexity 16 (threshold 15). Drivers by points: loops 8, if/else 7, boolean chains 1 (nesting depth added 6). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/collection.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"e239011e95643a605a31c8634d68f34eed5b4bd843ed2390500380814185b63d"}},{"ruleId":"D2","level":"warning","message":{"text":"rootcoord.executeOperatePrivilegeTaskSteps (cognitive 16): rootcoord.executeOperatePrivilegeTaskSteps has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, match/switch 1 (nesting depth added 3). Most of this is not in the body itself: 2 of the 16 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 57, 39). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/rbac_task.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"343a74355eb7cf0b8a452dfb5e73dd450b213b1f0b8f3709d83f0716d528cd4f"}},{"ruleId":"D2","level":"warning","message":{"text":"createCollectionTask.validateSchema (cognitive 16): createCollectionTask.validateSchema has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c989f84ef180573940e8dbf8633d6cea79db5ad8ae6f1c4930e032924145b76"}},{"ruleId":"D2","level":"warning","message":{"text":"dmlChannels.broadcastMark (cognitive 16): dmlChannels.broadcastMark has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, loops 8 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/dml_channels.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"410e104879730d8fd3d1a139d6072e3c6e6b54c5235ca365afdad2cd29af5828"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.getDenyReadingDBs (cognitive 16): QuotaCenter.getDenyReadingDBs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":818}}}],"partialFingerprints":{"codehealthFindingId/v1":"773584b38721725295d86d4df53700a279d3376ad0ea0cb3fae5ae36c9d7307d"}},{"ruleId":"D2","level":"warning","message":{"text":"QuotaCenter.getDenyWritingDBs (cognitive 16): QuotaCenter.getDenyWritingDBs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":852}}}],"partialFingerprints":{"codehealthFindingId/v1":"736ee18cd245edac5cb0e017d80b3a5fc222f7ab5660eacaa03636c93fe14faf"}},{"ruleId":"D2","level":"warning","message":{"text":"NativePayloadWriter.AddSparseFloatVectorToPayload (cognitive 16): NativePayloadWriter.AddSparseFloatVectorToPayload has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":925}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcd21fdbf8170c3d82ea2bf47e62193358726419ab6755a882d9b2c98e1db9c6"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelManager.getNewIncomingTask (cognitive 16): ChannelManager.getNewIncomingTask has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/channel/manager.go"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ea6cb812e58e5d34e7fd3df09fe97d519b074f03a58fd2e00855acce2467990"}},{"ruleId":"D2","level":"warning","message":{"text":"openerAdaptorImpl.handleAlterWALAdvanceCheckpointsStage (cognitive 16): openerAdaptorImpl.handleAlterWALAdvanceCheckpointsStage has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/adaptor/opener.go"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"f358c4fe1a37eb64e73c13bf7a3f1cd68a677ef4da922a9876d01078f59377bc"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.NewCohereEmbeddingProvider (cognitive 16): embedding.NewCohereEmbeddingProvider has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, match/switch 2, boolean chains 1, loops 1 (nesting depth added 5). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/cohere_embedding_provider.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c43af43baa733c7b0aa84e5f29fcb9d5297bfeb4ba005a85b636ef50b2e3449"}},{"ruleId":"D2","level":"warning","message":{"text":"embedding.NewTEIEmbeddingProvider (cognitive 16): embedding.NewTEIEmbeddingProvider has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, match/switch 2, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/embedding/tei_embedding_provider.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cfa39c858dc304b2b44afbfa45a3fe507fc7f56b6e17cabf3ac876061e9229c"}},{"ruleId":"D2","level":"warning","message":{"text":"clientManager.GetConn (cognitive 16): clientManager.GetConn has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/models/zilliz/zilliz_client.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"671cc40fc12e971d128532e3e6a15e645dc1d35f89732aa5f499bc3dddf8fb2f"}},{"ruleId":"D2","level":"warning","message":{"text":"rerank.newSiliconflowProvider (cognitive 16): rerank.newSiliconflowProvider has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/rerank/siliconflow_rerank_provider.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0bcef27da3001ce5589b0388d4f93634a97dd75536411367aee331c6f1c1307"}},{"ruleId":"D2","level":"warning","message":{"text":"rowParser.reconstructArrayForStructArray (cognitive 16): rowParser.reconstructArrayForStructArray has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 5 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d53317133c4cc3a7a4227ef1061469cc8b55018dbf6146da090776a9e0947d7"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadSparseFloatVectorData (cognitive 16): parquet.ReadSparseFloatVectorData has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1163}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1c71497f9e82fd41bc266926c0036b8e3f7fe3ef681ce542f74194c69f14a5c"}},{"ruleId":"D2","level":"warning","message":{"text":"parquet.ReadNullableFP16BF16FloatVectorData (cognitive 16): parquet.ReadNullableFP16BF16FloatVectorData has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1 (nesting depth added 6). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1605}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b0758c9675a4cbba4979124efd29ce0a81746d46032bb893442356612c4e3f"}},{"ruleId":"D2","level":"warning","message":{"text":"queryutil.getFieldValue (cognitive 16): queryutil.getFieldValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1500}}}],"partialFingerprints":{"codehealthFindingId/v1":"b74ffcfb8256c7eb5e56b0b167f93ac620da1ebb2ddb1ba250e955b4fbbb8154"}},{"ruleId":"D2","level":"warning","message":{"text":"fairPollingTaskQueue.pop (cognitive 16): fairPollingTaskQueue.pop has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/searchutil/scheduler/queues.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"f75372ba285f5e6361a6d98591f606c5c2867c8ca4d4fab5f07433dfc4fb6842"}},{"ruleId":"D2","level":"warning","message":{"text":"client.Subscribe (cognitive 16): client.Subscribe has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/client/client_impl.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a574670c2cb4715fe971501a71ff0bae2c1e7182a28d4410fce50f03cdb90f9"}},{"ruleId":"D2","level":"warning","message":{"text":"MsgPackAdaptorHandler.Handle (cognitive 16): MsgPackAdaptorHandler.Handle has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, boolean chains 2, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/message/adaptor/handler.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"03239a7d7d14823ba2da0173c7b9a45fdc14a450c008e4201bc30baf92be9cf8"}},{"ruleId":"D2","level":"warning","message":{"text":"dec.strings (cognitive 16): dec.strings has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/fastpb/unsafeopt.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"38ddd5cccf1e6c793900757ca6312ecdfc81f337f7c944c47b2160c39d3010d8"}},{"ruleId":"D2","level":"warning","message":{"text":"funcutil.GetIP (cognitive 16): funcutil.GetIP has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 3, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"e09aa5c7f7ad4b9f877f30254cf68c66c5077578f03475128161c799d16ad6a3"}},{"ruleId":"D2","level":"warning","message":{"text":"typeutil.SelectMinPKWithTimestamp (cognitive 16): typeutil.SelectMinPKWithTimestamp has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, boolean chains 5, match/switch 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":3690}}}],"partialFingerprints":{"codehealthFindingId/v1":"b552d40348022bcdadf39bd50f82f43be2d744e58cbc16ca3a4ed961e6e9dbd8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: paramtable/component_param.go: FileTooLong \u2014 6401 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/component_param.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"353b75148a9026995757bc3e5f6480fd1f330314a682f92d989ad2c717594598"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/impl.go: FileTooLong \u2014 5080 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"03d576a25b43a97beaffde85342959f81e1c0ca90272a9e261beb5c68e8e498a"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: mixCoordImpl: TooManyMethods \u2014 238 methods, declared across 3 files: coordinator/mix_coord.go (205), coordinator/restful_mgr_routes.go (30), coordinator/restful_replica.go (3). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f827851d5eace738c8eb8c9c1cdec74b683afcece576fc20275d0c3b43902fb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Proxy: TooManyMethods \u2014 190 methods, declared across 4 files: proxy/impl.go (149), proxy/management.go (15), proxy/proxy.go (15), proxy/snapshot_impl.go (11). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/proxy.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c29a9028fbac92d8cc51e85d73766ccb99dabc375e8ee5b17feb659e7b7a9c3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: httpserver/handler_v2.go: FileTooLong \u2014 3034 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b41aec8b4cdfbac504efd57082c0bfdd41ea30f79e48ea0d59cd76d4f419698"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 181 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/service.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3ea57268b84eb0f57eac2fb4e2ace822f7f488c9afff5596378bd4ac2743b70"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 180 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"0642ac34b9fe10d01392cc5dba4d644e8385357a3e2128d1d5464133b5e02f81"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Core: TooManyMethods \u2014 176 methods, declared across 27 files: rootcoord/root_coord.go (130), rootcoord/ddl_callbacks_alter_collection_properties.go (5), rootcoord/ddl_callbacks_alter_collection_schema.go (4), rootcoord/ddl_callbacks_rbac_privilege.go (4), \u002B23 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"a41e159b95e37bf2b3afa2d68c69b590522cecc8040b3d39c030cd20bc6ce8c9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: typeutil/schema.go: FileTooLong \u2014 2877 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9104acef44ca8cebefdfeb480bf3fc745d84c08d311ca22314120c6f7c9139e3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 171 methods, declared across 8 files: datacoord/services.go (74), datacoord/server.go (56), datacoord/index_service.go (16), datacoord/metrics_info.go (13), \u002B4 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/server.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"f279cbe515aeca3bbbcab06c68d86286b11fcc91b39b1d963af7563d827e014e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: httpserver/utils.go: FileTooLong \u2014 2831 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4278c4b603be65940d05f8ebcfeba6a15f953452f22093c7455857296b3606e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 163 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"05882b4240e67e1d046d6ba8edaac9cc1134e619fe90848156f51ed32726d38d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task.go: FileTooLong \u2014 2637 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f7a4d7cfd74651f3c4a024f1d16d57116982fcd3a17117cf5246b10dde10ee0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/search_pipeline.go: FileTooLong \u2014 2468 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c994b2ef500c8adfd48e99ea90163e6f9a3838195acdf31495d86297301f51b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/meta.go: FileTooLong \u2014 2352 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e339a300444c7e42154be8f5da77f99af744084a70587e2012e7cad4aa6d713e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rootcoord/root_coord.go: FileTooLong \u2014 2330 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/root_coord.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d719155b7d1069cc14eb10960f0d934c45784a145da193d69ebb6920add1852c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 137 methods, declared across 20 files: milvusclient/collection.go (18), milvusclient/rbac.go (14), milvusclient/client.go (12), milvusclient/snapshot.go (11), \u002B16 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/client.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"3da482e8cdec4502a6c1e40ac2d7132ab21cac8d53bea9c4309c15bc6cc3cbc0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/util.go: FileTooLong \u2014 2169 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"90add37ee2afee8ada81aade77bd0b6b53c7d7cb649c3a6b3da70af2d29c5811"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: planparserv2/parser_visitor.go: FileTooLong \u2014 2025 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3780788c59c72d84cc06aa063645bbab69b6dc3b4fa9a5424d53aa0a60b51a8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/services.go: FileTooLong \u2014 1994 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/services.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d43f12bc61f76118e508c4c1b5b04dda664f29b16b772150877988b00ff0296e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 114 methods, declared across 14 files: querycoordv2/server.go (35), querycoordv2/services.go (32), querycoordv2/ops_services.go (18), querycoordv2/handlers.go (13), \u002B10 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/server.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1d221113a2e082a24a25b600b98b9c1e0574cc018b2a04f90e27898cb316fb2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: HandlersV2: TooManyMethods \u2014 113 methods, declared across 3 files: httpserver/handler_v2.go (104), httpserver/resource_group_handler_v2.go (6), httpserver/file_resource_handler_v2.go (3). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"820b72a4a3877163ee8c8771c845e51761ffb85f06f2526bee280b51a9b957af"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MetaTable: TooManyMethods \u2014 103 methods, declared across 2 files: rootcoord/meta_table.go (97), rootcoord/file_resource_ref.go (6). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"a225911418e640ebab8b35e9408600e0b81ffb655f466294c20bf96b29e202b6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: parquet/field_reader.go: FileTooLong \u2014 1689 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/parquet/field_reader.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"17115819ff6981ead45d2cae9bdfdaa1c6dc7ac5a9e958cd1a72c3ce3c46e211"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rootcoord/meta_table.go: FileTooLong \u2014 1570 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/meta_table.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf5531cabf28ea24b560df4fb174e6f43b793ef24b4d40abd2f63941523afea3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rootcoord/kv_catalog.go: FileTooLong \u2014 1522 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"40199e52def25badc8fb22dabb5de9fc350d6eed24a84c884f91cd57f6090b5b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/insert_data.go: FileTooLong \u2014 1484 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/insert_data.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4b114325e49e21939a7f858f73dd1d95171b5c18cdfaa03f1aa8b54a3dc5860"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: meta: TooManyMethods \u2014 86 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"433f6dfe052b79f96da5007d4f92d3af4bb61af39d8e22f2b41bb45af11cbcbc"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: shardDelegator: TooManyMethods \u2014 85 methods, declared across 4 files: delegator/delegator.go (41), delegator/delegator_data.go (31), delegator/delta_forward.go (11), delegator/delegator_twostage.go (2). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbd6fb59a9b0b0ec66a0cc8761b0bf26d615bfb62cbc515b2d246ee018face6d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/garbage_collector.go: FileTooLong \u2014 1375 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"237159c33fe2e70f09c07c885e64311ff065a492a235078e84dded6ccaf207ac"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: querynodev2/services.go: FileTooLong \u2014 1356 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/services.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f723b79c5649865276e82c2c5874ae1e9b58047d667a89fd1009c7d655baef80"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: paramtable/quota_param.go: FileTooLong \u2014 1353 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/quota_param.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c70ac6e293a00e27f4b5a96982e831cc22f4663241b1c29a64332c3abb8096e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrpcRootCoordClient: TooManyMethods \u2014 79 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/mock/grpc_rootcoord_client.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd7f31f2d68b79e6e4883c6b9384dcbdb89426935f14e666f8d1c9e09458e96c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: testutil/test_util.go: FileTooLong \u2014 1309 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/testutil/test_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8304f96bc7aa46f52bdbc077ee3bc46889c71780665efcc917ed6059df728e0b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: paramtable/service_param.go: FileTooLong \u2014 1278 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/service_param.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbab4a329610333f7aec35aba6f51d01c663bbc5b96efc781363af737c82c33c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/utils.go: FileTooLong \u2014 1271 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4ae62995a54d6aad77027c67902d1af26cdb673547fd3d1e389d7c1aaeaa589"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: client/client.go: FileTooLong \u2014 1267 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeb105bcb1c03c688df2325db389d514782d319fed5b4428d676092c7ecc2532"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Catalog: TooManyMethods \u2014 73 methods, declared across 2 files: rootcoord/kv_catalog.go (72), rootcoord/update.go (1). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcbffa0d658d5359cb835f0c4212c9259a2b4417dd6965558b050ce5165aaeb2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: writebuffer/write_buffer.go: FileTooLong \u2014 1205 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b3b49c7ce61f7165416e4afd52406935dd1b6aa2543a05a94cfd0461299dd64"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rootcoord/quota_center.go: FileTooLong \u2014 1185 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c00d19fc20aa19f33c4fd7c23685f020b34beeee7be2480d88a0a8a31e643a3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Catalog: TooManyMethods \u2014 71 methods, declared across 2 files: datacoord/kv_catalog.go (69), datacoord/update.go (2). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. Most of these members implement metastore.DataCoordCatalog (60 of 71 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e94d69f62cf5430823ef7b384fbfaf3cbcc21b42a894a96d4e849481593dbc1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_upsert.go: FileTooLong \u2014 1143 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_upsert.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"32cc0f1f208c83be08c7fe24b422b7ed449754bcaf8f86b0a946edef1d722c43"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/serde.go: FileTooLong \u2014 1118 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa3a92744dc10d6d68ee6389ae22e397ccaf0dc117a43cd8c845825f0ba6f351"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ParserVisitor: TooManyMethods \u2014 67 methods, declared across 2 files: planparserv2/parser_visitor.go (66), planparserv2/bloom_match.go (1). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"909d90a1e72185bba8fff8ffee4e442d5b783e0d59371c42dce225edeed769ac"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: textEncoder: TooManyMethods \u2014 67 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mlog/zap_text_encoder.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"dce984d1dc2c1586cf26d148911ed68e2c76f1e7aa493dc75991e8867823ee24"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: delegator/delegator.go: FileTooLong \u2014 1106 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e02f5cdc1ab357f4012e3c28cd5257372a0de161b2dd4fe122d4f5cc43ff7da8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: queryutil/helpers.go: FileTooLong \u2014 1100 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/queryutil/helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"45172e011062a58167c4ab6c623d9d319ba3a96c3618d3e84edbcb8522071f91"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_search.go: FileTooLong \u2014 1077 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e6ded2d6a6957d43a3b3edb2b483fcada47f7f14dd44a4273746f0fc0cd365f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: milvusclient/telemetry.go: FileTooLong \u2014 1036 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8ab5005582bcc34ca58eab233f2e3d08286e4a72c6c21b3ab8f23fb57b6eec8"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: DataNode: TooManyMethods \u2014 61 methods, declared across 4 files: datanode/services.go (29), datanode/data_node.go (17), datanode/index_services.go (13), datanode/metrics_info.go (2). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/data_node.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"305c0c17b33630bbf8d84721d639956106d5b1c1458ac0d7fae0b88cbc14aa7c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: delegator/delegator_data.go: FileTooLong \u2014 989 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/delegator_data.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a01c4a4dcc4013012955ca8e3dbd6c281f0bf2e41710ab29660203ff1152e5b6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: metrics/querynode_metrics.go: FileTooLong \u2014 937 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/metrics/querynode_metrics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d2bfa22f4a4188498a90825260ea6e89c05fd0da1b02f1e0e635715c2790d9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: task/scheduler.go: FileTooLong \u2014 932 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/scheduler.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd92ffb65b5b8838a9f8f6affe8ae0b22d2e216dc5c0580795ff3b809498fde2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: coordinator/restful_mgr_routes.go: FileTooLong \u2014 920 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/restful_mgr_routes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d45084787e598ad78b66d430d270e113490faf1f5b53e5d7e8932bb299cf7b7"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: writeBufferBase: TooManyMethods \u2014 55 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b02d0a191189de630f62e9666da2ef0e696fac1736f552897c5da93a25e3c78"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/validate_util.go: FileTooLong \u2014 916 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/validate_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cb14a48661ede62f35d2ebc23a6df1f513d8b6f563a2dad7f3f05b409b288ca"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/index_meta.go: FileTooLong \u2014 909 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99f32897935230d9719832905936b1e9fd3a901a5ce1a00bc536c30c4b81b226"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: merr/utils.go: FileTooLong \u2014 906 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/merr/utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fbd1eec64444d58d2751b1573e8b38acc590a8c26dafef59ad69368b181d63d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/payload_reader.go: FileTooLong \u2014 902 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_reader.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82575d04626aba177757bbe2027aac7c9355845dcc068c74c25e09c5196a54d6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/payload_writer.go: FileTooLong \u2014 883 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dae1a303e7c00586efaaee58d76e187dcf5b9290339799364a31058cd461212c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/meta_cache.go: FileTooLong \u2014 869 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a886b710d6a30593585e43bd8434d6f4b29131e06cafd9ae018d5fbcd159a34"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_query.go: FileTooLong \u2014 866 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"41e9dc57362f54e4d5917381d306ccd01a51a90db03eead28445cb4d5a10bed2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: testutils/gen_data.go: FileTooLong \u2014 859 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/testutils/gen_data.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"91b6e6136bece8be4d2c7cfafac82ee3c822d67d6d9f943d0e9eb270624bb8af"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ResourceManager: TooManyMethods \u2014 51 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/resource_manager.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8558ac0b20a3aecd3be0068e5754b1edcaa3c29c67b7b021423293ea4b491de"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: function/manager.go: FileTooLong \u2014 842 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2bc953ccce736c9fa01e11a014d656c080b4006b66bd5106f92e524c63593b8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: coordinator/mix_coord.go: FileTooLong \u2014 831 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9b27fffbd2cc36319a734c2ed823bc6b73bf13d2b540c73a422dfed3d99b20b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: indexMeta: TooManyMethods \u2014 49 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dd37528b3e2570186498a70c5d7cc13f820af00bfb524121b60be02645edbf5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/server.go: FileTooLong \u2014 803 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"36cecea4bd761a805bc693bc72473c0f5542b26347642862a0a5c94b5818bd05"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: compactor/bump_schema_version_compactor.go: FileTooLong \u2014 803 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"89cd72f300388a04d15edcc3d3f18a294c2745555161e993f7badd0a97ef18ab"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/service.go: FileTooLong \u2014 801 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f1a26670a8ef6bad9338ca2e91edd03e582aedfb9346a72789373c40947338f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Handlers: TooManyMethods \u2014 48 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6400c41296c01428a3680d43cf3cb99ca216305e802ec7127178fe90105c5af"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: syncmgr/growing_source.go: FileTooLong \u2014 796 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f35447fe5ca0703628ab483292fc10a2dac2f3d24d915bf49d97f2f01e1ba2e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: httpserver/request_v2.go: FileTooLong \u2014 791 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/request_v2.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e28ee1931335306d8bd15cdea4429bdd07c786b6ba8d5131d164b3ece188656"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_index.go: FileTooLong \u2014 789 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab3377500c6812effb330bd5ec7e1fed949652c58828a2419122b935d5a3a255"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/kv_catalog.go: FileTooLong \u2014 788 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b16f3d9c18e8f24fd3ef3d13a5d87ef959a125cc948d4b07b7f98b3d8daf6f2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrowingSourceSyncTask: TooManyMethods \u2014 47 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/growing_source.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b3864f701443dd20a23a24902a124ef9947eb8bb5e92a5a9529be33fffb338b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: querycoordv2/services.go: FileTooLong \u2014 778 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/services.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a39d32ae0570f73c796610893449a899b5b22dd208b9c81969815930c62fe32e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/index_service.go: FileTooLong \u2014 767 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ef01c1a795952223fc130ad398a6d64ed743a7f0a024f8cfbac136b3f084f21"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/snapshot_meta.go: FileTooLong \u2014 759 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_meta.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe7c4cb028a0eb2af62a7751910c0589d4cb01a5ee2ee0884920b6945075b7d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: httpserver/handler_v1.go: FileTooLong \u2014 759 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f37a2610789b0a8290516e16f888234ab8b4063e835ee5cde8c560ba1eb4e76"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: server/rocksmq_impl.go: FileTooLong \u2014 759 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/mqimpl/rocksmq/server/rocksmq_impl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f3347f7c48430ecdf03be21fb76db0d3e0b809b9c0261f85de83257e43137f1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: compactor/clustering_compactor.go: FileTooLong \u2014 758 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b674f23ef6c715bce949c00209dfe834dc809006d9a3dcfb29310f14df33a4c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: recoveryStorageImpl: TooManyMethods \u2014 45 methods, declared across 4 files: recovery/recovery_storage_impl.go (32), recovery/recovery_background_task.go (8), recovery/recovery_persisted.go (3), recovery/recovery_stream.go (2). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/recovery/recovery_storage_impl.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"2501b436d10d8405a1bc3b1d3356895c100df02c4ad96ccb63e925fef7f14c39"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrpcQueryCoordClient: TooManyMethods \u2014 44 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/mock/grpc_querycoord_client.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"89f88ea67476917e7ed38308e33335c2c6777e03169c30f101aba08c1fa38547"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: sessionutil/session_util.go: FileTooLong \u2014 733 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f43465a16b1a503c586eb2fb8c49c3038db6c4ae300436c96f5d7aefcf15d619"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: external/task_update.go: FileTooLong \u2014 717 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7329ffc338f8f1a64292dcc839c9bfeeae7cb4583e6a88ada96eb989320bdb7e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datanode/services.go: FileTooLong \u2014 717 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"643de92b7cb3bb9a473cb7e6441d2a9f83e75ffd49def0ffbe1a739ca5d42a47"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/snapshot_manager.go: FileTooLong \u2014 709 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99f278ec7e3a4ed5161d699d728b5e202621ce4b64bc6d6ac235168eacc5196d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ClientTelemetryManager: TooManyMethods \u2014 42 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f6504a4d593c7819196090d17a916af83fefeb89389c094375886757df57fa8"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 42 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/querynode/service.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"12708ded82594b0c54c9f0c5cc33028e7ddba96a757381b07cb831fbb48dcfb2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: meta/resource_manager.go: FileTooLong \u2014 696 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/resource_manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f4051712ad1d9eaf88f03c7282414d14018e08642ac8148d109b31291aac0a2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/data_codec.go: FileTooLong \u2014 694 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/data_codec.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b35eadfa5f91077eb570057cf794997f1dedc2b0a50a880e0f7d4c75d4d0b52"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: clusteringCompactionTask: TooManyMethods \u2014 41 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"dea6c2d04d38d9bd099853fc6da00d093f5037a475ba651f844c0cc1f1bc9c5c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/search_util.go: FileTooLong \u2014 678 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2faffbfb07089b5743cdf3f4ce3218f031518a79d7df6b44fca51933a756d264"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tasks/heap_merge_reduce.go: FileTooLong \u2014 677 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/tasks/heap_merge_reduce.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"46cd63111f6835b8c21cd40b6903f4618c80e2ad3c6a9e9e661132e4b95f5f06"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MetaCache: TooManyMethods \u2014 40 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb5406fcd901b7b6accd84c857c83ce0fd10b44553dce80b5629023405029c0b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rewriter/range.go: FileTooLong \u2014 657 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb90a6c857643f79371256fe44c09cceb53498d28bf981516faa80e7c459a94b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: msgstream/mq_msgstream.go: FileTooLong \u2014 656 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/mq/msgstream/mq_msgstream.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"49b6d7818b6e2788c498b6ed21a2ded457a4b10e15fb5698712ac1dba0c55c8c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: meta/replica_manager.go: FileTooLong \u2014 655 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e88d8b39e4350e48fd16fb7ef0676c0a428329d6d2c7bd308cde765a7046779"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/field_value.go: FileTooLong \u2014 654 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_value.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bf08952aa1898ee74f1d055c609256f9e2bc77ed0879e0cea58fa82eb3dfe6a"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 39 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/service.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"00daf1978c495ceae68cf3b4070dfacad4ad096a8ef73e23ffa5112c69a3c465"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: index/task_stats.go: FileTooLong \u2014 646 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4947aed46428aaedd077e9c4814ff89c65b861d1f55cdf3b31aa60be5038fc2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/import_util.go: FileTooLong \u2014 644 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"90fc58d29708885609f43e1d2b441e1bc68fbfe4e06b2a56744fda6a4624351c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: planparserv2/utils.go: FileTooLong \u2014 640 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0b82a96a53091a829a0d9206fa012349825716e2f89b8c5520b0d957818e5ba"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: garbageCollector: TooManyMethods \u2014 38 methods, declared across 2 files: datacoord/garbage_collector.go (36), datacoord/garbage_collector_lob.go (2). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5f6f6fbaacff1256b0b78e2f66085da466c3fb13d122bcda58fd3d78471fca0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: snapshotMeta: TooManyMethods \u2014 37 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_meta.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"efb92349239fcde096453f262cd88efcb685f6230fb1ac341807a1e747561409"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: RefreshExternalCollectionTask: TooManyMethods \u2014 37 methods, declared across 3 files: external/task_update.go (21), external/milvus_table_deltalog.go (12), external/milvus_table_refresh.go (4). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/external/task_update.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"86b397418f46841c38259d4a6deef1e5a0077dd46202564fcb98d0fd838b7850"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: metrics/streaming_service_metrics.go: FileTooLong \u2014 609 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/metrics/streaming_service_metrics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5bc43de36d1e09a0024efa1fe094b25c45a812cd7e1db8ab2b91c47b37106b3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_snapshot.go: FileTooLong \u2014 607 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_snapshot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"403d87c244605df5455d60fac8f8eb00de6a8191c9b10651ccd08ea2e2b585b5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: metrics/proxy_metrics.go: FileTooLong \u2014 604 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/metrics/proxy_metrics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"64fcce0781b01060c19582afefea788298dfb80125e147d764fb058a1c1e1550"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 36 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/querynode/client/client.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"df0d095dd9437c37f5dbdfe147ccd816f7a448620d322cae94ef97f7b0b20a70"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: etcdKV: TooManyMethods \u2014 36 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a656da8dd35ae57601e8579faff52227adbeff9960ec482d7497d1c40cc3dd3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: QuotaCenter: TooManyMethods \u2014 36 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/quota_center.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"d256aaf35a2f1117a14d0d110870f3f0a17ffd8395f95452875a43d4a06891df"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/compaction_trigger_v2.go: FileTooLong \u2014 599 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger_v2.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"544d968ac6282dc2fe8aadd43243c51056e4741864c759ae4b0ff7e06499e8dc"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/search_reduce_util.go: FileTooLong \u2014 598 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a7cef88f14cabc148226d3d4ccab016ba8fea6fdf4a3eb19e0733f6746b52b9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: funcutil/func.go: FileTooLong \u2014 596 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/funcutil/func.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e550e0d3a3325de5624075f2f2d658c9c60bc3e90ad317a7954b4a892258022c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/compaction_trigger.go: FileTooLong \u2014 595 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"049aab19f6a578b6bb7cefec4e0de855f4e95da193dc1e2fbb5754b3bcde760a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: querycoordv2/server.go: FileTooLong \u2014 586 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ff38ecd8ca9686008ca606b16f4e53dee9f66075ad1989f937108fd0216359d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/handler.go: FileTooLong \u2014 584 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/handler.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06241d70c2ab1d0a24324195d7bc5d26aa285f17aa237887380b4a6df7f2bf1b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rootcoord/create_collection_task.go: FileTooLong \u2014 584 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/create_collection_task.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"be7ef944faa3633e92dd4540f350154e5e194252dddfc7a4f52d8fa1646042e4"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: CollectionManager: TooManyMethods \u2014 35 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/collection_manager.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0c118df525cc039162b483d369f83461d78453e2bf397ca3d71bbc4d2da395d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: messageImpl: TooManyMethods \u2014 35 methods, declared across 2 files: message/message_impl.go (34), message/marshal_log_object.go (1). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/streaming/util/message/message_impl.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d41fea45f5e4e511ca3ffca5463d610d8230f958bb5327be292d4993755c9ad"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telemetry/manager.go: FileTooLong \u2014 582 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/telemetry/manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f44b2f29ea83d520e507859145e7158316fb275239c47c8fdc25114d158658eb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: chain/converter.go: FileTooLong \u2014 581 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/converter.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2281b53ba9ef73a4c12db6f53abe1e5050d501c23533120dbf1a242d25d69c49"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: milvusclient/read_options.go: FileTooLong \u2014 578 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read_options.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0be848db08fdcc632cc40a82f09dce294bd3fcb9fde82a0dc1843984ec9967f7"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 34 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/client/client.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0e50fdfb0317b4c97f44027fa32fc02b707b68845680621b350744e015d053d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrpcQueryNodeClient: TooManyMethods \u2014 34 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/mock/grpc_querynode_client.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"02b0693022e49a29a6e0b3bf48aef555b9f86c5aef0daf080fc63e6de6fd1f9c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: qnServerWrapper: TooManyMethods \u2014 34 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/wrappers/qn_wrapper.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"94013c37fdfb7d5cc2282dfc4776c6dde47ce605ae2eaf402cdf4b294d731301"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/compaction_task_clustering.go: FileTooLong \u2014 565 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f767af76e742450f8d8c65a4b775f68d4124d83a0205a562afb154c0f357793"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: json/row_parser.go: FileTooLong \u2014 563 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/json/row_parser.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"53130652012c73670ec06a26e5c4eb2f73c438f48529e969ea8052f93c9111e5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rewriter/term_in.go: FileTooLong \u2014 562 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/term_in.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5e31b1ea208e9a02c9aa8f795dac2d39eabfff6395af8e3b32f78de41a1809c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: column/columns.go: FileTooLong \u2014 561 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b0052d04d3fdc0cef6a589b8c63ca9779dcae14a1af0722e8f067246654dd62"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: chain/operator_merge.go: FileTooLong \u2014 555 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/function/chain/operator_merge.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"49b396faf70b198488012c2151789bc507399951e9a3662e2155c5d1e9022621"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/serde_events.go: FileTooLong \u2014 554 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/serde_events.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"470856d65979fbbdfa585c6a7c5c59c5c403b240b4f8dd9100e361dfb0eb59b0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mixcoord/service.go: FileTooLong \u2014 551 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6a8c071fd071522806718667bdf38bebc645384828553f930af2307395df8c3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: clusteringCompactionTask: TooManyMethods \u2014 33 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"81faf3bacdde147604273c27ecb4b673abf99e06d8f3fe6f7a6cde96add7b896"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: delegatorGrowingSourceProvider: TooManyMethods \u2014 33 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/delegator/growing_flush_source.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cbde0c1ed3b36bfd6b6a7a6f55989a37c33b66ffc8709c83bc273d0ac07dfeb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: DDLCallback: TooManyMethods \u2014 33 methods, declared across 16 files: rootcoord/ddl_callbacks.go (7), rootcoord/ddl_callbacks_rbac_privilege.go (4), rootcoord/ddl_callbacks_rbac_role.go (4), rootcoord/ddl_callbacks_alter_collection_properties.go (3), \u002B12 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rootcoord/ddl_callbacks.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"309eb87b2e0be20775534a462b67bdcf624f14a87d2722b625a0a35b67f6bd80"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: shardManagerImpl: TooManyMethods \u2014 33 methods, declared across 4 files: shards/shard_manager_segment.go (13), shards/shard_manager_collection.go (11), shards/shard_manager_partition.go (6), shards/shard_manager.go (3). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingnode/server/wal/interceptors/shard/shards/shard_manager.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b770b9df81c75baaae73eaceb41f826ec1cf3dc70fccfce6dcdb3c504fc7341"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: etcd/etcd_kv.go: FileTooLong \u2014 541 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06788f7fc3120efc35aeef3f0b6b7d3b0ee8a6a9c5a78b57a11cd0ffffce5acd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_scheduler.go: FileTooLong \u2014 539 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_scheduler.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4339fc92aea91892fe5e2ea069805635c36f92103bbf6a685f8202605460b917"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: storage/binlog_record_writer.go: FileTooLong \u2014 535 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/binlog_record_writer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"19edfbe04f8f33d68797eabe50856da1755582a8b23c9a27a623779a2284754c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: EmbedEtcdKV: TooManyMethods \u2014 32 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b4735ef8f5322d0884201c814a75b9fbd595483c5217218496e3dcf992f6237"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: NativePayloadWriter: TooManyMethods \u2014 32 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/payload_writer.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6074bfddece4e912adc0c7cccb29a024dd9584d71c09f1fefb98fb5c3d7bd30"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: balancerImpl: TooManyMethods \u2014 32 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/streamingcoord/server/balancer/balancer_impl.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"58a9053322149d3786b19c97a807c1addbed7f81eac7691692137af8c9b119cd"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Session: TooManyMethods \u2014 32 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/sessionutil/session_util.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e9e38a3f2d6969902bca2aeb65da510d700c150f1dc072ff138496570ea4380"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: csv/row_parser.go: FileTooLong \u2014 532 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/importutilv2/csv/row_parser.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e64af9b8d1f91f3e4bec6ace1a446c6aa9754ea7da80fdae9603217dc826c51"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: common/common.go: FileTooLong \u2014 525 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/common/common.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"95609ab5e7d41c28c2ae25e884b2e486948fbbbf134707a886c5ab3eb4ab6ad5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: session/cluster.go: FileTooLong \u2014 523 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/session/cluster.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f183529a5f43572550ebb342fa5207c9cf62ea48aad347dba1caaaad21f76f8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/compaction_inspector.go: FileTooLong \u2014 522 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecbd4ee51696ce3e914153d404ec9081346df64de90fdfbdc7a576aec2cda2d9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: importv2/util.go: FileTooLong \u2014 521 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"77c990c2fe11c5c494798a44876f73eccb36ac2e35d85f977d0d463c4ce3cdc3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: importv2/copy_segment_utils.go: FileTooLong \u2014 517 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/copy_segment_utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ad18df4a69266e236fb2d220d0a0070f22b3e06d779626979785abee75ab1b2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: task/executor.go: FileTooLong \u2014 517 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/task/executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7b5a44c6f29179c62d28b9f4f1520c192c2e85d06e86ee1497a394c450e6660"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrpcAccessInfo: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/grpc_info.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7bb0ef4ed12c876e5e0a86ce9c75f1f4a6ad3786b8cd79d7ac50ffa6e6c2ff9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: RestfulInfo: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/restful_info.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d03bc8e3bd5d9cb890018ddba2d9eaaf51639c2440d40d77878fe5cbde09e2d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: searchTask: TooManyMethods \u2014 31 methods, declared across 2 files: proxy/task_search.go (30), proxy/search_pipeline.go (1). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd47be37a106e5daeaebbd99c4e86e8e874669a56051ef431ed2dd8a601a0b69"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ReplicaManager: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querycoordv2/meta/replica_manager.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b03f883d20cb7810fac7ffe58d2e3d9cdc48ee83ba00a81abfd29df7ad206bd"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Collection: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/querynodev2/segments/collection.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"299ae3554b5eddbd39a064b3560ef6e2975a29bd9707eb6fb79697ac5d0adb2d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GrpcDataNodeClient: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/mock/grpc_datanode_client.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ebe8a1e765b8e6b628197d5bb86e62d191f80015d7a58346e4c3d36ca32f150"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Manager: TooManyMethods \u2014 31 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/config/manager.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5649751da0eade8f3ef3806f0986cb0c436c75a242ca17f0a807bdcdc1dcf8b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/task_refresh_external_collection.go: FileTooLong \u2014 514 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a2e14715dbb88de711ca3dbde0aeb1fceca5be5f983371114efe691ae6e7943"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: proxy/task_delete.go: FileTooLong \u2014 507 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_delete.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dcb57fdafa79e80149cf783dfe2742483f8d36812de81affa8e2733d7e25c94"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tikv/txn_tikv.go: FileTooLong \u2014 504 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66bfded59fbae0cd6862300130ef752b6fe1c3616bb624d6605d3f778bed2089"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: datacoord/external_collection_refresh_meta.go: FileTooLong \u2014 501 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_meta.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f09650434d021e250a4568a94b0fc60078f72d23b36ece9e0a1ad59f7fcde8ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): client/milvusclient/telemetry.go:1146-1165 | client/milvusclient/telemetry.go:1200-1219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/telemetry.go:1146\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":1146}}}],"partialFingerprints":{"codehealthFindingId/v1":"410f5127205c1e7d7f53061df53d37c7f9aafd85318c572b5de3d2195543e97d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/datacoord/compaction_task_bump_schema_version.go:117-136 | internal/datacoord/compaction_task_clustering.go:386-405 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_bump_schema_version.go:117\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"c487cf726aa4d06e4508e0b1f45428741f5b9b772e329105af7ee8b0c3bdf3ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/proxy/task_query.go:870-889 | internal/proxy/task_search.go:296-315 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_query.go:870\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":870}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7084062b66a89920c6a89cd6d2b6c696c7b580d34fa658d693dc583c2527da5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): client/milvusclient/index.go:71-88 | client/milvusclient/maintenance.go:223-240 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/index.go:71\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/index.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc329fbddc73224e33315fb2d9c6e236b752bc11f2a0f431f2e0eded317f7f66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/parser/planparserv2/rewriter/range.go:604-622 | internal/parser/planparserv2/rewriter/range.go:818-835 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:604\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"7569efa86c28aa98844cf4406421026ba30bab9c2500992bd0e2724707a9456c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/datanode/compactor/clustering_compactor.go:1103-1119 | internal/datanode/compactor/mix_compactor.go:690-706 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":1103}}}],"partialFingerprints":{"codehealthFindingId/v1":"15633ae32fb5d8fe030fe83451d48f83c7e32562660904fc77fddefc5973376f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:652-668 | internal/parser/planparserv2/parser_visitor.go:849-865 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:652\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f7d5dcaf8ebcbedde40645962e4d2a0b1366ebf2d69c4f43117981560d27e3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:1798-1814 | internal/parser/planparserv2/parser_visitor.go:1862-1878 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:1798\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1798}}}],"partialFingerprints":{"codehealthFindingId/v1":"88206a05117ad81a9522ad2838752c7f3800b8b3685c416339737382b15453b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/parser/planparserv2/rewriter/range.go:521-537 | internal/parser/planparserv2/rewriter/range.go:735-751 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:521\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd72a7e74dd63652a31a5525287cba387ef4aa7bf72089c30b69cd8bd0854c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/proxy/task_alias.go:95-111 | internal/proxy/task_alias.go:260-276 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_alias.go:95\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_alias.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"74eed57128a54ef4f3320a240acdfecd32a8a9e5a2ac04850aa9c3ca93c5d79a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): client/column/generic_base.go:100-115 | client/column/vector_array.go:188-203 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/generic_base.go:100\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/generic_base.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4212158d9540f1e2f2c8485f16ea8f55646f351b4b2b64c25ad01daeb21b63b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/datacoord/session/cluster.go:321-335 | internal/datacoord/session/cluster.go:368-382 | internal/datacoord/session/cluster.go:733-747 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/session/cluster.go:321\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/session/cluster.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"a949aa105e020eb5e90a8d886cfe8cb4033502b9a79feb8fd498ae06b69ae8a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/datanode/compactor/compactor_common.go:184-198 | internal/datanode/index/task_stats.go:584-599 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/compactor_common.go:184\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/compactor_common.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"0edc23f22a194be19c0a940ec0d5655633e4b7a69921eefce5e36e28ee6112af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/datanode/compactor/mix_compactor.go:646-661 | internal/datanode/compactor/sort_compaction.go:642-656 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/mix_compactor.go:646\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"66b8347a43a7d9be7751cf1318960d6bf8e6eb3e019dcdf0ab7facd722a5b362"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/proxy/accesslog/info/grpc_info.go:250-264 | internal/proxy/accesslog/info/restful_info.go:199-213 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/accesslog/info/grpc_info.go:250\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/grpc_info.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"566f3617d93e470c5eabc488a10e201211e688ece31a7325e3c8ebf49970234b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): cmd/tools/migration/backend/etcd210.go:115-128 | cmd/tools/migration/backend/etcd210.go:157-170 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/backend/etcd210.go:115\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd210.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e4a26f6192f8901416dff08aae8043add79c040e1e7c904d998dbb892eaa6e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/agg/aggregate.go:103-122 | internal/agg/operators.go:206-219 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/agg/aggregate.go:103\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba08e809c77765e1b674a6b7d2e8811bccba9c40c516556bb0894ad73689494e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/datanode/index/task_stats.go:517-530 | internal/datanode/index/task_stats.go:708-721 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/index/task_stats.go:517\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"8886c8f5d3a97f5d5c763802110062bd32fbd055fe5e5a320e604381551eba54"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:362-375 | internal/parser/planparserv2/parser_visitor.go:451-464 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:362\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"527afbbe0e7657efbb39357b5b564f1a66029cd0f18de35fd7eac497e956dd05"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:485-499 | internal/parser/planparserv2/parser_visitor.go:2024-2037 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:485\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee5d77cf1b9abeda076d72a70c900f55e19633d1d6a9145543613510a5930f42"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:839-852 | internal/parser/planparserv2/parser_visitor.go:895-908 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f28fd78ad9e10153161f918d9fdb0d329bf6132954fd54d7f5ce62a99d5ce19"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:1537-1550 | internal/parser/planparserv2/parser_visitor.go:1618-1631 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:1537\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1537}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c0ec37d83b89be244a5c1b7e5bbf0a53c5e5ba02e8226d5e1c4535d7562882e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/parser/planparserv2/rewriter/range.go:158-172 | internal/parser/planparserv2/rewriter/range.go:304-317 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:158\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"473d6dd09e14d5d1e925806c83d33659942d101ddac02bb4466be7be9a68d819"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/proxy/search_pipeline.go:2272-2285 | internal/proxy/search_pipeline.go:2354-2367 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_pipeline.go:2272\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2272}}}],"partialFingerprints":{"codehealthFindingId/v1":"94b1d4e8ef0286f3d3461bc9961e4401555a87329c7825af4ff29035e00c80c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/proxy/task.go:3201-3214 | internal/proxy/task.go:3461-3474 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task.go:3201\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3201}}}],"partialFingerprints":{"codehealthFindingId/v1":"79b10d9dbab00fb1d55c5371dfb0d71eab2b9c66fff32fba4d83e0246c70d433"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/proxy/task_search.go:656-669 | internal/proxy/task_search.go:953-966 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_search.go:656\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8d2950c2f22aa34ad1ddb8db79df9414780e4e8e2e4664f4a637e1c2cd64684"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 4): cmd/tools/migration/meta/meta210.go:118-130 | cmd/tools/migration/meta/meta210.go:174-186 | cmd/tools/migration/meta/meta210.go:240-252 | cmd/tools/migration/meta/meta210.go:272-284 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/meta/meta210.go:118\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/meta210.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b4952e2a75cd6524fcc6350f44f32d4d0bc6bf021e1b147a9659f642b6063fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): client/milvusclient/telemetry.go:225-240 | client/milvusclient/telemetry.go:254-266 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/telemetry.go:225\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"120a61ffa644a6faf31a83cc746a8a83f221c08a1459bf860e344882ac30eda7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): client/milvusclient/write_options.go:483-498 | client/milvusclient/write_options.go:586-598 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/write_options.go:483\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/write_options.go"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d977c4f87eb0792c828fffbc93873204be631ecb03cd51d76a954dfbe18c4c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/tools/migration/meta/meta220.go:61-73 | cmd/tools/migration/meta/meta220.go:108-120 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/meta220.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebeffc237e195adc4f71f782168af22aa69680c1c9764ba31be345f107ef8144"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/tools/migration/meta/meta220.go:145-157 | cmd/tools/migration/meta/meta220.go:174-186 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/meta220.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"baad86d8cd671d5c1a7d6ce83def86b8af9c60abe37450054ae778e2e71b1cf3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datacoord/garbage_collector.go:1745-1757 | internal/datacoord/garbage_collector.go:1830-1842 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1745\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1745}}}],"partialFingerprints":{"codehealthFindingId/v1":"f189c628b1a1e305ed179edc8c575b16ed7193815547e6652b36a783a5772a2a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datacoord/garbage_collector.go:1872-1884 | internal/datacoord/garbage_collector.go:1910-1922 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1872\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1872}}}],"partialFingerprints":{"codehealthFindingId/v1":"781727392a39637c8863fbcf51baca8ba79d50cfec89c0d96ada23bfcf027cdb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datacoord/index_service.go:869-881 | internal/datacoord/index_service.go:924-936 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/index_service.go:869\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":869}}}],"partialFingerprints":{"codehealthFindingId/v1":"8739e2253dcdc25e47fc088c1279ed12fa56b538b4c94f091081cefbd39256d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datanode/importv2/hash.go:49-61 | internal/datanode/importv2/hash.go:135-147 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/hash.go:49\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/hash.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"816418990bdcefbfc64eedfa0a7470d502a48500bbb95bfda84c292967db10fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datanode/importv2/hash.go:81-93 | internal/datanode/importv2/hash.go:206-218 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/hash.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"6772d64884c19196d6d848917267b6d6920347c30ef08b4f934924f8f4432f58"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/datanode/importv2/task_import.go:75-87 | internal/datanode/importv2/task_l0_import.go:69-81 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:75\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ed7b9b898b2fa7ca63ecc9b99480a7ce373cc0488fa61790465abddf996ec9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/distributed/datanode/service.go:110-122 | internal/distributed/querynode/service.go:228-240 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/datanode/service.go:110\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/service.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b9436830bf430d1a565821de5c828b1cad4e2598a9a73a1da7dfa3bca090a53"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1453-1465 | internal/distributed/proxy/httpserver/handler_v2.go:1521-1533 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1453\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1453}}}],"partialFingerprints":{"codehealthFindingId/v1":"77b213e4ec95a5212c3b5c5304926302826f58375cc9fe6d689a6f61a92f3d3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/metastore/kv/querycoord/kv_catalog.go:261-273 | internal/metastore/kv/querycoord/kv_catalog.go:288-300 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/querycoord/kv_catalog.go:261\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/querycoord/kv_catalog.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"7da01654efa0dd8d08b77b19112d332f687d384fdec7a5a1485830b4eb650ca3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:395-407 | internal/parser/planparserv2/parser_visitor.go:489-501 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:395\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d5ce7fc4b01e9d5eed6906d5028de835dc789dc4aafeabb5a4b987bcab80198"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:1487-1499 | internal/parser/planparserv2/parser_visitor.go:1567-1580 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:1487\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":1487}}}],"partialFingerprints":{"codehealthFindingId/v1":"020fd641abbce8d0514baab004a1d53c8f325ff3f0fe5ef964d46066d73c594d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:2375-2387 | internal/parser/planparserv2/parser_visitor.go:2422-2434 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:2375\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2375}}}],"partialFingerprints":{"codehealthFindingId/v1":"23b150f295394c2a2efce45aca47006f3999d28a9f561de2ce9f41e77b8f8723"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:2897-2909 | internal/parser/planparserv2/parser_visitor.go:2978-2991 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:2897\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2897}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e25157aa124afe6214393cf9d4a161f60e70c6c2e37c526a3b55b1431f6fa31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/proxy/impl.go:2979-2991 | internal/proxy/impl.go:3211-3223 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2979\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2979}}}],"partialFingerprints":{"codehealthFindingId/v1":"31d29d5b65579ae85b5172972657de4238a9b39841192b39ce03502e4a9a8575"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 6): internal/datacoord/session/cluster.go:306-317 | internal/datacoord/session/cluster.go:353-364 | internal/datacoord/session/cluster.go:420-431 | internal/datacoord/session/cluster.go:497-508 | internal/datacoord/session/cluster.go:572-583 | internal/datacoord/session/cluster.go:715-726 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/session/cluster.go:420\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/session/cluster.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee14f059b2e94850d1dfee6c3c51f3fcee7715e75eddf5da72ee43f7e332075"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): internal/proxy/impl.go:2277-2288 | internal/proxy/impl.go:3853-3864 | internal/proxy/impl.go:4016-4027 | internal/proxy/impl.go:4069-4080 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2277\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2277}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe2f969843e9c4dab01cb502e122d8dda41ca96375996dac22d6d0b324c08f50"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/datacoord/compaction_task_bump_schema_version.go:411-422 | internal/datacoord/compaction_task_l0.go:434-445 | internal/datacoord/compaction_task_mix.go:326-337 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_bump_schema_version.go:411\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ecd3e196c288dfb5df99aa199bc7a3a4ecaffe4cdc4bfc6bdfd87c301d310c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): cmd/tools/migration/backend/etcd210.go:59-70 | cmd/tools/migration/backend/etcd210.go:125-136 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd210.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff59e9314b3468c689c14c0342cfa104ca7006726e82ac97b3fcbf6e7496240a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datacoord/compaction_task_bump_schema_version.go:339-350 | internal/datacoord/compaction_task_mix.go:255-266 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"035c0ee1075d60f6483dd460100073539063f45dcc330f3a9c4e0087bf46dd71"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datacoord/compaction_task_bump_schema_version.go:366-377 | internal/datacoord/compaction_task_mix.go:230-242 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_bump_schema_version.go:366\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"762c494be451c8680e4d8bed5c54da376913509b879a350d5955ab8dfe9e2736"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datacoord/garbage_collector.go:2073-2084 | internal/datacoord/garbage_collector.go:2131-2143 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:2073\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":2073}}}],"partialFingerprints":{"codehealthFindingId/v1":"f18b4d54f13367fc4d55511d7bccd684b6cac7acbc598a583492f823991bdb4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datacoord/index_meta.go:945-956 | internal/datacoord/index_meta.go:966-977 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"691d3320ffd3349b289c4e827e3b9e5757d58279ee36699567d7e4b1536a74a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datacoord/segment_manager.go:728-740 | internal/datacoord/segment_manager.go:749-760 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/segment_manager.go:728\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_manager.go"},"region":{"startLine":728}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cd2ee1fca3bee98a2822fec20f7269934c494a5f93c4be8bccf97beb18bb561"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datanode/compactor/compactor_common.go:492-503 | internal/datanode/index/task_stats.go:461-472 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/compactor_common.go:492\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/compactor_common.go"},"region":{"startLine":492}}}],"partialFingerprints":{"codehealthFindingId/v1":"7489c105f7ed8950ddf91fda9f5796b31d16f08b55e003b723e1ecc8777d6b9e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datanode/compactor/sort_compaction.go:317-328 | internal/datanode/index/task_stats.go:316-328 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/sort_compaction.go:317\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/sort_compaction.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"17f5b8284fb242389bede55656bcb3af89f4f70215095a312c263c7717ecf6ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datanode/importv2/hash.go:249-260 | internal/datanode/importv2/hash.go:271-282 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/hash.go:249\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/hash.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4dd4cf34743a8babee50dd7799c5054afe640e3e1bc57fa6f2224288a1e18f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/datanode/importv2/task_import.go:261-272 | internal/datanode/importv2/task_l0_import.go:218-229 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:261\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7fc851d6478d5dc46e693e3d10ee49d6e36e61d56a9e772ab046560fe104020"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/distributed/proxy/service.go:274-285 | internal/distributed/proxy/service.go:399-410 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/service.go"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd851a7ebaf57864a4eaa8410b82aba213113c1ca2392f204639da4e17e36b89"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/distributed/streaming/balancer.go:126-137 | internal/distributed/streaming/balancer.go:148-159 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/streaming/balancer.go:126\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/balancer.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7ee6a0d595735056b6b08857de48dc2fb35540b80d9afc1a16213a312426d33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/distributed/streaming/balancer.go:170-181 | internal/distributed/streaming/balancer.go:190-201 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/streaming/balancer.go:170\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/streaming/balancer.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"5522df4569e8aa08b7139d161fde287349dbe461cc5a8a30b55b64c146f676b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/flushcommon/pipeline/data_sync_service.go:355-366 | internal/flushcommon/pipeline/data_sync_service.go:407-418 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/pipeline/data_sync_service.go:355\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/pipeline/data_sync_service.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f64e1cc264c8d020616b1e86edd858e6a72f5f45403fd10c0737128c48bebfe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/flushcommon/syncmgr/meta_writer.go:103-115 | internal/flushcommon/syncmgr/meta_writer.go:237-248 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/meta_writer.go:103\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/meta_writer.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9a7480564313c9cf3a88aef9ef0157fd30ec2678fa8670376bbeae4141b4db1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/kv/mem/mem_kv.go:320-331 | internal/kv/mem/mem_kv.go:344-355 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/mem/mem_kv.go:320\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/mem/mem_kv.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf8d52ec7b3dd5ee57d4982592b0294326f7b45533219d5688bf5490a742c98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:2552-2563 | internal/parser/planparserv2/parser_visitor.go:2605-2616 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:2552\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2552}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3cca44492a751f8cb700e459a39e07ec13536fb688b31e35624c2eedc6446e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/parser/planparserv2/rewriter/range.go:265-276 | internal/parser/planparserv2/rewriter/range.go:378-389 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:265\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8435044ce4ed458d04f6a9e08419545f3ea36d1829e71c0fb35d77ac5d749cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/impl.go:822-833 | internal/proxy/impl.go:1540-1551 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:822\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":822}}}],"partialFingerprints":{"codehealthFindingId/v1":"b74118ab4a190a18239e955f6ad2887b5c719899eb61a6b1317d04aebecf5ae6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/impl.go:1474-1485 | internal/proxy/impl.go:1532-1543 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1474\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1474}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7e6381b2cef9320309d99438280eb0592c047c2e734e129d5fc95252f8df0cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/impl.go:4484-4495 | internal/proxy/impl.go:4542-4554 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:4484\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":4484}}}],"partialFingerprints":{"codehealthFindingId/v1":"df394452b7ef1fabe6bcf83d6aaa13de1488b69d3e654ca58f39fbcb5ef84f36"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/management.go:531-542 | internal/proxy/management.go:606-617 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/management.go:531\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/management.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"294fc65c46edff148fa497945fcf0571015c39f1caa7503ca39c7871279aace2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/task.go:2721-2732 | internal/proxy/task.go:2820-2831 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task.go:2721\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":2721}}}],"partialFingerprints":{"codehealthFindingId/v1":"e208542c160a35b53cdc77a8584a444b61af6badc0190f90320b3cbd69beb244"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/proxy/task_search.go:677-688 | internal/proxy/task_search.go:996-1007 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_search.go:677\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"807891a0ad5f81eac52f2887ebaaa76218122bc4d3f8c93068a3e2ff584c9a30"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 8): internal/proxy/impl.go:923-933 | internal/proxy/impl.go:987-997 | internal/proxy/impl.go:2052-2062 | internal/proxy/impl.go:2104-2114 | internal/proxy/impl.go:2273-2283 | internal/proxy/impl.go:3849-3859 | internal/proxy/impl.go:4012-4022 | internal/proxy/impl.go:4065-4075 \u2014 all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:923\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":923}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f57b186865e82383df776f4c56087382e5cc323b776a812667614b2763ed31c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/distributed/datanode/service.go:138-148 | internal/distributed/mixcoord/service.go:224-234 | internal/distributed/proxy/service.go:430-440 | internal/distributed/querynode/service.go:258-268 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/datanode/service.go:138\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/service.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"5792c3aa92544c78797f65da00188effdd28dcb64d6b866e7c7d7654707aed99"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): client/column/columns.go:551-561 | client/column/columns.go:600-610 | client/column/columns.go:649-659 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/columns.go:551\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"e92aec8cba199d700dbce8287a51e605fa19b0e0abadc6137e8f4b750874c5ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): client/column/columns.go:572-582 | client/column/columns.go:621-631 | client/column/columns.go:670-680 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/columns.go:572\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/columns.go"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0db891dba5a25eab366aa6d110d46a3656bbf90019237a4948d17688e04d74b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): client/milvusclient/results.go:120-130 | client/milvusclient/results.go:195-207 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/results.go:120\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/results.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ab0079dc5f5c3ed0f6ced831ba6d3e08197eeb02749ce76b86d6938d4bff3ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): client/milvusclient/read.go:56-66 | client/milvusclient/read.go:413-423 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/read.go:56\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/read.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"3139641fd5f0bafe910f282ba11a13edf6273ca5b93227540af87f68c83971ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): client/milvusclient/snapshot.go:118-128 | client/milvusclient/snapshot.go:144-154 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/snapshot.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"42f919780e80a4301837ec5efd0141cbef563639979b879a2dd1b9a5a257f879"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/tools/migration/backend/etcd210.go:232-242 | cmd/tools/migration/backend/etcd210.go:255-265 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/backend/etcd210.go:232\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd210.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e9d91451ecb7440761f59427652dcdb7039217669d119ecaceba3e3ce373398"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/coordinator/mix_coord.go:796-806 | internal/coordinator/mix_coord.go:838-848 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/coordinator/mix_coord.go:796\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"7359c297aa6358459e293a3ae7f0147cf2ace1465368e098e297d5c58c47abd9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datacoord/external_collection_refresh_meta.go:287-297 | internal/datacoord/external_collection_refresh_meta.go:378-389 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/external_collection_refresh_meta.go:287\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_meta.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3f86ae7ac0ee34a27b68899514744376271636a37b50c452c4fac8b36b894a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datacoord/meta.go:2401-2411 | internal/datacoord/meta.go:2490-2500 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/meta.go:2401\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":2401}}}],"partialFingerprints":{"codehealthFindingId/v1":"c705a068f90dcc53c0d591f9f6cf1cc47775dde044acf8d82c1a4cc2e79bb3b5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datacoord/meta.go:3287-3297 | internal/datacoord/meta.go:3405-3415 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/meta.go:3287\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":3287}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5fbd334ea7ca3e827cbd6ddf220e4b79f641c958a6a336dfc97d74fcb5d11c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datanode/compactor/record_materializer.go:460-470 | internal/datanode/compactor/record_materializer.go:501-511 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/record_materializer.go:460\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/record_materializer.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a43aa3e29b2ca31c2dfb07d044092b22785404f7104ce4443e25e00e57b89c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datanode/importv2/task_import.go:150-160 | internal/datanode/importv2/task_l0_import.go:125-135 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:150\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1fe91595e9e1824e55664467a28bfc5e902df448c517798f5a629b68744d968"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/datanode/importv2/task_l0_preimport.go:64-74 | internal/datanode/importv2/task_preimport.go:72-82 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_l0_preimport.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7e3a1b77d7f74169366cfaaed7aef84ee1d4f112465518288fceab4759da81a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:964-974 | internal/distributed/proxy/httpserver/handler_v2.go:991-1001 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:964\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":964}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5863f3cec3d9b34edac1897f0e80c4418d8d30c933c01430901766f6cb9b321"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/distributed/proxy/httpserver/wrap_request.go:236-246 | internal/distributed/proxy/httpserver/wrap_request.go:331-341 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/wrap_request.go:236\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/wrap_request.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"13b186c4f88ae990b7416ab73240ae1c0e862e6be2a592dae214b1004a743238"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/flushcommon/syncmgr/pack_writer.go:141-151 | internal/flushcommon/syncmgr/pack_writer.go:229-239 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/pack_writer.go:141\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fdc8912ddef38cf12b3471dbe50d4c1b1e3e3ac29d8d80c17478b7e3d9edd9e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/flushcommon/syncmgr/pack_writer_v3.go:674-684 | internal/flushcommon/syncmgr/pack_writer_v3.go:706-716 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/pack_writer_v3.go:674\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":674}}}],"partialFingerprints":{"codehealthFindingId/v1":"e18ebeb1eea525d54d7d80c96ed2f587b2fd48f051a15ca1c9bd310bc05fca96"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/metastore/kv/datacoord/kv_catalog.go:1198-1208 | internal/metastore/kv/rootcoord/kv_catalog.go:2294-2304 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/datacoord/kv_catalog.go:1198\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"e117cccec7a2e855f4f212dc8cdd2013d7d863645e41fbb4018d5623a00a30a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/impl.go:1173-1183 | internal/proxy/impl.go:1752-1762 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1173\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1173}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6036363cd550b1a32a86b1336dbc9d7c69c38d163002b3d2f51acb3487f9735"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/impl.go:1648-1658 | internal/proxy/impl.go:1701-1711 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1648\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1648}}}],"partialFingerprints":{"codehealthFindingId/v1":"539631530778ff661543916786720f0692535947298cc001ab3570b42f5df12f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/impl.go:1665-1675 | internal/proxy/impl.go:1718-1728 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1665\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1665}}}],"partialFingerprints":{"codehealthFindingId/v1":"c08dd5617b647a7b21483f941656ce12c2c66f65af16f1ce5fd3568ba0bcdee6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/impl.go:1901-1911 | internal/proxy/impl.go:1990-2000 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1901\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1901}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e89e8b20fa5cc5fb54a2d3748c5176a5c76478a5604e50fc608b55ce38afbc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/impl.go:4471-4481 | internal/proxy/impl.go:4531-4541 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:4471\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":4471}}}],"partialFingerprints":{"codehealthFindingId/v1":"771aa25bcc1e66af2eee1383fc9cb3e2bd9f0847916e9b00f6b0edeaef84a750"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/search_reduce_util.go:269-279 | internal/proxy/search_reduce_util.go:392-402 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_reduce_util.go:269\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2a681b1c34cbf0599c944047aeebc98b0593bf8ee04f3f27661beae064e0a3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/search_util.go:660-670 | internal/proxy/search_util.go:677-687 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_util.go:660\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4304a60180a4e4001a212d438502bee90f760df8748eaa4c63da96005b8cd55"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/proxy/task_search.go:728-738 | internal/proxy/task_search.go:1115-1125 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_search.go:728\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":728}}}],"partialFingerprints":{"codehealthFindingId/v1":"76fcd0aa364bd179d44facb8bc90bd229b97f46652658f124f35820b54c03757"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 9): internal/proxy/impl.go:527-537 | internal/proxy/impl.go:1287-1298 | internal/proxy/impl.go:1351-1360 | internal/proxy/impl.go:1419-1429 | internal/proxy/impl.go:1478-1488 | internal/proxy/impl.go:2273-2283 | internal/proxy/impl.go:3849-3859 | internal/proxy/impl.go:4012-4022 | internal/proxy/impl.go:4065-4075 \u2014 all 9 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:527\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"d04a7dadc22b01a0b5a7a92fbbd32d8227a1b3675cef5fbac4f066ae28002691"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 7): internal/datacoord/session/cluster.go:254-263 | internal/datacoord/session/cluster.go:327-336 | internal/datacoord/session/cluster.go:374-383 | internal/datacoord/session/cluster.go:450-459 | internal/datacoord/session/cluster.go:526-536 | internal/datacoord/session/cluster.go:601-610 | internal/datacoord/session/cluster.go:739-748 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/session/cluster.go:254\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/session/cluster.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"f67d98516e790f3f9a84ad570294945b5c7ed8c490b27e15ee279f5621e1f416"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 7): internal/proxy/impl.go:427-436 | internal/proxy/impl.go:820-830 | internal/proxy/impl.go:925-935 | internal/proxy/impl.go:989-999 | internal/proxy/impl.go:1538-1548 | internal/proxy/impl.go:2054-2064 | internal/proxy/impl.go:2106-2116 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:427\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"5544310a871cab81de8b95e1c5e68e391b098c58191af0347c07ee9d144fffbb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 6): internal/parser/planparserv2/parser_visitor.go:420-430 | internal/parser/planparserv2/parser_visitor.go:514-524 | internal/parser/planparserv2/parser_visitor.go:562-571 | internal/parser/planparserv2/parser_visitor.go:1786-1795 | internal/parser/planparserv2/parser_visitor.go:1850-1859 | internal/parser/planparserv2/parser_visitor.go:2061-2071 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e3408188ba0f3271f69b5ccaafe62b3646bf73c33889af5975d642346bcb34e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 6): internal/proxy/impl.go:2168-2177 | internal/proxy/impl.go:2228-2237 | internal/proxy/impl.go:2338-2347 | internal/proxy/impl.go:2398-2407 | internal/proxy/impl.go:3913-3922 | internal/proxy/impl.go:3968-3977 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2168\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2168}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cc26f726c869b569cd4603e4820a6fa87525037c91588e238f0b4af77403dcd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 6): internal/proxy/impl.go:2185-2194 | internal/proxy/impl.go:2240-2249 | internal/proxy/impl.go:2355-2364 | internal/proxy/impl.go:2415-2424 | internal/proxy/impl.go:3925-3934 | internal/proxy/impl.go:3980-3989 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2185\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2185}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdc9ec7bb7b9810c28f759378bf9e9a30962cb96d9ec4a222f859917873aa4ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): client/bulkwriter/bulk_import.go:125-134 | client/bulkwriter/bulk_import.go:203-212 | client/bulkwriter/bulk_import.go:350-359 | client/bulkwriter/bulk_import.go:411-420 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/bulkwriter/bulk_import.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f07834ca1e92511c7617627f92d0c51c8f2cbe2ebfa80120bda37ae3f41b4b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/datacoord/stats_task_meta.go:180-189 | internal/datacoord/stats_task_meta.go:210-219 | internal/datacoord/stats_task_meta.go:237-246 | internal/datacoord/stats_task_meta.go:265-274 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_task_meta.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"b707b88294563b87b4108b8cba69e528ca995326712346f6cd3002fd0ae3b736"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/distributed/proxy/httpserver/handler_v2.go:1098-1107 | internal/distributed/proxy/httpserver/handler_v2.go:1130-1139 | internal/distributed/proxy/httpserver/handler_v2.go:1306-1316 | internal/distributed/proxy/httpserver/handler_v2.go:1349-1358 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1098\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1098}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd720eeb2da5994e51769c3bde74313f1721ed2a696887ed9edd45215cc922e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/datacoord/compaction_task_bump_schema_version.go:99-108 | internal/datacoord/compaction_task_clustering.go:346-355 | internal/datacoord/compaction_task_l0.go:344-353 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_bump_schema_version.go:99\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c4a7bfa74e9f81f2ef4b2e0ee60673bf8bf723167a3ce24951323c746543b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/datacoord/copy_segment_task.go:946-955 | internal/datacoord/copy_segment_task.go:1017-1026 | internal/datacoord/copy_segment_task.go:1083-1092 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/copy_segment_task.go:946\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":946}}}],"partialFingerprints":{"codehealthFindingId/v1":"5de3a0ac90e6ff4726311c30187eba339e3b7185dd21c5e77df41d6d34276764"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/distributed/proxy/httpserver/utils.go:666-675 | internal/distributed/proxy/httpserver/utils.go:680-689 | internal/distributed/proxy/httpserver/utils.go:694-703 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:666\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":666}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c4d39b58209263f2da6ddf65641125265954960e2ae370a806e06bf2c81fa4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/proxy/impl.go:1144-1153 | internal/proxy/impl.go:1201-1210 | internal/proxy/impl.go:1780-1789 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1144\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1144}}}],"partialFingerprints":{"codehealthFindingId/v1":"256ae98355e6720930615c7fcc98f9a12201792fad806a13a0089c6f173c794e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): client/milvusclient/telemetry.go:381-390 | client/milvusclient/telemetry.go:427-437 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/telemetry.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"55eb1b43a60d5b873b41c166749a36f170c5c56d4ff73f8e60d85c66fce80925"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/coordinator/mix_coord.go:822-831 | internal/coordinator/mix_coord.go:864-873 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/coordinator/mix_coord.go:822\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/coordinator/mix_coord.go"},"region":{"startLine":822}}}],"partialFingerprints":{"codehealthFindingId/v1":"985491bad626a38233ea25a105eb4b6e8da73dee223912c03d3c1e01edb22894"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/datacoord/compaction_trigger.go:858-868 | internal/datacoord/compaction_trigger.go:889-898 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_trigger.go:858\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":858}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ef7fc19b03dcf7cbb6555ae84a22b425fad955c99fe9b49e68fb72367e67a7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/datacoord/compaction_trigger_v2.go:556-565 | internal/datacoord/compaction_trigger_v2.go:787-796 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_trigger_v2.go:556\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger_v2.go"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ec83a931c2d7bfc807f86228d58a26371b0761b888acdfdd835ed652ac5611c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/datacoord/copy_segment_task.go:1003-1012 | internal/datacoord/copy_segment_task.go:1069-1078 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/copy_segment_task.go:1003\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":1003}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eab870bb7b905e0045c260b28b08d60ebf709cf5cd1bc6ca491c0e3702d9db5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/datanode/importv2/task_import.go:217-226 | internal/datanode/importv2/task_l0_import.go:204-213 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:217\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"a45762d59be71588fd71359b62776ee3a6c0e9ef5e38ccaef1e1a06437b61fd6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/datanode/services.go:238-247 | internal/datanode/services.go:287-296 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/services.go:238\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a68426822a243cc529e5c5de6617c840c8b5009f7e1dc706b2096eb397625b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/flushcommon/syncmgr/pack_writer_v2.go:271-280 | internal/flushcommon/syncmgr/pack_writer_v3.go:336-345 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/pack_writer_v2.go:271\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v2.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b872586e617ea615c458dbc8e652c1f5820b326eb957f730283dd270334d8f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/flushcommon/syncmgr/storage_serializer.go:174-183 | internal/flushcommon/syncmgr/storage_serializer.go:249-258 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/storage_serializer.go:174\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/storage_serializer.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"41c7791f156ea24dcc2ecf6e92202129df66ee095253f11a47c83b3c346f26d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:487-496 | internal/kv/etcd/etcd_kv.go:584-593 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":487}}}],"partialFingerprints":{"codehealthFindingId/v1":"688533be6a0e68718db953b917720e8b3d7acc03cbfa9b24d476810f53eaae17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/metastore/kv/rootcoord/kv_catalog.go:1797-1807 | internal/metastore/kv/rootcoord/kv_catalog.go:1867-1876 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/rootcoord/kv_catalog.go:1797\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1797}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d213f677b767bc1c903ada820371214a25063c86bae6e1c740f7c8f4a71d990"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/highlighter.go:405-417 | internal/proxy/highlighter.go:561-570 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/highlighter.go"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"2086c78dc48028ef2c127ea66e43d4cadda53b4efe3315cf483f382079be151b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:491-500 | internal/proxy/impl.go:3614-3624 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:491\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd706b0c82d9224ca99c478742b811f3183fb4bd1ad6c97d9dc4d58cd9b638f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:737-746 | internal/proxy/impl.go:790-799 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:737\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d14b8f8f4db5afe5b571c145d61a4ff6f3100713b8ca7f2691f5e3122e56798"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:1184-1193 | internal/proxy/impl.go:1763-1772 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1184\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1184}}}],"partialFingerprints":{"codehealthFindingId/v1":"310c0228a96803caedeb9d481ebfe07da01c4fe99ada4728b3ef665b95da4d56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:2932-2941 | internal/proxy/impl.go:3162-3171 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2932\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2932}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c905202a052bd9d3865d1b995d2f081bd8033d7410c7a9adc1e2f387c823d9a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:3460-3469 | internal/proxy/impl.go:3740-3749 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:3460\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":3460}}}],"partialFingerprints":{"codehealthFindingId/v1":"6430c19616ba117fac9ae16020c2ffc15aae4627de1c7f4e38361cd614a191a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/impl.go:4211-4220 | internal/proxy/impl.go:4273-4282 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:4211\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":4211}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cecd07494fffcbfbb5194d43d92e1b429fe6ff3e0e4c66dc99d6e3d7846033d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/search_pipeline.go:2664-2673 | internal/proxy/search_pipeline.go:2681-2690 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_pipeline.go:2664\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2664}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a75965ffac9b1290e5fa2790efe7309b098729aaf383a177f4bc0f8aff9a366"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/search_reduce_util.go:109-118 | internal/proxy/search_reduce_util.go:622-631 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_reduce_util.go:109\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e161c79f57ad158d92f937149e7ae4ab15764750faf33b97fd78d36a975b09"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/search_util.go:542-551 | internal/proxy/search_util.go:1022-1031 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c2e2e9398733b4f7d4d0261eced0925e935fcca30b8aad781bf9816b388f6e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/search_util.go:1003-1012 | internal/proxy/task_query.go:390-399 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_util.go:1003\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":1003}}}],"partialFingerprints":{"codehealthFindingId/v1":"de7850c62e74c844b8d2d2e6266d013857865753a711fc39f28883c137268b2b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/task_query.go:631-640 | internal/proxy/task_search.go:133-142 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_query.go:631\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c1842ba4447e861be4b3c9ce0875a935cd2a3e6ebd85b4c369afa56820aefa8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/proxy/task_scheduler.go:736-745 | internal/proxy/task_scheduler.go:764-775 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_scheduler.go:736\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_scheduler.go"},"region":{"startLine":736}}}],"partialFingerprints":{"codehealthFindingId/v1":"f90f57e48b25e80bb3c8a75c9d9464335e3cc44d225773622a98973c9eedf54e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 5): internal/proxy/search_pipeline.go:2826-2834 | internal/proxy/search_pipeline.go:2858-2866 | internal/proxy/search_pipeline.go:2890-2898 | internal/proxy/search_pipeline.go:2922-2930 | internal/proxy/search_pipeline.go:2979-2987 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2826}}}],"partialFingerprints":{"codehealthFindingId/v1":"7571d740313b2bce690cbe868741ecba27ad35da2deea6b8e0162b23b277353a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/distributed/datanode/service.go:127-135 | internal/distributed/mixcoord/service.go:212-220 | internal/distributed/proxy/service.go:419-427 | internal/distributed/querynode/service.go:246-254 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/datanode/service.go:127\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/service.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"f52df4c40fa162fd74386b3d1abacd9218efd1b8b08b6070e02a6fc6655ad4d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/datacoord/session/cluster.go:117-125 | internal/datacoord/session/cluster.go:159-167 | internal/datacoord/session/cluster.go:631-640 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/session/cluster.go:159\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/session/cluster.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"d23a792f6f4aeaa028a69a470f495909a09a77d1edd126e5a8fd6be700492d72"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/datacoord/stats_task_meta.go:252-260 | internal/datacoord/stats_task_meta.go:281-289 | internal/datacoord/stats_task_meta.go:371-379 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/stats_task_meta.go:252\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_task_meta.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"e54522991a746ddf457fa71cb96de9e91d7ec61043281f068c27c79821099501"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/datanode/compactor/clustering_compactor.go:353-361 | internal/datanode/compactor/clustering_compactor.go:376-384 | internal/datanode/compactor/clustering_compactor.go:436-444 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/clustering_compactor.go:353\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"da62cb53d7627d9d0d102dd4d3515f014b6db95afc44e89f4d86171090d4d3b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/distributed/proxy/httpserver/handler_v1.go:701-709 | internal/distributed/proxy/httpserver/handler_v1.go:785-793 | internal/distributed/proxy/httpserver/handler_v1.go:904-912 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:701\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":701}}}],"partialFingerprints":{"codehealthFindingId/v1":"f139227052af3286f63845199a8fa5b0ab22187cb02f9d380e2e270184e06994"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/distributed/proxy/httpserver/utils.go:2205-2213 | internal/distributed/proxy/httpserver/utils.go:2219-2227 | internal/distributed/proxy/httpserver/utils.go:2233-2241 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:2205\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2205}}}],"partialFingerprints":{"codehealthFindingId/v1":"21b12ad649b72c2f3a7ad201a349fc2d2e772197fb9df7814f007db539a648c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/proxy/management.go:312-320 | internal/proxy/management.go:450-458 | internal/proxy/management.go:483-491 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/management.go:312\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/management.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4ccd8436de76083fde827f391b32dbef5697d89d54e8b2289b12eddbf45289f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): client/column/dynamic.go:89-97 | client/column/dynamic.go:134-142 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/dynamic.go:89\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/dynamic.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5dd789bd38f012e6da1a4be6fd154029281d55df08ba2e471195f58abca4cfd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): client/milvusclient/maintenance.go:79-89 | client/milvusclient/maintenance.go:174-182 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/milvusclient/maintenance.go:79\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/maintenance.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"03cbdd3a106b27882cdd1db4d3467e13baf4a2eb1396ce0d5bbaa831c11574a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/tools/migration/mmap/tool/main.go:74-82 | cmd/tools/migration/mmap/tool/main.go:109-117 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/mmap/tool/main.go:74\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/mmap/tool/main.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d1483ed588a8a7bf564a46a2798db36081afadd30eea7d088371e12c4f97eab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/agg/aggregate_util.go:104-112 | internal/agg/aggregate_util.go:149-157 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/agg/aggregate_util.go:104\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_util.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"2efe918f0575b25fc44e05a28d25d1d44216db6dc400d885f19ca7de33f4fad1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datacoord/external_collection_refresh_meta.go:233-242 | internal/datacoord/external_collection_refresh_meta.go:249-257 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/external_collection_refresh_meta.go:233\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_meta.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"66ee11b7763dc81ef516eade4c8f7c9643bba9867416ad4f12a3f67b8410b8e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datacoord/garbage_collector.go:1551-1559 | internal/datacoord/garbage_collector.go:1796-1805 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1551\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1551}}}],"partialFingerprints":{"codehealthFindingId/v1":"01391434c264c6f1e0c611caef55bf2be47f7a74d5d9c4970a80b1d6e09a6048"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datanode/compactor/clustering_compactor.go:1079-1087 | internal/datanode/compactor/mix_compactor.go:179-187 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/clustering_compactor.go:1079\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/clustering_compactor.go"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"2adaddc8038662727a1417c346e8410099c1807a39a0306eff68d9484b958204"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datanode/compactor/compactor_common.go:126-134 | internal/datanode/index/task_stats.go:551-559 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/compactor_common.go:126\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/compactor_common.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"8099f47251042b2bc7ebe346a68275c4da8eae1938837131cb89492d3f036910"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datanode/importv2/task_l0_preimport.go:173-181 | internal/datanode/importv2/task_preimport.go:168-176 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_l0_preimport.go:173\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_l0_preimport.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ced558c107dd84e204f96b6d447eb9bac5680099928ceddf374b88db2e96aea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/datanode/index/task_stats.go:558-566 | internal/datanode/index/task_stats.go:736-744 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/index/task_stats.go:558\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/task_stats.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6003229ca15a5c66df49f42a6e708aef5d42c171a1a5caaa461896acf6b5579"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:543-551 | internal/distributed/proxy/httpserver/handler_v1.go:622-630 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:543\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ad81e015fad898f7f54b625f3e175d7b2571d2a6542bccc7bdf78cd3b8f7473"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:725-733 | internal/distributed/proxy/httpserver/handler_v1.go:825-833 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:725\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"efce1bf87f33095da5d6dca753e8882a58554be3e02e289d934840e0e9fce9ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1407-1415 | internal/distributed/proxy/httpserver/handler_v2.go:1492-1500 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1407}}}],"partialFingerprints":{"codehealthFindingId/v1":"5759a93e434dbc2726b83637a509931d193ea2472a7a57e799ff8a3d8d44e9eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1584-1592 | internal/distributed/proxy/httpserver/handler_v2.go:1668-1676 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1584}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3085faf1e3cac94aaada65b0764d08136b13867c5ca7be20e549d5c2bdbe745"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1711-1719 | internal/distributed/proxy/httpserver/handler_v2.go:1746-1754 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1711\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1711}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c4de74d40d0b14d691d088697b2c6d95bb81f8af2b31a08a6dc378ff3ec76f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1856-1864 | internal/distributed/proxy/httpserver/handler_v2.go:2128-2136 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1856}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fcc57330b1d2fc075e5ff8a738ca3f97d26b1a821828f1a7d5c1cc0420fab18"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1942-1950 | internal/distributed/proxy/httpserver/handler_v2.go:2165-2173 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1942}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdfc2c5538182e1cc7af2c6cab4ba4997af93050b7aa6b06b354a70285852694"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/flushcommon/syncmgr/storage_serializer.go:142-150 | internal/flushcommon/syncmgr/storage_serializer.go:214-222 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/storage_serializer.go:142\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/storage_serializer.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"87ec6950d887426e06fc06a43a98e0cb0378ef407af11beddd253a06761b030b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/flushcommon/writebuffer/write_buffer.go:558-567 | internal/flushcommon/writebuffer/write_buffer.go:774-782 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/writebuffer/write_buffer.go:558\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f720fa26d4a5da71025c026bcafc1e9441b2830dc9009dd785a4f4e850cd9c7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:499-507 | internal/kv/etcd/embed_etcd_kv.go:569-577 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:499\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"80f30f6aa51b826c681aa29781fd57d5c9b2436fdaf134dcb8d72e7f6e8d4656"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/metastore/kv/datacoord/kv_catalog.go:1157-1165 | internal/metastore/kv/rootcoord/kv_catalog.go:2253-2261 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":1157}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1624bd0355e132a33f5f8d33691df0a88455f7ace6d53b38648b3a578bfeaaf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/metastore/kv/rootcoord/kv_catalog.go:474-483 | internal/metastore/kv/rootcoord/kv_catalog.go:544-552 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/rootcoord/kv_catalog.go:474\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":474}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ee196be11ac85c1c12473e986d2dbd3fd1fe99bf10f5065d88932eba52d5f54"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/proxy/impl.go:613-621 | internal/proxy/impl.go:675-683 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:613\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"89c2b3b2ac408e49d63fc178ee89fa3a845aa0d4c37ad29d85aae1dcec1e4013"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/proxy/impl.go:2508-2517 | internal/proxy/impl.go:2751-2759 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2508}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbc8d7e43e4170348ae1e728f8bad8598ba31845cd09202af06546e501a0be0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/proxy/impl.go:5290-5298 | internal/proxy/impl.go:5322-5330 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:5290\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5290}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2319c831c4fe1dd95d886aabad2d2528f95838777ef2b3052c29e97a8147ad7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/proxy/impl.go:5518-5526 | internal/proxy/impl.go:5578-5586 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:5518\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5518}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cbff1278240a9313b748b3b7e0d199fcd12522e6b533050bf0a69dd04d38cc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/proxy/search_util.go:291-299 | internal/proxy/search_util.go:317-326 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_util.go:291\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_util.go"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"92b7c1d54546f3c523a6e2ce951e676858d6ada595cf0e2f33d3149e32120110"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/kv/etcd/embed_etcd_kv.go:414-421 | internal/kv/etcd/embed_etcd_kv.go:431-438 | internal/kv/etcd/embed_etcd_kv.go:468-475 | internal/kv/etcd/embed_etcd_kv.go:525-532 | internal/kv/etcd/embed_etcd_kv.go:594-601 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:414\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d2cc5179fa17aaf960e5e9e9a1fb64a4ac63ec050a1c7fff3855adabcb423e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/datacoord/copy_segment_task.go:771-778 | internal/datacoord/copy_segment_task.go:942-949 | internal/datacoord/copy_segment_task.go:1013-1020 | internal/datacoord/copy_segment_task.go:1079-1086 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/copy_segment_task.go:771\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_task.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"8975c1517d2240ecf9452e5cc34aa4d6ee59a6d47f4086922ef2ea670bc66a83"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/datacoord/stats_task_meta.go:197-204 | internal/datacoord/stats_task_meta.go:252-260 | internal/datacoord/stats_task_meta.go:281-289 | internal/datacoord/stats_task_meta.go:371-379 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/stats_task_meta.go:197\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/stats_task_meta.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"1119655b7ca5a904c46e0b616f11a822caeed1ff98644c505ddca882d0185ba1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/distributed/datanode/service.go:225-232 | internal/distributed/mixcoord/service.go:138-145 | internal/distributed/proxy/service.go:502-509 | internal/distributed/querynode/service.go:151-158 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/datanode/service.go:225\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/datanode/service.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b273a4102551f9ab319b770de8127e4ce8620c57eb3bbf750dc7cb76c833821"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/datacoord/compaction_trigger.go:820-827 | internal/datacoord/compaction_trigger.go:857-864 | internal/datacoord/compaction_trigger.go:888-895 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_trigger.go:820\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger.go"},"region":{"startLine":820}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d0afbec31afc5a913dd45c03c3df07d82ee486b93a1417c7d1c6a3ec08f39f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/datacoord/compaction_trigger_v2.go:430-437 | internal/datacoord/compaction_trigger_v2.go:564-571 | internal/datacoord/compaction_trigger_v2.go:795-802 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_trigger_v2.go:430\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger_v2.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b3f95fb51009fea9c14afa068aeed90d94a1776e0a906e33361529c46f4ac2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/datacoord/index_service.go:533-540 | internal/datacoord/index_service.go:786-793 | internal/datacoord/index_service.go:900-907 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/index_service.go:533\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":533}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3ee794e5f6c81cf53e7d078b9e0b6ee3db09d2d50682d4406bf8f2767fd48cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/parser/planparserv2/parser_visitor.go:2473-2480 | internal/parser/planparserv2/parser_visitor.go:2524-2531 | internal/parser/planparserv2/parser_visitor.go:2577-2584 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:2473\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":2473}}}],"partialFingerprints":{"codehealthFindingId/v1":"32a6125054e100d9a3edb858b5fe68bbb144f1faf6d3299869607b8633e99365"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/proxy/task_scheduler.go:266-273 | internal/proxy/task_scheduler.go:291-298 | internal/proxy/task_scheduler.go:464-471 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_scheduler.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"3238db647c2b3808dfe705cdc49cd82374a63ca10c36c83f1e06901bd380d7e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): client/milvusclient/write_options.go:562-569 | client/milvusclient/write_options.go:581-588 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/milvusclient/write_options.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"7735c2c14d0f3422f08e3ba816fa5155c9b0acd6d322771a30d1728cdc7b875d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/tools/migration/backend/etcd210.go:416-423 | cmd/tools/migration/backend/etcd210.go:442-450 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/backend/etcd210.go:416\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/backend/etcd210.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"73453cd2fc48c6b10bac5d2d52ace15fa287799cab1b3a50cad14a300978626d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/tools/migration/meta/meta220.go:49-56 | cmd/tools/migration/meta/meta220.go:98-105 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/tools/migration/meta/meta220.go:49\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tools/migration/meta/meta220.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"a84f1a2c8759b0416c4337cc46a6b0f8259cfdad698c68bf65d20859ecf6c070"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/agg/aggregate_util.go:601-608 | internal/agg/aggregate_util.go:612-619 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/agg/aggregate_util.go:601\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/agg/aggregate_util.go"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"17ffc4bc85f2bdd706877b7c82164cda86190755d62f92d5d05be78cc37bb36e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/import_task_import.go:143-150 | internal/datacoord/import_task_preimport.go:115-122 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/import_task_import.go:143\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_task_import.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cde4f5c587b098e3d4161d5da3e35d2cec5f20bc0513cd216cd4c7ba774771f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/import_task_import.go:319-326 | internal/datacoord/import_task_preimport.go:212-219 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/import_task_import.go:319\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_task_import.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"1052b3b47bdfc7f370a70f612235472920b6d292732db355c438e8bbd45598ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/index_service.go:420-427 | internal/datacoord/index_service.go:986-993 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/index_service.go:420\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7d8404d329bd9c56069bf478c9bd8305320770949c0f062c29184eb4a9cff34"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/meta.go:2427-2434 | internal/datacoord/meta.go:2533-2540 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/meta.go:2427\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":2427}}}],"partialFingerprints":{"codehealthFindingId/v1":"95d8a2e75bdaa05b7e4aa61475345e80b2f950d3f26027000b7e8cc0f78da9b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/segment_manager.go:573-581 | internal/datacoord/segment_manager.go:698-705 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/segment_manager.go:573\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_manager.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"01182489ae6e5cd5ed85ea2287ce6d2363430772189dad6812d18d609b6ced0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/task_refresh_external_collection.go:361-368 | internal/datacoord/task_refresh_external_collection.go:417-424 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/task_refresh_external_collection.go:361\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/task_refresh_external_collection.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"2467efea7296d05aa41d2f7e87b290060cbd12c1c494e8a9ff30fd9628a614a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datacoord/util.go:569-576 | internal/datacoord/util.go:582-589 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/util.go:569\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/util.go"},"region":{"startLine":569}}}],"partialFingerprints":{"codehealthFindingId/v1":"464db50d1b41148fa25bc269eb52e5ce788931d08ac70836b43671d7e2296653"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/compactor/sort_compaction.go:225-232 | internal/datanode/compactor/sort_compaction.go:238-245 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/sort_compaction.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba0e3355b593e42562fef25761886614d017d2ab61a890c283d5babf6672921a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/importv2/task_import.go:168-175 | internal/datanode/importv2/task_l0_import.go:143-150 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:168\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"23d941ea8834156c3efaac59d43b3e4198af66ee798af3e5a47b7c5696d6d7e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/importv2/task_import.go:193-200 | internal/datanode/importv2/task_l0_import.go:186-193 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:193\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"e274ee447fd0342f239bf168e71ad7d38034d5acecee6d656c65cd27de3253af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/importv2/task_l0_preimport.go:133-140 | internal/datanode/importv2/task_preimport.go:143-150 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_l0_preimport.go:133\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_l0_preimport.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"98d59d5a558bbe1c59165113575842a061bf37dae2bd61c8466f5b3c797f5d39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/services.go:374-382 | internal/datanode/services.go:402-409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/services.go:374\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca1556e9cc669c5b4f9ef44c1e00a709f5cdb4c4e52b5b7df57564c027710ff0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/datanode/services.go:793-800 | internal/datanode/services.go:802-809 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":793}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d6a187d6e73ded06ed543efd97610f2192825d428e9d4bbaec063a5fb7f5df9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:605-612 | internal/distributed/proxy/httpserver/handler_v1.go:684-691 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfdf389aee48ac117089e5d1db4ad150fa336f4bdaf4b834a99420df94c58069"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:806-813 | internal/distributed/proxy/httpserver/handler_v1.go:925-932 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:806\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":806}}}],"partialFingerprints":{"codehealthFindingId/v1":"5162350bd292722e37850fc36b6d65275ce3845f0296933d44e1d2023ef9b101"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1477-1484 | internal/distributed/proxy/httpserver/handler_v2.go:1554-1561 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1477\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1477}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee571599e4633357cd5bf83766907c8c60cd504b27728789bc466b67473cb80e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1595-1602 | internal/distributed/proxy/httpserver/handler_v2.go:1679-1686 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1595\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1595}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fee9fa803a86d8cec71b77145c6ed29dca1f726dff6e0fb260ba7d7b41b7866"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2391-2398 | internal/distributed/proxy/httpserver/handler_v2.go:2402-2409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2391\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2391}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6929e3de7b917c6119a1892c3c447adf01a8f65da20bc01ec4228cbebce6f17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:1232-1239 | internal/distributed/proxy/httpserver/utils.go:1284-1291 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:1232\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"884235fe8b979377d7074e1e553a27bd9d203de62fe5665f63d81eef10181da4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/flushcommon/writebuffer/write_buffer.go:704-711 | internal/flushcommon/writebuffer/write_buffer.go:729-740 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/writebuffer/write_buffer.go:704\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":704}}}],"partialFingerprints":{"codehealthFindingId/v1":"6710ac45eca475b6dc10ec41204467cb36e8d4b347de43e710b70abd613384d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/flushcommon/writebuffer/write_buffer.go:1278-1285 | internal/flushcommon/writebuffer/write_buffer.go:1763-1770 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/writebuffer/write_buffer.go:1278\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":1278}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc1aa55c4b003755c98e81f259e01afef015757219d32157119b86bdce3bc988"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:463-470 | internal/kv/etcd/etcd_kv.go:455-462 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b7256d2e6088eb47e8ad46cbbb75b8328175e5588c4cc28e7e01587f1234b36"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:586-593 | internal/kv/etcd/etcd_kv.go:617-624 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:586\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":586}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fdc873db434c083320896a57398164c457d193b4744a03f9a4691ed37146f9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:606-613 | internal/kv/etcd/embed_etcd_kv.go:623-630 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea296d50826af2446e99067c4f09a9470949326e9e6eb42125c10b57fc007af0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:131-138 | internal/kv/etcd/etcd_kv.go:182-189 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd8e43228236248f7b62b752084958cb3a283f80b6c215f01ec0c63fab74540e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:261-268 | internal/kv/etcd/etcd_kv.go:296-303 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/etcd_kv.go:261\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"c60d384da6f747e146dd0b58b7e4783a6d8e90dc09c57992ec4c353661c8bf43"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/tikv/txn_tikv.go:243-251 | internal/kv/tikv/txn_tikv.go:345-352 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/tikv/txn_tikv.go:243\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"c81a394365ea33d97afaaadca2f63005df8c53cfa61be29f58d360b642b9bf23"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/kv/tikv/txn_tikv.go:504-511 | internal/kv/tikv/txn_tikv.go:555-563 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/tikv/txn_tikv.go:504\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b457eb40cd2b5c5f7425b646a673bf36105c0bd153089a1a3d0d27c92f834f6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/parser/planparserv2/parser_visitor.go:343-350 | internal/parser/planparserv2/parser_visitor.go:1954-1961 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/parser_visitor.go:343\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/parser_visitor.go"},"region":{"startLine":343}}}],"partialFingerprints":{"codehealthFindingId/v1":"abef9fc87e2a5dd15eac5c505c92153b8437b245ab53fa23f2f327a9a222de9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/parser/planparserv2/rewriter/range.go:355-362 | internal/parser/planparserv2/rewriter/range.go:373-380 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:355\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ee943be3bc4fa80dc0a56558a24421b21737a68329b3b5c5ebe447e3869b8a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/proxy/accesslog/info/grpc_info.go:293-300 | internal/proxy/accesslog/info/restful_info.go:242-249 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/accesslog/info/grpc_info.go:293\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/grpc_info.go"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3c9ad1c586a95a7df5d7649bfa1e746bc883d4eb959ac4a1d9dcc3475513b86"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/proxy/impl.go:2969-2976 | internal/proxy/impl.go:3201-3208 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:2969\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":2969}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b5b8cdfb51d7339d59077e83a73ce934b04abf39c38bbca948b1151c82718ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/proxy/impl.go:3066-3073 | internal/proxy/impl.go:3297-3304 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:3066\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":3066}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d07ab2457089fdf2e9fe8b1e15a9e03283f262128c336100afa9018a2560d57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/proxy/impl.go:5052-5059 | internal/proxy/impl.go:5136-5144 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:5052\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5052}}}],"partialFingerprints":{"codehealthFindingId/v1":"c65f0fdfcc839837fa39854c099a174a86cadee86a4c8d53271c83971b5027be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 8): internal/proxy/impl.go:296-303 | internal/proxy/impl.go:338-344 | internal/proxy/impl.go:422-432 | internal/proxy/impl.go:524-534 | internal/proxy/impl.go:815-825 | internal/proxy/impl.go:1284-1295 | internal/proxy/impl.go:1349-1357 | internal/proxy/impl.go:1416-1426 \u2014 all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:296\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9c44372480c854b08ddae1dd1a85443945a50a6184d2a263bb39e04cf755f8a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 6): internal/datanode/services.go:674-680 | internal/datanode/services.go:683-689 | internal/datanode/services.go:692-698 | internal/datanode/services.go:701-707 | internal/datanode/services.go:710-716 | internal/datanode/services.go:719-725 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":674}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b6ef5e1d048ab7a2ad4b9e4cd7a78f9aea2396288d4711e3ec03b8acd18058a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 6): internal/distributed/proxy/httpserver/handler_v1.go:248-254 | internal/distributed/proxy/httpserver/handler_v1.go:447-453 | internal/distributed/proxy/httpserver/handler_v1.go:503-509 | internal/distributed/proxy/httpserver/handler_v1.go:575-581 | internal/distributed/proxy/httpserver/handler_v1.go:653-659 | internal/distributed/proxy/httpserver/handler_v1.go:941-947 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:248\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"033c9b49e152931eb33939d60d7274e4cf6730ff836882ec774df394f096d6b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 6): internal/distributed/proxy/httpserver/handler_v2.go:2368-2374 | internal/distributed/proxy/httpserver/handler_v2.go:2390-2396 | internal/distributed/proxy/httpserver/handler_v2.go:2401-2407 | internal/distributed/proxy/httpserver/handler_v2.go:2412-2418 | internal/distributed/proxy/httpserver/handler_v2.go:2423-2429 | internal/distributed/proxy/httpserver/handler_v2.go:2445-2451 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2368\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2368}}}],"partialFingerprints":{"codehealthFindingId/v1":"797543756e18a0c124b92141adaff761738d9661003976bc594a947d503845fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): internal/distributed/proxy/httpserver/handler_v1.go:536-542 | internal/distributed/proxy/httpserver/handler_v1.go:694-700 | internal/distributed/proxy/httpserver/handler_v1.go:778-784 | internal/distributed/proxy/httpserver/handler_v1.go:897-903 | internal/distributed/proxy/httpserver/handler_v1.go:1010-1016 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:536\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"99c4935f87415bda1614ba9f8eff710679b28f7d3d538641f3199b26986a4fe1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/parser/planparserv2/rewriter/range.go:199-205 | internal/parser/planparserv2/rewriter/range.go:339-345 | internal/parser/planparserv2/rewriter/range.go:625-632 | internal/parser/planparserv2/rewriter/range.go:838-845 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/parser/planparserv2/rewriter/range.go:199\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/parser/planparserv2/rewriter/range.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"36936e21702703573892e2f2f1dc2331fa38102057ce0af028f3e8229eddcb7d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/datacoord/garbage_collector.go:1777-1783 | internal/datacoord/garbage_collector.go:1861-1867 | internal/datacoord/garbage_collector.go:1983-1989 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1777\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1777}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4bb262233cbf0a45ab17bd19bed9eedfd0ddfcf9179ec3dcd7caaf8a19fc360"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/distributed/proxy/httpserver/handler_v2.go:942-948 | internal/distributed/proxy/httpserver/handler_v2.go:2798-2804 | internal/distributed/proxy/httpserver/handler_v2.go:2887-2893 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:942\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":942}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e4340f94fcbfef2ab1f88abe0bfd4ed37d3b0b12e6e96216a0329d075f6c726"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/proxy/search_pipeline.go:640-646 | internal/proxy/search_pipeline.go:679-685 | internal/proxy/search_pipeline.go:769-775 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_pipeline.go:640\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbf09f6054aab84eba9171e4890d1b7ead0e6c6477afdd5a9c28d58534d6692c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/compaction_inspector.go:327-333 | internal/datacoord/compaction_inspector.go:339-345 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_inspector.go:327\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a7f7ee64db47f68a566d733858538900912a1dd7cc9926e97a75364b0721cbd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/compaction_task_clustering.go:223-229 | internal/datacoord/compaction_task_mix.go:169-175 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_clustering.go:223\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_clustering.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"60d2001fe9e2273b617be0e2eeb22ef381080c1fda7dfe13f1f3b7fa1c5e9dfd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/compaction_trigger_v2.go:447-453 | internal/datacoord/compaction_trigger_v2.go:516-522 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_trigger_v2.go:447\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_trigger_v2.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"d30c03fcc13dbdee59ababb5de2fdac9063a058e74e95008f3c850544e17971c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/copy_segment_inspector.go:184-190 | internal/datacoord/copy_segment_inspector.go:217-223 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/copy_segment_inspector.go:184\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/copy_segment_inspector.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4f2597212f2267c1bbefb6fc0e70d2d6a00f3d52e29c6bb73f69710618173ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/external_collection_refresh_checker.go:316-322 | internal/datacoord/external_collection_refresh_checker.go:325-331 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/external_collection_refresh_checker.go:316\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/external_collection_refresh_checker.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"63c848a3901fa908405631993aabf4fbeab1eb6e08308881af6905b0cc44eddd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/garbage_collector.go:1624-1630 | internal/datacoord/garbage_collector.go:1636-1642 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1624\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1624}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9dfbc7755e1cc65c9ad38f4f2734fbdfcdf625ebf3f1fb496a30c0cbeac514a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/garbage_collector.go:1826-1832 | internal/datacoord/garbage_collector.go:1948-1954 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1826\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1826}}}],"partialFingerprints":{"codehealthFindingId/v1":"c17d29c7420613444ee16d6434d51d212705d4e4d23b2e412b52d3f68095ee27"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/index_meta.go:302-308 | internal/datacoord/stats_task_meta.go:98-104 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_meta.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8dfa730a4cec9d31b510448109bcd6abb5b424f1d6637f24bdfc3f2a8a31669"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datacoord/server.go:859-865 | internal/datacoord/server.go:880-886 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/server.go:859\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/server.go"},"region":{"startLine":859}}}],"partialFingerprints":{"codehealthFindingId/v1":"912017d8b0a70edfc4304abbfb52683072561c07190e739f189e83171a02d63e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datanode/compactor/bump_schema_version_compactor.go:573-579 | internal/datanode/index/task_stats.go:293-300 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/bump_schema_version_compactor.go:573\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/bump_schema_version_compactor.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f4e6c9f1e2c9477c6ff26418601f6219c9b1bb4dfba1c57ca32d2869a20fc00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datanode/importv2/task_import.go:179-185 | internal/datanode/importv2/task_preimport.go:154-160 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:179\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"4284f3d057c616e780cef9919ec16d71459e064da0044f241c5cde77ee20003e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/datanode/services.go:663-669 | internal/datanode/services.go:920-926 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/services.go:663\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":663}}}],"partialFingerprints":{"codehealthFindingId/v1":"22701dec532147cd4f7d0eae1a65e87b9caada86c4632bd97be6ab976d79d205"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/client/client.go:67-73 | internal/distributed/querynode/client/client.go:69-76 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/client/client.go:67\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/client/client.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"253df7aa077849049a118b5759c4133aeb639c0d043c064718544b1fb530d3fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:462-468 | internal/distributed/proxy/httpserver/handler_v1.go:668-674 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:462\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":462}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b66f6f27395bd6298287b54a981182baa7c6d8af796ab02ebd7d0406fce10c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:761-767 | internal/distributed/proxy/httpserver/handler_v1.go:880-886 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:761\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0dcb8c423824b5f634fe34c91b4f1a27c6fe2b3a4bf8ef66a17f853bd7399b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:771-777 | internal/distributed/proxy/httpserver/handler_v1.go:890-896 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:771\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"f35f5f072a1d3482dd4957c2e1bc4ed5ec71427fb49a24a7f04481fda9555355"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:794-800 | internal/distributed/proxy/httpserver/handler_v1.go:913-919 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:794\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"35a8adb802f0bf0876c0b5a8241707815675e974c7e7caec1c11dcda4d71776d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:911-917 | internal/distributed/proxy/httpserver/handler_v2.go:2784-2790 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:911\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":911}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb192fa87feef66eceae466795c0d01bf605bc34b0651c55f8ba315de67c88bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:949-955 | internal/distributed/proxy/httpserver/handler_v2.go:1150-1156 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:949\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":949}}}],"partialFingerprints":{"codehealthFindingId/v1":"59a0e32ebbae6220e608c13d8c69ddf3810e108a2c72fafba9f0d433be8fb8e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1606-1612 | internal/distributed/proxy/httpserver/handler_v2.go:1690-1696 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1606\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1606}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aa28938f6f8b9d21e98c5b5ef000167a741436b826efaf78a5b433a9d8154c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2012-2018 | internal/distributed/proxy/httpserver/handler_v2.go:2179-2185 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2012\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2012}}}],"partialFingerprints":{"codehealthFindingId/v1":"69a71702eff1dbaa45b33c73881796024e46fbcf2c0bcd8793ea55a37b15a018"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2600-2606 | internal/distributed/proxy/httpserver/handler_v2.go:2646-2652 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2600\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2600}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb9d9c71aee01516be41a9415b799fe3310a955adade6bee7c4968d8f851141b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2762-2768 | internal/distributed/proxy/httpserver/handler_v2.go:3486-3492 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2762\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2762}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8a2329643e5d2026021fa6cedc7d07c0135931db4ef20bbd08deed73fb1fbce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2835-2841 | internal/distributed/proxy/httpserver/handler_v2.go:2894-2900 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2835\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2835}}}],"partialFingerprints":{"codehealthFindingId/v1":"459e42e6f75f2b8a2b41dbaba51ce473364c05366d59daafc98bcb47bcc91c98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:3540-3546 | internal/distributed/proxy/httpserver/handler_v2.go:3558-3564 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:3540\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":3540}}}],"partialFingerprints":{"codehealthFindingId/v1":"827ff9066ae11782b02b78b8d6797f1e754ee6dbfe16ed9cac83822183fc4143"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:3988-3994 | internal/distributed/proxy/httpserver/handler_v2.go:4035-4041 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:3988\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":3988}}}],"partialFingerprints":{"codehealthFindingId/v1":"3adecb99b86ad87f5ce2237eb3daad0eaa5101aaedac024d909d1138af7eb95a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:557-563 | internal/distributed/proxy/httpserver/utils.go:595-601 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"87af7dcc7802ab6405bdcdcbf6b150167e0b4eb750803f1e861e202e1c66a35f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/flushcommon/syncmgr/pack_writer_v3.go:587-594 | internal/flushcommon/syncmgr/pack_writer_v3.go:704-710 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/pack_writer_v3.go"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bd5218d0ac7fca3ea8b70e34d54123951a95a79998988b4e52c9a8302071674"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:170-177 | internal/kv/etcd/embed_etcd_kv.go:218-224 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"31dacf511b7fdf25aa67265a3444a0d4de921ac6ae6646b0342191fddba66f75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:289-295 | internal/kv/etcd/embed_etcd_kv.go:325-331 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"47512540820deeb0d5dc70471cc203fa262a44e44e479f100115db4d53b0fd4a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/metastore/kv/streamingcoord/kv_catalog.go:169-175 | internal/metastore/kv/streamingcoord/kv_catalog.go:231-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/streamingcoord/kv_catalog.go:169\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/streamingcoord/kv_catalog.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"56a4ea5bf9bba2d0eb8cfb0be56df8fd0eb551b8ba2840540ad26119df9c3b32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/impl.go:385-391 | internal/proxy/impl.go:478-485 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:478\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c5429c0eb0b0b5ce4b5d16a67db2b2af1536c3f80a8a50fc90a62fa376acc60"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/impl.go:1135-1141 | internal/proxy/impl.go:1838-1844 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:1135\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1135}}}],"partialFingerprints":{"codehealthFindingId/v1":"be77a0ba7664dbdfd72c13eec3670109eb5701fc8fb01df89e6b0cca195754bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/impl.go:4233-4239 | internal/proxy/impl.go:4379-4386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:4233\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":4233}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbc128b6f3b21611373ed97e057e13871302006231688b550d7f5e057d794aa0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/meta_cache.go:548-554 | internal/proxy/meta_cache.go:559-565 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/meta_cache.go:548\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/meta_cache.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc2c1a57c4a8cdbe8caf7e1a44471c1a840599029e0b480b35acf4cbada6130b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/query_pipeline.go:269-275 | internal/proxy/query_pipeline.go:316-322 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/query_pipeline.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"323b6ca66e699de26f3520b2e7efccc7c4d6f6c8a598b56ebc79cd297afc569a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/query_pipeline.go:278-284 | internal/proxy/query_pipeline.go:341-347 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/query_pipeline.go:278\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/query_pipeline.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"e555a6064cd0dda47f9ed8714ee7ae77d962c3b3433d04c759e3a56998d18486"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/rate_limit_interceptor.go:111-117 | internal/proxy/rate_limit_interceptor.go:158-164 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/rate_limit_interceptor.go:111\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/rate_limit_interceptor.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f47396e926631f7487e4a9e148e2bf592aea547f57240803eac99601c3bfa5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/search_pipeline.go:2719-2725 | internal/proxy/search_pipeline.go:2763-2769 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_pipeline.go:2719\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":2719}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f6875d64c2c630e3f01cf9547688851762ffdb5073b8e44764915db560ed343"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/search_reduce_util.go:153-159 | internal/proxy/search_reduce_util.go:673-679 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_reduce_util.go:153\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2e473b60103ffdecdcda5e26589491041fe93f28e84b5acd64f617ee0d952b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/task.go:631-637 | internal/proxy/task.go:2276-2282 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task.go:631\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ca3fd0dc71c46b2c2a9b5ce1fb353b6e0b33e2c115131dca6981e69cfe9569b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/proxy/task_query.go:901-907 | internal/proxy/task_search.go:336-343 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_query.go:901\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":901}}}],"partialFingerprints":{"codehealthFindingId/v1":"eef8ac7079871d50a94173c0a0ddf2b4c4a5b87299f4d0e61322e4fb4a80a0ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 54): internal/distributed/mixcoord/client/client.go:213-218 | internal/distributed/mixcoord/client/client.go:225-230 | internal/distributed/mixcoord/client/client.go:249-254 | internal/distributed/mixcoord/client/client.go:260-265 | internal/distributed/mixcoord/client/client.go:328-333 | internal/distributed/mixcoord/client/client.go:339-344 | internal/distributed/mixcoord/client/client.go:361-366 | internal/distributed/mixcoord/client/client.go:372-377 | internal/distributed/mixcoord/client/client.go:383-388 | internal/distributed/mixcoord/client/client.go:395-400 | internal/distributed/mixcoord/client/client.go:419-424 | internal/distributed/mixcoord/client/client.go:500-505 | internal/distributed/mixcoord/client/client.go:536-541 | internal/distributed/mixcoord/client/client.go:548-553 | internal/distributed/mixcoord/client/client.go:560-565 | internal/distributed/mixcoord/client/client.go:572-577 | internal/distributed/mixcoord/client/client.go:630-635 | internal/distributed/mixcoord/client/client.go:652-657 | internal/distributed/mixcoord/client/client.go:663-668 | internal/distributed/mixcoord/client/client.go:674-679 | internal/distributed/mixcoord/client/client.go:685-690 | internal/distributed/mixcoord/client/client.go:718-723 | internal/distributed/mixcoord/client/client.go:757-762 | internal/distributed/mixcoord/client/client.go:836-841 | internal/distributed/mixcoord/client/client.go:1126-1131 | internal/distributed/mixcoord/client/client.go:1291-1296 | internal/distributed/mixcoord/client/client.go:1303-1308 | internal/distributed/mixcoord/client/client.go:1314-1319 | internal/distributed/mixcoord/client/client.go:1595-1600 | internal/distributed/mixcoord/client/client.go:1607-1612 | internal/distributed/mixcoord/client/client.go:1631-1636 | internal/distributed/mixcoord/client/client.go:1643-1648 | internal/distributed/mixcoord/client/client.go:1691-1696 | internal/distributed/mixcoord/client/client.go:1738-1743 | internal/distributed/mixcoord/client/client.go:1749-1754 | internal/distributed/mixcoord/client/client.go:1760-1765 | internal/distributed/mixcoord/client/client.go:1782-1787 | internal/distributed/mixcoord/client/client.go:1793-1798 | internal/distributed/mixcoord/client/client.go:1826-1831 | internal/distributed/mixcoord/client/client.go:1837-1842 | internal/distributed/mixcoord/client/client.go:1881-1886 | internal/distributed/mixcoord/client/client.go:1892-1897 | internal/distributed/mixcoord/client/client.go:1914-1919 | internal/distributed/mixcoord/client/client.go:1925-1930 | internal/distributed/mixcoord/client/client.go:1936-1941 | internal/distributed/mixcoord/client/client.go:1947-1952 | internal/distributed/mixcoord/client/client.go:1958-1963 | internal/distributed/mixcoord/client/client.go:1969-1974 | internal/distributed/mixcoord/client/client.go:2002-2007 | internal/distributed/mixcoord/client/client.go:2013-2018 | internal/distributed/mixcoord/client/client.go:2091-2096 | internal/distributed/mixcoord/client/client.go:2102-2107 | internal/distributed/mixcoord/client/client.go:2192-2197 | internal/distributed/mixcoord/client/client.go:2203-2208 \u2014 all 54 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:213\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"90faceae6a786724b36c842e2c2aba064d24887cc0ab912f62b06f6083ec4215"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 23): internal/distributed/mixcoord/client/client.go:920-925 | internal/distributed/mixcoord/client/client.go:931-936 | internal/distributed/mixcoord/client/client.go:942-947 | internal/distributed/mixcoord/client/client.go:953-958 | internal/distributed/mixcoord/client/client.go:964-969 | internal/distributed/mixcoord/client/client.go:1011-1016 | internal/distributed/mixcoord/client/client.go:1032-1037 | internal/distributed/mixcoord/client/client.go:1053-1058 | internal/distributed/mixcoord/client/client.go:1074-1079 | internal/distributed/mixcoord/client/client.go:1100-1105 | internal/distributed/mixcoord/client/client.go:1144-1149 | internal/distributed/mixcoord/client/client.go:1194-1199 | internal/distributed/mixcoord/client/client.go:1213-1218 | internal/distributed/mixcoord/client/client.go:1267-1272 | internal/distributed/mixcoord/client/client.go:1279-1284 | internal/distributed/mixcoord/client/client.go:2113-2118 | internal/distributed/mixcoord/client/client.go:2124-2129 | internal/distributed/mixcoord/client/client.go:2137-2142 | internal/distributed/mixcoord/client/client.go:2148-2153 | internal/distributed/mixcoord/client/client.go:2159-2164 | internal/distributed/mixcoord/client/client.go:2170-2175 | internal/distributed/mixcoord/client/client.go:2181-2186 | internal/distributed/mixcoord/client/client.go:2214-2219 \u2014 all 23 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:920\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":920}}}],"partialFingerprints":{"codehealthFindingId/v1":"8863b4d2595f6ee39f201c71f079725f09b8e30e58b5952b34521ed9c08c1eee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 21): internal/distributed/mixcoord/client/client.go:189-194 | internal/distributed/mixcoord/client/client.go:237-242 | internal/distributed/mixcoord/client/client.go:272-277 | internal/distributed/mixcoord/client/client.go:284-289 | internal/distributed/mixcoord/client/client.go:305-310 | internal/distributed/mixcoord/client/client.go:350-355 | internal/distributed/mixcoord/client/client.go:431-436 | internal/distributed/mixcoord/client/client.go:443-448 | internal/distributed/mixcoord/client/client.go:455-460 | internal/distributed/mixcoord/client/client.go:512-517 | internal/distributed/mixcoord/client/client.go:584-589 | internal/distributed/mixcoord/client/client.go:596-601 | internal/distributed/mixcoord/client/client.go:641-646 | internal/distributed/mixcoord/client/client.go:696-701 | internal/distributed/mixcoord/client/client.go:707-712 | internal/distributed/mixcoord/client/client.go:729-734 | internal/distributed/mixcoord/client/client.go:1715-1720 | internal/distributed/mixcoord/client/client.go:1804-1809 | internal/distributed/mixcoord/client/client.go:2024-2029 | internal/distributed/mixcoord/client/client.go:2035-2040 | internal/distributed/mixcoord/client/client.go:2069-2074 \u2014 all 21 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:189\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d1124a0ec510f985bc28257e9d1a8d1b9a66cb4e8581e1381c6373760b109f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 13): internal/distributed/mixcoord/client/client.go:1583-1588 | internal/distributed/mixcoord/client/client.go:1619-1624 | internal/distributed/mixcoord/client/client.go:1667-1672 | internal/distributed/mixcoord/client/client.go:1679-1684 | internal/distributed/mixcoord/client/client.go:1727-1732 | internal/distributed/mixcoord/client/client.go:1771-1776 | internal/distributed/mixcoord/client/client.go:1815-1820 | internal/distributed/mixcoord/client/client.go:1848-1853 | internal/distributed/mixcoord/client/client.go:1870-1875 | internal/distributed/mixcoord/client/client.go:1903-1908 | internal/distributed/mixcoord/client/client.go:1991-1996 | internal/distributed/mixcoord/client/client.go:2046-2051 | internal/distributed/mixcoord/client/client.go:2057-2062 \u2014 all 13 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:1583\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":1583}}}],"partialFingerprints":{"codehealthFindingId/v1":"b158ac2a197f4989160b7ca8b164b04746ae1567af4f2e40f1bb807a420b0116"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 8): internal/distributed/proxy/client/client.go:126-131 | internal/distributed/proxy/client/client.go:137-142 | internal/distributed/proxy/client/client.go:148-153 | internal/distributed/proxy/client/client.go:159-164 | internal/distributed/proxy/client/client.go:172-177 | internal/distributed/proxy/client/client.go:184-189 | internal/distributed/proxy/client/client.go:195-200 | internal/distributed/proxy/client/client.go:248-253 \u2014 all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/client/client.go:126\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/client/client.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"55c3ef03b7c1ea6094340daabbd23d6fce7c6e610ba36258414138cc3423d49c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 8): internal/distributed/proxy/httpserver/utils.go:650-655 | internal/distributed/proxy/httpserver/utils.go:664-669 | internal/distributed/proxy/httpserver/utils.go:678-683 | internal/distributed/proxy/httpserver/utils.go:692-697 | internal/distributed/proxy/httpserver/utils.go:706-711 | internal/distributed/proxy/httpserver/utils.go:720-725 | internal/distributed/proxy/httpserver/utils.go:734-739 | internal/distributed/proxy/httpserver/utils.go:748-753 \u2014 all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:650\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"358d2a60f4c44907b2f2bfe696f970a03d7331ab6a8e7cfa525d4e8f71d1ecef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 7): internal/distributed/mixcoord/client/client.go:317-322 | internal/distributed/mixcoord/client/client.go:407-412 | internal/distributed/mixcoord/client/client.go:476-481 | internal/distributed/mixcoord/client/client.go:488-493 | internal/distributed/mixcoord/client/client.go:524-529 | internal/distributed/mixcoord/client/client.go:613-618 | internal/distributed/mixcoord/client/client.go:825-830 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:317\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"74ae59e53695f4d10e1af1571172b5ed0000ab82a559b4c6e66be869694cba7a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 5): internal/distributed/mixcoord/client/client.go:201-206 | internal/distributed/mixcoord/client/client.go:740-745 | internal/distributed/mixcoord/client/client.go:1859-1864 | internal/distributed/mixcoord/client/client.go:1980-1985 | internal/distributed/mixcoord/client/client.go:2080-2085 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:201\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5ae2a65fee11f3eb86733e893d325ce0ddaaa1022df7f9cfd4c47bd7dab400c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 5): internal/distributed/mixcoord/client/client.go:859-865 | internal/distributed/mixcoord/client/client.go:871-877 | internal/distributed/mixcoord/client/client.go:883-889 | internal/distributed/mixcoord/client/client.go:907-913 | internal/distributed/mixcoord/client/client.go:1655-1660 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:859\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":859}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d7b64ca3a0d4a16ced9726d61af9d5930dd792da83ea877aa6d0c3f0167215f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/datacoord/garbage_collector.go:1190-1195 | internal/datacoord/garbage_collector.go:1202-1207 | internal/datacoord/garbage_collector.go:1214-1219 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1190\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1190}}}],"partialFingerprints":{"codehealthFindingId/v1":"31105d62eeb065a4c3066b1ee16b904d97d3cdac0adb7e45b886da753a8e315f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/datacoord/segment_manager.go:320-325 | internal/datacoord/segment_manager.go:579-584 | internal/datacoord/segment_manager.go:703-708 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/segment_manager.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"9414dc4403c650558c14bb78c21dbd6140d27bf3fc727487c4b734885432792d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/distributed/mixcoord/client/client.go:768-773 | internal/distributed/mixcoord/client/client.go:787-792 | internal/distributed/mixcoord/client/client.go:806-811 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/mixcoord/client/client.go:768\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/mixcoord/client/client.go"},"region":{"startLine":768}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd803e0e7adeca66a6ac8571ab734f49102dea66a7e16fe0e49536fc5b1126fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/distributed/proxy/httpserver/utils.go:1663-1668 | internal/distributed/proxy/httpserver/utils.go:1672-1677 | internal/distributed/proxy/httpserver/utils.go:1681-1686 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1663}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea1ccc378440745ffb19696a7414852b32ad3e731c3a064829ac272ee99bec78"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/kv/etcd/etcd_kv.go:385-390 | internal/kv/etcd/etcd_kv.go:407-412 | internal/kv/etcd/etcd_kv.go:612-617 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/etcd_kv.go:385\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec85aaa4ae1c9d8f1b9fd23b8e3578e1577d67c7d4344c9191dc02034b778bc9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/proxy/search_pipeline.go:628-633 | internal/proxy/search_pipeline.go:667-672 | internal/proxy/search_pipeline.go:757-762 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_pipeline.go:628\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":628}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddedc3cf21b5c0c900ac13cfac2d78cb5737599f24ba6c68c465566ddd5598ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): client/column/conversion.go:41-46 | client/column/conversion.go:152-157 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/conversion.go:41\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/conversion.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab478072fdc1f51b44d294080b52252f8649c168cb42d713a53c292520660a26"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): client/column/conversion.go:50-55 | client/column/conversion.go:159-164 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060client/column/conversion.go:50\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"client/column/conversion.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"c37922beb171b61bcbd4bed07b38d1c41c51f815a3cc328746bd4f09461129bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/datacoord/compaction_task_bump_schema_version.go:233-238 | internal/datacoord/compaction_task_l0.go:129-134 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_task_bump_schema_version.go:233\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_task_bump_schema_version.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5868f7a22874d7b608414442ad702376b58dd976d2813f38a5a6433ad0a4868"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/datacoord/import_inspector.go:85-90 | internal/datacoord/import_inspector.go:100-105 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/import_inspector.go:85\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_inspector.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"efbeabf0fd81a01340ff87ad0a90570e5c850778854013edccfeccd1c3d3493c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/datacoord/import_task_import.go:182-187 | internal/datacoord/import_task_preimport.go:142-148 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/import_task_import.go:182\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/import_task_import.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"e00e5e57700f09ca15d2b25637383033c1cc1b207d44f5ad02e0886d7b6c3627"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/datacoord/snapshot_manager.go:745-750 | internal/datacoord/snapshot_manager.go:771-776 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/snapshot_manager.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"05c13631a4c60f09c495d31f0bf61d6fe7f34288e918fd5d3a4d048d26f24e04"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:147-152 | internal/distributed/proxy/httpserver/handler_v1.go:168-173 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:147\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"02e1a9c3226077f3eaf42c0dc04ced6823d3e3ba6d0b2a9c34ec16487252b633"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1434-1439 | internal/distributed/proxy/httpserver/handler_v2.go:1502-1507 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1434\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1434}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f6ef3e2a845a0cda5341241ccd38eef3f88933dd86ef1c352e88bc983ab2e58"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2065-2070 | internal/distributed/proxy/httpserver/handler_v2.go:2237-2242 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2065\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2065}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce93353f76416de9a69b759266e91168747711ed7a291a3a750f63f0c9aa9224"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:2736-2741 | internal/distributed/proxy/httpserver/handler_v2.go:2772-2777 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:2736\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":2736}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6d61a10898b98cf63db967e39e80ad8b2b2da7b3f0545cab695c4030c165bda"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:547-552 | internal/distributed/proxy/httpserver/utils.go:586-591 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"9219e9f983ad74d45f5a8645b3f1860ed5701f99fe05337a8b117208ad96965c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:2344-2349 | internal/distributed/proxy/httpserver/utils.go:2408-2413 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:2344\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":2344}}}],"partialFingerprints":{"codehealthFindingId/v1":"c998b04e73c7cb2fb1bf4dd168980293d9b2b6b5978d342870df3e8d1ab5769d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/flushcommon/syncmgr/meta_writer.go:157-162 | internal/flushcommon/syncmgr/meta_writer.go:277-284 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/syncmgr/meta_writer.go:157\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/syncmgr/meta_writer.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cdee63511142b4343500b48cc4c7f4c460a5f9707c4dce5d0834981d3e8784e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:225-230 | internal/kv/etcd/embed_etcd_kv.go:371-376 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc4baa2ca577868375d91390d543245e1dac4ded24eeeb88b6296553ce7ef567"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:246-251 | internal/kv/etcd/etcd_kv.go:212-217 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"779ed4e87575acddbd6cd69308a1a83b87212904315c661ac61ddbd261950f9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:303-308 | internal/kv/etcd/etcd_kv.go:273-278 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:303\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"3771d13f3078a31f57574d0a740f63c855a7c8c118897b54ad30d38f5df930ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:339-344 | internal/kv/etcd/etcd_kv.go:308-313 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:339\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b78acfea77a54b27cd27e38aa17e021a69c5785494c968abda352e2fdd28520"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/embed_etcd_kv.go:484-490 | internal/kv/etcd/etcd_kv.go:478-483 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/embed_etcd_kv.go:484\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/embed_etcd_kv.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"281456525871ecfc105072a894695852dd38e5e88f0e4a203751ddc235060903"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:190-195 | internal/kv/etcd/etcd_kv.go:338-343 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"46a5f4f6f5a875cd7bb02e1bab82439b9c1f1cb5f0f121c34468b689a2e562af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:643-648 | internal/kv/etcd/etcd_kv.go:659-664 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"d870fe1705f9cf18fdaa606d70b944b44343043dbb8f8edf1e2a14d4ba8c3a08"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:748-753 | internal/kv/tikv/txn_tikv.go:793-798 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/etcd_kv.go:748\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"9abee36ced38d185ff530a3ab39ed82702b6f056bf71cda8b7010aa62f3cf2ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:762-767 | internal/kv/tikv/txn_tikv.go:814-819 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/etcd_kv.go:762\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":762}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c50b02b723c6c60a8f92c026201c0a8cf301ed4ab1f48eadbf0dbb8c1ac0e53"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/kv/tikv/txn_tikv.go:495-500 | internal/kv/tikv/txn_tikv.go:546-551 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/tikv/txn_tikv.go:495\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/tikv/txn_tikv.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7a0b054f63bcc5ca52ed5cf261f91b524329d2670f83eb5c7b1765031836687"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/metastore/kv/querycoord/kv_catalog.go:143-148 | internal/metastore/kv/rootcoord/kv_catalog.go:1029-1034 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/querycoord/kv_catalog.go:143\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/querycoord/kv_catalog.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c5315f991964e7a4790873bac8467f0cc13f6139b5bd5482a38cd1a88b21993"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/metastore/kv/rootcoord/kv_catalog.go:1705-1710 | internal/metastore/kv/rootcoord/kv_catalog.go:2023-2028 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/rootcoord/kv_catalog.go"},"region":{"startLine":1705}}}],"partialFingerprints":{"codehealthFindingId/v1":"7766a2da5e03560c4fb82dd75cfd065eab7ee621814cbfee2a261dd67c52b4f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/accesslog/info/grpc_info.go:349-354 | internal/proxy/accesslog/info/restful_info.go:284-289 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/accesslog/info/grpc_info.go:349\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/grpc_info.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0c7bbcddc572db4eddab548fa9f2aba5d8025fe747607b2049b937e0e28ccec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/accesslog/info/grpc_info.go:360-365 | internal/proxy/accesslog/info/restful_info.go:295-300 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/accesslog/info/grpc_info.go:360\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/accesslog/info/grpc_info.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa246b7c56dbb0f10d04e39f3352f393310b3ae4fce59075b69ae9815a3dbed7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/impl.go:904-910 | internal/proxy/impl.go:964-969 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":904}}}],"partialFingerprints":{"codehealthFindingId/v1":"8570c804ce8c4b126b0b08394ec846244c55fc442ef93553e16620ca98af7ded"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/impl.go:5505-5510 | internal/proxy/impl.go:5565-5570 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":5505}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aa47865643d3401d5783829beea5faf4852028e8bc7afc586f3f40517c02df9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/search_reduce_util.go:251-256 | internal/proxy/search_reduce_util.go:375-380 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"64aeeaa06f0acbe01a05e585f7ed4b8cf74d64ec615c3c0d5d312fd410f21726"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/task.go:3037-3042 | internal/proxy/task.go:3074-3079 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":3037}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e3a89faff3d0f62be53e9012a49d3887a17448f67fcd2cd8c01705562bb0c43"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/proxy/task_query.go:643-648 | internal/proxy/task_search.go:145-150 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_query.go:643\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_query.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"581bcf6bc8d913700d0c9a1bdd6069f78a485338770b919fabaab01a15a08d2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/distributed/proxy/httpserver/handler_v1.go:1033-1037 | internal/distributed/proxy/httpserver/handler_v2.go:2063-2067 | internal/distributed/proxy/httpserver/handler_v2.go:2235-2239 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:1033\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":1033}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f9604c5d39cbc94cfe893f68c702145b5e4fd5b5269e4d3cd0f9e3650131659"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/distributed/proxy/httpserver/handler_v2.go:3913-3917 | internal/distributed/proxy/httpserver/handler_v2.go:3985-3989 | internal/distributed/proxy/httpserver/handler_v2.go:4032-4036 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":3913}}}],"partialFingerprints":{"codehealthFindingId/v1":"f32136295537e8e236ea6674bfcd0d809a21fbe9a99d7bc6ccdd3ab316a7c427"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/proxy/impl.go:6522-6526 | internal/proxy/impl.go:6549-6553 | internal/proxy/impl.go:6602-6606 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/impl.go:6522\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":6522}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8aeeb7b1700c283dde8e075bea1682f16b5dc652fa494ee7499ffab90058efc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datacoord/broker/coordinator_broker.go:226-230 | internal/datacoord/broker/coordinator_broker.go:253-257 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/broker/coordinator_broker.go:226\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/broker/coordinator_broker.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe892e587537c411d2ea5f7961b3f3ab4c59337443c5e8479ab6c0247c0a8c2d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datacoord/compaction_inspector.go:489-493 | internal/datacoord/compaction_inspector.go:505-509 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/compaction_inspector.go:489\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/compaction_inspector.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bd16bfa44744e10ed8ffb239c0c169a77fa6977dd65f8f30698efd74b6d97f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datacoord/garbage_collector.go:1854-1858 | internal/datacoord/garbage_collector.go:1976-1980 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/garbage_collector.go:1854\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/garbage_collector.go"},"region":{"startLine":1854}}}],"partialFingerprints":{"codehealthFindingId/v1":"c537196bbde38038b4418af63d7798c71b37224ca1e31df0fc453a79e0f5b301"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datacoord/index_service.go:559-563 | internal/datacoord/index_service.go:816-820 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/index_service.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab8ec3eb68001643d4da15d3fc1d7a2211b6267a32955d91498bb940281be5f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datacoord/meta.go:3362-3366 | internal/datacoord/meta.go:3580-3584 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datacoord/meta.go:3362\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datacoord/meta.go"},"region":{"startLine":3362}}}],"partialFingerprints":{"codehealthFindingId/v1":"0005bc7cb195551eb7c079fa1a4ff522ed68b1f49c5ea3eb66615a9bb13cea6c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datanode/compactor/mix_compactor.go:546-550 | internal/datanode/compactor/sort_compaction.go:488-492 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/compactor/mix_compactor.go:546\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/compactor/mix_compactor.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"3570617ff3746ba75e3fe6c5ed0b55de1339ed10b7877e2668953e5e2bdea8f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datanode/importv2/task_import.go:188-192 | internal/datanode/importv2/task_preimport.go:163-167 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/importv2/task_import.go:188\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/importv2/task_import.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"e59e367ed54656bb53979f7e38ff807264f2c5b86d2a3e163ee43433c286747b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/datanode/services.go:432-436 | internal/datanode/services.go:478-482 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/datanode/services.go:432\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/services.go"},"region":{"startLine":432}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc1329eaab35c36ae72e82ee94348076fe05d042bcec7f78c12f678906228a79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:635-639 | internal/distributed/proxy/httpserver/handler_v2.go:1508-1512 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:635\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"db66debafdf1524498d5b740df539bcd78592782e349a0aeae986bfd41c2d54d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:681-685 | internal/distributed/proxy/httpserver/handler_v2.go:1551-1555 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:681\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"5df6b01d2b1863c6cb0a2bf4ef4aa0c2ff623b6e6a0d3e87d2eb5ffeb65b9e9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:875-879 | internal/distributed/proxy/httpserver/handler_v2.go:1674-1678 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:875\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"615fcde2a454e1ab7072d88167a9bddb3f79f84de396097b9a34fa7e03cb1d4d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v1.go:888-892 | internal/distributed/proxy/httpserver/handler_v2.go:1688-1692 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v1.go:888\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v1.go"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"20e02b2a0373072b2af592b7e58c8a48edfe45e33f4e156b648c0b2185071d22"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/handler_v2.go:1963-1967 | internal/distributed/proxy/httpserver/handler_v2.go:2218-2222 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/handler_v2.go:1963\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1963}}}],"partialFingerprints":{"codehealthFindingId/v1":"09957319987df14e33b0394f055cde2b55c722e55fb059f395dae79773f781e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:1981-1985 | internal/distributed/proxy/httpserver/utils.go:1991-1995 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:1981\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1981}}}],"partialFingerprints":{"codehealthFindingId/v1":"6249aeb0ef94f8505c50060f6a984997c28e99ca65ff75c96bb4a24bf93f371b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/distributed/proxy/httpserver/utils.go:3095-3099 | internal/proxy/rate_limit_interceptor.go:57-61 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/distributed/proxy/httpserver/utils.go:3095\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":3095}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8e292e8cd348043ad3beffdaec44ab4e7c0b54639b9984c9e25b47a95d6d245"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/flushcommon/writebuffer/write_buffer.go:963-967 | internal/flushcommon/writebuffer/write_buffer.go:1674-1678 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/flushcommon/writebuffer/write_buffer.go:963\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/flushcommon/writebuffer/write_buffer.go"},"region":{"startLine":963}}}],"partialFingerprints":{"codehealthFindingId/v1":"7465c45f7e0d8ea1d797009de1685cf51f30c3a56a9cf5efd78e0e5bc8bac7bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/kv/etcd/etcd_kv.go:743-747 | internal/kv/tikv/txn_tikv.go:788-792 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/kv/etcd/etcd_kv.go:743\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/kv/etcd/etcd_kv.go"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e66578b608e53e38c9c6812d72233f79b007b04a388847636b371d0f259b17a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/metastore/kv/datacoord/kv_catalog.go:1178-1182 | internal/metastore/kv/rootcoord/kv_catalog.go:2274-2278 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/metastore/kv/datacoord/kv_catalog.go:1178\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/metastore/kv/datacoord/kv_catalog.go"},"region":{"startLine":1178}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0bff9dd1a033a331a23a9aaa17f1170e799fc476137512ca809098c2073463b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/proxy/pipeline_trace.go:100-104 | internal/proxy/pipeline_trace.go:126-130 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/pipeline_trace.go:100\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/pipeline_trace.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb2ea69a793db3b38a9d2af3c7c432f6dca24180d2556b57241f773b3d5539c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/proxy/search_reduce_util.go:258-262 | internal/proxy/search_reduce_util.go:382-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/search_reduce_util.go:258\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_reduce_util.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"17574e19da75971a0c200585c7eb486da5019de0aa446f00ec31637c8372036d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/proxy/task.go:910-914 | internal/proxy/task.go:1030-1034 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task.go:910\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":910}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f1a86f58f998862b3480e14d8bf9f5f9994d28c56b36ac9034a6055ed9044f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/proxy/task_search.go:493-498 | internal/proxy/task_search.go:879-883 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"3807ac3de27197cbb7c0e2303d87c3491aeae4fdc6e715776360299f1c28b137"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/proxy/task_search.go:513-517 | internal/proxy/task_search.go:975-979 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/proxy/task_search.go:513\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d4f600c171475b4e90796ede42433c799f1fef87d61bfd28602705ab60b033f"}},{"ruleId":"D13","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c0103eaee9addcf342afaa430b5e734fedfcb10e3dd9254140830fe8062c5882"},"taxa":[{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D13","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"26b1c10cce1dedc5f7acee716b5f46143864307b9529ea658c22e1d82c289447"},"taxa":[{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D13","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1d760d36ad53ffae071df8e21da9e4459d25bd6c1c5717a86c63026cf4c834d8"},"taxa":[{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: pkg/util/paramtable/component_param.go: pkg/util/paramtable/component_param.go changed 52 times in last 90 days, max complexity 46. 10 of those changes were fix/bug commits, and the other 42 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/paramtable/component_param.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8941f2bae4e8511f6eb8c6e83e79233de101e5d42a203601ca467d0552257abf"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/distributed/proxy/httpserver/handler_v2.go: internal/distributed/proxy/httpserver/handler_v2.go changed 27 times in last 90 days, max complexity 66. 8 of those changes were fix/bug commits, and the other 19 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/handler_v2.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8964882afa07f1922de4df150d34d7dca4fb4ce182d160fa81a92dcf5e61d68a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/search_pipeline.go: internal/proxy/search_pipeline.go changed 15 times in last 90 days, max complexity 111. 7 of those changes were fix/bug commits, and the other 8 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/search_pipeline.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fa5e65b17431d58604cfdb089645b69562afa3cb1e32c338e415a9c9e253843"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/util.go: internal/proxy/util.go changed 22 times in last 90 days, max complexity 74. 6 of those changes were fix/bug commits, and the other 16 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/util.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0c34b043ca0214713114f3cdb29bc3d6a4a344c31fa20d5c3c60f90dd1e25cb"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: pkg/util/typeutil/schema.go: pkg/util/typeutil/schema.go changed 16 times in last 90 days, max complexity 99. 4 of those changes were fix/bug commits, and the other 12 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/typeutil/schema.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5186faceb7434cb1749256fad8a3ab1ceb4ebcbbbb090ef71453b0b4cb69959f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/distributed/proxy/httpserver/utils.go: internal/distributed/proxy/httpserver/utils.go changed 12 times in last 90 days, max complexity 131. 4 of those changes were fix/bug commits, and the other 8 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/distributed/proxy/httpserver/utils.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4385b16697accf982edd562e6c51c2a804637c9218b519a05c222e6160d0ba22"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/task.go: internal/proxy/task.go changed 25 times in last 90 days, max complexity 56. 5 of those changes were fix/bug commits, and the other 20 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"15c69dfb9cc67fb366d90b91d22cc074a006748c98ce21886f67e122b5903e80"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/task_search.go: internal/proxy/task_search.go changed 22 times in last 90 days, max complexity 63. 9 of those changes were fix/bug commits, and the other 13 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_search.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fafa5b13e23f2a53a161366faf1016c4ba656ec95c1c4e5c1e42682627e2fa26"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/task_index.go: internal/proxy/task_index.go changed 7 times in last 90 days, max complexity 120. 1 of those changes was a fix/bug commit, and the other 6 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/task_index.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f3b7a00d1d5bd009308559ff8fef50a1a941bc6ae8254ac8d2d549ede49f118"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/proxy/impl.go: internal/proxy/impl.go changed 22 times in last 90 days, max complexity 35. 7 of those changes were fix/bug commits, and the other 15 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/proxy/impl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"56aa26473d3b7947d1e56854d07401802ed920a9c561dbdf8d9b502360eaaab1"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 42 significant file(s) lose their only recent owner: internal/streamingcoord/server/balancer/balancer_impl.go, internal/streamingnode/server/wal/adaptor/scanner_switchable.go, internal/distributed/streaming/forward.go, pkg/streaming/util/message/message.go, internal/streamingnode/client/handler/producer/producer_impl.go, internal/streamingnode/client/manager/manager_client_impl.go, pkg/streaming/util/message/marshal_log_object.go, internal/coordinator/restful_replica.go (\u002B34 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"b0a6ce8487a30701fa09a6fd4c2e4bc4b37085d1ffed54d37b29ccdb638db0a8"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #2: If anonymized user #2 becomes unavailable, 9 significant file(s) lose their only recent owner: internal/querynodev2/tasks/heap_merge_reduce.go, internal/querynodev2/tasks/l0_function_chain.go, internal/proxy/function_chain_validator.go, internal/util/segcore/boost_score.go, internal/util/segcore/search_result_arrow.go, internal/querynodev2/tasks/boost_score.go, internal/querynodev2/tasks/merge_entry.go, internal/util/credentials/credentials.go (\u002B1 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"3cb0f29d20a0dbee86df222fe7f82d62280d22cea84c70e22e36ab2cc6dc14bc"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #3: If anonymized user #3 becomes unavailable, 8 significant file(s) lose their only recent owner: client/milvusclient/iterator.go, internal/proxy/shardclient/look_aside_balancer.go, client/milvusclient/maintenance.go, client/milvusclient/resource_group.go, internal/metastore/kv/rootcoord/legacy_tombstone_gc.go, client/milvusclient/index.go, client/milvusclient/rbac_v2.go, client/milvusclient/partition.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"42f16c8cee4714ce715bc6ce225241f067d7d94fe14ffaec730081ed1ee9b085"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #4: If anonymized user #4 becomes unavailable, 7 significant file(s) lose their only recent owner: tools/mgit.py, internal/proxy/telemetry_models.go, client/index/gpu.go, pkg/config/source.go, internal/streamingnode/server/walmanager/wal_state_pair.go, internal/parser/planparserv2/pool.go, internal/datanode/pool_stats.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"b28d1f59ba6e505be28fa59bdb6f2b24dc0235e8d8c67570a9144bf7393e3c82"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #5: If anonymized user #5 becomes unavailable, 5 significant file(s) lose their only recent owner: internal/storagev2/packed/explore_ffi.go, internal/storagev2/packed/utils.go, client/milvusclient/snapshot_options.go, internal/datacoord/copy_segment_inspector.go, internal/storagev2/packed/ffi_sample.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"687ca8459c27976a3265c1351076488d1cfb6c1d7e8cb3d7abe72d44f1d4b287"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #6: If anonymized user #6 becomes unavailable, 4 significant file(s) lose their only recent owner: internal/datacoord/import_checker.go, pkg/util/replicateutil/config_validator.go, pkg/metrics/cdc_metrics.go, internal/util/importutilv2/common/mock_reader.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"e781d7b73f487ece434c42676def9a6b8c23e4522f1e719c2e9608ac805547c1"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #7: If anonymized user #7 becomes unavailable, 3 significant file(s) lose their only recent owner: internal/util/function/manager.go, internal/util/analyzer/canalyzer/c_analyzer_factory.go, internal/util/function/local_store.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"f963f80ab16757022fa7017911ee5cb102332dfc078dc93c43f947dc7e1fb751"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #8: If anonymized user #8 becomes unavailable, 3 significant file(s) lose their only recent owner: internal/parser/planparserv2/rewriter/range.go, internal/proxy/struct_hybrid_search.go, internal/parser/planparserv2/cwrapper/wrapper.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"55e5f78240eb8cd60978d3fc5e218bf6d13ca56b9770550798b09d562b21f0a4"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #9: If anonymized user #9 becomes unavailable, 3 significant file(s) lose their only recent owner: internal/datanode/compactor/record_materializer.go, internal/proxy/search_agg/context_builder.go, internal/proxy/search_agg/types.go. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0dc94ceedf5b97d5b29292c6348c9d78b807fe47a9e1233e9438731d2858d5ef"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 10 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold \u2014 folded into the bus-factor score and metrics (97 single-owned of 1257 analysed files in total, counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first). They are anonymized user #10 (2 file(s)), anonymized user #11 (2 file(s)), anonymized user #12 (2 file(s)), anonymized user #13 (1 file(s)), anonymized user #14 (1 file(s)), anonymized user #15 (1 file(s)) (\u002B4 more) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D19","level":"note","message":{"text":"The Milvus banner links to milvus.io/docs/install_standalone-docker.md, but there is no standalone Docker install guide for readers who prefer a self-contained build.: Add a short standalone Docker quickstart section (build and run) under What is Milvus? or the Quickstart heading so users can choose their preferred deployment."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"README.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfe7ef11935c1d139ad2b6ed39c988502eddbf91ee5707a73f3d9ee7d68ecb81"}},{"ruleId":"D20","level":"warning","message":{"text":"Decision and consequences are present but trade-offs (e.g., etcd lease/lease timeout handling, index deletion consistency with MetaTable) are not stated: Add a Consequences section covering the trade-offs of relying on etcd leases for discovery vs. eventual-consistency recovery after power loss, and how IndexCoord handles lease expiration and task rescheduling"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/20210731-index_design.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b66da8b72cd8bced1db41649c6f3047468378349bda3465b4557e7b5448fee8f"}},{"ruleId":"D20","level":"warning","message":{"text":"Context/problem (the CreateCollection flow\u0027s motivation and why it matters) is absent in favor of only the execution path with proto code; consequences/trade-offs are not present: Add a Context section explaining what a Collection represents (data set vs table), why its existence/importance justifies this DML path, and any prior pain points. Add Consequences covering trade-offs such as the cost of waiting on WaitToFinish or the impact of schema mutation constraints"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/20211217-milvus_create_collection.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d41914e3780cb433c0a54d73c8b700394ced4ebbe478872acaa291235fef23bf"}},{"ruleId":"D20","level":"warning","message":{"text":"No context/problem and no consequences/trade-offs; the body is a stub of only one major interface with data format and a sequence diagram: Add a Context section explaining why vector search matters (e.g. similarity search for embeddings) and a Consequences section covering trade-offs such as accuracy vs efficiency, GPU-to-CPU copy cost, and the role of heterogeneous support"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/20211223-knowhere_design.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"15451e0622a57a0fcbf47958ebe960c674a798e367a7f778b404e140477bb53e"}},{"ruleId":"D20","level":"warning","message":{"text":"Context/problem and consequences/trade-offs are absent from the visible text: Add a Context section explaining why CDC replication is needed (real-time data sync between clusters), an alternative model or trade-off for non-standby setups, and a Consequences section covering operational complexity, resource cost, and failover behavior"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/cdc/user_docs/02-cdc-replication-quick-start.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1c266ec7eb58bab1f720971da6a3c1132ced214ddb641d7b03bd9c9ede87e80"}},{"ruleId":"D20","level":"warning","message":{"text":"No context/problem motivating segcore search and no consequences/trade-offs: Add a Context section explaining why segcore is needed (vector query performance) and a Consequences section covering trade-offs like higher latency vs. full-text search"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/segcore/Search.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e441bab9c8e9fc88a37705581ddd2fd4ac719dbedd15f704057549d4b16f4c54"}},{"ruleId":"D20","level":"warning","message":{"text":"No context/problem and no explicit decision; only a glossary documenting schema types: Convert the glossary into an ADR describing the data-modeling requirements (e.g. concurrent insertion/query on Segments) and the decision that Schema defines vector\u003CFieldMeta\u003E with metric_type, plus its consequences"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/segcore/basic_types.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b283457c313b6766ee35badad509f31d1d08067b8aade280f29bb269746d0bf9"}},{"ruleId":"D20","level":"warning","message":{"text":"No context/problem and no consequences/trade-offs; only a list of scripts with installation/prerequisites is present: Add the problem motivating script/tooling (e.g. consistent formatting across contributors) and the consequences (dependency on clang-format/clang-15, CI cost)"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/segcore/scripts_and_tools.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7996bd34881e21f19347c60f5f8cd41f8abce364ebaeadf8afda0c4934efb956"}},{"ruleId":"D20","level":"warning","message":{"text":"No context/problem and no consequences/trade-offs; the document is a class/interface reference listing only types, interfaces, and implementation classes: Add a Context section explaining why segments are split into growing and sealed (dynamic insert vs index loading) and a Consequences section on trade-offs such as code duplication or loss of shared internal logic"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/segcore/segment_overview.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4acdea640539be4eeea97bb82abbfd97369d26acfe69db8f9ca4951b0832bda1"}},{"ruleId":"D20","level":"warning","message":{"text":"Decision and consequences fall below the clip marker; context/problem is mostly code listing with no rationale or trade-offs: Add a Context section explaining why visitors must execute on ANNS nodes only (current scope) and the consequences of restricting new visitors to this subset"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/design-docs/design_docs/segcore/visitor.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9349d2eec45fe5950f5170bcca85653a3a1c7f383ccf0be71a2f415a8a0bc14b"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7fe5bc2cefe96eadcdbf706b817b9f91679f20d1b75ee9024f7586370980b5a9"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"39a2e48cc11c6e47a7a3ce543a6af9e76057d52f4861555786f39d1052890901"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"5853de2a0268446ee303c2c49dd849d1a27f762c09ae3662dddbc6df89a21862"}},{"ruleId":"D28","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3cdfd7beb31b791ae18dcb425e21eb157c842e7bbcd522cc330573c1a6538db1"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"49b4a6d657cffc413e486a70503e53db2d40b338b58f191e0e68394ab379d006"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b92c0b35221f541619d9432b2d645d9665c12c05fbc2b3a3778f912ce31398f1"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"bf6da398218aaa6f4d695ed02418671af2e7950f9d34b887c089835f4a5306b0"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f24c07c097f914f35fed63802e702c4079213e6f1360f0058433257a04fc7041"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"95b0183cf8a5ea9c3358ac0240dab93a8759025a98ff501ace8f415ac6a3d24d"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"38517643813af0e16ecc3a2ffa1c5107b06438a7a6b04b84b5790d84f6e2af91"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1b7b2b4935442fd49e40013462aac6fc888107c4e379cd200ce27cac8fd6ea51"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"693787324ee9db269699f82932f6c59d46855ea2e812351a90a2d215c0fda407"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c4c4ef5cfe488e7c592c11a2fa17510c01d7c0923bba97b0558226285fe4d003"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f3b6b10e3a369e6eda5f1099d91bd647d3e7dfe69f4b17410c84ad4cb85e9e58"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"284aca0e75012a2fa999b38391e7f657ec13bec0ca8892e0b48923b07e727267"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"5211d057ddfefcda5fa5aae863f9d8d17e5d9cebd9a3fb62b9d474cc701f8f83"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6c4a1a0d8c64af530e78c6ca215ed0f4d289dd2340adea4019a50d6463207cae"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"da0198c63950efe3b9332731d1392aa937e1e0fcfbca8be9011479751cdd693d"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"576f3832a7473a5fe69bd68ad1baaf2f523f42ed2cf5d189333666ad0fb7151a"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"5dd6923a9efbaee441b822f233cc687f4c3edbd0d450a0a240f63f4ebf76a3af"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"89c39d87ccf02c258fa0bd913330f8048882b4d6374c3efbfd091aee45ef9e51"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"afc6207dc4664dac2b20144880e6750438cf8ca28d7fad31f2bcee9786dd2f02"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"710b7b83bfdaf4d52755e7e0a3bd4ae781e0757dfff49de797687f24cbad65f7"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1d681aeb8ffe59a3a808bfcaa8d574e0d1cf2b6d7c742c59682ac2c384e388d6"}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"5596df9eb23c123bd6e6c4687beefc0d231d7ffbd8f37ce5134ff64dfec390b9"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ba896aa566e2e40df790d8a4e4c82f68c6225c0aff6e6815546c98073ffcd386"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"393043b115edf423c1dc63a7c33984f2a338790d33658fbdcce254bbb01d6ffc"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f19c427553a4efcffd20fd94819e870cb5b3027ba64cdd2f32be78c696bb1922"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"077fb2687a5a29472a57f0edfb38ee05d4a1e2db9ac0971f04ff6fbe680af441"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"080b06e700098ffd67e23b3f52b74487c7e3c020b57dfe71dd8d43465cff46e9"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7118a4a36b2bfab92c5c4886d360d288c4ec3dd69dfccc05b33ec8e1da300a18"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e49784d8fb9bca2cff8297f00c39e6680d6c787b93416a889fd569b552023d61"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"109c25832cd4ab92def8ee3c692b6905962885a1f712c927b1953665c9226a4f"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1f09d8899397292f30ec322271caf2c368774a535fb720b5d140e9c50485453f"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"814541a2d0566263e83464b127a6489a119373497edb7d89913c33c05a59cfb5"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"167403172a59ecf62203e275c8f1872297b88cd41f7af8f70380830071716e1b"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e921d5aeb73b15fa62da18c7ca7a2ec6b42039cc1fc149de435460dbd7798072"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"64765b7b7a34ba8cbb1a35214c778021e70397f270d81319e6d3c76d1e33d5d4"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"79ac6c5c62c18bb00d0b3c4f9eff550e53953655dd63d9a17f2f0f8a28c04a4a"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"40b0a8472a09f1a519e2324aa41d372b706c4f56eb0ccc9472ea2ea21e04b576"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"38c39ee0f8d99e73ebe0d9b589a00db66ab45d32eaded8b8f2ccff973bef9205"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3d7a76fc188d7d8c9b67c2f2e9a8acb7181b3d84f6354ad67a179f81d35c3e77"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d986e2510f732c2f25aa323e2df83226bebc032f3e4aa3c66dc2ab7c86efbe85"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"802fc0ee946a24b39fea845be0a4153cbb6a1678c9fca37dbfef16c146eeafb6"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"838b7dfb0d00548e2e74e5df2345bca5fb4bf5a8909af25073a66363564b9507"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8fba4177e41eebd1fea21569ec9b5cb1bc9a458e3dfccde8086ae28126151717"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8f2926ec9453d9057490973077a85c947cf6c5fcdc4029e690ffe5dd1ae668ad"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8d636e81feb4138aadb869a2fff0502dec762fabeedaf46ae04f1287987f8a85"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"76e78eeb02131fe8d5a6f19a3b0a6a3245faff55735885ee715019d90f040de6"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6284c0456fb69071fa5c9bc4f906da08d4cfc5084c4335a58f9866906a44138e"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/storage/field_value.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c97bdb4a8401aa53bc08eb5e955f7f3eed194a9a06ff50fd6743a319bd217786"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/milvus/mck.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec028aa25869c183518292015c6cf825d7b385fe453db42a8bf1ba0900639c06"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 44 smaller file(s) also have no living knowledge \u2014 folded into the freshness score and metrics rather than listed individually (46 orphaned of 1260 analysed files in total, counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first)."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ce861fd78f6935114d3a342cb90ad25870f984e1042954fcbbe27c0e23be3658"}},{"ruleId":"D35","level":"error","message":{"text":"Boundary-crossing change coupling: init_segcore.go \u2194 component_param.go: \u0060internal/datanode/index/init_segcore.go\u0060 (context internal) and \u0060pkg/util/paramtable/component_param.go\u0060 (context pkg) sit in DIFFERENT parts of the tree yet change together 64% of the time (7 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) \u2014 the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can\u0027t see."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/datanode/index/init_segcore.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c166530e0183e55e6b20b2d9a068440306ac85aa5cf8fba9aa66df6516fc06c"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: quota_metric.go \u2194 quota_param.go: \u0060pkg/util/metricsinfo/quota_metric.go\u0060 and \u0060pkg/util/paramtable/quota_param.go\u0060 change together 80% of the time (8 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) with no explicit dependency \u2014 the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE \u2014 the registration is the link, and it is meant not to be an import \u2014 and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pkg/util/metricsinfo/quota_metric.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cac2c06327ed9878f459e55bf1d284cf7d7ebb19af78911d14b8f38dc762b31"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1b213f6eedd4b140d0bc37bdf1496f72811a643f34064f12518b32e9e83bcfc7"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0e17f71490e4d120a48b2b2881ab866c93b272bef2febb673a3e8e42b2c288ab"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"eb00976a698a5d68999b7ee6d27206fd374e916853e7ff1ead5eed42386f043f"}},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"90f83b4fa27db32740afe9540c905f3c0499caed87f61049a8a903ecc95b41c3"}},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0752d0df7434000fcabf1048e2de30a7a1a8b982b3db9a19898c4dec199856b4"}},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d657599f6f99da1927d3377533dfc0888b34c4d84aa7d5579841fd72d0e39bce"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"73aec212f0ec31f297dd64e0bc4466846fff7ddeaebc0ddb6930f2e6d5c8ede5"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b24a92c0a3847dbbac92c32259cf4e3a5ef46beaa40ad9a32aec2245493e188b"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e6be940f2d4e5a4bd2ab8f0900bae07f6c2f6f18c9d1360043df8098a1f5f7e2"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"45c819584ca41131212530475d5e26a97c7e68022e821acae7cbed378bc77f8d"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f5e8e2b271c5a964660f1fb42137ad23f6cc3c9d14059bf15eb1f167e39dbd23"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"995bd72ac96c49b9f9674cd8900950d51884c94b2c51985433af24662c8bbb2a"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ffd8a279cbcdbf09edd9dca992332803cc5b723fb5066927473bc9bfd827c358"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"803a4fb5508171328935afdec49d85709bfa10461af8abdf87347cde0c9de1bc"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9742e2efa4c190cb75c7ae6d4e81a49b9662cbc141879020f168158886f57fe5"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0e5c47a31fc85035f76e77b8c8df7e22558e2390a8f52f0a355d97e8530198e8"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6d716c5abe187edcf36d83ee4605b641791ac1e710e9dac1f219a8885b466496"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b05d2ecc8104fc8f569f8753e75ad83aa043174030e4164218638c8d09631349"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b307d1daa2d3e0840d5d1650577e742a5c4806d471ef5cf2597034d133fd2f8b"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a4846a802f1ac58dbf440db433f242896f4dd87071282818ca6ebdfb8fc3de17"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"60e93c57b30c43d8faaad12a492868b7396a4e49b1e819baa5ca404add10b585"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"5de4fe91c347d0fb1714fc6b7aaad8f4d86513bbcb09b3f0cf650b2542278f2f"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f8def41d59d0070c57655149949124560a3f403d88983f134b04687d53632f3d"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0811f35d149775324928c4c5295940e432e3939f1c83d382ccaaa56d236cfa9e"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a4c9b88a0e8c51a96559c1e6a56dddcb623279cce7eabb20389342806d4e9d8a"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a5615491030b1c2d797614b7ea635bb9e57f31e8c95cf89d337308fa89f3b2f6"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a7e5781431801afd1ab29f29cd99861e773736d37d6849daf000dbaad429e6de"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8ead8a0bfc9b9da9db14641c9be98737c3cc739ef463109c8173ef4662833004"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c3101d36131a52584dde37b042bdfe9fc6a1d1edad6398c91ef166385743b007"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fd25356eea489deb4f8233657abd033ceba37b38c0e02426be9a5fd3d7e3a23c"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"aeec9931ef08337c6205bf10ebe110ddf1ae33983515f7088e01d537c7a36e40"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"4100517787f0303a49e2f54bdc7bf63ef08c7db77ab893c5ed3df3387fb1fa26"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c8e6740321a9758be2667eea6842293616ba35402441f8df0a0ca2a8f6a5fa68"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"50c379534161bb30611d421e82af3666b891a67b9a6a35df5a4fc4b4977e653b"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"2a69eede9507a4861ba3838a5b0ce6db57013488a8c714d81c6394cae4926960"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"94e02eea5764fec7c68881dfaf08794994cb5f5915475658189d0ffad65d6e22"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d7f45ae1380a8f67430da26fc42d784fb3b2ce836b43cd87bab3e822ed87c91c"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7d0ae42b0bc15bd07a3e2f7143cc12ce5b36dac682be13f4145fc874702a0a6d"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"231ad4dc838e4a2768e6f7a1e67ca410b16632a9e046ea516d551978147d4308"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"dc8eccc0797e2b9654a53ed13d1c6693580f9bf5f45414109e3b9a765c950096"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f5410e01994ba2597d4c5463c53899afb46b4dbe168a60b8d259f2597f7e5820"}},{"ruleId":"D40","level":"note","message":{"text":"No network policy: No Kubernetes NetworkPolicy (or Cilium policy) found. Without one, every pod can talk to every other pod and reach out to the internet by default. Add a default-deny policy and open only the flows you need."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"295828650a2aaa1b03ae9b32ae6843a0c38011e5a70b1926442c4fa7187de5f0"}},{"ruleId":"D41","level":"note","message":{"text":"No seccomp profile: Workloads do not set a seccomp profile (RuntimeDefault or a Localhost profile). Seccomp blocks the syscalls a container never needs, shrinking the kernel attack surface a container escape would use."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"3f418e9f76c3ac90484e0e94a454bfe9b08e914e1cdd218e1fc9e3b261a3bf6e"}},{"ruleId":"D41","level":"note","message":{"text":"No AppArmor/SELinux confinement: Workloads declare no AppArmor or SELinux profile. A mandatory-access-control profile confines what a compromised container can touch on the host, complementing seccomp\u0027s syscall filter."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"e83fbc31033373d6c51983ed230eb4ba61f7775ed02afb30f5fc1840bde01d4f"}},{"ruleId":"D42","level":"note","message":{"text":"No runtime threat detection: No runtime threat-detection engine (Tetragon TracingPolicy / Falco) is committed. These observe process, file and network activity in-kernel and can alert or kill on malicious behaviour a static scan cannot catch."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"aade9827a37dfc7ee064f80a997f47b5d11e31bc09704e26b9252bef00aa0c58"}},{"ruleId":"D42","level":"note","message":{"text":"No admission-control policy: No policy-enforcement gate (Kyverno / OPA Gatekeeper / PodSecurity admission) is committed. Admission control keeps workloads that violate your security baseline from ever reaching the cluster."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"57f2e92ed1519af6e21f44cce82a94119700b7d516006ea2955d969d5328b76b"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1032","guid":"5f21e517-68aa-a650-9a25-5771ef024637","name":"OWASP Top Ten \u2014 Security Misconfiguration category","shortDescription":{"text":"OWASP Top Ten \u2014 Security Misconfiguration category"},"helpUri":"https://cwe.mitre.org/data/definitions/1032.html"},{"id":"CWE-1357","guid":"e4d2e772-757e-0a5c-bd7d-77052949d866","name":"Reliance on Insufficiently Trustworthy Component","shortDescription":{"text":"Reliance on Insufficiently Trustworthy Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1357.html"},{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-16","guid":"659db3ea-affc-8453-8add-c1218fbfcb92","name":"Configuration","shortDescription":{"text":"Configuration"},"helpUri":"https://cwe.mitre.org/data/definitions/16.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-494","guid":"b8a65e0d-e459-4a55-a931-fc1136482375","name":"Download of Code Without Integrity Check","shortDescription":{"text":"Download of Code Without Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/494.html"},{"id":"CWE-732","guid":"1da27e8f-b330-7650-ab63-bd61953eae5d","name":"Incorrect Permission Assignment for Critical Resource","shortDescription":{"text":"Incorrect Permission Assignment for Critical Resource"},"helpUri":"https://cwe.mitre.org/data/definitions/732.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Command Injection","shortDescription":{"text":"Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"OS Command Injection","shortDescription":{"text":"OS Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Cross-site Scripting (XSS)","shortDescription":{"text":"Cross-site Scripting (XSS)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"SQL Injection","shortDescription":{"text":"SQL Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Code Injection","shortDescription":{"text":"Code Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":94,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}