Record update callbacks are file-based, loading a DLL/SO library on physical file open and unloading the DLL/SO on file close. This design leads to difficulties for more complex callbacks that attempt to maintain longer-term state information. To address this, the PLUGIN keyword functionality has been extended to support loading generic, user-defined libraries once at server startup, and unloading them at server shutdown.
This is enabled by setting in ctsrvr.cfg:
PLUGIN_CALLBACK <LABEL>;<DLL>
where:
When the library is loaded at startup, it must export the following function:
int ctDECL ctPlugin_describe(char * name,size_t * size,int request)
and may optionally provide the following functions:
Example
An example implementation is provided in ctrucbdll.c.
Note:
Currently, only Record Update callbacks and Deferred Index callbacks can utilize this PLUGIN_CALLBACK functionality.