Comments (1)
This bug is due to the fact that the entries_read field should return 0 when it is undetermined. The current lag is determined based on entries_read.
So, there are two situations that we are clear about:
s->max_deleted_entry_id <= cg->last_id
andcg->last_id <= s.first_id
- if
cg->last_id < s.first_id
thencg->entries_read = s->entries_added - s->length;
- if
cg->last_id == s.first_id
thencg->entries_read = s->entries_added - s->length - 1;
- if
s->max_deleted_entry_id <= cg->last_id and cg->last_id == s->last_id
- the result is
cg->entries_read = s->entries_added
- the result is
- otherwise: cg->entries_read = SCG_INVALID_ENTRIES_READ
In native logic, there exists an empty stream logic:
- s->length == 0 and cg->last_id < s->last_id
cg->entries_read = s->entries_added
This is unreasonable because the current entries_read cannot be the same as entries_added. I suggest that We should remove this.
Based on this conclusion, I will first attempt to submit a PR. Could you please help me check if the conclusion is correct. Or what additional information do I need to provide to help everyone make a judgment. @madolson @stockholmux .tks
from valkey.
Related Issues (20)
- [Daily Test Failure] tests/unit/cluster/slot-migration.tcl in test-macos-latest
- Improve type safety of key embedding
- code usege of sds (and maybe other data types) HOT 1
- Add maxmemory-reserved-scale parameter to evict keys earlier HOT 2
- [NEW] WAIT ALL HOT 4
- [BUG] Example ACL for sentinel does not work HOT 1
- []Defrag level is calculated correctly HOT 1
- [NEW] Cluster support without special client bindings HOT 2
- [NEW] Opt-in for inclusive language (primary/replia in ROLE reply, CLUSTER SHARDS, etc.) HOT 4
- Regression from PR #445 Incorrectly Allows Slot Ownership Updates via Replica HOT 1
- Followup items from https://github.com/valkey-io/valkey/pull/758
- [NEW] Better branching strategy for Valkey HOT 10
- [Test Case Fail]External Server Tests HOT 3
- [BUG] nodes.conf can be corrupted when node is restarted before cluster shard ID stabilizes (for 7.2) HOT 5
- [BUG] CLUSTER SHARDS command returns "empty array" in slots section HOT 3
- [NEW] Can we add 'count' option to the 'RANDOMKEY' command? HOT 5
- [NEW] Nightly builds for Docker
- Update rioconnwrite size from https://github.com/valkey-io/valkey/pull/60 HOT 2
- Missing Check for Sender's Config Epoch Before Accepting Primary Claim
- Blocking commands are marked as being nested
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from valkey.