瀏覽代碼

更新

master
huangjiajun 1 月之前
父節點
當前提交
e72bed4e64
共有 1 個文件被更改,包括 4 次插入4 次删除
  1. +4
    -4
      app/svc/svc_data_center_original_data.go

+ 4
- 4
app/svc/svc_data_center_original_data.go 查看文件

@@ -217,10 +217,10 @@ func DataCenterOriginalDataDoing(c *gin.Context, req md.DataCenterDataCenterOrig
return nil
}
func OriginalDataMoreApplicationDoing(c *gin.Context, req md.DataCenterOriginalDataMoreApplicationDoingReq) error {
state, _ := cache.GetString(c.GetString("mid") + ":original.wx.ad.data")
if state == "1" {
return e.NewErr(400000, "数据采集中~")
}
//state, _ := cache.GetString(c.GetString("mid") + ":original.wx.ad.data")
//if state == "1" {
// return e.NewErr(400000, "数据采集中~")
//}
// 加锁 防止并发提取
mutexKey := fmt.Sprintf("%s:DataCenterOriginalDataDoingOriginalDataMoreApplicationDoing", c.GetString("mid"))
withdrawAvailable, err := cache.Do("SET", mutexKey, 1, "EX", 5, "NX")


Loading…
取消
儲存