Commit f3f7a8ad authored by 吴贤德's avatar 吴贤德

中心服务修改

parent 72f34e93
...@@ -2,6 +2,7 @@ package Controller ...@@ -2,6 +2,7 @@ package Controller
import ( import (
log "github.com/sirupsen/logrus" log "github.com/sirupsen/logrus"
"src/Common/DateTime"
"src/Common/Unit" "src/Common/Unit"
"src/Config" "src/Config"
"src/Model/Wasu" "src/Model/Wasu"
...@@ -29,8 +30,8 @@ func (this *WasuChecker) checkIncrementList() { ...@@ -29,8 +30,8 @@ func (this *WasuChecker) checkIncrementList() {
log.Infoln("WasuChecker.checkIncrementList Starting...") log.Infoln("WasuChecker.checkIncrementList Starting...")
mediaModel := new(Wasu.MediaListModel) mediaModel := new(Wasu.MediaListModel)
mediaModel.Config = this.Config mediaModel.Config = this.Config
//date := DateTime.Format("YYYYMMDD", time.Now()) date := DateTime.Format("YYYYMMDD", time.Now())
date:="20171213" //date:="20171213"
mediaList := mediaModel.FetchList(date, 1) mediaList := mediaModel.FetchList(date, 1)
ok := mediaModel.UpdateMediaList(mediaList) ok := mediaModel.UpdateMediaList(mediaList)
if !ok { if !ok {
......
...@@ -19,9 +19,9 @@ func main() { ...@@ -19,9 +19,9 @@ func main() {
configCHK.Start() configCHK.Start()
//华数媒资拉取 //华数媒资拉取
//wasuCHK := new (WasuChecker) wasuCHK := new (WasuChecker)
//wasuCHK.Config=config wasuCHK.Config=config
//wasuCHK.Start() wasuCHK.Start()
//合作方媒资推送 //合作方媒资推送
spCHK :=new(SpChecker) spCHK :=new(SpChecker)
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
#标准输出日志文件路径 #标准输出日志文件路径
LOG_PATH="./nohup.log" LOG_PATH="./nohup.log"
#进程名 #进程名
PROGRAM="SooonerIMTraffic" PROGRAM="SooonerHotelCS"
BAK_TIME="" BAK_TIME=""
while true ; do while true ; do
...@@ -13,7 +13,8 @@ while true ; do ...@@ -13,7 +13,8 @@ while true ; do
if [ $PRO_NOW -lt 1 ]; then if [ $PRO_NOW -lt 1 ]; then
mv $LOG_PATH $LOG_PATH.bak$BAK_TIME mv $LOG_PATH $LOG_PATH.bak$BAK_TIME
nohup ./$PROGRAM > $LOG_PATH 2>&1 & #nohup ./$PROGRAM > $LOG_PATH 2>&1 &
nohup ./$PROGRAM >/dev/null 2>$LOG_PATH &
date >> ./service_check.log date >> ./service_check.log
echo "start1" >> ./service_check.log echo "start1" >> ./service_check.log
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment