CacheName | Description |
---|---|
config | Type: dict[str, Any] |
Name | Description |
---|---|
connection_string | Connection string to the Cosmos DB account. Type: Optional[str] Default: None |
container_id | The container ID for the Cosmos DB account. Type: Optional[str] Default: None |
cache_seed | A seed for the cache. Type: Union[str, int] Default: 42 |
client | Optional[CosmosClient]: Pass an existing Cosmos DB client. Type: Optional[Any] Default: None |
Type | Description |
---|---|
Cache | Cache: A Cache instance configured for Cosmos DB. |
Name | Description |
---|---|
cache_seed | A seed for the cache. Defaults to 42. Type: Union[str, int] Default: 42 |
cache_path_root | The root path for the disk cache. Defaults to “.cache”. Type: str Default: ‘.cache’ |
Type | Description |
---|---|
Cache | Cache: A Cache instance configured for Disk caching. |
Name | Description |
---|---|
cache | Type: “‘Optional[Cache]‘“ Default: None |
Type | Description |
---|---|
Cache | None | Cache: The current cache instance. |
Name | Description |
---|---|
cache_seed | A seed for the cache. Defaults to 42. Type: Union[str, int] Default: 42 |
redis_url | The URL for the Redis server. Defaults to “redis://localhost:6379/0”. Type: str Default: ‘redis |
Type | Description |
---|---|
Cache | Cache: A Cache instance configured for Redis. |
Name | Description |
---|---|
key | The key identifying the item in the cache. Type: str |
default | The default value to return if the key is not found. Defaults to None. Type: Optional[Any] Default: None |
Type | Description |
---|---|
Any | None | The value associated with the key if found, else the default value. |
Name | Description |
---|---|
key | The key under which the item is to be stored. Type: str |
value | The value to be stored in the cache. Type: Any |