[ https://issues.apache.org/jira/browse/SOLR-3022?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
James Dyer updated SOLR-3022: ----------------------------- Attachment: SOLR-3022.patch Here's a patch that changes both of the "problem constructors" by leaving "alreadyLogged" as false unless the passed-in Throwable happens to be a SolrException, in which case "alreadyLogged" is inherited. I also quickly reviewed each place this is used and manually switched to suppress logging in places it made sense. By the way, going through this revealed a lot of places where developers took pains to create nice loggable messages, but the SolrException constructor is making it so they'll never see the light of day. As for the duplication of SOLR-2191, it would be nice if we can maybe apply something simple like this patch first and see if it seems to meet everyone's need. Then if its not enough or if there still seems to be a reason to completely eliminate "logOnce", that could be done as a second step? This way we can fix the lost logging messages now and still have the option to do more (or less) later. I agree having lots of constructors is not usually a good idea. In an Exception class it might be nice though to retain them, giving developers added convenience. (and besides, its a lot of grunt work to get rid of the extra ones :) ). > AbstractPluginLoader does not log caught exceptions > --------------------------------------------------- > > Key: SOLR-3022 > URL: https://issues.apache.org/jira/browse/SOLR-3022 > Project: Solr > Issue Type: Bug > Affects Versions: 4.0 > Reporter: James Dyer > Assignee: Erick Erickson > Priority: Trivial > Fix For: 4.0 > > Attachments: SOLR-3022.patch, SOLR-3022.patch, SOLR-3022.patch > > > I was setting up a new 4.x environment but forgot to put a custom Analyzer in > the classpath. Unfortunately AbstractPluginLoader didn't log the exception > and it took a long time for me to figure out why "No cores were created". -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org