pmemobj_log_set_threshold - Man Page

set the logging threshold value

Synopsis

    #include <libpmemobj.h>

    enum pmemobj_log_level {
        PMEMOBJ_LOG_LEVEL_HARK,
        PMEMOBJ_LOG_LEVEL_FATAL,
        PMEMOBJ_LOG_LEVEL_ERROR,
        PMEMOBJ_LOG_LEVEL_WARNING,
        PMEMOBJ_LOG_LEVEL_NOTICE,
        PMEMOBJ_LOG_LEVEL_INFO,
        PMEMOBJ_LOG_LEVEL_DEBUG
    };

    enum pmemobj_log_threshold {
        PMEMOBJ_LOG_THRESHOLD,
        PMEMOBJ_LOG_THRESHOLD_AUX
    };

    int pmemobj_log_set_threshold(enum pmemobj_log_threshold threshold,
        enum pmemobj_log_level value);

Description

pmemobj_log_set_threshold() sets the logging threshold value.

Available thresholds are:

Available threshold values are defined by enum pmemobj_log_level. They are listed in descending order of severity:

Return Value

pmemobj_log_set_threshold() function returns 0 on success or returns a non-zero value and sets errno on failure. On failure, the threshold value remains unchanged.

Errors

pmemobj_log_set_threshold() can set the following errno values on fail:

See Also

pmemobj_log_get_threshold(3), pmemobj_log_set_function(3).

Referenced By

libpmemobj(7), pmemobj_log_get_threshold(3), pmemobj_log_set_function(3).

2024-07-18 PMDK - PMDK Programmer's Manual