docs: recommendations for cache memory (#8140)
* env-vars-table * remove-cache-table * fix-bool-cli-links * run-cache * note * code-review * support
This commit is contained in:
parent
bdf658a616
commit
f45ca81dda
3 changed files with 18 additions and 27 deletions
|
|
@ -84,17 +84,11 @@ LANGFLOW_DB_CONNECT_TIMEOUT=20
|
|||
|
||||
## Configure cache memory
|
||||
|
||||
Langflow provides multiple caching options that can be configured using the `LANGFLOW_CACHE_TYPE` environment variable.
|
||||
The default Langflow caching behavior is an asynchronous, in-memory cache.
|
||||
```
|
||||
LANGFLOW_LANGCHAIN_CACHE=InMemoryCache
|
||||
LANGFLOW_CACHE_TYPE=Async
|
||||
```
|
||||
|
||||
| Type | Description | Storage Location | Persistence |
|
||||
| ----------------- | ---------------------------- | ------------------------ | ---------------------- |
|
||||
| `async` (default) | Asynchronous in-memory cache | Application memory | Cleared on restart |
|
||||
| `memory` | Thread-safe in-memory cache | Application memory | Cleared on restart |
|
||||
| `disk` | File system-based cache | System cache directory\* | Persists after restart |
|
||||
| `redis` | Distributed cache | Redis server | Persists in Redis |
|
||||
|
||||
\*System cache directory locations:
|
||||
|
||||
- Linux/WSL: `~/.cache/langflow/`
|
||||
- macOS: `/Users/<username>/Library/Caches/langflow/`
|
||||
- Windows: `%LOCALAPPDATA%\langflow\langflow\Cache`
|
||||
Alternative caching options can be configured, but options other than the default asynchronous, in-memory cache are not supported.
|
||||
The default behavior is suitable for most use cases.
|
||||
Loading…
Add table
Add a link
Reference in a new issue