Add extra logging in DefaultWebInterfaceManager class

XMLWordPrintable

    • 4

      NOTE: This suggestion is for Confluence Server. Using Confluence Cloud? See the corresponding suggestion.

      When using an incompatible plugin, Confluence will report an exception without an accompanying stack trace - for example the NullPointerException below:

      2008-08-10 08:40:36,609 ERROR [http-8080-Processor6] [atlassian.plugin.web.DefaultWebInterfaceManager] filterFragmentsByCondition Could not evaluate condition: java.lang.NullPointerException
       -- url: /display/sample/Home | userName: ogawa | action: viewpage | page: 589828
      

      It is impossible to know which plugin is failing based on the exception above.

      This can be improved by including the stack trace of the error so we know where the problem actually lives.

      Please include the following in method filterFragmentsByCondition :

                  catch (Throwable t)
                  {
                      if (log.isDebugEnabled())
                          log.debug("Could not evaluate condition for descriptor: " + descriptor, t);
                      else
                          log.warn("Could not evaluate condition for descriptor: " + descriptor + ", with throwable: " + t);
                      iterator.remove();
                  }
      

            Assignee:
            BillA
            Reporter:
            Roy Hartono [Atlassian]
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: