repo
stringlengths
5
53
pr_number
int32
1
321k
task_type
stringclasses
2 values
issue_text
stringlengths
0
81.2k
pr_title
stringlengths
1
319
pr_body
stringlengths
0
105k
base_sha
stringlengths
40
40
head_sha
stringlengths
40
40
gold_diff
stringlengths
0
202M
changed_files
listlengths
0
100
review_threads
listlengths
0
100
test_patch
stringlengths
0
23.4M
merged
bool
1 class
thoughtbot/factory_bot
1,747
issue_to_patch
Bump to 6.5.2 [skip ci]
ce30e8bd401ad81de75741561093cc986bae9ce1
532a1a1ffe2076eff3c36f07595edcd920258705
diff --git a/Gemfile.lock b/Gemfile.lock index dd26683d2..db20bede0 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - factory_bot (6.5.0) + factory_bot (6.5.2) activesupport (>= 6.1.0) GEM diff --git a/NEWS.md b/NEWS.md index 51464cf43..9952d2eb2 100644 --- a/NE...
[ "Gemfile.lock", "NEWS.md", "lib/factory_bot/version.rb" ]
[]
true
tikv/tikv
18,032
issue_to_patch
TiKV panics: [region 15822] 15824 status Some((15824, true)) is not expected ## Bug Report <!-- Thanks for your bug report! Don't worry if you can't fill out all the sections. --> ``` /opt/tidb/kv.log:[2024/12/12 21:11:46.853 +00:00] [FATAL] [lib.rs:480] ["[region 15822] 15824 status Some((15824, true)) is not expect...
raftstore: fix missing pending peers in region heartbeat after split
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
caf82d2864d1501af733bf60c99a7732e105144b
92582fec52915822255afbf98779a82aa3db1ddd
diff --git a/components/raftstore/src/store/peer.rs b/components/raftstore/src/store/peer.rs index f6aabc8d56b..419340ce0b4 100644 --- a/components/raftstore/src/store/peer.rs +++ b/components/raftstore/src/store/peer.rs @@ -2109,6 +2109,22 @@ where } if status.progress.is_none() { + // I...
[ "components/raftstore/src/store/peer.rs", "components/test_pd_client/src/pd.rs", "tests/failpoints/cases/test_split_region.rs" ]
[ { "comment": "NIT: it's better to add extra annotations here to specify that the calling of this part will only be executed by a new split peer with already `campaigned`, who will most likely be elected as the new leader of the region.\r\n", "path": "components/raftstore/src/store/peer.rs", "hunk": "@@ ...
diff --git a/components/test_pd_client/src/pd.rs b/components/test_pd_client/src/pd.rs index a4ee044e42a..e8e6ef0b715 100644 --- a/components/test_pd_client/src/pd.rs +++ b/components/test_pd_client/src/pd.rs @@ -1721,6 +1721,7 @@ impl PdClient for TestPdClient { region_stat, replication_statu...
true
tikv/tikv
19,704
issue_to_patch
[cherry-pick] status_server: fix the bug if profiling flag is not reset
This is a manual cherry-pick of tidbcloud/cloud-storage-engine#4860 for hotfix. ### What is changed and how it works? Issue Number: Close #19703 What's Changed: ```commit-message status_server: fix the bug if profiling flag is not reset. Replace the previous `defer!`-based reset of `CPU_PROFILE_ACTIVE` (introduced...
eb05e796a2af1aacac5b76b681fa62680f8783ac
dae7811a70039735bb936d486238121ef60dad48
diff --git a/deny.toml b/deny.toml index 81a6f270339..35acae66df3 100644 --- a/deny.toml +++ b/deny.toml @@ -109,6 +109,12 @@ ignore = [ # RUSTSEC-2026-0097 (unsound with custom logger). Upstream dependency # constraints prevent upgrading at the moment. "RUSTSEC-2026-0097", + # Ignore RUSTSEC-2026-017...
[ "deny.toml", "src/server/status_server/profile.rs" ]
[]
true
tikv/tikv
19,518
issue_to_patch
Enforce tidb_max_keys_read at tikv layer tikv task to implement `tidb_max_keys_read` feature: https://github.com/pingcap/tidb/issues/66925
implement tidb_max_keys_read
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
642bdf8c631079f8ffe96a20af56e09dd5088f40
c4c341891618b18cf0314c74a133ff331707593c
diff --git a/components/tidb_query_common/src/storage/scanner.rs b/components/tidb_query_common/src/storage/scanner.rs index 39c525129c3..e900c8d0a98 100644 --- a/components/tidb_query_common/src/storage/scanner.rs +++ b/components/tidb_query_common/src/storage/scanner.rs @@ -192,6 +192,12 @@ impl<T: Storage, F: KvForm...
[ "components/tidb_query_common/src/storage/scanner.rs", "components/tidb_query_datatype/src/expr/ctx.rs", "components/tidb_query_executors/src/fast_hash_aggr_executor.rs", "components/tidb_query_executors/src/index_lookup_executor.rs", "components/tidb_query_executors/src/index_scan_executor.rs", "componen...
[ { "comment": "The Cargo.toml contains a patch for kvproto pointing to a personal fork with a \"max-keys-read\" branch. This is marked \"NOT FOR MERGE\" in the comment, but the patch is still active. This will need to be reverted before merging to ensure the build uses the official kvproto dependency.\n```sugges...
diff --git a/tests/benches/coprocessor_executors/util/fixture.rs b/tests/benches/coprocessor_executors/util/fixture.rs index 9c5826226f5..a104078f6bf 100644 --- a/tests/benches/coprocessor_executors/util/fixture.rs +++ b/tests/benches/coprocessor_executors/util/fixture.rs @@ -341,6 +341,11 @@ impl BatchExecutor for Bat...
true
tikv/tikv
19,518
comment_to_fix
implement tidb_max_keys_read
_⚠️ Potential issue_ | _🟠 Major_ **`max_keys_read` enforcement can be bypassed for IndexLookUp plans due to stats undercounting.** At Line 827, enforcement depends on `ExecuteStats.scanned_rows_per_range`, but `components/tidb_query_executors/src/index_lookup_executor.rs` (Lines 547-550) still has a TODO for handlin...
642bdf8c631079f8ffe96a20af56e09dd5088f40
c4c341891618b18cf0314c74a133ff331707593c
diff --git a/components/tidb_query_executors/src/runner.rs b/components/tidb_query_executors/src/runner.rs index 190923db3b2..58f030b3e8f 100644 --- a/components/tidb_query_executors/src/runner.rs +++ b/components/tidb_query_executors/src/runner.rs @@ -91,6 +91,31 @@ pub struct BatchExecutorsRunner<SS> { /// curre...
[ "components/tidb_query_executors/src/runner.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_\n\n**`max_keys_read` enforcement can be bypassed for IndexLookUp plans due to stats undercounting.**\n\nAt Line 827, enforcement depends on `ExecuteStats.scanned_rows_per_range`, but `components/tidb_query_executors/src/index_lookup_executor.rs` (Lines 547-550) st...
true
tikv/tikv
19,518
comment_to_fix
implement tidb_max_keys_read
_⚠️ Potential issue_ | _🟠 Major_ **Two new `max_keys_read` tests can panic before assertions.** Both tests expect `range.is_some()`, which triggers `take_scanned_range()`. But their `MockExecutor` instances don’t set `scanned_range`, so `take_scanned_range().unwrap()` can panic. <details> <summary>✅ Proposed fix</s...
642bdf8c631079f8ffe96a20af56e09dd5088f40
c4c341891618b18cf0314c74a133ff331707593c
diff --git a/components/tidb_query_executors/src/runner.rs b/components/tidb_query_executors/src/runner.rs index 190923db3b2..58f030b3e8f 100644 --- a/components/tidb_query_executors/src/runner.rs +++ b/components/tidb_query_executors/src/runner.rs @@ -91,6 +91,31 @@ pub struct BatchExecutorsRunner<SS> { /// curre...
[ "components/tidb_query_executors/src/runner.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_\n\n**Two new `max_keys_read` tests can panic before assertions.**\n\nBoth tests expect `range.is_some()`, which triggers `take_scanned_range()`. But their `MockExecutor` instances don’t set `scanned_range`, so `take_scanned_range().unwrap()` can panic.\n\n<details...
true
tikv/tikv
19,518
comment_to_fix
implement tidb_max_keys_read
_⚠️ Potential issue_ | _🟠 Major_ **`peek_scanned_rows_sum` undercounts keys during table-lookup phase** At Line 554, only `self.src.peek_scanned_rows_sum()` is returned. `BatchIndexLookUpExecutor` also scans keys via `state.table_scan` in table-lookup phase, so `max_keys_read` enforcement can be bypassed/under-enfor...
642bdf8c631079f8ffe96a20af56e09dd5088f40
c4c341891618b18cf0314c74a133ff331707593c
diff --git a/components/tidb_query_executors/src/index_lookup_executor.rs b/components/tidb_query_executors/src/index_lookup_executor.rs index dc50d46e42b..4cbba19214c 100644 --- a/components/tidb_query_executors/src/index_lookup_executor.rs +++ b/components/tidb_query_executors/src/index_lookup_executor.rs @@ -219,17 ...
[ "components/tidb_query_executors/src/index_lookup_executor.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_\n\n**`peek_scanned_rows_sum` undercounts keys during table-lookup phase**\n\nAt Line 554, only `self.src.peek_scanned_rows_sum()` is returned. `BatchIndexLookUpExecutor` also scans keys via `state.table_scan` in table-lookup phase, so `max_keys_read` enforcement c...
true
tikv/tikv
19,518
comment_to_fix
implement tidb_max_keys_read
_⚠️ Potential issue_ | _🟡 Minor_ **Clarify the contract for `peek_scanned_rows_sum()` to avoid undercounting bugs.** Line 71 says “total number of rows scanned”, but current base implementation is “since last collection” (because `collect_exec_stats` drains scanner counters via `collect_scanned_rows_per_range`). Ple...
642bdf8c631079f8ffe96a20af56e09dd5088f40
c4c341891618b18cf0314c74a133ff331707593c
diff --git a/components/tidb_query_executors/src/interface.rs b/components/tidb_query_executors/src/interface.rs index b69316a7df2..10e705a550e 100644 --- a/components/tidb_query_executors/src/interface.rs +++ b/components/tidb_query_executors/src/interface.rs @@ -68,6 +68,10 @@ pub trait BatchExecutor: Send { ///...
[ "components/tidb_query_executors/src/interface.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**Clarify the contract for `peek_scanned_rows_sum()` to avoid undercounting bugs.**\n\nLine 71 says “total number of rows scanned”, but current base implementation is “since last collection” (because `collect_exec_stats` drains scanner counters via `collect_sca...
true
tikv/tikv
19,700
issue_to_patch
gcp: refresh access tokens before expiry
### Related issue Fixes https://github.com/tikv/tikv/issues/19659 ### Related PRs Refs https://github.com/tikv/tame-oauth/pull/3 ### What changed - Refreshes cached GCP access tokens before they enter the final 10 minutes of their lifetime. - Keeps the refresh scoped to the existing token provider/cache...
b95bdcc3ac150efd59375c18430ef052c9b7faa8
3cbd89acd6117325144e5012b5903779e99c6c2b
diff --git a/Cargo.lock b/Cargo.lock index 376e49374e7..29b846f04c4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7764,7 +7764,7 @@ dependencies = [ [[package]] name = "tame-oauth" version = "0.9.6" -source = "git+https://github.com/tikv/tame-oauth?branch=fips-0.9#487e287c0d316b832dc44735cd9b7f7c432a10aa" +source = "...
[ "Cargo.lock", "components/cloud/gcp/src/client.rs" ]
[]
true
tikv/tikv
18,856
issue_to_patch
cdc: adjust log level from error to warn to reduce error level logs (#18484)
This is an automated cherry-pick of #18484 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
cad4f565d7d712d8f6751cdca554a5b7e10953c2
f90f5ebf095206df6873b475e221b33615c8a271
diff --git a/components/cdc/src/endpoint.rs b/components/cdc/src/endpoint.rs index 6dbe53fd13b..c7c38eb1bf3 100644 --- a/components/cdc/src/endpoint.rs +++ b/components/cdc/src/endpoint.rs @@ -867,7 +867,7 @@ impl<T: 'static + CdcHandle<E>, E: KvEngine, S: StoreRegionMeta> Endpoint<T, E, let txn_extra_op = mat...
[ "components/cdc/src/endpoint.rs", "components/cdc/src/initializer.rs" ]
[]
true
tikv/tikv
19,692
issue_to_patch
backup-stream: add log for backup stream grpc service (#19619)
This is an automated cherry-pick of #19619 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
d1527738da2e00536c7bcb9fa7b6127d95d8a925
diff --git a/components/backup-stream/src/checkpoint_manager.rs b/components/backup-stream/src/checkpoint_manager.rs index a10937b6134..fd4f4f13440 100644 --- a/components/backup-stream/src/checkpoint_manager.rs +++ b/components/backup-stream/src/checkpoint_manager.rs @@ -383,6 +383,10 @@ impl CheckpointManager { ...
[ "components/backup-stream/src/checkpoint_manager.rs", "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/service.rs" ]
[]
true
tikv/tikv
19,711
issue_to_patch
*: update vulnerable third-party dependencies #19458
This is a manual cherry-pick of https://github.com/tikv/tikv/pull/19458 ### What is changed and how it works? Issue Number: ref https://github.com/tikv/tikv/issues/19713 What's Changed: ```commit-message *: upgrade vulnerable third-party dependencies on release-8.5 Backport dependency and advisory fixes...
39357640d499832db04186c3812fd3ea622c7728
1fcce5adefc628d1d184685ba4fd68e282829923
diff --git a/Cargo.lock b/Cargo.lock index a3d4888b5c9..51e21e81815 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -388,11 +388,11 @@ dependencies = [ [[package]] name = "aws-lc-fips-sys" -version = "0.13.7" +version = "0.13.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2608e5a7965...
[ "Cargo.lock", "Cargo.toml", "cmd/build.rs", "components/backup-stream/Cargo.toml", "components/compact-log-backup/Cargo.toml", "components/compact-log-backup/src/test_util.rs", "components/engine_rocks/src/rocks_metrics.rs", "components/raftstore-v2/src/batch/store.rs", "components/raftstore-v2/src/...
[]
diff --git a/components/compact-log-backup/src/test_util.rs b/components/compact-log-backup/src/test_util.rs index d50d6803bd6..12938b0bfe2 100644 --- a/components/compact-log-backup/src/test_util.rs +++ b/components/compact-log-backup/src/test_util.rs @@ -21,7 +21,7 @@ use futures::{ use keys::origin_key; use kvprot...
true
tikv/tikv
19,702
issue_to_patch
gcp: refresh access tokens before expiry
### Related issue Fixes https://github.com/tikv/tikv/issues/19659 ### Related PRs Refs https://github.com/tikv/tame-oauth/pull/3 ### What changed - Refreshes cached GCP access tokens before they enter the final 10 minutes of their lifetime. - Keeps the refresh scoped to the existing token provider/cache...
13b9af5c34ad0dd62b5ae5ee02e05806e6d31e0b
75b407e5020725b0370bc65942781c194f9cb9ef
diff --git a/Cargo.lock b/Cargo.lock index aaeff425a94..d2ebe5ac300 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6699,7 +6699,7 @@ dependencies = [ [[package]] name = "tame-oauth" version = "0.9.6" -source = "git+https://github.com/tikv/tame-oauth?branch=fips-0.9#487e287c0d316b832dc44735cd9b7f7c432a10aa" +source = "...
[ "Cargo.lock", "components/cloud/gcp/src/client.rs" ]
[]
true
tikv/tikv
19,709
issue_to_patch
pd: report hot read cpu in heartbeat (#19305)
This is an automated cherry-pick of #19305 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
b7d1a0f3968e6072a6e910d7b6e2c594be4881a8
4f093d12a23faf39fe7bd6243c5f1a56f89c7cc1
diff --git a/Cargo.lock b/Cargo.lock index 246916c6183..d3ab37cc74b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3773,7 +3773,7 @@ dependencies = [ [[package]] name = "kvproto" version = "0.0.2" -source = "git+https://github.com/pingcap/kvproto.git#f3cc977452223626ecf070d9780eed5d3915ff9b" +source = "git+https://git...
[ "Cargo.lock", "components/pd_client/src/client.rs", "components/pd_client/src/lib.rs", "components/raftstore-v2/src/worker/pd/mod.rs", "components/raftstore-v2/src/worker/pd/region.rs", "components/raftstore-v2/src/worker/pd/store.rs", "components/raftstore/src/store/worker/pd.rs", "components/raftsto...
[]
true
tikv/tikv
19,650
issue_to_patch
cloud: Enable WIF for GCS using google official rust SDK (#19573)
This PR cherry-picked from #19573 Enable WIF for GCS using google official rust SDK <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody sho...
989946ff8debdec9076896ea7e982be67c0bc45d
cb46f9370b54ce626713fa0313566e2dc0ca1d17
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8add755c48d..b8081983b77 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -122,6 +122,8 @@ RUSTFLAGS=-Cdebuginfo=1 cargo build When building with make, cargo will automatically use [pipelined][p] compilation to increase the parallelism of the build. To turn o...
[ "CONTRIBUTING.md", "Cargo.lock", "Cargo.toml", "Dockerfile", "Dockerfile.FIPS", "Dockerfile.test", "Makefile", "cmd/tikv-ctl/src/cmd.rs", "cmd/tikv-ctl/src/main.rs", "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/metadata/store/pd.rs", "components/backup-stream/src/r...
[]
diff --git a/components/backup-stream/tests/suite.rs b/components/backup-stream/tests/suite.rs index 0fcd807ea2a..8d1ea80798d 100644 --- a/components/backup-stream/tests/suite.rs +++ b/components/backup-stream/tests/suite.rs @@ -385,6 +385,7 @@ impl Suite { let regions = sim.region_info_accessors.get(&id).unwr...
true
tikv/tikv
19,315
issue_to_patch
Support GCP workload identity federation for backup bucket access in google cloud ## Feature Request ### Is your feature request related to a problem? Please describe: <!-- A description of what the problem is. --> Currently gcp SDK don't support using WIF, so need to replace old gcp to the new official gcs SDK. ### ...
BR: add new storage type using google offical rust package.
…ge_class in config start with v2 to use it. <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two....
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/.github/workflows/tikv-clippy-darwin.yml b/.github/workflows/tikv-clippy-darwin.yml index da7c37130d8..b3f29af6bc6 100644 --- a/.github/workflows/tikv-clippy-darwin.yml +++ b/.github/workflows/tikv-clippy-darwin.yml @@ -2,6 +2,7 @@ name: Clippy (Darwin) env: CMAKE_VERSION: "3.28.0" + GO_VERSION: "1....
[ ".github/workflows/tikv-clippy-darwin.yml", "Cargo.lock", "Cargo.toml", "Dockerfile", "Dockerfile.FIPS", "Dockerfile.test", "cmd/tikv-ctl/src/cmd.rs", "cmd/tikv-ctl/src/main.rs", "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/metadata/store/pd.rs", "components/backup-s...
[ { "comment": "_⚠️ Potential issue_ | _🔴 Critical_\n\n<details>\n<summary>🧩 Analysis chain</summary>\n\n🌐 Web query:\n\n`site:crates.io google-cloud-storage versions latest`\n\n💡 Result:\n\nThe latest published version of the Rust crate **`google-cloud-storage`** is **`1.7.0`**. [1]\n\n**Sources:** [1]\n\n--...
diff --git a/components/backup-stream/tests/suite.rs b/components/backup-stream/tests/suite.rs index bf6d03125d2..6d26142fffb 100644 --- a/components/backup-stream/tests/suite.rs +++ b/components/backup-stream/tests/suite.rs @@ -385,6 +385,7 @@ impl Suite { let regions = sim.region_info_accessors.get(&id).unwr...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
_⚠️ Potential issue_ | _🟠 Major_ **The "v2" prefix is not stripped before passing to `GcsStorageV2::from_input`.** When `storage_class` is set to something like `"v2STANDARD"`, the code correctly selects the v2 backend (Line 76), but passes the full config including `"v2STANDARD"` as the storage class to `from_input...
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/components/external_storage/src/export.rs b/components/external_storage/src/export.rs index ea0754124aa..a71a285e96f 100644 --- a/components/external_storage/src/export.rs +++ b/components/external_storage/src/export.rs @@ -10,6 +10,7 @@ use cloud::blob::{BlobStorage, DeletableStorage, IterableStorage, Put...
[ "components/external_storage/src/export.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_\n\n**The \"v2\" prefix is not stripped before passing to `GcsStorageV2::from_input`.**\n\nWhen `storage_class` is set to something like `\"v2STANDARD\"`, the code correctly selects the v2 backend (Line 76), but passes the full config including `\"v2STANDARD\"` as ...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
`tokio-util` and `anyhow` are listed as direct dependencies but don’t appear to be used in this crate’s source. If the project enables `unused_crate_dependencies` (or to keep the dependency tree smaller), consider removing unused deps. ```suggestion url = "2.0" bytes = "1" ```
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/components/cloud/gcp_v2/Cargo.toml b/components/cloud/gcp_v2/Cargo.toml new file mode 100644 index 00000000000..99e2c7c8515 --- /dev/null +++ b/components/cloud/gcp_v2/Cargo.toml @@ -0,0 +1,33 @@ +[package] +name = "gcp_v2" +version = "0.0.1" +edition = "2021" +publish = false +license = "Apache-2.0" + +[d...
[ "components/cloud/gcp_v2/Cargo.toml" ]
[ { "comment": "`tokio-util` and `anyhow` are listed as direct dependencies but don’t appear to be used in this crate’s source. If the project enables `unused_crate_dependencies` (or to keep the dependency tree smaller), consider removing unused deps.\n```suggestion\nurl = \"2.0\"\nbytes = \"1\"\n```", "path"...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
_⚠️ Potential issue_ | _🟡 Minor_ **`unwrap()` on `set_host` can panic for bucket names with invalid URL host characters.** Line 159 calls `url.set_host(Some(&self.bucket)).unwrap()`. While valid GCS bucket names only use characters that are safe for opaque URL hosts, the `bucket` field comes directly from protobuf i...
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/components/cloud/gcp_v2/src/lib.rs b/components/cloud/gcp_v2/src/lib.rs new file mode 100644 index 00000000000..2454a58c28b --- /dev/null +++ b/components/cloud/gcp_v2/src/lib.rs @@ -0,0 +1,805 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{future::Future, io, pin::Pin}...
[ "components/cloud/gcp_v2/src/lib.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**`unwrap()` on `set_host` can panic for bucket names with invalid URL host characters.**\n\nLine 159 calls `url.set_host(Some(&self.bucket)).unwrap()`. While valid GCS bucket names only use characters that are safe for opaque URL hosts, the `bucket` field come...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
### There's an issue! `gcs_v2_enable` has duplicated inputs in task creation: it is inside `BackendConfig` and also passed as a separate `bool`, then `StreamTaskHandler::new` overwrites `backend_config.gcs_v2_enable`. This is an intention mismatch and a dual source of truth that can hide caller mistakes. ### W...
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/components/backup-stream/src/router.rs b/components/backup-stream/src/router.rs index aa315d63efc..a131e8a0379 100644 --- a/components/backup-stream/src/router.rs +++ b/components/backup-stream/src/router.rs @@ -343,10 +343,11 @@ pub struct Config { pub temp_file_memory_quota: u64, pub max_flush_...
[ "components/backup-stream/src/router.rs" ]
[ { "comment": "### There's an issue!\r\n\r\n`gcs_v2_enable` has duplicated inputs in task creation: it is inside `BackendConfig` and also passed as a separate `bool`, then `StreamTaskHandler::new` overwrites `backend_config.gcs_v2_enable`.\r\n\r\nThis is an intention mismatch and a dual source of truth that can ...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
Why there is an option? `default()` returns `true` is enough?
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/src/config/mod.rs b/src/config/mod.rs index 4478c937f1f..219fa731a09 100644 --- a/src/config/mod.rs +++ b/src/config/mod.rs @@ -3053,6 +3053,9 @@ pub struct BackupConfig { // Do not expose this config to user. // It used to debug s3 503 error. pub s3_multi_part_size: ReadableSize, + /// E...
[ "src/config/mod.rs" ]
[ { "comment": "Why there is an option? `default()` returns `true` is enough?", "path": "src/config/mod.rs", "hunk": "@@ -3119,6 +3123,11 @@ pub struct BackupStreamConfig {\n pub num_threads: usize,\n #[online_config(skip)]\n pub enable: bool,\n+ /// Enable GCS v2 external storage backend f...
true
tikv/tikv
19,315
comment_to_fix
BR: add new storage type using google offical rust package.
...as this is hard coded and no test case tests it, I think we don't need to add such a field. Just always set enable gcs v2 to `true` when creating backend. If this is actually required, prefer add the whole `BackendConfig` here. Also export it to CLI.
20cb1df927775f11dcca902dcbede1256edcbdf1
cc77d31b66c21a9368673bb9f77c9fde6a9cf5fb
diff --git a/cmd/tikv-ctl/src/main.rs b/cmd/tikv-ctl/src/main.rs index eb9dfe7ddae..85c75bb8ebb 100644 --- a/cmd/tikv-ctl/src/main.rs +++ b/cmd/tikv-ctl/src/main.rs @@ -406,6 +406,7 @@ fn main() { minimal_compaction_size, prefetch_running_count, prefetch_buffer_count, + ...
[ "cmd/tikv-ctl/src/main.rs" ]
[ { "comment": "...as this is hard coded and no test case tests it, I think we don't need to add such a field. Just always set enable gcs v2 to `true` when creating backend.\n\nIf this is actually required, prefer add the whole `BackendConfig` here. Also export it to CLI.", "path": "cmd/tikv-ctl/src/main.rs",...
true
tikv/tikv
19,706
issue_to_patch
*: fix cargo-deny CI for release-8.5 v8.5.3 cut
### What changed Backports the cargo-deny CI compatibility fixes needed for the `release-8.5-20260609-v8.5.3` cut: - Upgrade the `scripts/deny` path to run `cargo-deny@0.18.9` with a standalone Rust 1.92 toolchain. - Update lockfile entries for `tracing-subscriber` and `bytes` advisories. - Add release-branch a...
13b9af5c34ad0dd62b5ae5ee02e05806e6d31e0b
95f3a06b7d1e88cc32db9ef75c3567fd6230ed01
diff --git a/Cargo.lock b/Cargo.lock index aaeff425a94..31e9947534a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1144,9 +1144,9 @@ checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" [[package]] name = "bytes" -version = "1.7.2" +version = "1.11.1" source = "registry+https://github.com/ru...
[ "Cargo.lock", "Cargo.toml", "cmd/tikv-server/Cargo.toml", "components/cloud/aws/Cargo.toml", "components/codec/Cargo.toml", "components/in_memory_engine/Cargo.toml", "components/raftstore-v2/Cargo.toml", "components/raftstore/Cargo.toml", "components/tikv_util/Cargo.toml", "deny.toml", "scripts/...
[]
true
tikv/tikv
19,305
issue_to_patch
pd: report hot read cpu in heartbeat ref https://github.com/tikv/pd/issues/5718
pd: report hot read cpu in heartbeat
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/Cargo.lock b/Cargo.lock index ea4d210e108..6abb0c73d25 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3773,7 +3773,7 @@ dependencies = [ [[package]] name = "kvproto" version = "0.0.2" -source = "git+https://github.com/pingcap/kvproto.git#9f0ac2fc9a1a6bb8337e01ff72d6b864802698b6" +source = "git+https://git...
[ "Cargo.lock", "components/pd_client/src/client.rs", "components/pd_client/src/lib.rs", "components/raftstore-v2/src/worker/pd/mod.rs", "components/raftstore-v2/src/worker/pd/region.rs", "components/raftstore-v2/src/worker/pd/store.rs", "components/raftstore/src/store/worker/pd.rs", "components/raftsto...
[ { "comment": "`interval_seconds` is computed from `store_stat.last_report_ts`, but `last_report_ts` is intentionally not updated for fake store heartbeats. Since `region_cpu_records_store` is still cleared during this function, a fake heartbeat will cause the next real heartbeat to under-report CPU usage (CPU t...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
`interval_seconds` is computed from `store_stat.last_report_ts`, but `last_report_ts` is intentionally not updated for fake store heartbeats. Since `region_cpu_records_store` is still cleared during this function, a fake heartbeat will cause the next real heartbeat to under-report CPU usage (CPU time since fake / inter...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore/src/store/worker/pd.rs b/components/raftstore/src/store/worker/pd.rs index c5f29ca1aab..b131cc4f954 100644 --- a/components/raftstore/src/store/worker/pd.rs +++ b/components/raftstore/src/store/worker/pd.rs @@ -904,8 +904,16 @@ const HOTSPOT_KEY_RATE_THRESHOLD: u64 = 128; const HOTSPO...
[ "components/raftstore/src/store/worker/pd.rs" ]
[ { "comment": "`interval_seconds` is computed from `store_stat.last_report_ts`, but `last_report_ts` is intentionally not updated for fake store heartbeats. Since `region_cpu_records_store` is still cleared during this function, a fake heartbeat will cause the next real heartbeat to under-report CPU usage (CPU t...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
Same issue as raftstore v1: `interval_seconds` is based on `store_stat.last_report_ts`, but `last_report_ts` isn’t updated for fake heartbeats while `region_cpu_records_store` is still cleared. After a fake heartbeat, CPU usage will be under-reported. Consider skipping consumption of `region_cpu_records_store` on fake ...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore-v2/src/worker/pd/store.rs b/components/raftstore-v2/src/worker/pd/store.rs index 55ef7497ccf..45cc1e36048 100644 --- a/components/raftstore-v2/src/worker/pd/store.rs +++ b/components/raftstore-v2/src/worker/pd/store.rs @@ -57,6 +57,12 @@ fn hotspot_query_num_report_threshold() -> u64 {...
[ "components/raftstore-v2/src/worker/pd/store.rs" ]
[ { "comment": "Same issue as raftstore v1: `interval_seconds` is based on `store_stat.last_report_ts`, but `last_report_ts` isn’t updated for fake heartbeats while `region_cpu_records_store` is still cleared. After a fake heartbeat, CPU usage will be under-reported. Consider skipping consumption of `region_cpu_r...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
_⚠️ Potential issue_ | _🟡 Minor_ **Stale `region_cpu_records_store` entries when `interval_seconds == 0`.** When `interval_seconds` is 0, the `else` branch sets `cpu_usage` to 0 but does **not** call `self.region_cpu_records_store.remove(region_id)`. This means entries accumulate silently until the next heartbeat wi...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore-v2/src/worker/pd/store.rs b/components/raftstore-v2/src/worker/pd/store.rs index 55ef7497ccf..45cc1e36048 100644 --- a/components/raftstore-v2/src/worker/pd/store.rs +++ b/components/raftstore-v2/src/worker/pd/store.rs @@ -57,6 +57,12 @@ fn hotspot_query_num_report_threshold() -> u64 {...
[ "components/raftstore-v2/src/worker/pd/store.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**Stale `region_cpu_records_store` entries when `interval_seconds == 0`.**\n\nWhen `interval_seconds` is 0, the `else` branch sets `cpu_usage` to 0 but does **not** call `self.region_cpu_records_store.remove(region_id)`. This means entries accumulate silently u...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
_⚠️ Potential issue_ | _🟡 Minor_ **Orphaned entries in `region_cpu_records_since_store_heartbeat` are not drained.** The loop iterates over `region_peers` and calls `.remove(region_id)` on `region_cpu_records_since_store_heartbeat` for each known peer (lines 961-963, 967). Any region_id present in the CPU map but **...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore/src/store/worker/pd.rs b/components/raftstore/src/store/worker/pd.rs index c5f29ca1aab..b131cc4f954 100644 --- a/components/raftstore/src/store/worker/pd.rs +++ b/components/raftstore/src/store/worker/pd.rs @@ -904,8 +904,16 @@ const HOTSPOT_KEY_RATE_THRESHOLD: u64 = 128; const HOTSPO...
[ "components/raftstore/src/store/worker/pd.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**Orphaned entries in `region_cpu_records_since_store_heartbeat` are not drained.**\n\nThe loop iterates over `region_peers` and calls `.remove(region_id)` on `region_cpu_records_since_store_heartbeat` for each known peer (lines 961-963, 967). Any region_id pre...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
_⚠️ Potential issue_ | _🟠 Major_ **Orphan CPU records in `region_cpu_records_since_store_heartbeat` are not drained after the loop.** The loop (lines 214-258) iterates `self.region_peers` and calls `.remove(region_id)` on `region_cpu_records_since_store_heartbeat` for each known peer. Any `region_id` present in the ...
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore-v2/src/worker/pd/store.rs b/components/raftstore-v2/src/worker/pd/store.rs index 55ef7497ccf..45cc1e36048 100644 --- a/components/raftstore-v2/src/worker/pd/store.rs +++ b/components/raftstore-v2/src/worker/pd/store.rs @@ -57,6 +57,12 @@ fn hotspot_query_num_report_threshold() -> u64 {...
[ "components/raftstore-v2/src/worker/pd/store.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_\n\n**Orphan CPU records in `region_cpu_records_since_store_heartbeat` are not drained after the loop.**\n\nThe loop (lines 214-258) iterates `self.region_peers` and calls `.remove(region_id)` on `region_cpu_records_since_store_heartbeat` for each known peer. Any `...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
Although the case `interval_seconds == 0` is not expected under normal operating conditions, it should should be explicitly handled for safety.
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore/src/store/worker/pd.rs b/components/raftstore/src/store/worker/pd.rs index c5f29ca1aab..b131cc4f954 100644 --- a/components/raftstore/src/store/worker/pd.rs +++ b/components/raftstore/src/store/worker/pd.rs @@ -904,8 +904,16 @@ const HOTSPOT_KEY_RATE_THRESHOLD: u64 = 128; const HOTSPO...
[ "components/raftstore/src/store/worker/pd.rs" ]
[ { "comment": "Although the case `interval_seconds == 0` is not expected under normal operating conditions, it should should be explicitly handled for safety.", "path": "components/raftstore/src/store/worker/pd.rs", "hunk": "@@ -924,6 +931,71 @@ fn hotspot_query_num_report_threshold() -> u64 {\n HOTS...
true
tikv/tikv
19,305
comment_to_fix
pd: report hot read cpu in heartbeat
```suggestion fn should_report_hotspot_read_peer( ```
b1028c06d08b5859f0b09cbe8c312c4782ae85b9
e45b0d2813c0db0d7f6421e2cce5cd8e39dada24
diff --git a/components/raftstore/src/store/worker/pd.rs b/components/raftstore/src/store/worker/pd.rs index c5f29ca1aab..b131cc4f954 100644 --- a/components/raftstore/src/store/worker/pd.rs +++ b/components/raftstore/src/store/worker/pd.rs @@ -904,8 +904,16 @@ const HOTSPOT_KEY_RATE_THRESHOLD: u64 = 128; const HOTSPO...
[ "components/raftstore/src/store/worker/pd.rs" ]
[ { "comment": "```suggestion\nfn should_report_hotspot_read_peer(\n```", "path": "components/raftstore/src/store/worker/pd.rs", "hunk": "@@ -924,6 +932,74 @@ fn hotspot_query_num_report_threshold() -> u64 {\n HOTSPOT_QUERY_RATE_THRESHOLD * 10\n }\n \n+#[inline]\n+fn should_report_read_peer(", "re...
true
tikv/tikv
19,696
issue_to_patch
raftstore: fail fast on disk hang (#19613)
This is an automated cherry-pick of #19613 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
06d95836cf7b2b883302e77e61f057e7e33689f1
f934353ff67ee9d1afb884905cf570f8d600ad16
diff --git a/components/raftstore-v2/src/batch/store.rs b/components/raftstore-v2/src/batch/store.rs index 07a0aea7725..61a56284487 100644 --- a/components/raftstore-v2/src/batch/store.rs +++ b/components/raftstore-v2/src/batch/store.rs @@ -5,7 +5,7 @@ use std::{ path::Path, sync::{ Arc, Mutex, - ...
[ "components/raftstore-v2/src/batch/store.rs", "components/raftstore/src/store/async_io/write.rs", "components/raftstore/src/store/async_io/write_tests.rs", "components/raftstore/src/store/config.rs", "components/raftstore/src/store/disk_probe.rs", "components/raftstore/src/store/fail_fast.rs", "componen...
[]
true
tikv/tikv
19,684
issue_to_patch
backup-stream: fix initial range scan deadlock (#19648)
This is an automated cherry-pick of #19648 ### What is changed and how it works? Issue Number: Close #19615 What's Changed: ```commit-message backup-stream: fix initial range scan deadlock When log backup initializes a range with many regions, the region collector runs the seek-region callback on its own...
8c68760de4a263095071c80a1951157d6e6aa246
81903d707e47783e914be0c8be16585c187d16f7
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index 0baf33a87aa..cdf42b8a669 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -631,12 +631,10 @@ where /// initialize a range: it simply scan the regions with le...
[ "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/subscription_manager.rs", "components/backup-stream/tests/failpoints/mod.rs", "components/backup-stream/tests/suite.rs" ]
[]
diff --git a/components/backup-stream/tests/failpoints/mod.rs b/components/backup-stream/tests/failpoints/mod.rs index 891e21d4493..49c5070d333 100644 --- a/components/backup-stream/tests/failpoints/mod.rs +++ b/components/backup-stream/tests/failpoints/mod.rs @@ -131,6 +131,41 @@ mod all { let c = suite.globa...
true
tikv/tikv
19,621
issue_to_patch
cdc, tikv_kv: avoid repeated old value cursor prev in incremental scan (#19614)
This is an automated cherry-pick of #19614 ### What is changed and how it works? Issue Number: Close #19565 See: https://github.com/tikv/tikv/issues/19565#issuecomment-4497043662 What's Changed: Add an opt-in missing range cache to mixed cursors. When a seek lands on a later key, the cursor can cache the e...
b95bdcc3ac150efd59375c18430ef052c9b7faa8
16eef18915a99aa0b4c164df51dfd5109a8c8beb
diff --git a/components/cdc/src/initializer.rs b/components/cdc/src/initializer.rs index 397716410c0..be1cc7eefa2 100644 --- a/components/cdc/src/initializer.rs +++ b/components/cdc/src/initializer.rs @@ -655,17 +655,22 @@ mod tests { use kvproto::{ cdcpb::{Event_oneof_event, EventLogType}, error...
[ "components/cdc/src/initializer.rs", "components/cdc/src/old_value.rs", "components/tikv_kv/src/btree_engine.rs", "components/tikv_kv/src/cursor.rs", "components/tikv_kv/src/lib.rs", "components/tikv_kv/src/metrics.rs", "components/tikv_kv/src/stats.rs", "src/coprocessor/metrics.rs", "src/storage/kv...
[]
diff --git a/src/storage/kv/test_engine_builder.rs b/src/storage/kv/test_engine_builder.rs index c8210f6d1bc..44630130dfe 100644 --- a/src/storage/kv/test_engine_builder.rs +++ b/src/storage/kv/test_engine_builder.rs @@ -230,6 +230,7 @@ mod tests { snapshot.iter(CF_DEFAULT, iter_opt).unwrap(), ...
true
tikv/tikv
19,699
issue_to_patch
*: enforce exact max-ts for non-TiDB requests (#19654)
This is an automated cherry-pick of #19654 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
1145e8311651421bf14b35bf328e334a8f4bab91
330a1cc08bcd6e6de8415a6e63601059b2c5da48
diff --git a/Cargo.lock b/Cargo.lock index 376e49374e7..62fce78f9a1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4342,7 +4342,7 @@ dependencies = [ [[package]] name = "kvproto" version = "0.0.2" -source = "git+https://github.com/pingcap/kvproto.git?branch=release-8.5#39498d6b17fc516bc18d178e981b0f76d18fcad6" +source...
[ "Cargo.lock", "components/backup/src/endpoint.rs", "components/concurrency_manager/src/lib.rs", "src/storage/mod.rs", "src/storage/txn/commands/check_secondary_locks.rs", "src/storage/txn/commands/check_txn_status.rs", "src/storage/txn/commands/cleanup.rs" ]
[]
true
tikv/tikv
19,683
issue_to_patch
raftstore: fix hibernate quorum feature test flake (#19678)
This is an automated cherry-pick of #19678 ### What is changed and how it works? Issue Number: ref #19682 What's Changed: ```commit-message The hibernate quorum feature test installed a broad send packet filter before the observation window and expected `when(filter)` to keep the `awakened` marker inactive...
8c68760de4a263095071c80a1951157d6e6aa246
aeab5446a7153f195504a985e8bfa06f634fd83c
[ "tests/integrations/raftstore/test_hibernate.rs" ]
[]
diff --git a/tests/integrations/raftstore/test_hibernate.rs b/tests/integrations/raftstore/test_hibernate.rs index bc3b2307f87..8e49e834ae0 100644 --- a/tests/integrations/raftstore/test_hibernate.rs +++ b/tests/integrations/raftstore/test_hibernate.rs @@ -11,10 +11,29 @@ use futures::executor::block_on; use kvproto::...
true
tikv/tikv
19,693
issue_to_patch
import: mark applied write cf txn source (#19657)
This is an automated cherry-pick of #19657 ### What is changed and how it works? Issue Number: close #19669, ref pingcap/tidb#68660 What's Changed: ```commit-message import: mark applied write CF entries with physical import txn source PITR restores write CF records through apply log. Before this change, ...
8c68760de4a263095071c80a1951157d6e6aa246
af579487ae408a9e58c340ffbe397591a8f0bd07
diff --git a/src/import/sst_service.rs b/src/import/sst_service.rs index 7c1f0fc5006..2b56f7c4e65 100644 --- a/src/import/sst_service.rs +++ b/src/import/sst_service.rs @@ -104,6 +104,10 @@ const REJECT_SERVE_MEMORY_USAGE: u64 = 1024 * 1024 * 1024; //1G // consider block cache and raft store. the memory usage will be ...
[ "src/import/sst_service.rs", "tests/integrations/import/test_apply_log.rs" ]
[]
diff --git a/tests/integrations/import/test_apply_log.rs b/tests/integrations/import/test_apply_log.rs index afd01ce6935..ed72aa091f3 100644 --- a/tests/integrations/import/test_apply_log.rs +++ b/tests/integrations/import/test_apply_log.rs @@ -1,11 +1,12 @@ // Copyright 2024 TiKV Project Authors. Licensed under Apach...
true
tikv/tikv
19,252
issue_to_patch
Log Backup may get stuck due to async lock held across `.await` ## Bug Report <!-- Thanks for your bug report! Don't worry if you can't fill out all the sections. --> Under certain configurations, Log Backup may get permanently stuck. Once this happens: - Log backup no longer makes progress, no related backup log ou...
log backup: reduce lock lifetime during flush log file
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
a2c3ecf49a4accd6698ea61ed87594a45bdc40be
2ecbeb1c25955e6933d4ecf9196b16ff8aa335ee
diff --git a/clippy.toml b/clippy.toml index 35e8b514685..475a46d97e8 100644 --- a/clippy.toml +++ b/clippy.toml @@ -106,3 +106,7 @@ a use-after-free would result. See RUSTSEC-2025-0022 avoid-breaking-exported-api = false upper-case-acronyms-aggressive = true + +[[await-holding-invalid-types]] +path = "dashmap::map...
[ "clippy.toml", "components/backup-stream/src/router.rs" ]
[ { "comment": "```suggestion\r\n let task_handler = match self.get_task_handler(cx.task_name).ok()?;\r\n```", "path": "components/backup-stream/src/router.rs", "hunk": "@@ -723,34 +723,29 @@ impl RouterInner {\n /// of this flush. returns `None` if failed.\n #[instrument(skip(self, cx))]\n...
true
tikv/tikv
19,647
issue_to_patch
Dynamic resource group isolation (#19509)
This is an automated cherry-pick of #19509 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
06d95836cf7b2b883302e77e61f057e7e33689f1
2c151cdbca36b541a59a7e4bb45fe3a363723c64
diff --git a/components/backup/src/endpoint.rs b/components/backup/src/endpoint.rs index d05f7a72e27..ebbf61d6b30 100644 --- a/components/backup/src/endpoint.rs +++ b/components/backup/src/endpoint.rs @@ -244,7 +244,15 @@ async fn save_backup_file_worker<EK: KvEngine>( ) { while let Ok(msg) = rx.recv().await { ...
[ "components/backup/src/endpoint.rs", "components/resource_control/src/config.rs", "components/resource_control/src/future.rs", "components/resource_control/src/lib.rs", "components/resource_control/src/metrics.rs", "components/resource_control/src/resource_group.rs", "components/resource_control/src/res...
[]
diff --git a/tests/integrations/config/mod.rs b/tests/integrations/config/mod.rs index ba3d2928f77..007a7c0547b 100644 --- a/tests/integrations/config/mod.rs +++ b/tests/integrations/config/mod.rs @@ -910,10 +910,17 @@ fn test_serde_custom_tikv_config() { value.resource_control = ResourceControlConfig { e...
true
tikv/tikv
19,698
issue_to_patch
Support rank limit (#19306)
This is an automated cherry-pick of #19306 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
6a5c2c0e2e796c56ad3b69ddbe24a29d6d5a1fea
11bb8bca51e706a4bc9af217f2fda6f576ac0068
diff --git a/Cargo.lock b/Cargo.lock index 376e49374e7..4066ad9308e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -8808,7 +8808,7 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tipb" version = "0.0.1" -source = "git+https://github.com/pingcap/tipb.git?branch=releas...
[ "Cargo.lock", "components/tidb_query_executors/src/limit_executor.rs", "components/tidb_query_executors/src/runner.rs" ]
[]
true
tikv/tikv
19,617
issue_to_patch
remove individual background rate limiter (#19496)
This is an automated cherry-pick of #19496 Moving to a global rate limiter instead of separate rate limit for each resource group <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsu...
fd786013b603312c9bf0fa53be051f618208c88f
59ade8850f28b0b1e7916a6849a00189d33b4dd3
diff --git a/components/resource_control/src/metrics.rs b/components/resource_control/src/metrics.rs index 594c6af486a..87a624051df 100644 --- a/components/resource_control/src/metrics.rs +++ b/components/resource_control/src/metrics.rs @@ -6,20 +6,19 @@ use prometheus::*; lazy_static! { pub static ref BACKGROUND...
[ "components/resource_control/src/metrics.rs", "components/resource_control/src/resource_group.rs", "components/resource_control/src/service.rs", "components/resource_control/src/worker.rs", "metrics/grafana/tikv_details.dashboard.py", "metrics/grafana/tikv_details.json", "metrics/grafana/tikv_details.js...
[]
true
tikv/tikv
18,786
issue_to_patch
resolve: returns StoreTombstone directly if PD returns `store not found`. (#18023)
This is an automated cherry-pick of #18023 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
d7980db62e1313167ba5a305bf3f50f2a7db4616
2125a603a3070779eacfc162bd9c1ac620744726
diff --git a/deny.toml b/deny.toml index b01d278916b..17330e1e007 100644 --- a/deny.toml +++ b/deny.toml @@ -113,6 +113,12 @@ ignore = [ # RUSTSEC-2026-0097 (unsound with custom logger). Upstream dependency # constraints prevent upgrading at the moment. "RUSTSEC-2026-0097", + # Ignore RUSTSEC-2026-017...
[ "deny.toml", "src/server/resolve.rs" ]
[]
true
tikv/tikv
19,549
issue_to_patch
server: fix ime debug url path (#19547)
This is an automated cherry-pick of #19547 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
6a5c2c0e2e796c56ad3b69ddbe24a29d6d5a1fea
48c6f17d31f14bd10fa794da27402b6cada17280
diff --git a/src/server/status_server/mod.rs b/src/server/status_server/mod.rs index 58340f9e2f3..e9cef6707d1 100644 --- a/src/server/status_server/mod.rs +++ b/src/server/status_server/mod.rs @@ -855,7 +855,7 @@ where Self::handle_resume_grpc(grpc_service_mgr) ...
[ "src/server/status_server/mod.rs" ]
[]
true
tikv/tikv
19,107
issue_to_patch
server: fix the bug that ServerCfgManager and grcp initializing with different memory quota (#19105)
This is an automated cherry-pick of #19105 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
75f416eae21653bcbe396336a4a48ad4cef98870
340aed2acb52c2ed3720d88818acba59d9fc3026
diff --git a/src/server/server.rs b/src/server/server.rs index b6eb4430021..f7f51ab21b7 100644 --- a/src/server/server.rs +++ b/src/server/server.rs @@ -69,6 +69,7 @@ struct BuilderFactory<S: Tikv + Send + Clone + 'static> { cfg: Arc<VersionTrack<Config>>, security_mgr: Arc<SecurityManager>, health_servi...
[ "src/server/server.rs" ]
[]
true
tikv/tikv
19,092
issue_to_patch
raftstore*: Add missing metric `apply_msg_len` (#19058)
This is an automated cherry-pick of #19058 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
521e388eceb86483ff30ec5dbf5aba99d963102a
749f147991b1413d13ba0bc8d11888a8aaeb7492
diff --git a/components/raftstore/src/store/fsm/apply.rs b/components/raftstore/src/store/fsm/apply.rs index 19aeb627f42..dbe79c10f7d 100644 --- a/components/raftstore/src/store/fsm/apply.rs +++ b/components/raftstore/src/store/fsm/apply.rs @@ -683,6 +683,7 @@ where } self.apply_time.flush(); ...
[ "components/raftstore/src/store/fsm/apply.rs" ]
[]
true
tikv/tikv
19,691
issue_to_patch
cdc: cancel both send and receive on watchdog abort (#19612)
This is an automated cherry-pick of #19612 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
66281313174893ffac7e7e14bd387e8c90f2fdb6
diff --git a/components/cdc/Cargo.toml b/components/cdc/Cargo.toml index 592effa62bd..a71560c5efa 100644 --- a/components/cdc/Cargo.toml +++ b/components/cdc/Cargo.toml @@ -61,7 +61,7 @@ thiserror = "1.0" tikv = { workspace = true } tikv_kv = { workspace = true } tikv_util = { workspace = true } -tokio = { version =...
[ "components/cdc/Cargo.toml", "components/cdc/src/channel.rs", "components/cdc/src/delegate.rs", "components/cdc/src/endpoint.rs", "components/cdc/src/initializer.rs", "components/cdc/src/lib.rs", "components/cdc/src/service.rs", "components/cdc/src/types.rs", "components/cdc/src/watchdog.rs", "com...
[]
diff --git a/components/cdc/tests/failpoints/test_endpoint.rs b/components/cdc/tests/failpoints/test_endpoint.rs index 12b44bd163d..403aebfa8cf 100644 --- a/components/cdc/tests/failpoints/test_endpoint.rs +++ b/components/cdc/tests/failpoints/test_endpoint.rs @@ -744,94 +744,3 @@ fn test_cdc_unresolved_region_count_be...
true
tikv/tikv
19,654
issue_to_patch
Enforce exact max-ts validation for selected non-TiDB requests ## Problem TiKV's concurrency manager max-ts validation allows a configured drift tolerance for normal update paths. For selected requests from non-TiDB clients, that tolerance can hide invalid future timestamps greater than PD TSO. ## Scope Use the req...
*: enforce exact max-ts for non-TiDB requests
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
a763bd7ba4e56bd45a5a146b0a5712e039235d80
288ee4750b9abd7cadde538f4f160ce63b494910
diff --git a/Cargo.lock b/Cargo.lock index bcf38359556..2bb40715c65 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4422,7 +4422,7 @@ dependencies = [ [[package]] name = "kvproto" version = "0.0.2" -source = "git+https://github.com/pingcap/kvproto.git#f33f20c54524c6c62cde791f9b274fdf1044535a" +source = "git+https://git...
[ "Cargo.lock", "components/backup/src/endpoint.rs", "components/concurrency_manager/src/lib.rs", "src/storage/mod.rs", "src/storage/txn/commands/check_secondary_locks.rs", "src/storage/txn/commands/check_txn_status.rs", "src/storage/txn/commands/cleanup.rs" ]
[ { "comment": "`Request` gained a new required field `request_origin`, but several `Request { ... }` struct literals in the tests are not updated (e.g. around lines 1684, 1797, 1830, 1942). This will fail to compile the `backup` crate tests unless those initializers add `request_origin: ...` (e.g. `RequestOrigin...
true
tikv/tikv
19,654
comment_to_fix
*: enforce exact max-ts for non-TiDB requests
`Request` gained a new required field `request_origin`, but several `Request { ... }` struct literals in the tests are not updated (e.g. around lines 1684, 1797, 1830, 1942). This will fail to compile the `backup` crate tests unless those initializers add `request_origin: ...` (e.g. `RequestOrigin::RequestOriginUnknown...
a763bd7ba4e56bd45a5a146b0a5712e039235d80
288ee4750b9abd7cadde538f4f160ce63b494910
diff --git a/components/backup/src/endpoint.rs b/components/backup/src/endpoint.rs index f54863c6b7c..9bdc44580c4 100644 --- a/components/backup/src/endpoint.rs +++ b/components/backup/src/endpoint.rs @@ -10,14 +10,14 @@ use std::{ use async_channel::SendError; use causal_ts::{CausalTsProvider, CausalTsProviderImpl...
[ "components/backup/src/endpoint.rs" ]
[ { "comment": "`Request` gained a new required field `request_origin`, but several `Request { ... }` struct literals in the tests are not updated (e.g. around lines 1684, 1797, 1830, 1942). This will fail to compile the `backup` crate tests unless those initializers add `request_origin: ...` (e.g. `RequestOrigin...
true
tikv/tikv
19,654
comment_to_fix
*: enforce exact max-ts for non-TiDB requests
`Request` gained a new required field `request_origin`, but several `Request { ... }` struct literals in the tests are not updated (e.g. around lines 1684, 1797, 1830, 1942). This will fail to compile the `backup` crate tests unless those initializers add `request_origin: ...` (e.g. `RequestOrigin::RequestOriginUnknown...
a763bd7ba4e56bd45a5a146b0a5712e039235d80
288ee4750b9abd7cadde538f4f160ce63b494910
diff --git a/components/backup/src/endpoint.rs b/components/backup/src/endpoint.rs index f54863c6b7c..9bdc44580c4 100644 --- a/components/backup/src/endpoint.rs +++ b/components/backup/src/endpoint.rs @@ -10,14 +10,14 @@ use std::{ use async_channel::SendError; use causal_ts::{CausalTsProvider, CausalTsProviderImpl...
[ "components/backup/src/endpoint.rs" ]
[ { "comment": "`Request` gained a new required field `request_origin`, but several `Request { ... }` struct literals in the tests are not updated (e.g. around lines 1684, 1797, 1830, 1942). This will fail to compile the `backup` crate tests unless those initializers add `request_origin: ...` (e.g. `RequestOrigin...
true
tikv/tikv
19,654
comment_to_fix
*: enforce exact max-ts for non-TiDB requests
_⚠️ Potential issue_ | _🟡 Minor_ | _⚡ Quick win_ **Make the strict-path test use a real update attempt.** The second call reuses `within_drift`, so this test only exercises the strict validation path because `update_max_ts` currently still validates no-op updates. If the implementation is later short-circuited to ma...
a763bd7ba4e56bd45a5a146b0a5712e039235d80
288ee4750b9abd7cadde538f4f160ce63b494910
diff --git a/components/concurrency_manager/src/lib.rs b/components/concurrency_manager/src/lib.rs index 57605fd9e3f..e4e2806ca36 100644 --- a/components/concurrency_manager/src/lib.rs +++ b/components/concurrency_manager/src/lib.rs @@ -28,6 +28,7 @@ use std::{ }; use crossbeam::atomic::AtomicCell; +use kvproto::kv...
[ "components/concurrency_manager/src/lib.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_ | _⚡ Quick win_\n\n**Make the strict-path test use a real update attempt.**\n\nThe second call reuses `within_drift`, so this test only exercises the strict validation path because `update_max_ts` currently still validates no-op updates. If the implementation is l...
true
tikv/tikv
19,306
issue_to_patch
Support rank limit ## Feature Request ### Is your feature request related to a problem? Please describe: <!-- A description of what the problem is. --> ### Describe the feature you'd like: <!-- A description of what you want to happen. --> ### Describe alternatives you've considered: <!-- A description of any alter...
Support rank limit
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/Cargo.lock b/Cargo.lock index 77e60303d9c..04883a3bb7b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -8937,7 +8937,7 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tipb" version = "0.0.1" -source = "git+https://github.com/pingcap/tipb.git#1374320b4bd8f...
[ "Cargo.lock", "components/tidb_query_executors/src/limit_executor.rs", "components/tidb_query_executors/src/runner.rs" ]
[ { "comment": "_🛠️ Refactor suggestion_ | _🟠 Major_\n\n**Replace verbose `match` on `Result` with the `?` operator.**\n\nMultiple instances of `match res { Ok(_) => {}, Err(err) => { return Err(err); } }` throughout this function and `find_different_truncate_key_row` are equivalent to `res?;`. This pattern app...
true
tikv/tikv
19,306
comment_to_fix
Support rank limit
_🛠️ Refactor suggestion_ | _🟠 Major_ **Replace verbose `match` on `Result` with the `?` operator.** Multiple instances of `match res { Ok(_) => {}, Err(err) => { return Err(err); } }` throughout this function and `find_different_truncate_key_row` are equivalent to `res?;`. This pattern appears at lines 136–139, 152...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/components/tidb_query_executors/src/limit_executor.rs b/components/tidb_query_executors/src/limit_executor.rs index 5f346fd28d2..771d5320164 100644 --- a/components/tidb_query_executors/src/limit_executor.rs +++ b/components/tidb_query_executors/src/limit_executor.rs @@ -1,10 +1,20 @@ // Copyright 2019 Ti...
[ "components/tidb_query_executors/src/limit_executor.rs" ]
[ { "comment": "_🛠️ Refactor suggestion_ | _🟠 Major_\n\n**Replace verbose `match` on `Result` with the `?` operator.**\n\nMultiple instances of `match res { Ok(_) => {}, Err(err) => { return Err(err); } }` throughout this function and `find_different_truncate_key_row` are equivalent to `res?;`. This pattern app...
true
tikv/tikv
19,306
comment_to_fix
Support rank limit
_⚠️ Potential issue_ | _🟡 Minor_ **Typo: `preifx_key_col_index` → `prefix_key_col_index`.** <details> <summary>✏️ Fix</summary> ```diff - for preifx_key_col_index in 0..self.truncate_key_num { - if current_key[preifx_key_col_index] + for pre...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/components/tidb_query_executors/src/limit_executor.rs b/components/tidb_query_executors/src/limit_executor.rs index 5f346fd28d2..771d5320164 100644 --- a/components/tidb_query_executors/src/limit_executor.rs +++ b/components/tidb_query_executors/src/limit_executor.rs @@ -1,10 +1,20 @@ // Copyright 2019 Ti...
[ "components/tidb_query_executors/src/limit_executor.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**Typo: `preifx_key_col_index` → `prefix_key_col_index`.**\n\n\n\n<details>\n<summary>✏️ Fix</summary>\n\n```diff\n- for preifx_key_col_index in 0..self.truncate_key_num {\n- if current_key[preifx_key_col_index]...
true
tikv/tikv
19,306
comment_to_fix
Support rank limit
_⚠️ Potential issue_ | _🔴 Critical_ **Arithmetic underflow panic when source returns an empty batch.** When the source executor returns a batch with 0 logical rows (e.g., `is_drained: Remain` with empty results), `total_row_num` is 0. Since `0 < self.remaining_rows` is true (for any positive limit), `output_row_num`...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/components/tidb_query_executors/src/limit_executor.rs b/components/tidb_query_executors/src/limit_executor.rs index 5f346fd28d2..771d5320164 100644 --- a/components/tidb_query_executors/src/limit_executor.rs +++ b/components/tidb_query_executors/src/limit_executor.rs @@ -1,10 +1,20 @@ // Copyright 2019 Ti...
[ "components/tidb_query_executors/src/limit_executor.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🔴 Critical_\n\n**Arithmetic underflow panic when source returns an empty batch.**\n\nWhen the source executor returns a batch with 0 logical rows (e.g., `is_drained: Remain` with empty results), `total_row_num` is 0. Since `0 < self.remaining_rows` is true (for any positiv...
true
tikv/tikv
19,306
comment_to_fix
Support rank limit
_⚠️ Potential issue_ | _🔴 Critical_ **Forcing `Drain` on empty batch can cause data loss.** When the source returns 0 logical rows with `is_drained: Ok(BatchExecIsDrain::Remain)` (a valid scenario in batched execution — the source has more data but produced nothing this iteration), lines 306–307 unconditionally over...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/components/tidb_query_executors/src/limit_executor.rs b/components/tidb_query_executors/src/limit_executor.rs index 5f346fd28d2..771d5320164 100644 --- a/components/tidb_query_executors/src/limit_executor.rs +++ b/components/tidb_query_executors/src/limit_executor.rs @@ -1,10 +1,20 @@ // Copyright 2019 Ti...
[ "components/tidb_query_executors/src/limit_executor.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🔴 Critical_\n\n**Forcing `Drain` on empty batch can cause data loss.**\n\nWhen the source returns 0 logical rows with `is_drained: Ok(BatchExecIsDrain::Remain)` (a valid scenario in batched execution — the source has more data but produced nothing this iteration), lines 30...
true
tikv/tikv
19,306
comment_to_fix
Support rank limit
_⚠️ Potential issue_ | _🟡 Minor_ **Overwriting `is_drained` may suppress source errors.** When `output_row_num < result.logical_rows.len()`, line 341 unconditionally sets `result.is_drained = Ok(BatchExecIsDrain::Drain)`. If the source returned `is_drained: Err(...)`, the error is silently discarded. Consider preser...
030d7b4b4dc3211304cab22aa20cf4c566a68217
657d2110b489b377d9df65bf8e1287cfad808b7c
diff --git a/components/tidb_query_executors/src/limit_executor.rs b/components/tidb_query_executors/src/limit_executor.rs index 5f346fd28d2..771d5320164 100644 --- a/components/tidb_query_executors/src/limit_executor.rs +++ b/components/tidb_query_executors/src/limit_executor.rs @@ -1,10 +1,20 @@ // Copyright 2019 Ti...
[ "components/tidb_query_executors/src/limit_executor.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_\n\n**Overwriting `is_drained` may suppress source errors.**\n\nWhen `output_row_num < result.logical_rows.len()`, line 341 unconditionally sets `result.is_drained = Ok(BatchExecIsDrain::Drain)`. If the source returned `is_drained: Err(...)`, the error is silently ...
true
tikv/tikv
19,687
issue_to_patch
in_memory_engine: fix manual eviction leaves regions stuck in Evicting (#19586)
This is an automated cherry-pick of #19586 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
9c703408800b225d035025ca1112d117b1c82fbe
diff --git a/components/in_memory_engine/src/background.rs b/components/in_memory_engine/src/background.rs index 74a1dd3d78f..9d777f1079e 100644 --- a/components/in_memory_engine/src/background.rs +++ b/components/in_memory_engine/src/background.rs @@ -283,6 +283,7 @@ impl BgWorkManager { pub fn start_bg_hint_serv...
[ "components/in_memory_engine/src/background.rs", "components/in_memory_engine/src/region_label.rs" ]
[]
true
tikv/tikv
19,613
issue_to_patch
raftstore: fail fast on EPS disk hang to avoid zombie leaders ### Background TiKV can enter a zombie-like failure mode when the underlying EBS disk on a store becomes unresponsive. In this state, the process may still appear alive and can continue to hold Raft leadership, but it is no longer able to make meaningful f...
raftstore: fail fast on disk hang
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore-v2/src/batch/store.rs b/components/raftstore-v2/src/batch/store.rs index 648ede2aff5..465c56a3a87 100644 --- a/components/raftstore-v2/src/batch/store.rs +++ b/components/raftstore-v2/src/batch/store.rs @@ -5,7 +5,7 @@ use std::{ path::Path, sync::{ Arc, Mutex, - ...
[ "components/raftstore-v2/src/batch/store.rs", "components/raftstore/src/store/async_io/write.rs", "components/raftstore/src/store/async_io/write_tests.rs", "components/raftstore/src/store/config.rs", "components/raftstore/src/store/disk_probe.rs", "components/raftstore/src/store/fail_fast.rs", "componen...
[ { "comment": "`try_start_probe()`'s return value is ignored. If it returns `false` (probe already marked in-flight), this code still calls `probe_once()`, making the probe state inconsistent and potentially allowing overlapping probes. Prefer: (a) early-return `None` when `try_start_probe()` is `false`, or (b) ...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
`try_start_probe()`'s return value is ignored. If it returns `false` (probe already marked in-flight), this code still calls `probe_once()`, making the probe state inconsistent and potentially allowing overlapping probes. Prefer: (a) early-return `None` when `try_start_probe()` is `false`, or (b) remove the guard entir...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/worker/disk_check.rs b/components/raftstore/src/store/worker/disk_check.rs index 0f0046a4d92..a1037f53cd7 100644 --- a/components/raftstore/src/store/worker/disk_check.rs +++ b/components/raftstore/src/store/worker/disk_check.rs @@ -2,7 +2,6 @@ use std::{ fmt::{self, ...
[ "components/raftstore/src/store/worker/disk_check.rs" ]
[ { "comment": "`try_start_probe()`'s return value is ignored. If it returns `false` (probe already marked in-flight), this code still calls `probe_once()`, making the probe state inconsistent and potentially allowing overlapping probes. Prefer: (a) early-return `None` when `try_start_probe()` is `false`, or (b) ...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
The config field is documented as 'exits when the Raft disk probe makes no successful progress for this long', but the trigger condition only fires when there is an in-flight probe whose elapsed time exceeds the timeout (i.e., hang), not when probes keep failing quickly for a long period (no successful progress). Eithe...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fail_fast.rs b/components/raftstore/src/store/fail_fast.rs new file mode 100644 index 00000000000..ac9e9a36f85 --- /dev/null +++ b/components/raftstore/src/store/fail_fast.rs @@ -0,0 +1,529 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ +...
[ "components/raftstore/src/store/fail_fast.rs" ]
[ { "comment": "The config field is documented as 'exits when the Raft disk probe makes no successful progress for this long', but the trigger condition only fires when there is an in-flight probe whose elapsed time exceeds the timeout (i.e., hang), not when probes keep failing quickly for a long period (no succe...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
The config field is documented as 'exits when the Raft disk probe makes no successful progress for this long', but the trigger condition only fires when there is an in-flight probe whose elapsed time exceeds the timeout (i.e., hang), not when probes keep failing quickly for a long period (no successful progress). Eithe...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fail_fast.rs b/components/raftstore/src/store/fail_fast.rs new file mode 100644 index 00000000000..ac9e9a36f85 --- /dev/null +++ b/components/raftstore/src/store/fail_fast.rs @@ -0,0 +1,529 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ +...
[ "components/raftstore/src/store/fail_fast.rs" ]
[ { "comment": "The config field is documented as 'exits when the Raft disk probe makes no successful progress for this long', but the trigger condition only fires when there is an in-flight probe whose elapsed time exceeds the timeout (i.e., hang), not when probes keep failing quickly for a long period (no succe...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
`start()` is a no-op while `new()` already spawns background tasks. This makes the lifecycle misleading (callers might assume `start()` is required or that it changes state). Consider either moving the `spawn_interval_task` setup into `start()` (so `new()` is cheap and side-effect-free) or removing `start()` and the ca...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fail_fast.rs b/components/raftstore/src/store/fail_fast.rs new file mode 100644 index 00000000000..ac9e9a36f85 --- /dev/null +++ b/components/raftstore/src/store/fail_fast.rs @@ -0,0 +1,529 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ +...
[ "components/raftstore/src/store/fail_fast.rs" ]
[ { "comment": "`start()` is a no-op while `new()` already spawns background tasks. This makes the lifecycle misleading (callers might assume `start()` is required or that it changes state). Consider either moving the `spawn_interval_task` setup into `start()` (so `new()` is cheap and side-effect-free) or removin...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_ **Don’t run the blocking probes while fail-fast is disabled.** `disk_hang_timeout` defaults to `None`, but `new()` still starts both `write + sync_all` probe loops immediately and the checker just returns early. That means the default config still adds background fsyn...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fail_fast.rs b/components/raftstore/src/store/fail_fast.rs new file mode 100644 index 00000000000..ac9e9a36f85 --- /dev/null +++ b/components/raftstore/src/store/fail_fast.rs @@ -0,0 +1,529 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ +...
[ "components/raftstore/src/store/fail_fast.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_\n\n**Don’t run the blocking probes while fail-fast is disabled.**\n\n`disk_hang_timeout` defaults to `None`, but `new()` still starts both `write + sync_all` probe loops immediately and the checker just returns early. That means the default config ...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _🏗️ Heavy lift_ **Skip the KV probe when raft and KV share the same mount.** This wiring always enables both probe paths, but the new config/docs explicitly describe probing both disks only when they are on different mount points. On the common shared-mount setup that turns one he...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fsm/store.rs b/components/raftstore/src/store/fsm/store.rs index 091d9694a2c..8f0825b7409 100644 --- a/components/raftstore/src/store/fsm/store.rs +++ b/components/raftstore/src/store/fsm/store.rs @@ -10,6 +10,7 @@ use std::{ }, mem, ops::{Deref, DerefMut}, + ...
[ "components/raftstore/src/store/fsm/store.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _🏗️ Heavy lift_\n\n**Skip the KV probe when raft and KV share the same mount.**\n\nThis wiring always enables both probe paths, but the new config/docs explicitly describe probing both disks only when they are on different mount points. On the common shared-mou...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟡 Minor_ | _⚡ Quick win_ **Reject sub-second `disk_hang_timeout` values or document the 1s resolution.** The fail-fast checker only samples probe state once per second, so values below `1s` cannot fire at the configured bound. Right now the setting reads like an exact timeout even though the ...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/config.rs b/components/raftstore/src/store/config.rs index a85d81fef14..4924650d044 100644 --- a/components/raftstore/src/store/config.rs +++ b/components/raftstore/src/store/config.rs @@ -22,6 +22,8 @@ use time::Duration as TimeDuration; use super::worker::{RaftStoreBatchCo...
[ "components/raftstore/src/store/config.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟡 Minor_ | _⚡ Quick win_\n\n**Reject sub-second `disk_hang_timeout` values or document the 1s resolution.**\n\nThe fail-fast checker only samples probe state once per second, so values below `1s` cannot fire at the configured bound. Right now the setting reads like an exac...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _🏗️ Heavy lift_ <details> <summary>🧩 Analysis chain</summary> 🏁 Script executed: ```shell #!/bin/bash set -euo pipefail # Locate the relevant symbols/usages in the file FILE="components/raftstore/src/store/async_io/write.rs" if [ ! -f "$FILE" ]; then echo "File not found: $F...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/async_io/write.rs b/components/raftstore/src/store/async_io/write.rs index 8f5bfff1f58..67d20b0e135 100644 --- a/components/raftstore/src/store/async_io/write.rs +++ b/components/raftstore/src/store/async_io/write.rs @@ -10,7 +10,10 @@ use std::{ collections::VecDeque, ...
[ "components/raftstore/src/store/async_io/write.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _🏗️ Heavy lift_\n\n<details>\n<summary>🧩 Analysis chain</summary>\n\n🏁 Script executed:\n\n```shell\n#!/bin/bash\nset -euo pipefail\n\n# Locate the relevant symbols/usages in the file\nFILE=\"components/raftstore/src/store/async_io/write.rs\"\nif [ ! -f \"$FI...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_ **Fail closed if the probe thread cannot start.** If this spawn fails, the checker keeps running against probes that will never start, so the node silently loses the fail-fast protection while continuing to serve traffic. Please make monitor startup fatal, or propagat...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/fail_fast.rs b/components/raftstore/src/store/fail_fast.rs new file mode 100644 index 00000000000..ac9e9a36f85 --- /dev/null +++ b/components/raftstore/src/store/fail_fast.rs @@ -0,0 +1,529 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ +...
[ "components/raftstore/src/store/fail_fast.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_\n\n**Fail closed if the probe thread cannot start.**\n\nIf this spawn fails, the checker keeps running against probes that will never start, so the node silently loses the fail-fast protection while continuing to serve traffic. Please make monitor ...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_ **Prevent older writers from moving the shared append timestamp backwards.** All store writers share this `Arc<AtomicU64>`, so a plain `store()` is racy here: one writer can capture an older timestamp, get descheduled, and then overwrite a newer value published by ano...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/async_io/write.rs b/components/raftstore/src/store/async_io/write.rs index 8f5bfff1f58..67d20b0e135 100644 --- a/components/raftstore/src/store/async_io/write.rs +++ b/components/raftstore/src/store/async_io/write.rs @@ -10,7 +10,10 @@ use std::{ collections::VecDeque, ...
[ "components/raftstore/src/store/async_io/write.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_\n\n**Prevent older writers from moving the shared append timestamp backwards.**\n\nAll store writers share this `Arc<AtomicU64>`, so a plain `store()` is racy here: one writer can capture an older timestamp, get descheduled, and then overwrite a ne...
true
tikv/tikv
19,613
comment_to_fix
raftstore: fail fast on disk hang
_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_ **Keep the `0s` disable path consistent with the monitor.** This validation now rejects `disk_hang_timeout = 0s`, but `components/raftstore/src/store/fail_fast.rs` still treats `0` as "disabled" and skips probing/exit logic. That leaves the runtime disable branch unre...
0d08f98188fc015eff2ec2968f969576c146f369
dee87dca513da5729e7efa46ba83e806282c137a
diff --git a/components/raftstore/src/store/config.rs b/components/raftstore/src/store/config.rs index a85d81fef14..4924650d044 100644 --- a/components/raftstore/src/store/config.rs +++ b/components/raftstore/src/store/config.rs @@ -22,6 +22,8 @@ use time::Duration as TimeDuration; use super::worker::{RaftStoreBatchCo...
[ "components/raftstore/src/store/config.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🟠 Major_ | _⚡ Quick win_\n\n**Keep the `0s` disable path consistent with the monitor.**\n\nThis validation now rejects `disk_hang_timeout = 0s`, but `components/raftstore/src/store/fail_fast.rs` still treats `0` as \"disabled\" and skips probing/exit logic. That leaves the...
true
tikv/tikv
19,649
issue_to_patch
read pool queue fairness (#19385)
This is an automated cherry-pick of #19385 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
b7482f3f0af9d7566247681cf127b84ac3af8318
diff --git a/Cargo.lock b/Cargo.lock index bd0ff4e2416..376e49374e7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -9885,7 +9885,7 @@ checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" [[package]] name = "yatp" version = "0.0.1" -source = "git+https://github.com/tikv/yatp.git?branch=master#79...
[ "Cargo.lock", "components/resource_control/src/resource_group.rs", "src/read_pool.rs" ]
[]
true
tikv/tikv
19,554
issue_to_patch
Throttle background traffic (#19396)
This is an automated cherry-pick of #19396 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
6cfa83495369d5f57a6186dd54e446054e2ce783
diff --git a/components/backup/src/endpoint.rs b/components/backup/src/endpoint.rs index 162e9c883c7..d05f7a72e27 100644 --- a/components/backup/src/endpoint.rs +++ b/components/backup/src/endpoint.rs @@ -244,7 +244,8 @@ async fn save_backup_file_worker<EK: KvEngine>( ) { while let Ok(msg) = rx.recv().await { ...
[ "components/backup/src/endpoint.rs", "components/resource_control/src/config.rs", "components/resource_control/src/future.rs", "components/resource_control/src/lib.rs", "components/resource_control/src/resource_group.rs", "components/resource_control/src/resource_limiter.rs", "components/resource_contro...
[]
diff --git a/tests/integrations/config/mod.rs b/tests/integrations/config/mod.rs index 5018366a5bf..ba3d2928f77 100644 --- a/tests/integrations/config/mod.rs +++ b/tests/integrations/config/mod.rs @@ -910,6 +910,10 @@ fn test_serde_custom_tikv_config() { value.resource_control = ResourceControlConfig { en...
true
tikv/tikv
19,553
issue_to_patch
add min wait between two compaction rounds (#19361)
This is an automated cherry-pick of #19361 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
8c68760de4a263095071c80a1951157d6e6aa246
9e0eb9462053c282aa42be5e6474489732a4dc65
diff --git a/src/server/gc_worker/compaction_runner.rs b/src/server/gc_worker/compaction_runner.rs index c77bb5c98d6..b96fc0cd1c2 100644 --- a/src/server/gc_worker/compaction_runner.rs +++ b/src/server/gc_worker/compaction_runner.rs @@ -294,12 +294,23 @@ impl<S: GcSafePointProvider, R: RegionInfoProvider + 'static, E: ...
[ "src/server/gc_worker/compaction_runner.rs" ]
[]
true
tikv/tikv
19,657
issue_to_patch
sst_service: add txn_source for `apply` ## Development Task See https://github.com/pingcap/tidb/issues/68660 Effectively, TiCDC ignores writes created from an `apply` request due to absense of prewrite. But this path probably hurts changefeed's healthy.
import: mark applied write cf txn source
### What is changed and how it works? Issue Number: close #19669, ref pingcap/tidb#68660 What's Changed: ```commit-message import: mark applied write CF entries with physical import txn source PITR restores write CF records through apply log. Before this change, restored Put/Delete write records did not ca...
176eb0d654df43b8a5dcc082b74903f615d0c42a
aec7367455cfa6dde7f25c5412a2b487a01bae58
diff --git a/src/import/sst_service.rs b/src/import/sst_service.rs index 92537d971c1..6cb76138c40 100644 --- a/src/import/sst_service.rs +++ b/src/import/sst_service.rs @@ -104,6 +104,10 @@ const HIGH_IMPORT_MEMORY_WATER_RATIO: f64 = 0.95; // cleaned up eventually. const DEFAULT_FORCE_PARTITION_RANGE_TTL_SECONDS: u64...
[ "src/import/sst_service.rs", "tests/integrations/import/test_apply_log.rs" ]
[ { "comment": "The comment references an absolute local workspace path (`/workspace/tikv/pitr-txn-source/...`), which won’t exist for other contributors and will quickly become stale. Use a repository-relative path and clarify what the bit represents (this matches `components/cdc/src/txn_source.rs`, where the 17...
diff --git a/tests/integrations/import/test_apply_log.rs b/tests/integrations/import/test_apply_log.rs index afd01ce6935..ed72aa091f3 100644 --- a/tests/integrations/import/test_apply_log.rs +++ b/tests/integrations/import/test_apply_log.rs @@ -1,11 +1,12 @@ // Copyright 2024 TiKV Project Authors. Licensed under Apach...
true
tikv/tikv
19,619
issue_to_patch
The grpc function `get_last_flush_ts_of_region` response `not found` error but leaders are in the TiKV ## Bug Report <!-- Thanks for your bug report! Don't worry if you can't fill out all the sections. --> ### What version of TiKV are you using? <!-- You can run `tikv-server --version` --> v8.5 ### What operating sy...
backup-stream: add log for backup stream grpc service
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/checkpoint_manager.rs b/components/backup-stream/src/checkpoint_manager.rs index 01734a69f4f..885cfb1ee0d 100644 --- a/components/backup-stream/src/checkpoint_manager.rs +++ b/components/backup-stream/src/checkpoint_manager.rs @@ -386,6 +386,10 @@ impl CheckpointManager { ...
[ "components/backup-stream/src/checkpoint_manager.rs", "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/service.rs" ]
[ { "comment": "`region_epoch_version` in the `EpochNotMatch` variant is ambiguous (is it the requested epoch version or the current/actual region epoch version?). Rename the fields to be explicit (e.g., `requested_epoch_version` / `current_epoch_version`) or include both to avoid misleading diagnostics in logs."...
true
tikv/tikv
19,619
comment_to_fix
backup-stream: add log for backup stream grpc service
`region_epoch_version` in the `EpochNotMatch` variant is ambiguous (is it the requested epoch version or the current/actual region epoch version?). Rename the fields to be explicit (e.g., `requested_epoch_version` / `current_epoch_version`) or include both to avoid misleading diagnostics in logs.
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..0633b54174a 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -77,6 +77,34 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0; /// task has fatal error. con...
[ "components/backup-stream/src/endpoint.rs" ]
[ { "comment": "`region_epoch_version` in the `EpochNotMatch` variant is ambiguous (is it the requested epoch version or the current/actual region epoch version?). Rename the fields to be explicit (e.g., `requested_epoch_version` / `current_epoch_version`) or include both to avoid misleading diagnostics in logs."...
true
tikv/tikv
19,619
comment_to_fix
backup-stream: add log for backup stream grpc service
This manual `Debug` impl is verbose and easy to drift from the enum’s actual shape over time. If you don’t need a custom format beyond standard variant/field printing, prefer `#[derive(Debug)]`; if you do need a specific shape, consider documenting why to prevent future “simplification” that loses intended log structur...
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..0633b54174a 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -77,6 +77,34 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0; /// task has fatal error. con...
[ "components/backup-stream/src/endpoint.rs" ]
[ { "comment": "This manual `Debug` impl is verbose and easy to drift from the enum’s actual shape over time. If you don’t need a custom format beyond standard variant/field printing, prefer `#[derive(Debug)]`; if you do need a specific shape, consider documenting why to prevent future “simplification” that loses...
true
tikv/tikv
19,619
comment_to_fix
backup-stream: add log for backup stream grpc service
The log message is grammatically unclear and doesn’t crisply state what failed. Reword to clearly indicate partial failures and context (e.g., “failed to get checkpoints for some regions”) so operators can immediately understand the condition.
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..0633b54174a 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -77,6 +77,34 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0; /// task has fatal error. con...
[ "components/backup-stream/src/endpoint.rs" ]
[ { "comment": "The log message is grammatically unclear and doesn’t crisply state what failed. Reword to clearly indicate partial failures and context (e.g., “failed to get checkpoints for some regions”) so operators can immediately understand the condition.", "path": "components/backup-stream/src/endpoint.r...
true
tikv/tikv
19,619
comment_to_fix
backup-stream: add log for backup stream grpc service
Better to remove this, then directly print `GetCheckpointResult` as sample?
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..0633b54174a 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -77,6 +77,34 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0; /// task has fatal error. con...
[ "components/backup-stream/src/endpoint.rs" ]
[ { "comment": "Better to remove this, then directly print `GetCheckpointResult` as sample?", "path": "components/backup-stream/src/endpoint.rs", "hunk": "@@ -77,6 +77,40 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0;\n /// task has fatal error.\n const CHECKPOINT_SAFEPOINT_TTL_IF_ERROR: u64 = 24;\n \n+enum ...
true
tikv/tikv
19,619
comment_to_fix
backup-stream: add log for backup stream grpc service
Use `#[drive(Debug)]` instead.
0d08f98188fc015eff2ec2968f969576c146f369
e33ff8ecf11d32618932ccf98fd37275d40a626e
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..0633b54174a 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -77,6 +77,34 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0; /// task has fatal error. con...
[ "components/backup-stream/src/endpoint.rs" ]
[ { "comment": "Use `#[drive(Debug)]` instead.", "path": "components/backup-stream/src/endpoint.rs", "hunk": "@@ -77,6 +77,40 @@ const SLOW_EVENT_THRESHOLD: f64 = 120.0;\n /// task has fatal error.\n const CHECKPOINT_SAFEPOINT_TTL_IF_ERROR: u64 = 24;\n \n+enum SampleCheckpoint {\n+ NotFound {\n+ ...
true
tikv/tikv
19,612
issue_to_patch
TiCDC stuck due to sink memory quota is full ## Bug Report <!-- Thanks for your bug report! Don't worry if you can't fill out all the sections. --> ### What version of TiKV are you using? <!-- You can run `tikv-server --version` --> v7.5.7 ### What operating system and CPU are you using? <!-- If you're using Linux, ...
cdc: cancel both send and receive on watchdog abort
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/Cargo.toml b/components/cdc/Cargo.toml index 592effa62bd..a71560c5efa 100644 --- a/components/cdc/Cargo.toml +++ b/components/cdc/Cargo.toml @@ -61,7 +61,7 @@ thiserror = "1.0" tikv = { workspace = true } tikv_kv = { workspace = true } tikv_util = { workspace = true } -tokio = { version =...
[ "components/cdc/Cargo.toml", "components/cdc/src/channel.rs", "components/cdc/src/delegate.rs", "components/cdc/src/endpoint.rs", "components/cdc/src/initializer.rs", "components/cdc/src/lib.rs", "components/cdc/src/service.rs", "components/cdc/src/types.rs", "components/cdc/src/watchdog.rs", "com...
[ { "comment": "`watch::Receiver::changed()` completes with `Err` when the sender is dropped; since the result is ignored in `select!`, a normal drop of `cancel_tx` can be misinterpreted as an explicit cancellation. Handle the `Result` from `changed()` and only treat it as cancellation when the watched value is a...
diff --git a/components/cdc/tests/failpoints/test_endpoint.rs b/components/cdc/tests/failpoints/test_endpoint.rs index 12b44bd163d..403aebfa8cf 100644 --- a/components/cdc/tests/failpoints/test_endpoint.rs +++ b/components/cdc/tests/failpoints/test_endpoint.rs @@ -744,94 +744,3 @@ fn test_cdc_unresolved_region_count_be...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
`watch::Receiver::changed()` completes with `Err` when the sender is dropped; since the result is ignored in `select!`, a normal drop of `cancel_tx` can be misinterpreted as an explicit cancellation. Handle the `Result` from `changed()` and only treat it as cancellation when the watched value is actually set (e.g., `tr...
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/service.rs b/components/cdc/src/service.rs index c971f6e8200..d3ad11c915f 100644 --- a/components/cdc/src/service.rs +++ b/components/cdc/src/service.rs @@ -1,20 +1,10 @@ // Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0. -use std::{ - sync::{ - Arc, - ...
[ "components/cdc/src/service.rs" ]
[ { "comment": "`watch::Receiver::changed()` completes with `Err` when the sender is dropped; since the result is ignored in `select!`, a normal drop of `cancel_tx` can be misinterpreted as an explicit cancellation. Handle the `Result` from `changed()` and only treat it as cancellation when the watched value is a...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
Same issue as the receive side: ignoring the `Result` from `send_cancel_rx.changed()` can cause this branch to run when the `watch::Sender` is dropped (not necessarily when a cancellation is requested), which would incorrectly fail the gRPC sink with `connection cancelled`. Match on `changed().await` and verify the can...
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/service.rs b/components/cdc/src/service.rs index c971f6e8200..d3ad11c915f 100644 --- a/components/cdc/src/service.rs +++ b/components/cdc/src/service.rs @@ -1,20 +1,10 @@ // Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0. -use std::{ - sync::{ - Arc, - ...
[ "components/cdc/src/service.rs" ]
[ { "comment": "Same issue as the receive side: ignoring the `Result` from `send_cancel_rx.changed()` can cause this branch to run when the `watch::Sender` is dropped (not necessarily when a cancellation is requested), which would incorrectly fail the gRPC sink with `connection cancelled`. Match on `changed().awa...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
This test verifies that a change notification arrives, but it doesn’t assert that the cancellation value is actually set (e.g., `true`). After `changed().await`, also assert the observed value from the receiver (via `borrow()` / `borrow_and_update()`) to ensure the watchdog didn’t trigger due to sender-drop or another ...
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/service.rs b/components/cdc/src/service.rs index c971f6e8200..d3ad11c915f 100644 --- a/components/cdc/src/service.rs +++ b/components/cdc/src/service.rs @@ -1,20 +1,10 @@ // Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0. -use std::{ - sync::{ - Arc, - ...
[ "components/cdc/src/service.rs" ]
[ { "comment": "This test verifies that a change notification arrives, but it doesn’t assert that the cancellation value is actually set (e.g., `true`). After `changed().await`, also assert the observed value from the receiver (via `borrow()` / `borrow_and_update()`) to ensure the watchdog didn’t trigger due to s...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
```suggestion // Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. ```
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/watchdog.rs b/components/cdc/src/watchdog.rs new file mode 100644 index 00000000000..7d0d9bc5d5b --- /dev/null +++ b/components/cdc/src/watchdog.rs @@ -0,0 +1,341 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ + future, + sync::Arc, + time::...
[ "components/cdc/src/watchdog.rs" ]
[ { "comment": "```suggestion\n// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0.\n```", "path": "components/cdc/src/watchdog.rs", "hunk": "@@ -0,0 +1,206 @@\n+// Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0.", "resolving_sha": "09e3942c56de71675b44891ed585c0a36c655ed...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
ditto
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/watchdog.rs b/components/cdc/src/watchdog.rs new file mode 100644 index 00000000000..7d0d9bc5d5b --- /dev/null +++ b/components/cdc/src/watchdog.rs @@ -0,0 +1,341 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ + future, + sync::Arc, + time::...
[ "components/cdc/src/watchdog.rs" ]
[ { "comment": "ditto", "path": "components/cdc/src/watchdog.rs", "hunk": "@@ -0,0 +1,206 @@\n+// Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0.\n+\n+use std::{\n+ future,\n+ sync::Arc,\n+ time::{Duration, Instant},\n+};\n+\n+use crossbeam::atomic::AtomicCell;\n+use futures::{com...
true
tikv/tikv
19,612
comment_to_fix
cdc: cancel both send and receive on watchdog abort
ditto
7703b2159a2bd4e0a48e31a44003493443a4dc01
09e3942c56de71675b44891ed585c0a36c655eda
diff --git a/components/cdc/src/watchdog.rs b/components/cdc/src/watchdog.rs new file mode 100644 index 00000000000..7d0d9bc5d5b --- /dev/null +++ b/components/cdc/src/watchdog.rs @@ -0,0 +1,341 @@ +// Copyright 2026 TiKV Project Authors. Licensed under Apache-2.0. + +use std::{ + future, + sync::Arc, + time::...
[ "components/cdc/src/watchdog.rs" ]
[ { "comment": "ditto", "path": "components/cdc/src/watchdog.rs", "hunk": "@@ -0,0 +1,206 @@\n+// Copyright 2020 TiKV Project Authors. Licensed under Apache-2.0.\n+\n+use std::{\n+ future,\n+ sync::Arc,\n+ time::{Duration, Instant},\n+};\n+\n+use crossbeam::atomic::AtomicCell;\n+use futures::{com...
true
tikv/tikv
19,586
issue_to_patch
In-memory Engine: manual removal leaves regions stucks in `Evicting` ## Bug Report <!-- Thanks for your bug report! Don't worry if you can't fill out all the sections. --> Manual region removal through `RegionLabelRulesManager` calls `RegionManager::evict_region`, which only updates the region state to `Evicting`. I...
in_memory_engine: fix manual eviction leaves regions stuck in Evicting
<!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. PR Title Format: 1. module [, module2, modu...
b96b66319b5663e2c04e7ed3e9f167bf61ce4ac7
98cb31b57e8e430cac36637bae20b00447becb0c
diff --git a/components/in_memory_engine/src/background.rs b/components/in_memory_engine/src/background.rs index ca9f57bb8f1..d5f01d041cd 100644 --- a/components/in_memory_engine/src/background.rs +++ b/components/in_memory_engine/src/background.rs @@ -283,6 +283,7 @@ impl BgWorkManager { pub fn start_bg_hint_serv...
[ "components/in_memory_engine/src/background.rs", "components/in_memory_engine/src/region_label.rs" ]
[]
true
tikv/tikv
19,648
issue_to_patch
log_backup: "register backup stream ranges" is stuck forever when there are >32768 regions to initialize ## Bug Report ### What version of TiKV are you using? v8.5.6 (also reproduced on v8.1.2) ### What operating system and CPU are you using? ### Steps to reproduce 1. Create a cluster ```sh tiup playgrou...
backup-stream: fix initial range scan deadlock
### What is changed and how it works? Issue Number: Close #19615 What's Changed: ```commit-message backup-stream: fix initial range scan deadlock When log backup initializes a range with many regions, the region collector runs the seek-region callback on its own worker thread. The old callback used a bou...
176eb0d654df43b8a5dcc082b74903f615d0c42a
edf87827986151c26901b8f0fa3a0b6603f118d6
diff --git a/components/backup-stream/src/endpoint.rs b/components/backup-stream/src/endpoint.rs index dc0f08e9d10..b75e05f149f 100644 --- a/components/backup-stream/src/endpoint.rs +++ b/components/backup-stream/src/endpoint.rs @@ -640,12 +640,10 @@ where /// initialize a range: it simply scan the regions with le...
[ "components/backup-stream/src/endpoint.rs", "components/backup-stream/src/subscription_manager.rs", "components/backup-stream/tests/failpoints/mod.rs", "components/backup-stream/tests/suite.rs" ]
[ { "comment": "`wait_with_timeout` may return `false` and drop the receiver while the scheduled `Task::Sync` is still pending/rescheduling. When the condition eventually becomes true, the callback executes `tx.send(()).unwrap()`, which will panic because the receiver has been dropped. This can cause unrelated pa...
diff --git a/components/backup-stream/tests/failpoints/mod.rs b/components/backup-stream/tests/failpoints/mod.rs index 891e21d4493..49c5070d333 100644 --- a/components/backup-stream/tests/failpoints/mod.rs +++ b/components/backup-stream/tests/failpoints/mod.rs @@ -131,6 +131,41 @@ mod all { let c = suite.globa...
true
tikv/tikv
19,633
issue_to_patch
read_pool: pool size change not notified when auto-adjust is disabled ## Bug Report ### What version of TiKV are you using? Nightly (master branch). ### Steps to reproduce 1. Enable unified read pool with auto-adjust enabled and `min_thread_count < max_thread_count`. 2. Let the auto-adjust scale the pool size up (...
read_pool: notify pool size change upon AutoAdjust
### What is changed and how it works? Issue Number: Close #19632 What's Changed: ```commit-message When auto-adjust is disabled and the pool size is reset to core_thread_count, notify listeners of the pool size change. Previously, the notification was missing, causing components that rely on pool size change notific...
11b128e16d58d838c5949d7f86153105eda3dadb
f9a5894ecf122232bd8e0dae380401dece360833
diff --git a/src/read_pool.rs b/src/read_pool.rs index fbcc9e764e5..66311527203 100644 --- a/src/read_pool.rs +++ b/src/read_pool.rs @@ -778,6 +778,7 @@ impl Runnable for ReadPoolConfigRunner { if !s && self.cur_thread_count != self.core_thread_count { self.handle.scale_pool_size(s...
[ "src/read_pool.rs" ]
[ { "comment": "This test relies on a tight timing-based `recv_timeout(Duration::from_millis(100))`, which can be flaky under CI load. Since `runner.run(...)` is invoked synchronously in the test (not spawned onto another thread here), consider using a non-time-based assertion (e.g., `try_recv` immediately after ...
true
tikv/tikv
19,633
comment_to_fix
read_pool: notify pool size change upon AutoAdjust
This test relies on a tight timing-based `recv_timeout(Duration::from_millis(100))`, which can be flaky under CI load. Since `runner.run(...)` is invoked synchronously in the test (not spawned onto another thread here), consider using a non-time-based assertion (e.g., `try_recv` immediately after `run`, or `recv` if th...
11b128e16d58d838c5949d7f86153105eda3dadb
f9a5894ecf122232bd8e0dae380401dece360833
diff --git a/src/read_pool.rs b/src/read_pool.rs index fbcc9e764e5..66311527203 100644 --- a/src/read_pool.rs +++ b/src/read_pool.rs @@ -778,6 +778,7 @@ impl Runnable for ReadPoolConfigRunner { if !s && self.cur_thread_count != self.core_thread_count { self.handle.scale_pool_size(s...
[ "src/read_pool.rs" ]
[ { "comment": "This test relies on a tight timing-based `recv_timeout(Duration::from_millis(100))`, which can be flaky under CI load. Since `runner.run(...)` is invoked synchronously in the test (not spawned onto another thread here), consider using a non-time-based assertion (e.g., `try_recv` immediately after ...
true
tikv/tikv
19,633
comment_to_fix
read_pool: notify pool size change upon AutoAdjust
Unwrapping `cur_proc_stat()` can make this unit test fail with a panic on platforms/environments where process stats are unavailable. Consider handling the error by skipping the test (early return) when `cur_proc_stat()` fails, or using an `expect(...)` with a clearer message if the test environment guarantees availabi...
11b128e16d58d838c5949d7f86153105eda3dadb
f9a5894ecf122232bd8e0dae380401dece360833
diff --git a/src/read_pool.rs b/src/read_pool.rs index fbcc9e764e5..66311527203 100644 --- a/src/read_pool.rs +++ b/src/read_pool.rs @@ -778,6 +778,7 @@ impl Runnable for ReadPoolConfigRunner { if !s && self.cur_thread_count != self.core_thread_count { self.handle.scale_pool_size(s...
[ "src/read_pool.rs" ]
[ { "comment": "Unwrapping `cur_proc_stat()` can make this unit test fail with a panic on platforms/environments where process stats are unavailable. Consider handling the error by skipping the test (early return) when `cur_proc_stat()` fails, or using an `expect(...)` with a clearer message if the test environme...
true
tikv/tikv
19,633
comment_to_fix
read_pool: notify pool size change upon AutoAdjust
The test hardcodes thread counts (`2` and `8`) that duplicate values already set in `config`. Deriving these from `config` (e.g., `config.min_thread_count`, `config.max_thread_count`) reduces the chance of the test drifting out of sync if defaults/config values change.
11b128e16d58d838c5949d7f86153105eda3dadb
f9a5894ecf122232bd8e0dae380401dece360833
diff --git a/src/read_pool.rs b/src/read_pool.rs index fbcc9e764e5..66311527203 100644 --- a/src/read_pool.rs +++ b/src/read_pool.rs @@ -778,6 +778,7 @@ impl Runnable for ReadPoolConfigRunner { if !s && self.cur_thread_count != self.core_thread_count { self.handle.scale_pool_size(s...
[ "src/read_pool.rs" ]
[ { "comment": "The test hardcodes thread counts (`2` and `8`) that duplicate values already set in `config`. Deriving these from `config` (e.g., `config.min_thread_count`, `config.max_thread_count`) reduces the chance of the test drifting out of sync if defaults/config values change.\n", "path": "src/read_po...
true
tikv/tikv
19,633
comment_to_fix
read_pool: notify pool size change upon AutoAdjust
_⚠️ Potential issue_ | _🔴 Critical_ | _⚡ Quick win_ **Test initialization does not match production behavior.** The test sets `core_thread_count` to `config.min_thread_count`, but in production (`ReadPoolConfigManager::new`), `core_thread_count` is initialized to `max_thread_count`. This means the test validates res...
11b128e16d58d838c5949d7f86153105eda3dadb
f9a5894ecf122232bd8e0dae380401dece360833
diff --git a/src/read_pool.rs b/src/read_pool.rs index fbcc9e764e5..66311527203 100644 --- a/src/read_pool.rs +++ b/src/read_pool.rs @@ -778,6 +778,7 @@ impl Runnable for ReadPoolConfigRunner { if !s && self.cur_thread_count != self.core_thread_count { self.handle.scale_pool_size(s...
[ "src/read_pool.rs" ]
[ { "comment": "_⚠️ Potential issue_ | _🔴 Critical_ | _⚡ Quick win_\n\n**Test initialization does not match production behavior.**\n\nThe test sets `core_thread_count` to `config.min_thread_count`, but in production (`ReadPoolConfigManager::new`), `core_thread_count` is initialized to `max_thread_count`. This me...
true
tikv/tikv
19,678
issue_to_patch
raftstore: fix hibernate quorum feature test flake
### What is changed and how it works? Issue Number: ref #19682 What's Changed: ```commit-message The hibernate quorum feature test installed a broad send packet filter before the observation window and expected `when(filter)` to keep the `awakened` marker inactive while `filter` was false. However, `Region...
176eb0d654df43b8a5dcc082b74903f615d0c42a
f5ff8adce19ce20602d91b53b251c743b0d8c52c
[ "tests/integrations/raftstore/test_hibernate.rs" ]
[ { "comment": "The panic message labels `store_id` as `peer`, which is misleading (peer_id and store_id are different concepts). Rename the message placeholder to `store` (or change the function to accept/print the actual peer_id) so failures are diagnosable.", "path": "tests/integrations/raftstore/test_hibe...
diff --git a/tests/integrations/raftstore/test_hibernate.rs b/tests/integrations/raftstore/test_hibernate.rs index d2e9966d48e..86b1f5a1465 100644 --- a/tests/integrations/raftstore/test_hibernate.rs +++ b/tests/integrations/raftstore/test_hibernate.rs @@ -11,10 +11,29 @@ use futures::executor::block_on; use kvproto::...
true
tikv/tikv
19,678
comment_to_fix
raftstore: fix hibernate quorum feature test flake
The panic message labels `store_id` as `peer`, which is misleading (peer_id and store_id are different concepts). Rename the message placeholder to `store` (or change the function to accept/print the actual peer_id) so failures are diagnosable.
176eb0d654df43b8a5dcc082b74903f615d0c42a
f5ff8adce19ce20602d91b53b251c743b0d8c52c
diff --git a/tests/integrations/raftstore/test_hibernate.rs b/tests/integrations/raftstore/test_hibernate.rs index d2e9966d48e..86b1f5a1465 100644 --- a/tests/integrations/raftstore/test_hibernate.rs +++ b/tests/integrations/raftstore/test_hibernate.rs @@ -11,10 +11,29 @@ use futures::executor::block_on; use kvproto::...
[ "tests/integrations/raftstore/test_hibernate.rs" ]
[ { "comment": "The panic message labels `store_id` as `peer`, which is misleading (peer_id and store_id are different concepts). Rename the message placeholder to `store` (or change the function to accept/print the actual peer_id) so failures are diagnosable.", "path": "tests/integrations/raftstore/test_hibe...
true
tikv/tikv
19,678
comment_to_fix
raftstore: fix hibernate quorum feature test flake
`cluster.unstable_entries_state(region_id, store_id)` is called multiple times (each loop iteration and again in the panic). Consider reading it once per iteration into a local (e.g., `let (state, _) = ...;`) and reusing `state` for the comparison and the eventual panic message. This reduces duplication and makes the l...
176eb0d654df43b8a5dcc082b74903f615d0c42a
f5ff8adce19ce20602d91b53b251c743b0d8c52c
diff --git a/tests/integrations/raftstore/test_hibernate.rs b/tests/integrations/raftstore/test_hibernate.rs index d2e9966d48e..86b1f5a1465 100644 --- a/tests/integrations/raftstore/test_hibernate.rs +++ b/tests/integrations/raftstore/test_hibernate.rs @@ -11,10 +11,29 @@ use futures::executor::block_on; use kvproto::...
[ "tests/integrations/raftstore/test_hibernate.rs" ]
[ { "comment": "`cluster.unstable_entries_state(region_id, store_id)` is called multiple times (each loop iteration and again in the panic). Consider reading it once per iteration into a local (e.g., `let (state, _) = ...;`) and reusing `state` for the comparison and the eventual panic message. This reduces dupli...
true
tikv/tikv
19,678
comment_to_fix
raftstore: fix hibernate quorum feature test flake
The helper name `must_wait_hibernated` is a bit awkward/ambiguous (it reads like it waits *while* hibernated). Consider renaming to something more explicit like `must_wait_until_hibernated` to make call sites self-explanatory.
176eb0d654df43b8a5dcc082b74903f615d0c42a
f5ff8adce19ce20602d91b53b251c743b0d8c52c
diff --git a/tests/integrations/raftstore/test_hibernate.rs b/tests/integrations/raftstore/test_hibernate.rs index d2e9966d48e..86b1f5a1465 100644 --- a/tests/integrations/raftstore/test_hibernate.rs +++ b/tests/integrations/raftstore/test_hibernate.rs @@ -11,10 +11,29 @@ use futures::executor::block_on; use kvproto::...
[ "tests/integrations/raftstore/test_hibernate.rs" ]
[ { "comment": "The helper name `must_wait_hibernated` is a bit awkward/ambiguous (it reads like it waits *while* hibernated). Consider renaming to something more explicit like `must_wait_until_hibernated` to make call sites self-explanatory.", "path": "tests/integrations/raftstore/test_hibernate.rs", "hu...
true
tikv/tikv
19,679
issue_to_patch
[cherr-pick] raftstore: fix unreasonable snapshot cancel checking (#18873) #19101
This is a manual cherry-pick of https://github.com/tikv/tikv/pull/19101 for hotfix. <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should ...
0a1b0b1d8388aff85b501ac662675cbb0eac6542
033a7a5f5231ffc4ffbbdce3956c4e02f9978b8e
diff --git a/components/raftstore/src/store/fsm/peer.rs b/components/raftstore/src/store/fsm/peer.rs index 6d4a05a6ac2..9bea1dded3d 100644 --- a/components/raftstore/src/store/fsm/peer.rs +++ b/components/raftstore/src/store/fsm/peer.rs @@ -4467,10 +4467,19 @@ where self.fsm.peer.schedule_raftlog_gc(self.ctx, ...
[ "components/raftstore/src/store/fsm/peer.rs", "components/raftstore/src/store/peer_storage.rs" ]
[]
true
tikv/tikv
19,622
issue_to_patch
backup-stream: add flag into metadata name tag (#19609)
This is an automated cherry-pick of #19609 <!-- Thank you for contributing to TiKV! If you haven't already, please read TiKV's [CONTRIBUTING](https://github.com/tikv/tikv/blob/master/CONTRIBUTING.md) document. If you're unsure about anything, just ask; somebody should be along to answer within a day or two. ...
4c20a1b30748522a26f41d7698a7d217b146849a
32816f6b32fb7a84b93b27f197a6cbc9ca03a5ef
diff --git a/components/backup-stream/src/metrics.rs b/components/backup-stream/src/metrics.rs index 862c8c1a0b7..83ba2c2a2e3 100644 --- a/components/backup-stream/src/metrics.rs +++ b/components/backup-stream/src/metrics.rs @@ -118,6 +118,12 @@ lazy_static! { exponential_buckets(1024.0, 2.0, 16).unwrap() ...
[ "components/backup-stream/src/metrics.rs", "components/backup-stream/src/router.rs", "components/backup-stream/src/utils.rs" ]
[]
true
tikv/tikv
19,671
issue_to_patch
OWNERS: Auto Sync OWNERS files from community membership
### Check List Tests <!-- At least one of them must be included. --> - [x] No need to test > - [x] I checked and no code files have been changed. > <!-- Or your custom "No need to test" reasons -->
a763bd7ba4e56bd45a5a146b0a5712e039235d80
afe6f7c5bdc941a88ff625c47a1d13e0edc01e44
[]
[]
true