ZH_Recovery

Lunny Xiao edited this page Apr 17, 2015 · 1 revision

Recovery

Recovery 中间件可以检测和捕获到web函数中的panic情况,并保证程序不会crash。此中间件为默认中间件,包含在Classic中。

t := tango.New(tango.Recovery(true))
t.Run()

其中的参数表示是否将崩溃的堆栈信息显示出来。

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.