forked from acouzens/open5gs
[metrics] Fix log output for metrics
Even if the configured log level for the application was set to "error", the first "info" message of the metrics library was output to the log. Reorder the initialization of the metrics library.
This commit is contained in:
parent
1c3876517f
commit
b084edeee1
|
@ -49,13 +49,13 @@ int amf_initialize()
|
|||
rv = amf_m_tmsi_pool_generate();
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
||||
rv = amf_metrics_open();
|
||||
if (rv != 0) return OGS_ERROR;
|
||||
|
||||
rv = ogs_log_config_domain(
|
||||
ogs_app()->logger.domain, ogs_app()->logger.level);
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
||||
rv = amf_metrics_open();
|
||||
if (rv != 0) return OGS_ERROR;
|
||||
|
||||
rv = amf_sbi_open();
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
||||
|
|
|
@ -55,9 +55,6 @@ int mme_initialize()
|
|||
rv = mme_context_parse_config();
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
||||
rv = mme_metrics_open();
|
||||
if (rv != 0) return OGS_ERROR;
|
||||
|
||||
rv = ogs_log_config_domain(
|
||||
ogs_app()->logger.domain, ogs_app()->logger.level);
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
@ -65,6 +62,9 @@ int mme_initialize()
|
|||
rv = mme_m_tmsi_pool_generate();
|
||||
if (rv != OGS_OK) return rv;
|
||||
|
||||
rv = mme_metrics_open();
|
||||
if (rv != 0) return OGS_ERROR;
|
||||
|
||||
rv = mme_fd_init();
|
||||
if (rv != OGS_OK) return OGS_ERROR;
|
||||
|
||||
|
|
Loading…
Reference in New Issue