mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-24 15:46:29 +00:00
Add log_hint() function for logging hints
There are a few places where additional hints are written as log output, usually LOG_NOTICE. Create an explicit function to provide hints in a standardized manner; by storing the log level of the previous logger call, we can ensure the hint is only displayed when the log message itself would be. Part of an ongoing effort to better control repmgr's logging output.
This commit is contained in:
3
log.h
3
log.h
@@ -115,10 +115,11 @@ __attribute__((format(PG_PRINTF_ATTRIBUTE, 3, 4)));
|
||||
/* Logger initialisation and shutdown */
|
||||
bool logger_shutdown(void);
|
||||
|
||||
bool logger_init(t_configuration_options * opts, const char *ident,
|
||||
bool logger_init(t_configuration_options * opts, const char *ident,
|
||||
const char *level, const char *facility);
|
||||
|
||||
void logger_min_verbose(int minimum);
|
||||
void log_hint(const char *fmt, ...);
|
||||
|
||||
extern int log_type;
|
||||
extern int log_level;
|
||||
|
||||
Reference in New Issue
Block a user