Closed happy-berry closed 5 months ago
var req = HttpRequest.NewRequest().SetTimeout(time.Second * 5).SetHeaders(map[string]string{"Content-Type": "application/json"}) req.SetTimeout(time.Second * 3) fmt.Println(req) res, err := req.Post("http://127.0.0.1:8080/mock/Send/timeout", nil)
I saw the attribute timeout unable to take effect, It only has the dafault 30s . when initiating a post request, a new request object will be created instead of using the original request object to initiate the request
I saw the attribute timeout unable to take effect, It only has the dafault 30s . when initiating a post request, a new request object will be created instead of using the original request object to initiate the request