瀏覽代碼

Add log for prometheus collector start

Mészáros Mihály 5 年之前
父節點
當前提交
87d85f06bd
共有 1 個文件被更改,包括 6 次插入1 次删除
  1. 6 1
      src/apps/relay/mainrelay.c

+ 6 - 1
src/apps/relay/mainrelay.c

@@ -2485,7 +2485,12 @@ int main(int argc, char **argv)
 
 	drop_privileges();
 #if !defined(TURN_NO_PROMETHEUS)
-	start_prometheus_server();
+	if (start_prometheus_server()){
+	  TURN_LOG_FUNC(TURN_LOG_LEVEL_ERROR, "\nCould not start Prometheus collector!\n");
+	}
+	else {
+	  TURN_LOG_FUNC(TURN_LOG_LEVEL_INFO, "\nPrometheus collector started sucessfully.\n");
+	}
 #endif