Hi Isomorphic,
my goal is that my app is using one big war file, currently is using many war files.
That's why I have to add some security checks.
First example is here:
	Is there any other way I can use, in order to display the error with message I want?
Because if an error occurs in this area, so that I can immediately know where it comes from.
The error is now displayed only in the log. For the client, error message is: "The server failed to return a formatted response at all."
Btw.
1) Method "handleError" is not in the docs.
2 )In this example: Example processRequest is not "overridden".
Best regards
Pavo
					my goal is that my app is using one big war file, currently is using many war files.
That's why I have to add some security checks.
First example is here:
Code:
	
	public class LMSIDACall extends IDACall {
    /**
     * Called for every request received from the client. Server requests do not go though this.
     */
    @Override
    public void processRequest(HttpServletRequest servletRequest, HttpServletResponse servletResponse) throws ServletException, IOException {
        long userId = User.getUserId(servletRequest);
        String domainName = User.getDomainName(servletRequest);
        if (domainName != null && !domainName.equals(servletRequest.getServerName())) {
            handleError(servletResponse, "Good try! You're caught!", new Throwable("Error message"));
        } else
            try {
                .....
            } catch (Throwable e) {
                handleError(servletResponse, e);
            }
    }
}
Because if an error occurs in this area, so that I can immediately know where it comes from.
The error is now displayed only in the log. For the client, error message is: "The server failed to return a formatted response at all."
Btw.
1) Method "handleError" is not in the docs.
2 )In this example: Example processRequest is not "overridden".
Best regards
Pavo
Comment