Skip to content

[BUG] WATCH ignores keys which has expired #7918

@QuChen88

Description

@QuChen88

Currently, WATCH in a multi-exec transaction will ignore expired keys. So if a key that was previously being watched is expired and deleted from Redis, WATCH will not consider it at all... There is a TCL test for this behavior

https://github.com/redis/redis/blob/unstable/tests/unit/multi.tcl#L224

However, this behavior doesn't seem to make a lot of sense to me. If I am watching an item and the item gets deleted from Redis, I would want to be notified... Anyone know the reason behind this behavior in Redis?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions