Skip to content

Commit

Permalink
PROTOBUF - EXPIREAT, PEXPIREAT, PEXPIRE, UNLINK, EXISTS commands.
Browse files Browse the repository at this point in the history
  • Loading branch information
Adan Wattad authored Oct 18, 2023
1 parent ddee561 commit 4fd9341
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions babushka-core/src/protobuf/redis_request.proto
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,11 @@ enum RequestType {
SRem = 52;
SMembers = 53;
SCard = 54;
PExpireAt = 55;
PExpire = 56;
ExpireAt = 57;
Exists = 58;
Unlink = 59;
}

message Command {
Expand Down
5 changes: 5 additions & 0 deletions babushka-core/src/socket_listener.rs
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,11 @@ fn get_command(request: &Command) -> Option<Cmd> {
RequestType::SRem => Some(cmd("SREM")),
RequestType::SMembers => Some(cmd("SMEMBERS")),
RequestType::SCard => Some(cmd("SCARD")),
RequestType::PExpireAt => Some(cmd("PEXPIREAT")),
RequestType::PExpire => Some(cmd("PEXPIRE")),
RequestType::ExpireAt => Some(cmd("EXPIREAT")),
RequestType::Exists => Some(cmd("EXISTS")),
RequestType::Unlink => Some(cmd("UNLINK")),
}
}

Expand Down

0 comments on commit 4fd9341

Please sign in to comment.