System.err.println("Unable to init mailet " + mailetClassName);
System.err.println("Check spool manager logs for more details.");
throw new ConfigurationException("Unable to init mailet", ex);
}
if (mailet != null && matcher != null) {
MailetManagement wrappedMailet;
if (mailet instanceof MailetManagement) {
wrappedMailet = (MailetManagement) mailet;
} else {
wrappedMailet = new MailetManagement(mailet);
}
MatcherManagement wrappedMatcher;
if (matcher instanceof MatcherManagement) {
wrappedMatcher = (MatcherManagement) matcher;
} else {
wrappedMatcher = new MatcherManagement(matcher);
}
String onMatchException = null;
MailetConfig mailetConfig = wrappedMailet.getMailetConfig();
if (mailetConfig instanceof MailetConfigImpl) {
onMatchException = ((MailetConfigImpl) mailetConfig).getInitAttribute("onMatchException");
}