Skip to content

Commit 6359983

Browse files
committed
Merge branch 'main' into DOC-3624
2 parents 0a1695c + dddaae8 commit 6359983

File tree

119 files changed

+1667
-1918
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

119 files changed

+1667
-1918
lines changed

build/components/example.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
'java': '//',
2020
'go': '//',
2121
'c#': '//',
22+
'redisvl': '#'
2223
}
2324

2425
class Example(object):

config.toml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ tagManagerId = "GTM-TKZ6J9R"
4545
gitHubRepo = "https://github.com/redis/docs"
4646

4747
# Display and sort order for client examples
48-
clientsExamples = ["Python", "Node.js", "Java", "Go", "C#"]
48+
clientsExamples = ["Python", "Node.js", "Java", "Go", "C#", "RedisVL"]
4949
searchService = "/convai/api/search-service"
5050
ratingsService = "/docusight/api/rate"
5151

@@ -56,6 +56,14 @@ rdi_debezium_server_version = "2.3.0.Final"
5656
rdi_db_types = "cassandra|mysql|oracle|postgresql|sqlserver"
5757
rdi_cli_latest = "latest"
5858

59+
[params.clientsConfig]
60+
"Python"={lang="python", quickstartSlug="python/redis-py"}
61+
"Node.js"={lang="javascript", quickstartSlug="nodejs"}
62+
"Java"={lang="java", quickstartSlug="java/jedis"}
63+
"Go"={lang="go", quickstartSlug="go"}
64+
"C#"={lang="C#", quickstartSlug="dotnet"}
65+
"RedisVL"={lang="python", quickstartSlug="python/redis-vl"}
66+
5967
# Markup
6068
[markup]
6169
[markup.goldmark]

content/commands/json.mget/index.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ title: JSON.MGET
3232
---
3333
Return the values at `path` from multiple `key` arguments
3434

