mirror of
https://github.com/matrix-construct/construct
synced 2025-02-18 09:40:12 +01:00
ircd:Ⓜ️:sync: Add stats.info conf item; rename debug_stats item.
This commit is contained in:
parent
169abb0676
commit
c9f8e44c78
4 changed files with 15 additions and 7 deletions
|
@ -36,7 +36,8 @@ namespace ircd::m::sync
|
|||
|
||||
extern log::log log;
|
||||
extern ctx::pool pool;
|
||||
extern conf::item<bool> debug_stats;
|
||||
extern conf::item<bool> stats_info;
|
||||
extern conf::item<bool> stats_debug;
|
||||
}
|
||||
|
||||
struct ircd::m::sync::item
|
||||
|
|
15
ircd/m.cc
15
ircd/m.cc
|
@ -419,10 +419,17 @@ ircd::m::sync::pool
|
|||
"sync", pool_opts
|
||||
};
|
||||
|
||||
decltype(ircd::m::sync::debug_stats)
|
||||
ircd::m::sync::debug_stats
|
||||
decltype(ircd::m::sync::stats_info)
|
||||
ircd::m::sync::stats_info
|
||||
{
|
||||
{ "name", "ircd.m.sync.debug_stats" },
|
||||
{ "name", "ircd.m.sync.stats.info" },
|
||||
{ "default", false },
|
||||
};
|
||||
|
||||
decltype(ircd::m::sync::stats_debug)
|
||||
ircd::m::sync::stats_debug
|
||||
{
|
||||
{ "name", "ircd.m.sync.stats.debug" },
|
||||
{ "default", false },
|
||||
};
|
||||
|
||||
|
@ -684,7 +691,7 @@ try
|
|||
_polylog(data);
|
||||
|
||||
#ifdef RB_DEBUG
|
||||
if(data.stats && bool(debug_stats))
|
||||
if(data.stats && bool(stats_debug))
|
||||
{
|
||||
//data.out.flush();
|
||||
thread_local char tmbuf[32];
|
||||
|
|
|
@ -230,7 +230,7 @@ try
|
|||
}
|
||||
};
|
||||
|
||||
log::info
|
||||
if(stats_info) log::info
|
||||
{
|
||||
log, "polylog %s complete", loghead(data)
|
||||
};
|
||||
|
|
|
@ -109,7 +109,7 @@ ircd::m::sync::_rooms_polylog(data &data,
|
|||
|
||||
#ifdef RB_DEBUG
|
||||
thread_local char tmbuf[32];
|
||||
if(data.stats && bool(debug_stats)) log::debug
|
||||
if(data.stats && bool(stats_debug)) log::debug
|
||||
{
|
||||
log, "polylog %s %s in %s",
|
||||
loghead(data),
|
||||
|
|
Loading…
Add table
Reference in a new issue