if (node.invoke(env, errorContext)) {
// Exception was handled.
return errorContext.getProcessingPipeline();
}
} finally {
errorContext.dispose();
}
} catch (Exception e) {
getLogger().error("An exception occured while handling errors at " + node.getLocation(), e);
// Rethrow it: It will either be handled by the parent sitemap or by the environment (e.g. Cocoon servlet)
throw e;