Uploaded image for project: 'Apache Roller'
  1. Apache Roller
  2. ROL-2078

Hard to determinate the cause of mail provider setting error due to no stacktrace are logged

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 5.1.2
    • 5.2.0
    • None

    Description

      Currently, if Roller installation has any problem in mail provider setting, only following message are logged:

      WARN  2014-05-16 16:01:39,233 WebloggerStartup:prepare - Failed to setup mail provider, continuing anyways.
      Reason: ERROR connecting to mail server
      

      That is because logging procedure simply discarded the stacktrace:

      // setup mail provider, if configured
      try {
          mailProvider = new MailProvider();
      } catch(StartupException ex) {
          LOG.warn("Failed to setup mail provider, continuing anyways.\n"
                  + "Reason: " + ex.getMessage());
      }
      

      I think it's not informative. recently I got stucked in mail provider configuration due to this. in my case, the cause was missing intermediate SSL certification. I think it's very difficult to determine that cause without stacktrace or message of parent exception in such case.

      I guess some Roller installation may not have mail provider intentionally, so adding stacktrace logging in a verbose level than WARN seems reasonable.

      Attachments

        1. ROL-2078.patch
          0.7 kB
          Kohei Nozaki

        Activity

          People

            roller_unassigned Roller Unassigned
            xkylex Kohei Nozaki
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: