Prometheus Client Library for Modern C++
Public Member Functions | List of all members
prometheus::Exposer Class Reference

Public Member Functions

 Exposer (const std::string &bind_address, std::size_t num_threads=2, const CivetCallbacks *callbacks=nullptr)
 
 Exposer (std::vector< std::string > options, const CivetCallbacks *callbacks=nullptr)
 
 Exposer (const Exposer &)=delete
 
 Exposer (Exposer &&)=delete
 
Exposeroperator= (const Exposer &)=delete
 
Exposeroperator= (Exposer &&)=delete
 
void RegisterCollectable (const std::weak_ptr< Collectable > &collectable, const std::string &uri=std::string("/metrics"))
 
void RegisterAuth (std::function< bool(const std::string &, const std::string &)> authCB, const std::string &realm="Prometheus-cpp Exporter", const std::string &uri=std::string("/metrics"))
 
void RemoveCollectable (const std::weak_ptr< Collectable > &collectable, const std::string &uri=std::string("/metrics"))
 
std::vector< int > GetListeningPorts () const