35+
{{% warning %}}
36+
All specified keys must reside on the same [hash slot](https://redis.io/docs/latest/operate/oss_and_stack/reference/cluster-spec/#key-distribution-model).
37+
{{% /warning %}}
38+
3539
[Examples](#examples)
3640

3741
## Required arguments

content/commands/json.mset/index.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ Set or update one or more JSON values according to the specified `key`-`path`-`v
4343

4444
A JSON value is a hierarchical structure. If you change a value in a specific path - nested values are affected.
4545

46+
{{% warning %}}
47+
All specified keys must reside on the same [hash slot](https://redis.io/docs/latest/operate/oss_and_stack/reference/cluster-spec/#key-distribution-model).
48+
{{% /warning %}}
4649

4750
[Examples](#examples)
4851

content/develop/connect/clients/go.md

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,37 @@ telnet: Unable to connect to remote host: Connection refused
173173
If you use Docker, Istio, or any other service mesh/sidecar, make sure the app starts after the container is fully available, for example, by configuring healthchecks with Docker and holdApplicationUntilProxyStarts with Istio.
174174
For more information, see [Healthcheck](https://docs.docker.com/engine/reference/run/#healthcheck).
175175

176+
### Observability
177+
178+
To monitor go-redis performance and trace the execution of Redis commands, you can install OpenTelemetry instrumentation:
179+
180+
```go
181+
import (
182+
"github.com/redis/go-redis/v9"
183+
"github.com/redis/go-redis/extra/redisotel/v9"
184+
)
185+
186+
rdb := redis.NewClient(&redis.Options{...})
187+
188+
// Enable tracing instrumentation.
189+
if err := redisotel.InstrumentTracing(rdb); err != nil {
190+
panic(err)
191+
}
192+
193+
// Enable metrics instrumentation.
194+
if err := redisotel.InstrumentMetrics(rdb); err != nil {
195+
panic(err)
196+
}
197+
```
198+
199+
The code above instruments Redis commands to collect traces, logs, and metrics. You can find the full example on [GitHub](https://github.com/redis/go-redis/blob/master/example/otel/README.md).
200+
201+
OpenTelemetry is a vendor-agnostic observability framework that allows you to export data to Prometheus, Jaeger, Uptrace, and more. OpenTelemetry supports [distributed tracing](https://uptrace.dev/opentelemetry/distributed-tracing.html), metrics, and logs.
202+
203+
You can also use OpenTelemetry for [monitoring Redis Server](https://uptrace.dev/blog/redis-monitoring.html) performance metrics, which works by periodically executing the Redis `INFO` command and turning results into [OpenTelemetry metrics](https://uptrace.dev/opentelemetry/metrics.html).
204+
176205
### Learn more
177206

178207
* [Documentation](https://redis.uptrace.dev/guide/)
179208
* [GitHub](https://github.com/redis/go-redis)
180-
209+
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
categories:
3+
- docs
4+
- develop
5+
- stack
6+
- oss
7+
- rs
8+
- rc
9+
- oss
10+
- kubernetes
11+
- clients
12+
hideListLinks: true
13+
description: Connect your application to a Redis database using Python and try an example
14+
linkTitle: Python
15+
title: Connect with Redis Python clients
16+
weight: 4
17+
---
18+
19+
You have two choices of Python clients that you can use with Redis:
20+
21+
- [Redis Python library (redis-py)]({{< relref "/develop/connect/clients/python/redis-py" >}})
22+
- [Redis vector library (RedisVL)]({{< relref "/develop/connect/clients/python/redis-vl" >}})
23+
24+
You can also access Redis with an object-mapping client interface. See
25+
[RedisOM for Python]({{< relref "/integrate/redisom-for-python" >}})
26+
for more information.

content/develop/connect/clients/python.md renamed to content/develop/connect/clients/python/redis-py.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ categories:
1010
- kubernetes
1111
- clients
1212
description: Connect your Python application to a Redis database
13-
linkTitle: Python
14-
title: Python guide
13+
linkTitle: Redis Python library
14+
title: Redis Python library guide
1515
weight: 1
1616
---
1717

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
categories:
3+
- docs
4+
- develop
5+
- stack
6+
- oss
7+
- rs
8+
- rc
9+
- oss
10+
- kubernetes
11+
- clients
12+
description: Connect your Python vector application to a Redis vector database
13+
linkTitle: Redis vector library
14+
title: Redis vector library guide
15+
weight: 1
16+
---
17+
18+
See the [RedisVL Guide]({{< relref "/integrate/redisvl" >}}) for more information.

content/develop/get-started/vector-database.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ Iterate over all the Redis keys with the prefix `bikes:`:
134134

135135
{{< clients-example search_vss get_keys />}}
136136

137-
Use the keys as input to the [JSON.MGET]({{< baseurl >}}/commands/json.mget//) command, along with the `$.description` field, to collect the descriptions in a list. Then, pass the list of descriptions to the `.encode()` method:
137+
Use the keys as input to the [JSON.MGET]({{< baseurl >}}/commands/json.mget/) command, along with the `$.description` field, to collect the descriptions in a list. Then, pass the list of descriptions to the `.encode()` method:
138138

139139
{{< clients-example search_vss generate_embeddings />}}
140140

content/develop/reference/modules/modules-api-ref.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ You should avoid using `calloc()` directly.
114114

115115
void *RedisModule_TryCalloc(size_t nmemb, size_t size);
116116

117-
**Available since:** unreleased
117+
**Available since:** 7.4.0
118118

119119
Similar to [`RedisModule_Calloc`](#RedisModule_Calloc), but returns NULL in case of allocation failure, instead
120120
of panicking.
@@ -135,7 +135,7 @@ Use like `realloc()` for memory obtained with [`RedisModule_Alloc()`](#RedisModu
135135

136136
void *RedisModule_TryRealloc(void *ptr, size_t bytes);
137137

138-
**Available since:** unreleased
138+
**Available since:** 7.4.0
139139

140140
Similar to [`RedisModule_Realloc`](#RedisModule_Realloc), but returns NULL in case of allocation failure,
141141
instead of panicking.
@@ -467,7 +467,7 @@ Returns `REDISMODULE_OK` on success and `REDISMODULE_ERR` in case of the followi
467467

468468
int RedisModule_AddACLCategory(RedisModuleCtx *ctx, const char *name);
469469

470-
**Available since:** unreleased
470+
**Available since:** 7.4.0
471471

472472
[`RedisModule_AddACLCategory`](#RedisModule_AddACLCategory) can be used to add new ACL command categories. Category names
473473
can only contain alphanumeric characters, underscores, or dashes. Categories can only be added
@@ -5268,7 +5268,7 @@ With the following effects:
52685268

52695269
unsigned int RedisModule_ClusterKeySlot(RedisModuleString *key);
52705270

5271-
**Available since:** unreleased
5271+
**Available since:** 7.4.0
52725272

52735273
Returns the cluster slot of a key, similar to the `CLUSTER KEYSLOT` command.
52745274
This function works even if cluster mode is not enabled.
@@ -5279,7 +5279,7 @@ This function works even if cluster mode is not enabled.
52795279

52805280
const char *RedisModule_ClusterCanonicalKeyNameInSlot(unsigned int slot);
52815281

5282-
**Available since:** unreleased
5282+
**Available since:** 7.4.0
52835283

52845284
Returns a short string that can be used as a key or as a hash tag in a key,
52855285
such that the key maps to the given cluster slot. Returns NULL if slot is not

0 commit comments

Comments
 (0)