diff --git a/cmd/openim-api/main.go b/cmd/openim-api/main.go index be52751af..0f5b3a2dd 100644 --- a/cmd/openim-api/main.go +++ b/cmd/openim-api/main.go @@ -15,18 +15,12 @@ package main import ( - _ "net/http/pprof" - "time" - "github.com/openimsdk/open-im-server/v3/pkg/common/cmd" util "github.com/openimsdk/open-im-server/v3/pkg/util/genutil" + _ "net/http/pprof" ) func main() { - go func() { - time.Sleep(30 * time.Second) - panic("Panic after one minute!") - }() apiCmd := cmd.NewApiCmd(cmd.ApiServer) apiCmd.AddPortFlag() apiCmd.AddPrometheusPortFlag() diff --git a/scripts/check-all.sh b/scripts/check-all.sh index 803dad202..b7db44bdf 100755 --- a/scripts/check-all.sh +++ b/scripts/check-all.sh @@ -107,9 +107,10 @@ if [[ $? -ne 0 ]]; then echo "$result" exit 1 else + openim::util::find_ports_for_all_services ${OPENIM_ALL_SERVICE_LIBRARIES_NO_TRANSFER[@]} openim::log::success "All OpenIM services are running normally! " fi -openim::util::find_ports_for_all_services ${OPENIM_ALL_SERVICE_LIBRARIES_NO_TRANSFER[@]} + diff --git a/scripts/install/openim-push.sh b/scripts/install/openim-push.sh index 8dea4b1f1..aafb24c7b 100755 --- a/scripts/install/openim-push.sh +++ b/scripts/install/openim-push.sh @@ -72,7 +72,8 @@ function openim::push::start() { for (( i=0; i<${#OPENIM_PUSH_PORTS_ARRAY[@]}; i++ )); do openim::log::info "start push process, port: ${OPENIM_PUSH_PORTS_ARRAY[$i]}, prometheus port: ${PUSH_PROM_PORTS_ARRAY[$i]}" cmd="${OPENIM_PUSH_BINARY} --port ${OPENIM_PUSH_PORTS_ARRAY[$i]} -c ${OPENIM_PUSH_CONFIG} --prometheus_port ${PUSH_PROM_PORTS_ARRAY[$i]}" - nohup ${cmd} >> "${LOG_FILE}" 2> >(tee -a "$TMP_LOG_FILE" | while read line; do echo -e "\e[31m${line}\e[0m"; done >&2) >/dev/null & + #nohup ${cmd} >> "${LOG_FILE}" 2> >(tee -a "$TMP_LOG_FILE" | while read line; do echo -e "\e[31m${line}\e[0m"; done >&2) >/dev/null & + nohup ${cmd} >> "${LOG_FILE}" 2> >(tee -a "$TMP_LOG_FILE" | while read line; do echo -e "\e[31m${line}\e[0m"; done >&2) >> "${LOG_FILE}" 2>&1 & #nohup ${OPENIM_PUSH_BINARY} --port ${OPENIM_PUSH_PORTS_ARRAY[$i]} -c ${OPENIM_PUSH_CONFIG} --prometheus_port ${PUSH_PROM_PORTS_ARRAY[$i]} >> ${LOG_FILE} 2> >(tee -a "${STDERR_LOG_FILE}" "$TMP_LOG_FILE" >&2) & done return 0 diff --git a/scripts/start-all.sh b/scripts/start-all.sh index 93badf639..76d0b3d3b 100755 --- a/scripts/start-all.sh +++ b/scripts/start-all.sh @@ -123,7 +123,6 @@ fi openim::util::find_ports_for_all_services ${OPENIM_ALL_SERVICE_LIBRARIES_NO_TRANSFER[@]} - openim::log::status "Start the post-start tools:" ${TOOLS_START_SCRIPTS_PATH} openim::tools::post-start openim::log::status "post-start has been successfully completed!"