Uploaded image for project: 'Railo'
  1. Railo
  2. RAILO-1098

Using tar resource on tar file from Github throws error

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Critical
    • Resolution: Rejected
    • Affects Version/s: 3.2.0.006
    • Fix Version/s: None
    • Environment:

      Ubuntu 10.10, Railo Express w/ Railo 3.2.0.005 RC

    • Steps to Reproduce:
      Hide

      See the attached example or try the following:

      Download a tar.gz file from github. Ex: https://github.com/seancorfield/fw1/tarball/v1.2

      Try to use the tar file as a tar resource (tar://).

      Throws the following error:

      Java heap space
      at java.util.Arrays.copyOf(Arrays.java:2798):2798
      at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:111):111
      at java.io.BufferedOutputStream.write(BufferedOutputStream.java:122):122
      at railo.commons.io.IOUtil.copy(IOUtil.java:251):251
      at railo.commons.io.IOUtil.copy(IOUtil.java:50):50
      at railo.commons.io.IOUtil.copy(IOUtil.java:141):141
      at railo.commons.io.CompressUtil.extractTar(CompressUtil.java:168):168
      at railo.commons.io.CompressUtil.extract(CompressUtil.java:86):86
      at railo.commons.io.res.type.compress.Compress._load(Compress.java:93):93
      at railo.commons.io.res.type.compress.Compress.load(Compress.java:85):85
      at railo.commons.io.res.type.compress.Compress.<init>(Compress.java:54):54
      at railo.commons.io.res.type.compress.Compress.getInstance(Compress.java:67):67
      at railo.commons.io.res.type.tar.TarResourceProvider.getCompress(TarResourceProvider.java:17):17
      at railo.commons.io.res.type.compress.CompressResourceProvider.getResource(CompressResourceProvider.java:77):77
      at railo.commons.io.res.ResourcesImpl.getResource(ResourcesImpl.java:60):60
      at railo.runtime.config.ConfigImpl.getResource(ConfigImpl.java:2105):2105
      at railo.commons.io.res.util.ResourceUtil.toResourceNotExisting(ResourceUtil.java:201):201
      at railo.commons.io.res.util.ResourceUtil.toResourceNotExisting(ResourceUtil.java:179):179
      at railo.runtime.tag.Directory.setDirectory(Directory.java:239):239
      at test.tarfile_cfm$cf.call(/home/randy/workspace/test/tarFile.cfm:6):6
      at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:735):735
      at railo.runtime.listener.ClassicAppListener._onRequest(ClassicAppListener.java:35):35
      at railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:24):24
      at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1972):1972
      at railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:280):280
      at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:820):820
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502):502
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390):390
      at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216):216
      at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182):182
      at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765):765
      at railo.runtime.op.Caster.toPageException(Caster.java:2987):2987
      at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:738):738
      at railo.runtime.listener.ClassicAppListener._onRequest(ClassicAppListener.java:35):35
      at railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:24):24
      at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1972):1972
      at railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:280):280
      at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:820):820
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502):502
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390):390
      at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216):216
      at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182):182
      at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765):765
      at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418):418
      at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:199):199
      at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114):114
      at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152):152
      at org.mortbay.jetty.Server.handle(Server.java:326):326
      at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:536):536
      at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:913):913
      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539):539
      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212):212
      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:405):405
      at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409):409
      at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:451):451

      Show
      See the attached example or try the following: Download a tar.gz file from github. Ex: https://github.com/seancorfield/fw1/tarball/v1.2 Try to use the tar file as a tar resource (tar://). Throws the following error: Java heap space at java.util.Arrays.copyOf(Arrays.java:2798):2798 at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:111):111 at java.io.BufferedOutputStream.write(BufferedOutputStream.java:122):122 at railo.commons.io.IOUtil.copy(IOUtil.java:251):251 at railo.commons.io.IOUtil.copy(IOUtil.java:50):50 at railo.commons.io.IOUtil.copy(IOUtil.java:141):141 at railo.commons.io.CompressUtil.extractTar(CompressUtil.java:168):168 at railo.commons.io.CompressUtil.extract(CompressUtil.java:86):86 at railo.commons.io.res.type.compress.Compress._load(Compress.java:93):93 at railo.commons.io.res.type.compress.Compress.load(Compress.java:85):85 at railo.commons.io.res.type.compress.Compress.<init>(Compress.java:54):54 at railo.commons.io.res.type.compress.Compress.getInstance(Compress.java:67):67 at railo.commons.io.res.type.tar.TarResourceProvider.getCompress(TarResourceProvider.java:17):17 at railo.commons.io.res.type.compress.CompressResourceProvider.getResource(CompressResourceProvider.java:77):77 at railo.commons.io.res.ResourcesImpl.getResource(ResourcesImpl.java:60):60 at railo.runtime.config.ConfigImpl.getResource(ConfigImpl.java:2105):2105 at railo.commons.io.res.util.ResourceUtil.toResourceNotExisting(ResourceUtil.java:201):201 at railo.commons.io.res.util.ResourceUtil.toResourceNotExisting(ResourceUtil.java:179):179 at railo.runtime.tag.Directory.setDirectory(Directory.java:239):239 at test.tarfile_cfm$cf.call(/home/randy/workspace/test/tarFile.cfm:6):6 at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:735):735 at railo.runtime.listener.ClassicAppListener._onRequest(ClassicAppListener.java:35):35 at railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:24):24 at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1972):1972 at railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:280):280 at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32 at javax.servlet.http.HttpServlet.service(HttpServlet.java:820):820 at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502):502 at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390):390 at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216):216 at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182):182 at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765):765 at railo.runtime.op.Caster.toPageException(Caster.java:2987):2987 at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:738):738 at railo.runtime.listener.ClassicAppListener._onRequest(ClassicAppListener.java:35):35 at railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:24):24 at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1972):1972 at railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:280):280 at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32 at javax.servlet.http.HttpServlet.service(HttpServlet.java:820):820 at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502):502 at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390):390 at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216):216 at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182):182 at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765):765 at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418):418 at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:199):199 at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114):114 at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152):152 at org.mortbay.jetty.Server.handle(Server.java:326):326 at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:536):536 at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:913):913 at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539):539 at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212):212 at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:405):405 at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409):409 at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:451):451

      Description

      While trying to use a tar file downloaded from github as a resource I get a Java heap space error. Tried with a locally created tar.gz file and it seemed to work fine.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                micstriit Michael Offner
                Reporter:
                Zoramite Randy Merrill
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: