Hi,
I’d like detect that server db is down in application (vaadin + sqlcontainer). When error is exist, I’d like display own error information for user. I tried use this solution:
In tomcat web.xml I put:
<error-page>
<error-code>500</error-code>
<location>/error.html</location>
<error-page>
<error-page>
<error-code>501</error-code>
<location>/error.html</location>
<error-page>
<error-page>
<error-code>404</error-code>
<location>/error.html</location>
<error-page>
In main WebContent I put file error.html
And for tests I turn off server db (sql-server express) and redeployed webapp. When I starts webapp I’ve got error:
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
java.lang.NullPointerException
How can I do it?
Best regards,
Paul