Cache
get_archive_cache(prefix='.cache')
cached
Get the archive cache subfolder where to store persistent state about sources
Set the base archive via INVESTIGRAPH_ARCHIVE_URI (see
Settings)
Returns:
| Type | Description |
|---|---|
BaseStore
|
The archive cache store (see anystore) |
Source code in investigraph/cache.py
get_runtime_cache()
cached
Get shared runtime cache. This should be a fast key-value store that doesn't need to be persistent.
Set via INVESTIGRAPH_CACHE_URI (see Settings)
Returns:
| Type | Description |
|---|---|
BaseStore
|
The runtime cache store (see anystore) |
Source code in investigraph/cache.py
make_cache_key(uri, *args, **kwargs)
Compute a cache key for the given uri. This tries to get an etag or
last-modified header, or optionally falls back to computing a checksum or
a key just by the uri.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
uri
|
Uri
|
The local or remote uri for the file |
required |
cache
|
|
required | |
url_key_only
|
|
required | |
use_checksum
|
|
required | |
checksum
|
|
required |