Uploaded image for project: 'Archiva'
  1. Archiva
  2. MRM-1796

Can't download large archive file due to java.lang.NumberFormatException

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 1.3.6
    • Fix Version/s: 2.0.0
    • Component/s: Problem Reporting
    • Labels:
      None
    • Environment:
      Windows

      Description

      I tried to download a large archive(3GB,3,275,052,860 bytes to be precise) that I uploaded to Apache Archiva 1.3.6 using Eclispe Aether API and attempt to download it failed.
      Note: I was able to upload and download 1GB file fine.
      So it may seems that there is probably an attempt to convert a Long value (3,275,052,860) to an Integer value in the code below that results in
      java.lang.NumberFormatException: For input string: "3275052860"

      Detail of archiva trace log:
      ============================================================================

      jvm 1 | 2013-12-04 11:36:03.712::WARN: /archiva/repository/internal/com/datasynapse/fabric/HelloWorldXXL/6.0
      .0/HelloWorldXXL-6.0.0.war
      jvm 1 | java.lang.NumberFormatException: For input string: "3275052860"
      jvm 1 | at java.lang.NumberFormatException.forInputString(Unknown Source)
      jvm 1 | at java.lang.Integer.parseInt(Unknown Source)
      jvm 1 | at java.lang.Integer.parseInt(Unknown Source)
      jvm 1 | at org.apache.jackrabbit.webdav.io.OutputContextImpl.setContentLength(OutputContextImpl.java:60)

      jvm 1 | at org.apache.maven.archiva.webdav.ArchivaDavResource.spool(ArchivaDavResource.java:202)
      jvm 1 | at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.spoolResource(AbstractWebdavServlet
      .java:422)
      jvm 1 | at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.doGet(AbstractWebdavServlet.java:38
      8)
      jvm 1 | at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.execute(AbstractWebdavServlet.java:
      229)
      jvm 1 | at org.apache.maven.archiva.webdav.RepositoryServlet.service(RepositoryServlet.java:125)
      jvm 1 | at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
      jvm 1 | at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:416)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148)
      jvm 1 | at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:39)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148)
      jvm 1 | at org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCleanUp.java:99)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148)
      jvm 1 | at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilt
      er.java:96)
      jvm 1 | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148)
      jvm 1 | at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:387)
      jvm 1 | at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
      jvm 1 | at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
      jvm 1 | at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
      jvm 1 | at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417)
      jvm 1 | at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
      jvm 1 | at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
      jvm 1 | at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
      jvm 1 | at org.mortbay.jetty.Server.handle(Server.java:326)
      jvm 1 | at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534)
      jvm 1 | at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864)
      jvm 1 | at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539)
      jvm 1 | at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
      jvm 1 | at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
      jvm 1 | at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
      jvm 1 | at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:451)

        Attachments

          Activity

            People

            • Assignee:
              olamy Olivier Lamy
              Reporter:
              bklau2006 BK Lau
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: