Skip to content

feat: add XADD IDMP/IDMPAUTO and XCFGSET support#954

Merged
rueian merged 1 commit intoredis:mainfrom
jinbum-kim:feat/idmp-xcfgset
Mar 1, 2026
Merged

feat: add XADD IDMP/IDMPAUTO and XCFGSET support#954
rueian merged 1 commit intoredis:mainfrom
jinbum-kim:feat/idmp-xcfgset

Conversation

@jinbum-kim
Copy link
Copy Markdown
Contributor

@jinbum-kim jinbum-kim commented Feb 10, 2026

closes #947

This PR adds Redis Streams idempotent production support to rueidiscompat.

Note: XINFO STREAM IDMP fields are not implemented in rueidiscompat yet, so this PR tests XADD IDMP/IDMPAUTO and XCFGSET without XInfoStream assertions.


Note

Medium Risk
Adds new Redis 8.6+ Streams semantics to XADD and introduces XCFGSET, which can change write behavior and stream configuration if misused; scope is contained to the compat adapter and tests.

Overview
Adds Redis 8.6+ Streams idempotent production support to rueidiscompat by extending XAddArgs and emitting XADD IDMP/IDMPAUTO when ProducerID is provided.

Introduces XCFGSET support via new XCfgSetArgs plus Cmdable/Compat/Pipeline methods, and adds a dedicated RESP3 Redis 8.6 test suite to validate XADD idempotency and XCFGSET option handling.

Written by Cursor Bugbot for commit 1068cce. This will update automatically on new commits. Configure here.

@jinbum-kim
Copy link
Copy Markdown
Contributor Author

Hi @rueian, CI is failing on the new IDMP/IDMPAUTO and XCFGSET tests.

It seems the Redis instances used in CI are running a version that doesn’t support these features yet (Redis 8.6+).

In go-redis, there is a test-skip helper called SkipBeforeRedisVersion (also used helper by the tests in redis/go-redis#3693)

Before I proceed, is there already a related func to skip tests based on Redis version (similar to go-redis)? If not, would you like me to add one?

@rueian
Copy link
Copy Markdown
Collaborator

rueian commented Feb 11, 2026

Before I proceed, is there already a related func to skip tests based on Redis version (similar to go-redis)? If not, would you like me to add one?

No, we don't have such function. Could we just replace redis/redis-stack:7.4.0-v0 with redis 8.6.0?

@jinbum-kim
Copy link
Copy Markdown
Contributor Author

jinbum-kim commented Feb 11, 2026

Could we just replace redis/redis-stack:7.4.0-v0 with redis 8.6.0?

I tried switching the compat services in docker-compose.yml(in repo root) to redis:8.6.0 locally, but it broke several module-dependent tests (TFUNCTION*, TS., FT.), so a straight replacement doesn’t seem viable.

I also saw the redis-stack note that Redis 8 bundles Stack modules, but in our CI/test setup redis:8.6.0 still isn’t a drop-in replacement for the current redis-stack image (those commands are missing or not working as expected).

Given this, I’ve been thinking about a couple of approaches:

  1. add a separate redis:8+ service only for the new IDMP/XCFGSET tests,
  2. add a skip helper (like go-redis).

In my opinion, since more Redis 8.6+ features (IDMP/IDMPAUTO, XCFGSET, etc.) are being added over time, it might be a good time to update the CI setup to support 8.6+ once 😅

@rueian
Copy link
Copy Markdown
Collaborator

rueian commented Feb 11, 2026

add a separate redis:8+ service only for the new IDMP/XCFGSET tests,

Thanks for testing. Let's do this.

@jinbum-kim
Copy link
Copy Markdown
Contributor Author

OK — I’ll work on the related CI/test setup changes and open a separate PR.

@rueian
Copy link
Copy Markdown
Collaborator

rueian commented Feb 22, 2026

Hi @jinbum-kim, would you like to continue on this?

@jinbum-kim
Copy link
Copy Markdown
Contributor Author

Hi @rueian Sorry for the delay. I’ve been tied up with other work.

I just opened a PR for the CI/test setup changes needed for Redis 8.6+. Could you please take a look when you have a chance? After that’s merged, I’ll follow up with the remaining changes for this work right away.

@rueian
Copy link
Copy Markdown
Collaborator

rueian commented Feb 28, 2026

Hi @rueian Sorry for the delay. I’ve been tied up with other work.

I just opened a PR for the CI/test setup changes needed for Redis 8.6+. Could you please take a look when you have a chance? After that’s merged, I’ll follow up with the remaining changes for this work right away.

Hi @jinbum-kim, the CI setup PR has been merged!

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Signed-off-by: jinbum-kim <jinbum9958@gmail.com>
@jinbum-kim
Copy link
Copy Markdown
Contributor Author

Hi @rueian, all test are passed. PTAL! thank you🙌

@rueian rueian merged commit 76e1f25 into redis:main Mar 1, 2026
28 checks passed
@rueian
Copy link
Copy Markdown
Collaborator

rueian commented Mar 1, 2026

Thanks a lot @jinbum-kim!

@jinbum-kim jinbum-kim deleted the feat/idmp-xcfgset branch March 2, 2026 10:10
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.

Add support for Redis Streams Idempotent to rueidiscompat

2 participants