uri
This commit is contained in:
parent
ca5e252c0c
commit
e861416e48
|
@ -23,6 +23,7 @@
|
||||||
|
|
||||||
static SMonitor tsMonitor = {0};
|
static SMonitor tsMonitor = {0};
|
||||||
static char* tsMonUri = "/report";
|
static char* tsMonUri = "/report";
|
||||||
|
static char* tsMonFwUri = "/td_metric";
|
||||||
|
|
||||||
void monRecordLog(int64_t ts, ELogLevel level, const char *content) {
|
void monRecordLog(int64_t ts, ELogLevel level, const char *content) {
|
||||||
taosThreadMutexLock(&tsMonitor.lock);
|
taosThreadMutexLock(&tsMonitor.lock);
|
||||||
|
@ -558,7 +559,7 @@ void monSendPromReport() {
|
||||||
//uInfoL("report cont:\n%s\n", pCont);
|
//uInfoL("report cont:\n%s\n", pCont);
|
||||||
if (pCont != NULL) {
|
if (pCont != NULL) {
|
||||||
EHttpCompFlag flag = tsMonitor.cfg.comp ? HTTP_GZIP : HTTP_FLAT;
|
EHttpCompFlag flag = tsMonitor.cfg.comp ? HTTP_GZIP : HTTP_FLAT;
|
||||||
if (taosSendHttpReport(tsMonitor.cfg.server, tsMonUri, tsMonitor.cfg.port, pCont, strlen(pCont), flag) != 0) {
|
if (taosSendHttpReport(tsMonitor.cfg.server, tsMonFwUri, tsMonitor.cfg.port, pCont, strlen(pCont), flag) != 0) {
|
||||||
uError("failed to send monitor msg");
|
uError("failed to send monitor msg");
|
||||||
}else{
|
}else{
|
||||||
taos_collector_registry_clear_out(TAOS_COLLECTOR_REGISTRY_DEFAULT);
|
taos_collector_registry_clear_out(TAOS_COLLECTOR_REGISTRY_DEFAULT);
|
||||||
|
@ -571,7 +572,7 @@ void monSendContent(char *pCont) {
|
||||||
//uInfoL("report cont:\n%s\n", pCont);
|
//uInfoL("report cont:\n%s\n", pCont);
|
||||||
if (pCont != NULL) {
|
if (pCont != NULL) {
|
||||||
EHttpCompFlag flag = tsMonitor.cfg.comp ? HTTP_GZIP : HTTP_FLAT;
|
EHttpCompFlag flag = tsMonitor.cfg.comp ? HTTP_GZIP : HTTP_FLAT;
|
||||||
if (taosSendHttpReport(tsMonitor.cfg.server, tsMonUri, tsMonitor.cfg.port, pCont, strlen(pCont), flag) != 0) {
|
if (taosSendHttpReport(tsMonitor.cfg.server, tsMonFwUri, tsMonitor.cfg.port, pCont, strlen(pCont), flag) != 0) {
|
||||||
uError("failed to send monitor msg");
|
uError("failed to send monitor msg");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue