public void onAjaxExecutionException (@Nullable final IAjaxInvoker aAjaxInvoker, @Nullable final String sFunctionName, @Nonnull final IAjaxExecutor aAjaxExecutor, @Nonnull final IRequestWebScopeWithoutResponse aRequestScope, @Nonnull final Exception ex) { if (ex instanceof IOException) { if (!StreamHelper.isKnownEOFException (ex)) LOGGER.error ("Error writing result of Ajax function '" + sFunctionName + "' with " + aAjaxExecutor, ex); } else { LOGGER.error ("Error invoking Ajax function '" + sFunctionName + "' on " + aAjaxExecutor, ex); if (GlobalDebug.isDebugMode ()) RequestLogger.logRequestComplete (aRequestScope.getRequest ()); } } }
public void onAPIExecutionException (@Nonnull final IAPIInvoker aInvoker, @Nonnull final InvokableAPIDescriptor aInvokableDescriptor, @Nonnull final IRequestWebScopeWithoutResponse aRequestScope, @Nonnull final Throwable t) { if (t instanceof IOException) { if (!StreamHelper.isKnownEOFException (t)) LOGGER.error ("Error writing result of API '" + aInvokableDescriptor.getPath () + "' with " + aInvokableDescriptor, t); } else { LOGGER.error ("Error invoking API '" + aInvokableDescriptor.getPath () + "' on " + aInvokableDescriptor, t); if (GlobalDebug.isDebugMode ()) RequestLogger.logRequestComplete (aRequestScope.getRequest ()); } } }
@Nonnull public EContinue onException (@Nonnull final IRequestWebScope aRequestScope, @Nonnull final Throwable t) { final String sMsg = "Internal error on " + aRequestScope.getHttpVersion ().getName () + " " + aRequestScope.getMethod () + " on resource '" + aRequestScope.getURL () + "'"; if (StreamHelper.isKnownEOFException (t)) { // Debug only if (LOGGER.isDebugEnabled ()) LOGGER.debug (sMsg + " - " + ClassHelper.getClassLocalName (t) + " - " + t.getMessage ()); // Known - nothing more to do return EContinue.BREAK; } // Log always including full exception LOGGER.error (sMsg, t); // Invoke next handler return EContinue.CONTINUE; } }
if (!StreamHelper.isKnownEOFException (ex)) LOGGER.error ("Failed to write Excel workbook to output stream " + aOS, ex); return ESuccess.FAILURE;
if (!StreamHelper.isKnownEOFException (ex.getCause ())) LOGGER.error ("Error parsing multipart request content", ex);