FrcaCacheCreate Subroutine
Purpose
Creates a cache instance within the scope of a Fast Response Cache Accelerator (FRCA) instance.
Library
FRCA Library (libfrca.a)
Syntax
#include <frca.h>
int32_t FrcaCacheCreate ( CacheHandle, FrcaHandle, CacheSpec);
int32_t * CacheHandle;
int32_t FrcaHandle;
frca_cache_create_t * CacheSpec;
int32_t FrcaCacheCreate ( CacheHandle, FrcaHandle, CacheSpec);
int32_t * CacheHandle;
int32_t FrcaHandle;
frca_cache_create_t * CacheSpec;
Description
The FrcaCacheCreate subroutine creates a cache instance for an FRCA instance that has already been configured. Multiple caches can be created for an FRCA instance. Cache handles are unique only within the scope of the FRCA instance.
Parameters
Item | Description |
---|---|
CacheHandle | Returns a handle that is required by the other cache-related subroutines of the FRCA API to refer to the newly created FRCA cache instance. |
FrcaHandle | Identifies the FRCA instance for which the cache is created. |
CacheSpec | Points to a frca_ctrl_create_t structure, which specifies
the characteristics of the cache to be created. The structure contains
the following members:
Note: Structure
members do not necessarily appear in this order.
|
Return Values
Item | Description |
---|---|
0 | The subroutine completed successfully. |
-1 | The subroutine failed. The global variable errno is set to indicate the specific type of error. |
Error Codes
Item | Description |
---|---|
EINVAL | The CacheHandle or the CacheSpec parameter is zero or the CacheSpec parameter is not of the correct type FCTRL_CACHETYPE_HTTP. |
EFAULT | The CacheHandle or the CacheSpec point to an invalid address. |
ENOENT | The FrcaHandle parameter is invalid. |