开发者

How can I suppress the stacktraces and html in Wicket development mode

Usually the first line in the error message is sufficient in solving the problem so I do no开发者_开发百科t want to pollute my console in Eclipse.


You can subclass WebRequestCycle and override newRequestCycle in your WebApplication class. In WebRequestCycle you can handle RuntimeExceptions in any manner. There's a good explanation with code samples here.


Or in MyApp#init() set: getExceptionSettings().setUnexpectedExceptionDisplay( IExceptionSettings.SHOW_INTERNAL_ERROR_PAGE);

This will show the configured "error 500" page and log the exception in the server log files

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