z_depcache (zotonic_core v1.0.0-rc.10)

z_depcache interface file for handing depcache functions from the Zotonic context.

Link to this section Summary

Functions

Flush all keys from the caches
Flush the key and all keys depending on the key
Flush all items memoized in the process dictionary.
Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Fetch the key from the cache, when the key does not exist then lock the entry and let the calling process insert the value. All other processes requesting the key will wait till the key is updated and receive the key's new value.
Enable or disable the in-process caching using the process dictionary
Check if we use a local process dict cache
Add the key to the depcache, hold it for 3600 seconds and no dependencies
Add the key to the depcache, hold it for MaxAge seconds and no dependencies
Add the key to the depcache, hold it for MaxAge seconds and check the dependencies
Return the total memory size of all stored terms
Start depcache instance based on site configuration

Link to this section Functions

Flush all keys from the caches
Link to this function

flush(Key, Context)

Flush the key and all keys depending on the key
Link to this function

flush_process_dict()

Flush all items memoized in the process dictionary.
Link to this function

get(Key, Context)

Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Link to this function

get(Key, SubKey, Context)

Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Link to this function

get_subkey(Key, SubKey, Context)

Fetch the key from the cache, return the data or an undefined if not found (or not valid)
Link to this function

get_wait(Key, Context)

Fetch the key from the cache, when the key does not exist then lock the entry and let the calling process insert the value. All other processes requesting the key will wait till the key is updated and receive the key's new value.
Link to this function

in_process(Flag)

Enable or disable the in-process caching using the process dictionary
Link to this function

in_process_server(Server)

Check if we use a local process dict cache
Link to this function

memo(Function, Context)

Link to this function

memo(Function, MaxAge, Context)

Link to this function

memo(F, Key, MaxAge, Context)

Link to this function

memo(F, Key, MaxAge, Dep, Context)

Link to this function

record_depcache_event(Event, Host)

Link to this function

set(Key, Data, Context)

Add the key to the depcache, hold it for 3600 seconds and no dependencies
Link to this function

set(Key, Data, MaxAge, Context)

Add the key to the depcache, hold it for MaxAge seconds and no dependencies
Link to this function

set(Key, Data, MaxAge, Depend, Context)

Add the key to the depcache, hold it for MaxAge seconds and check the dependencies
Return the total memory size of all stored terms
Link to this function

start_link(SiteProps)

Start depcache instance based on site configuration