|
virtual Sint32 | start (const char *listen_address, const char *directory)=0 |
| Starts the cache manager. More...
|
|
virtual Sint32 | shutdown ()=0 |
| Shuts down the cache manager. More...
|
|
virtual Sint32 | set_http_address (const char *address, const char *user_name, const char *password)=0 |
| Sets the address and authentication information of the HTTP server. More...
|
|
virtual const IString * | get_http_address () const =0 |
| Returns the address of the HTTP server, or NULL if none is set. More...
|
|
virtual const IString * | get_http_user_name () const =0 |
| Returns the user name for the HTTP server, or NULL if none is set. More...
|
|
virtual const IString * | get_http_password () const =0 |
| Returns the password for the HTTP server, or NULL if none is set. More...
|
|
virtual Sint32 | set_multicast_address (const char *address)=0 |
| Sets the multicast address of the cache manager. More...
|
|
virtual const IString * | get_multicast_address () const =0 |
| Returns the multicast address, or NULL if none is set. More...
|
|
virtual Sint32 | set_cluster_interface (const char *address)=0 |
| Sets the cluster interface used by the cache manager. More...
|
|
virtual const IString * | get_cluster_interface () const =0 |
| Returns the cluster interface, or NULL if none is set. More...
|
|
virtual Sint32 | set_use_rdma (bool use_rdma)=0 |
| Enables or disables the usage of RDMA InfiniBand. More...
|
|
virtual bool | get_use_rdma () const =0 |
| Indicates whether RDMA InfiniBand is enabled. More...
|
|
virtual Sint32 | set_rdma_interface (const char *rdma_interface)=0 |
| Set the RDMA InfiniBand interface to be used. More...
|
|
virtual const IString * | get_rdma_interface () const =0 |
| Returns RDMA InfiniBand interface to be used. More...
|
|
virtual Sint32 | set_admin_http_address (const char *address)=0 |
| Sets the address for the administrative HTTP server. More...
|
|
virtual const IString * | get_admin_http_address () const =0 |
| Returns the address of the admin HTTP server, or NULL if none is set. More...
|
|
virtual Sint32 | set_memory_limits (Size low_water, Size high_water)=0 |
| Sets the memory limits for the garbage collection. More...
|
|
virtual void | get_memory_limits (Size *low_water, Size *high_water) const =0 |
| Returns the memory limits for the garbage collection. More...
|
|
virtual Sint32 | set_reference_count_checking (bool enabled)=0 |
| Enables or disables checking of reference counts. More...
|
|
virtual bool | get_reference_count_checking () const =0 |
| Indicates whether checking of reference counts is enabled. More...
|
|
virtual Uint32 | retain () const =0 |
| Increments the reference count. More...
|
|
virtual Uint32 | release () const =0 |
| Decrements the reference count. More...
|
|
virtual const IInterface * | get_interface (const Uuid &interface_id) const =0 |
| Acquires a const interface from another. More...
|
|
template<class T> |
const T * | get_interface () const |
| Acquires a const interface from another. More...
|
|
virtual IInterface * | get_interface (const Uuid &interface_id)=0 |
| Acquires a mutable interface from another. More...
|
|
template<class T> |
T * | get_interface () |
| Acquires a mutable interface from another. More...
|
|
virtual Uuid | get_iid () const =0 |
| Returns the interface ID of the most derived interface. More...
|
|
|
typedef Interface_declare< id1, ... > | Self |
| Own type. More...
|
|
typedef Uuid_t< id1, ... > | IID |
| Declares the interface ID (IID) of this interface. More...
|
|
typedef Uuid_t<0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0> | IID |
| Declares the interface ID (IID) of this interface. More...
|
|
static bool | compare_iid (const Uuid &iid) |
| Compares the interface ID iid against the interface ID of this interface and of its ancestors. More...
|
|
static bool | compare_iid (const Uuid &iid) |
| Compares the interface ID iid against the interface ID of this interface. More...
|
|
Represents an instance of the cache manager.
You cannot directly interact with the cache manager yourself. The purpose of this interface is to allow you to start a cache manager such that it can be used by other components, e.g., the Bridge. See mi::bridge::IApplication::set_disk_cache().
- See also
- mi::neuraylib::ICache_manager_factory
virtual Sint32 mi::neuraylib::ICache_manager::set_memory_limits |
( |
Size |
low_water, |
|
|
Size |
high_water |
|
) |
| |
|
pure virtual |
Sets the memory limits for the garbage collection.
The cache manager uses a garbage collection scheme to attempt to keep the total amount of memory, i.e., disk space, below a configurable limit called high
water
mark
. If that limit is exceeded the garbage collection reduces memory usage usage until another limit, the low
water
mark
, is reached (or no further memory reduction is possible).
- Note
- No guarantee is given that the high water mark is not exceeded. In particular, cache elements may be retained which prevents them from cache eviction.
-
The memory usage here refers to the size of the cache values itself. The meta data for managing the cache as well as overhead from the database backend are not included here.
- Parameters
-
low_water | The garbage collection stops when memory usage (in bytes) drops below this value. |
high_water | The garbage collection starts when memory usage (in bytes) exceeds this value. The value 0 disables the garbage collection. |
- Returns
- 0: Success.
- -1: Invalid parameters (
low_water
is not less than high_water
unless high_water
equals zero).