Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-2779

RemoteSpaceSummary.hashCode has NPE if key is not set

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Medium
    • 1.3.5
    • None
    • None
    • None

    Description

      Scenario: trying to add a new space via xmlrpc. End up in ConfluenceXmlRpcHandlerImpl.addSpace(...), BeanUtils.populate is called with the freshly created RemoteSpace and the map passed in over xmlrpc.

      If debug level logging is enabled, BeanUtils.populate logs the bean using toString (and thus hashCode since there is no custom toString on RemoteSpaceSummary). The logging occurs prior to the bean being populated with the values from the Map

      However: com.atlassian.confluence.rpc.soap.beans.RemoteSpaceSummary.hashCode() fire a NullPointerException if the key is not set.

      FWIW: It took me way too long to track this bug down - the stack traces were getting swallowed inside the XMLRPC handler. Although I will accept that that might have been my fault (through bad jetty config) than anything else. If it wasn't my fault that the stack traces were swallowed, then there should be a better way to make them show up.

      The exception being thrown out of the xmlrpc interfaces are pretty non-descript - eg. "Bad error, uh oh"

      Attachments

        Activity

          People

            Unassigned Unassigned
            bda0663e090a Ben Walding
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: