mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
* Exporter: metrics support cpu gauge. * Exporter: metrics support memory and uname.. * Exporter: Ignore error when uname fail. Co-authored-by: winlin <winlin@vip.126.com>
This commit is contained in:
parent
9673bfb92c
commit
9f4338bd9d
6 changed files with 78 additions and 3 deletions
|
@ -26,6 +26,10 @@
|
|||
|
||||
#include <srs_protocol_st.hpp>
|
||||
|
||||
#if defined(__linux__) || defined(SRS_OSX)
|
||||
#include <sys/utsname.h>
|
||||
#endif
|
||||
|
||||
class ISrsHttpMessage;
|
||||
|
||||
class SrsMessageHeader;
|
||||
|
@ -187,5 +191,10 @@ extern std::string srs_get_system_hostname(void);
|
|||
// Read all content util EOF.
|
||||
extern srs_error_t srs_ioutil_read_all(ISrsReader* in, std::string& content);
|
||||
|
||||
#if defined(__linux__) || defined(SRS_OSX)
|
||||
// Get system uname info.
|
||||
extern utsname* srs_get_system_uname_info();
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue