You've already forked pgbackrest
mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-07-15 01:04:37 +02:00
Move tls/http statistics output to command/command.
This module already has the filtering required to keep these messages from being displayed by default for commands that output to stdout (e.g. info).
This commit is contained in:
@ -7,6 +7,8 @@ Common Command Routines
|
||||
#include <string.h>
|
||||
|
||||
#include "common/debug.h"
|
||||
#include "common/io/http/client.h"
|
||||
#include "common/io/tls/client.h"
|
||||
#include "common/log.h"
|
||||
#include "common/memContext.h"
|
||||
#include "common/time.h"
|
||||
@ -179,6 +181,18 @@ cmdEnd(int code, const String *errorMessage)
|
||||
{
|
||||
MEM_CONTEXT_TEMP_BEGIN()
|
||||
{
|
||||
// Log tls statistics
|
||||
String *tlsClientStat = tlsClientStatStr();
|
||||
|
||||
if (tlsClientStat != NULL)
|
||||
LOG_DETAIL(strPtr(tlsClientStat));
|
||||
|
||||
// Log http statistics
|
||||
String *httpClientStat = httpClientStatStr();
|
||||
|
||||
if (httpClientStat != NULL)
|
||||
LOG_INFO(strPtr(httpClientStat));
|
||||
|
||||
// Basic info on command end
|
||||
String *info = strNewFmt("%s command end: ", cfgCommandName(cfgCommand()));
|
||||
|
||||
|
Reference in New Issue
Block a user