xrpld
Loading...
Searching...
No Matches
beast::insight::Group Class Referenceabstract

A collector front-end that manages a group of metrics. More...

#include <Group.h>

Inheritance diagram for beast::insight::Group:
Collaboration diagram for beast::insight::Group:

Public Types

using ptr = std::shared_ptr<Group>

Public Member Functions

virtual std::string const & name () const =0
 Returns the name of this group, for diagnostics.
template<class Handler>
Hook makeHook (Handler handler)
 Create a hook.
virtual Hook makeHook (HookImpl::HandlerType const &handler)=0
virtual Counter makeCounter (std::string const &name)=0
 Create a counter with the specified name.
Counter makeCounter (std::string const &prefix, std::string const &name)
virtual Event makeEvent (std::string const &name)=0
 Create an event with the specified name.
Event makeEvent (std::string const &prefix, std::string const &name)
virtual Gauge makeGauge (std::string const &name)=0
 Create a gauge with the specified name.
Gauge makeGauge (std::string const &prefix, std::string const &name)
virtual Meter makeMeter (std::string const &name)=0
 Create a meter with the specified name.
Meter makeMeter (std::string const &prefix, std::string const &name)

Detailed Description

A collector front-end that manages a group of metrics.

Definition at line 11 of file Group.h.

Member Typedef Documentation

◆ ptr

Definition at line 14 of file Group.h.

Member Function Documentation

◆ name()

virtual std::string const & beast::insight::Group::name ( ) const
nodiscardpure virtual

Returns the name of this group, for diagnostics.

Implemented in beast::insight::detail::GroupImp.

◆ makeHook() [1/2]

template<class Handler>
Hook beast::insight::Collector::makeHook ( Handler handler)
inherited

Create a hook.

A hook is called at each collection interval, on an implementation defined thread. This is a convenience facility for gathering metrics in the polling style. The typical usage is to update all the metrics of interest in the handler.

Handler will be called with this signature: void handler (void)

See also
Hook

Definition at line 45 of file Collector.h.

◆ makeHook() [2/2]

virtual Hook beast::insight::Collector::makeHook ( HookImpl::HandlerType const & handler)
pure virtualinherited

◆ makeCounter() [1/2]

virtual Counter beast::insight::Collector::makeCounter ( std::string const & name)
pure virtualinherited

◆ makeCounter() [2/2]

Counter beast::insight::Collector::makeCounter ( std::string const & prefix,
std::string const & name )
inherited

Definition at line 62 of file Collector.h.

◆ makeEvent() [1/2]

virtual Event beast::insight::Collector::makeEvent ( std::string const & name)
pure virtualinherited

◆ makeEvent() [2/2]

Event beast::insight::Collector::makeEvent ( std::string const & prefix,
std::string const & name )
inherited

Definition at line 78 of file Collector.h.

◆ makeGauge() [1/2]

virtual Gauge beast::insight::Collector::makeGauge ( std::string const & name)
pure virtualinherited

◆ makeGauge() [2/2]

Gauge beast::insight::Collector::makeGauge ( std::string const & prefix,
std::string const & name )
inherited

Definition at line 94 of file Collector.h.

◆ makeMeter() [1/2]

virtual Meter beast::insight::Collector::makeMeter ( std::string const & name)
pure virtualinherited

◆ makeMeter() [2/2]

Meter beast::insight::Collector::makeMeter ( std::string const & prefix,
std::string const & name )
inherited

Definition at line 110 of file Collector.h.