Commit dac0d0e0 authored by Your Name's avatar Your Name

default log is debug

parent 6f07b90c
......@@ -460,7 +460,7 @@ func main() {
flag.BoolVar(&withBillDb, "withbilldb", true, "enable with bill db, or simulate")
flag.IntVar(&logLevel, "loglevel", 0, "log level,default is debug,LevelDebug Level = -4 LevelInfo Level = 0 LevelWarn Level = 4 LevelError Level = 8 ")
flag.IntVar(&logLevel, "loglevel", -4, "log level,default is debug,LevelDebug Level = -4 LevelInfo Level = 0 LevelWarn Level = 4 LevelError Level = 8 ")
flag.Parse()
......@@ -628,7 +628,7 @@ func ApiAndJWT(c *fiber.Ctx) error {
pbMsg := pbUpstream.TaskContent{
TaskId: reqHeaders["Task-Id"][0],
TaskType: uint64(task.ID),
TaskKind: 1,
TaskKind: pbUpstream.TaskKind(task.Kind),
TaskCmd: task.Cmd,
TaskParam: c.Body(), //[]byte(reqHeaders["Task-Id"][0]),
TaskTimestamp: uint64(time.Now().UnixNano()),
......@@ -688,10 +688,9 @@ func ApiAndJWT(c *fiber.Ctx) error {
//fmt.Println("asyncMode-----------", asyncMode)
if asyncMode {
//time.Sleep(10 * time.Second)
m := make([]byte, 1024*1024)
return c.SendString(string(m))
time.Sleep(10 * time.Second)
m := make([]byte, 1024*1024+1024*512)
return c.Send(m)
//return c.SendString(pbMsg.TaskId)
} else {
......
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