mco_trace_init_simple_handler

Enable tracing with a simple file-based locking handler.

For an overview see page Tracing Framework in C

Prototype

    void mco_trace_init_simple_handler(	/*IN*/ const char * filename,
                       /*IN*/ mco_trace_file_appender_options close_policy,
                       /*IN*/ const char *format);

Arguments

filename
The name of the trace file.
close_policy
Either MCO_TRACE_LEAVE_OPENED or MCO_TRACE_KEEP_CLOSED (which will cause the handler to close the trace file after a record is written).
format
A printf-like format for messages. Format specifiers are:
    %t - message time
    %m - module
    %i - thread id
    %s - severity
    %f - source code file
    %l - source code line
    %e - error text

Description

This function enables tracing with a simple file-based locking handler. It must be called before any databases operations occur.

(Note that a user-provided custom handler can be registered with function mco_trace_set_handler().)

Return Codes

void
No status code returned.

Files

Header file:
mcotrace.h
Source file:
mcotracehandlers.c
Library:
libmcotrace.a