diff options
Diffstat (limited to 'reqToPB.go')
| -rw-r--r-- | reqToPB.go | 17 |
1 files changed, 9 insertions, 8 deletions
@@ -58,14 +58,15 @@ func ReqToPB(r *http.Request) (*HttpRequest, error) { // log.Info("TRYING TO MARSHAL bytes:", len(msg), err) pb := &HttpRequest{ - Method: r.Method, - URL: r.URL.String(), - Proto: r.Proto, - Headers: headers, - IP: getClientIP(r), - Host: r.Host, - Body: msg, - Hostname: r.Header.Get("hostname"), + Method: r.Method, + URL: r.URL.String(), + Proto: r.Proto, + Headers: headers, + IP: getClientIP(r), + Host: r.Host, + ClientData: msg, + ClientDataLen: int64(len(msg)), + Hostname: r.Header.Get("hostname"), } pb.Route = cleanURL(r.URL.Path) |
