mirror of
https://github.com/kataras/iris.git
synced 2026-03-05 16:05:58 +00:00
accesslog: log error bodies and communicate with the recover middleware
This commit is contained in:
@@ -609,6 +609,7 @@ New Package-level Variables:
|
||||
|
||||
New Context Methods:
|
||||
|
||||
- `Context.IsRecovered()` reports whether the current request was recovered from the [recover middleware](https://github.com/kataras/iris/tree/master/middleware/recover). Also the `iris.IsErrPrivate` function and `iris.ErrPrivate` interface have been introduced.
|
||||
- `Context.RecordBody()` same as the Application's `DisableBodyConsumptionOnUnmarshal` configuration field but registers per chain of handlers. It makes the request body readable more than once.
|
||||
- `Context.IsRecordingBody() bool` reports whether the request body can be readen multiple times.
|
||||
- `Context.ReadHeaders(ptr interface{}) error` binds request headers to "ptr". [Example](https://github.com/kataras/iris/blob/master/_examples/request-body/read-headers/main.go).
|
||||
|
||||
Reference in New Issue
Block a user