Skip to content

Commit

Permalink
Merge pull request #3552 from hhunter-ms/issue_3258
Browse files Browse the repository at this point in the history
[redis bindings][redo PR] Add GetDel support
  • Loading branch information
hhunter-ms authored Jun 19, 2023
2 parents 3e15220 + 10e4e50 commit 51adf43
Showing 1 changed file with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ An HTTP 204 (No Content) and empty body is returned if successful.

You can get a record in Redis using the `get` operation. This gets a key that was previously set.

This takes an optional parameter `delete`, which is by default `false`. When it is set to `true`, this operation uses the `GETDEL` operation of Redis. For example, it returns the `value` which was previously set and then deletes it.

#### Request

```json
Expand All @@ -120,6 +122,20 @@ You can get a record in Redis using the `get` operation. This gets a key that wa
}
```

#### Request with delete flag

```json
{
"operation": "get",
"metadata": {
"key": "key1",
"delete": "true"
},
"data": {
}
}
```

### delete

You can delete a record in Redis using the `delete` operation. Returns success whether the key exists or not.
Expand Down

0 comments on commit 51adf43

Please sign in to comment.