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

Accessing files and images dialog on Confluence editor resulted in NullPointerException

      Issue Summary

      In Confluence 7.12 and above, accessing the Files and images dialog to upload an image file will result in java.lang.NullPointerException in the <Confluence-Home>/logs/atlassian-confluence.log file.

      Steps to Reproduce

      1. Create a new page in Confluence or edit an existing Confluence page.
      2. Load up the Files and images dialog.
      3. Upload an image file (of any image file extension) to the page.

      The same java.lang.NullPointerException would also be thrown in the <Confluence-Home>/logs/atlassian-confluence.log when accessing the Files and images dialog of a page with an attachment image already embedded into it.

      Expected Results

      The page and its embedded attachments are load up fine without any errors thrown in the <Confluence-Home>/logs/atlassian-confluence.log.

      Actual Results

      The page and its embedded attachments are load up fine, but the below exception is thrown in the <Confluence-Home>/logs/atlassian-confluence.log file:

      2021-05-26 14:06:42,229 ERROR [http-nio-27120-exec-5] [[Standalone].[localhost].[/c7120].[file-server]] log Servlet.service() for servlet [file-server] in context with path [/c7120] threw exception
      java.lang.NullPointerException
              at com.atlassian.confluence.servlet.download.AttachmentDownload.streamResponse(AttachmentDownload.java:293)
              at com.atlassian.confluence.servlet.download.ServeAfterTransactionDownload.serveFile(ServeAfterTransactionDownload.java:51)
              at com.atlassian.plugin.servlet.AbstractFileServerServlet.doGet(AbstractFileServerServlet.java:28)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:626)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:733)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
              at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
              at com.atlassian.confluence.web.filter.DebugFilter.doFilter(DebugFilter.java:46)
              at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      ...
      

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

            [CONFSERVER-65732] Accessing files and images dialog on Confluence editor resulted in NullPointerException

            Jiri Hronik made changes -
            Resolution New: Fixed [ 1 ]
            Status Original: Waiting for Release [ 12075 ] New: Closed [ 6 ]
            Hasnae (Inactive) made changes -
            Status Original: Awaiting Merge [ 10064 ] New: Waiting for Release [ 12075 ]
            Hasnae (Inactive) made changes -
            QA Demo Status Original: Not Done [ 14330 ] New: Done [ 14331 ]
            Status Original: In Review [ 10051 ] New: Awaiting Merge [ 10064 ]
            Andrei Khudavets made changes -
            Labels Original: lbp warranty New: 713-lo lbp warranty
            Hasnae (Inactive) made changes -
            Fix Version/s New: 7.12.3 [ 95898 ]
            QA Kickoff Status Original: Not Done [ 14234 ] New: Not Needed [ 14236 ]
            Status Original: In Progress [ 3 ] New: In Review [ 10051 ]
            Hasnae (Inactive) made changes -
            Remote Link New: This issue links to "R7.12 P1. Baseline › Unit, Integration, CTK Tests › issue-712-CONFSERVER-65732-fix-up-npe-attachment-download (server-syd-bamboo)" [ 556957 ]
            Hasnae (Inactive) made changes -
            Remote Link New: This issue links to "R7.12 P1. Performance › Page Weight Ratchet Build › issue-712-CONFSERVER-65732-fix-up-npe-attachment-download (server-syd-bamboo)" [ 556956 ]
            Hasnae (Inactive) made changes -
            Remote Link New: This issue links to "R7.12 P1. Baseline › Main Tests (Postgres 11.x, Tomcat 9) › issue-712-CONFSERVER-65732-fix-up-npe-attachment-download (server-syd-bamboo)" [ 557059 ]
            Hasnae (Inactive) made changes -
            Remote Link New: This issue links to "R7.12 P1. Baseline › Code Check - Static Analysis › issue-712-CONFSERVER-65732-fix-up-npe-attachment-download (server-syd-bamboo)" [ 557154 ]
            Hasnae (Inactive) made changes -
            Remote Link New: This issue links to "R7.12 P1. Baseline › Data Center Tests, Postgres 11.x, Tomcat 9, Java 11 › issue-712-CONFSERVER-65732-fix-up-npe-attachment-download (server-syd-bamboo)" [ 557058 ]

              hrehioui Hasnae (Inactive)
              lrura Lauretha Rura
              Affected customers:
              7 This affects my team
              Watchers:
              14 Start watching this issue

                Created:
                Updated:
                Resolved: