mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-31 20:21:09 +00:00
_create_redis_cache
This commit is contained in:
+5
-2
@@ -618,8 +618,11 @@ class Router:
|
||||
|
||||
@staticmethod
|
||||
def _create_redis_cache(
|
||||
cache_config: dict[str, Any]
|
||||
) -> RedisCache | RedisClusterCache:
|
||||
cache_config: Dict[str, Any]
|
||||
) -> Union[RedisCache, RedisClusterCache]:
|
||||
"""
|
||||
Initializes either a RedisCache or RedisClusterCache based on the cache_config.
|
||||
"""
|
||||
if cache_config.get("startup_nodes"):
|
||||
return RedisClusterCache(**cache_config)
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user