1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-08 20:41:57 +00:00

More on Transactions: Fallback on, unexpected, panics and able to send 'silent' error which stills reverts the changes but no output

This commit is contained in:
Gerasimos (Makis) Maropoulos
2016-12-18 14:08:28 +02:00
parent 1da8231abd
commit 88c98bb1e1
5 changed files with 129 additions and 19 deletions

View File

@@ -2,6 +2,9 @@
**How to upgrade**: remove your `$GOPATH/src/github.com/kataras` folder, open your command-line and execute this command: `go get -u github.com/kataras/iris/iris`.
## 5.1.1 -> 5.1.3
- **More on Transactions vol 3**: Recovery from any (unexpected error) panics inside `context.BeginTransaction` without loud, continue the execution as expected. Next version will have a little cleanup if I see that the transactions code is going very large or hard to understand the flow*
## 5.1.1 -> 5.1.2
- **More on Transactions vol 2**: Added **iris.UseTransaction** and **iris.DoneTransaction** to register transactions as you register middleware(handlers). new named type **iris.TransactionFunc**, shortcut of `func(scope *iris.TransactionScope)`, that gives you a function which you can convert a transaction to a normal handler/middleware using its `.ToMiddleware()`, for more see the `test code inside context_test.go:TestTransactionsMiddleware`.