Skip to content

feat: support Redis 8.0 and Valkey 9.0#1005

Merged
suxb201 merged 6 commits intov4from
feat-redis-8
Dec 31, 2025
Merged

feat: support Redis 8.0 and Valkey 9.0#1005
suxb201 merged 6 commits intov4from
feat-redis-8

Conversation

@suxb201
Copy link
Copy Markdown
Member

@suxb201 suxb201 commented Dec 30, 2025

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread internal/commands/table.go
@suxb201 suxb201 force-pushed the feat-redis-8 branch 2 times, most recently from d2a96e7 to a75480f Compare December 30, 2025 09:51
@suxb201
Copy link
Copy Markdown
Member Author

suxb201 commented Dec 31, 2025

@codex review

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 296 to +300
typeByte := dump[0]
anotherReader := strings.NewReader(dump[1 : len(dump)-10])
o := types.ParseObject(anotherReader, typeByte, key)
// TODO: detect if server is Valkey and pass appropriate flag
// For now, assume Redis format (false)
o := types.ParseObject(anotherReader, typeByte, key, false)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Pass Valkey format flag when rewriting large DUMP payloads

When a key’s serialized DUMP exceeds TargetRedisProtoMaxBulkLen, this path rewrites the value by calling ParseObject(..., false), which forces the Redis 8 hash-expiration format. For Valkey 9 sources, type 22 hashes use the Valkey HASH_2 layout (field/value/8‑byte TTL), and ParseObject only switches to that decoding when isValkey is true. That means large Valkey hashes with field expiration will be mis-parsed (wrong TTLs or stream desync/panic) during scan-based migrations. This only happens in scan mode for large keys on Valkey 9+, but it will silently corrupt data or fail under those conditions.

Useful? React with 👍 / 👎.

@suxb201 suxb201 merged commit 6e0d05b into v4 Dec 31, 2025
10 checks passed
@suxb201 suxb201 deleted the feat-redis-8 branch December 31, 2025 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant