@@ -7,8 +7,14 @@ This extension provides Redis client functionality for DuckDB, allowing you to i
7
7
8
8
## Features
9
9
Currently supported Redis operations:
10
- - ` redis_get(key, host, port) ` : Retrieves a value from Redis for a given key
11
- - ` redis_set(key, value, host, port) ` : Sets a value in Redis for a given key
10
+ - ` redis_get(key, host, port, password) ` : Retrieves a value from Redis for a given key
11
+ - ` redis_set(key, value, host, port, password) ` : Sets a value in Redis for a given key
12
+
13
+ Features:
14
+ - Connection pooling for improved performance
15
+ - Redis authentication support
16
+ - Thread-safe operations
17
+ - Detailed error handling
12
18
13
19
## Installation
14
20
``` sql
@@ -17,6 +23,18 @@ LOAD redis;
17
23
```
18
24
19
25
## Usage Examples
26
+ ### Connecting with Authentication
27
+ ``` sql
28
+ -- Set a value with authentication
29
+ SELECT redis_set(' user:1' , ' John Doe' , ' localhost' , ' 6379' , ' mypassword' ) as result;
30
+
31
+ -- Get a value with authentication
32
+ SELECT redis_get(' user:1' , ' localhost' , ' 6379' , ' mypassword' ) as user_name;
33
+
34
+ -- For non-authenticated Redis servers, pass an empty string as password
35
+ SELECT redis_get(' user:1' , ' localhost' , ' 6379' , ' ' ) as user_name;
36
+ ```
37
+
20
38
### Setting Values in Redis
21
39
``` sql
22
40
-- Set a single value
0 commit comments