Skip to content

Commit f5154a2

Browse files
DOC-6268 pub/sub commands for a few clients
1 parent 10786b9 commit f5154a2

14 files changed

+973
-0
lines changed
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
{
2+
"api_calls": {
3+
"redis_py": [],
4+
"jedis": [
5+
{
6+
"signature": "void psubscribe(BinaryJedisPubSub jedisPubSub, final byte[]... patterns)",
7+
"params": [
8+
{
9+
"name": "jedisPubSub",
10+
"type": "BinaryJedisPubSub",
11+
"description": "Pub/sub listener object"
12+
},
13+
{
14+
"name": "patterns",
15+
"type": "byte[]...",
16+
"description": "Channel patterns to subscribe to"
17+
}
18+
],
19+
"returns": {
20+
"type": "void",
21+
"description": "Blocks until unsubscribed"
22+
}
23+
},
24+
{
25+
"signature": "void psubscribe(final JedisPubSub jedisPubSub, final String... patterns)",
26+
"params": [
27+
{
28+
"name": "jedisPubSub",
29+
"type": "JedisPubSub",
30+
"description": "Pub/sub listener object"
31+
},
32+
{
33+
"name": "patterns",
34+
"type": "String...",
35+
"description": "Channel patterns to subscribe to"
36+
}
37+
],
38+
"returns": {
39+
"type": "void",
40+
"description": "Blocks until unsubscribed"
41+
}
42+
}
43+
],
44+
"go-redis": [],
45+
"node_redis": [],
46+
"lettuce_sync": [],
47+
"lettuce_async": [],
48+
"lettuce_reactive": [],
49+
"ioredis": [],
50+
"redis_rs_sync": [],
51+
"redis_rs_async": [],
52+
"redisvl": [],
53+
"nredisstack_sync": [],
54+
"nredisstack_async": [],
55+
"php": []
56+
}
57+
}
58+
Lines changed: 178 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,178 @@
1+
{
2+
"api_calls": {
3+
"redis_py": [
4+
{
5+
"signature": "publish(channel: ChannelT, message: EncodableT, **kwargs)",
6+
"params": [
7+
{
8+
"name": "channel",
9+
"type": "ChannelT",
10+
"description": "Channel to publish the message to"
11+
},
12+
{
13+
"name": "message",
14+
"type": "EncodableT",
15+
"description": "Message to publish"
16+
},
17+
{
18+
"name": "**kwargs",
19+
"type": "Any",
20+
"description": "Additional keyword arguments"
21+
}
22+
],
23+
"returns": {
24+
"type": "ResponseT",
25+
"description": "Number of clients that received the message"
26+
}
27+
}
28+
],
29+
"jedis": [
30+
{
31+
"signature": "long publish(final byte[] channel, final byte[] message)",
32+
"params": [
33+
{
34+
"name": "channel",
35+
"type": "byte[]",
36+
"description": "Channel to publish the message to"
37+
},
38+
{
39+
"name": "message",
40+
"type": "byte[]",
41+
"description": "Message to publish"
42+
}
43+
],
44+
"returns": {
45+
"type": "long",
46+
"description": "Number of clients that received the message"
47+
}
48+
},
49+
{
50+
"signature": "long publish(final String channel, final String message)",
51+
"params": [
52+
{
53+
"name": "channel",
54+
"type": "String",
55+
"description": "Channel to publish the message to"
56+
},
57+
{
58+
"name": "message",
59+
"type": "String",
60+
"description": "Message to publish"
61+
}
62+
],
63+
"returns": {
64+
"type": "long",
65+
"description": "Number of clients that received the message"
66+
}
67+
}
68+
],
69+
"go-redis": [
70+
{
71+
"signature": "Publish(ctx context.Context, channel string, message interface{})",
72+
"params": [
73+
{
74+
"name": "ctx",
75+
"type": "context.Context",
76+
"description": "Context for the operation"
77+
},
78+
{
79+
"name": "channel",
80+
"type": "string",
81+
"description": "Channel to publish the message to"
82+
},
83+
{
84+
"name": "message",
85+
"type": "interface{}",
86+
"description": "Message to publish"
87+
}
88+
],
89+
"returns": {
90+
"type": "*IntCmd",
91+
"description": "Number of clients that received the message"
92+
}
93+
}
94+
],
95+
"node_redis": [],
96+
"lettuce_sync": [],
97+
"lettuce_async": [],
98+
"lettuce_reactive": [],
99+
"ioredis": [],
100+
"redis_rs_sync": [],
101+
"redis_rs_async": [],
102+
"redisvl": [],
103+
"nredisstack_sync": [
104+
{
105+
"signature": "long Publish(RedisChannel channel, RedisValue message, CommandFlags flags = CommandFlags.None)",
106+
"params": [
107+
{
108+
"name": "channel",
109+
"type": "RedisChannel",
110+
"description": "The channel to publish to"
111+
},
112+
{
113+
"name": "message",
114+
"type": "RedisValue",
115+
"description": "The message to send"
116+
},
117+
{
118+
"name": "flags",
119+
"type": "CommandFlags",
120+
"description": "The flags to use for this operation"
121+
}
122+
],
123+
"returns": {
124+
"type": "long",
125+
"description": "The number of clients that received the message on the destination server"
126+
}
127+
}
128+
],
129+
"nredisstack_async": [
130+
{
131+
"signature": "Task<long> PublishAsync(RedisChannel channel, RedisValue message, CommandFlags flags = CommandFlags.None)",
132+
"params": [
133+
{
134+
"name": "channel",
135+
"type": "RedisChannel",
136+
"description": "The channel to publish to"
137+
},
138+
{
139+
"name": "message",
140+
"type": "RedisValue",
141+
"description": "The message to send"
142+
},
143+
{
144+
"name": "flags",
145+
"type": "CommandFlags",
146+
"description": "The flags to use for this operation"
147+
}
148+
],
149+
"returns": {
150+
"type": "Task<long>",
151+
"description": "The number of clients that received the message on the destination server"
152+
}
153+
}
154+
],
155+
"php": [
156+
{
157+
"signature": "publish($channel, $message)",
158+
"params": [
159+
{
160+
"name": "$channel",
161+
"type": "string",
162+
"description": "Channel to publish the message to"
163+
},
164+
{
165+
"name": "$message",
166+
"type": "string",
167+
"description": "Message to publish"
168+
}
169+
],
170+
"returns": {
171+
"type": "int",
172+
"description": "Number of clients that received the message"
173+
}
174+
}
175+
]
176+
}
177+
}
178+
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
{
2+
"api_calls": {
3+
"redis_py": [
4+
{
5+
"signature": "pubsub_channels(pattern: PatternT = \"*\", **kwargs)",
6+
"params": [
7+
{
8+
"name": "pattern",
9+
"type": "PatternT",
10+
"description": "Pattern to match channel names (default: \"*\")"
11+
},
12+
{
13+
"name": "**kwargs",
14+
"type": "Any",
15+
"description": "Additional keyword arguments"
16+
}
17+
],
18+
"returns": {
19+
"type": "ResponseT",
20+
"description": "List of active channels matching the pattern"
21+
}
22+
}
23+
],
24+
"jedis": [
25+
{
26+
"signature": "List<String> pubsubChannels()",
27+
"params": [],
28+
"returns": {
29+
"type": "List<String>",
30+
"description": "List of all active channels"
31+
}
32+
},
33+
{
34+
"signature": "List<String> pubsubChannels(final String pattern)",
35+
"params": [
36+
{
37+
"name": "pattern",
38+
"type": "String",
39+
"description": "Pattern to match channel names"
40+
}
41+
],
42+
"returns": {
43+
"type": "List<String>",
44+
"description": "List of active channels matching the pattern"
45+
}
46+
}
47+
],
48+
"go-redis": [
49+
{
50+
"signature": "PubSubChannels(ctx context.Context, pattern string)",
51+
"params": [
52+
{
53+
"name": "ctx",
54+
"type": "context.Context",
55+
"description": "Context for the operation"
56+
},
57+
{
58+
"name": "pattern",
59+
"type": "string",
60+
"description": "Pattern to match channel names"
61+
}
62+
],
63+
"returns": {
64+
"type": "*StringSliceCmd",
65+
"description": "List of active channels matching the pattern"
66+
}
67+
}
68+
],
69+
"node_redis": [],
70+
"lettuce_sync": [],
71+
"lettuce_async": [],
72+
"lettuce_reactive": [],
73+
"ioredis": [],
74+
"redis_rs_sync": [],
75+
"redis_rs_async": [],
76+
"redisvl": [],
77+
"nredisstack_sync": [],
78+
"nredisstack_async": [],
79+
"php": [
80+
{
81+
"signature": "pubsub($subcommand, $argument)",
82+
"params": [
83+
{
84+
"name": "$subcommand",
85+
"type": "string",
86+
"description": "PUBSUB subcommand (e.g., 'CHANNELS')"
87+
},
88+
{
89+
"name": "$argument",
90+
"type": "mixed",
91+
"description": "Pattern to match channel names"
92+
}
93+
],
94+
"returns": {
95+
"type": "mixed",
96+
"description": "List of active channels matching the pattern"
97+
}
98+
}
99+
]
100+
}
101+
}
102+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"api_calls": {
3+
"redis_py": [],
4+
"jedis": [],
5+
"go-redis": [],
6+
"node_redis": [],
7+
"lettuce_sync": [],
8+
"lettuce_async": [],
9+
"lettuce_reactive": [],
10+
"ioredis": [],
11+
"redis_rs_sync": [],
12+
"redis_rs_async": [],
13+
"redisvl": [],
14+
"nredisstack_sync": [],
15+
"nredisstack_async": [],
16+
"php": []
17+
}
18+
}
19+

0 commit comments

Comments
 (0)