| | |
| | | } |
| | | |
| | | func GoPush(url string) { |
| | | |
| | | var err error |
| | | var msg []byte |
| | | var sock mangos.Socket |
| | |
| | | logger.Error("传输的数据超过大小限制") |
| | | return |
| | | } |
| | | errTimeOut := sock.SetOption(mangos.OptionRecvDeadline,time.Millisecond * 2000) |
| | | errTimeOut := sock.SetOption(mangos.OptionRecvDeadline,time.Millisecond * 1500) |
| | | if errTimeOut != nil { |
| | | logger.Error("接收响应超时") |
| | | return |
| | | } |
| | | errTimeOut1 := sock.SetOption(mangos.OptionSendDeadline,time.Millisecond * 2000) |
| | | errTimeOut1 := sock.SetOption(mangos.OptionSendDeadline,time.Millisecond * 1500) |
| | | if errTimeOut1 != nil { |
| | | logger.Error("发送超时") |
| | | return |