From 6a8268f323de09bd4efedd99fdf621c4916a0b77 Mon Sep 17 00:00:00 2001 From: xiongziliang <771730766@qq.com> Date: Thu, 1 Oct 2020 20:58:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=85=8D=E7=BD=AE=E9=A1=B9?= =?UTF-8?q?=20mediaServerId?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- conf/config.ini | 2 ++ server/WebHook.cpp | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/conf/config.ini b/conf/config.ini index 755222a0..9b439414 100644 --- a/conf/config.ini +++ b/conf/config.ini @@ -52,6 +52,8 @@ mergeWriteMS=0 #会直接影响rtsp/rtmp/hls/mp4/flv等协议的时间戳 #同协议情况下不影响(例如rtsp/rtmp推流,那么播放rtsp/rtmp时不会影响时间戳) modifyStamp=0 +#服务器唯一id,用于触发hook时区别是哪台服务器 +mediaServerId=your_server_id [hls] #hls写文件的buf大小,调整参数可以提高文件io性能 diff --git a/server/WebHook.cpp b/server/WebHook.cpp index 4d8aae39..96d06d06 100644 --- a/server/WebHook.cpp +++ b/server/WebHook.cpp @@ -130,7 +130,7 @@ const char *getContentType(const HttpArgs &value){ static void do_http_hook(const string &url,const ArgsType &body,const function &fun){ GET_CONFIG(string,mediaServerId,General::kMediaServerId); - const_cast(body)["mediaserverid"] = mediaServerId; + const_cast(body)["mediaServerId"] = mediaServerId; GET_CONFIG(float,hook_timeoutSec,Hook::kTimeoutSec); HttpRequester::Ptr requester(new HttpRequester);