实现基本的反向代理

This commit is contained in:
刘祥超
2020-09-27 15:26:06 +08:00
parent cb85a9bb01
commit fb587ac0de
13 changed files with 522 additions and 60 deletions

View File

@@ -35,8 +35,7 @@ func (this *HTTPRequest) doURL(method string, url string, host string, statusCod
resp, err := client.Do(req)
if err != nil {
logs.Error(errors.New(req.URL.String() + ": " + err.Error()))
this.addError(err)
this.write500()
this.write500(err)
return
}
defer func() {