1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

APM: Support distributed tracing by Tencent Cloud APM. v5.0.63

This commit is contained in:
winlin 2022-08-24 11:04:39 +08:00
parent 736c661808
commit 3e2f8622f8
49 changed files with 4989 additions and 719 deletions

View file

@ -185,6 +185,9 @@ srs_error_t SrsHybridServer::initialize()
if ((err = _srs_cls->initialize()) != srs_success) {
return srs_error_wrap(err, "cls client");
}
if ((err = _srs_apm->initialize()) != srs_success) {
return srs_error_wrap(err, "apm client");
}
// Register some timers.
timer20ms_->subscribe(clock_monitor_);
@ -396,6 +399,12 @@ srs_error_t SrsHybridServer::on_timer(srs_utime_t interval)
srs_freep(err);
}
// Report logs to APM if enabled.
if ((err = _srs_apm->report()) != srs_success) {
srs_warn("ignore apm err %s", srs_error_desc(err).c_str());
srs_freep(err);
}
return err;
}