You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CredentialsProvider class added to support password rotation (#2261)
* A CredentialsProvider class has been added to allow the user to add his own provider for password rotation
* Moved CredentialsProvider to a separate file, added type hints
* Changed username and password to properties
* Added: StaticCredentialProvider, examples, tests
Changed: CredentialsProvider to CredentialProvider
Fixed: calling AUTH only with password
* Changed private members' prefix to __
* fixed linters
* fixed auth test
* fixed credential test
* Raise an error if username or password are passed along with credential_provider
* fixing linters
* fixing test
* Changed dundered to single per side underscore
* Changed Connection class members username and password to properties to enable backward compatibility with changing the members value on existing connection.
* Reverting last commit and adding backward compatibility to 'username' and 'password' inside on_connect function
* Refactored CredentialProvider class
* Fixing tuple type to Tuple
* Fixing optional string members in UsernamePasswordCredentialProvider
* Fixed credential test
* Added credential provider support to AsyncRedis
* linters
* linters
* linters
* linters - black
Co-authored-by: dvora-h <67596500+dvora-h@users.noreply.github.com>
Co-authored-by: dvora-h <dvora.heller@redis.com>
"If you supply a custom `ConnectionPool` that is supplied to several `Redis` instances, you may want to disconnect the connection pool explicitly. Disconnecting the connection pool simply disconnects all connections hosted in the pool."
51
+
],
48
52
"metadata": {
53
+
"collapsed": false,
49
54
"pycharm": {
50
55
"name": "#%% md\n"
51
56
}
52
-
},
53
-
"source": [
54
-
"If you supply a custom `ConnectionPool` that is supplied to several `Redis` instances, you may want to disconnect the connection pool explicitly. Disconnecting the connection pool simply disconnects all connections hosted in the pool."
"The commands will not be reflected in Redis until execute() is called & awaited.\n",
88
86
"\n",
89
87
"Usually, when performing a bulk operation, taking advantage of a “transaction” (e.g., Multi/Exec) is to be desired, as it will also add a layer of atomicity to your bulk operation."
"Subscribing to channels matching a glob-style pattern:"
175
-
]
185
+
],
186
+
"metadata": {
187
+
"collapsed": false,
188
+
"pycharm": {
189
+
"name": "#%% md\n"
190
+
}
191
+
}
176
192
},
177
193
{
178
194
"cell_type": "code",
179
195
"execution_count": 5,
180
-
"metadata": {
181
-
"pycharm": {
182
-
"name": "#%%\n"
183
-
}
184
-
},
185
196
"outputs": [
186
197
{
187
198
"name": "stdout",
@@ -223,11 +234,16 @@
223
234
" await r.publish(\"channel:1\", STOPWORD)\n",
224
235
"\n",
225
236
" await future"
226
-
]
237
+
],
238
+
"metadata": {
239
+
"collapsed": false,
240
+
"pycharm": {
241
+
"name": "#%%\n"
242
+
}
243
+
}
227
244
},
228
245
{
229
246
"cell_type": "markdown",
230
-
"metadata": {},
231
247
"source": [
232
248
"## Sentinel Client\n",
233
249
"\n",
@@ -236,16 +252,17 @@
236
252
"Calling aioredis.sentinel.Sentinel.master_for or aioredis.sentinel.Sentinel.slave_for methods will return Redis clients connected to specified services monitored by Sentinel.\n",
237
253
"\n",
238
254
"Sentinel client will detect failover and reconnect Redis clients automatically."
0 commit comments