0 Replies Latest reply on Jan 17, 2012 1:55 AM by Eric Leron

    Content is not allowed in prolog during Upload in rich:fileUpload

    Eric Leron Newbie

      I have the following codes for fileUpload in Richfaces 3.3.3 that run as expected on my local machine using Tomcat v7.0 on Windows XP SP2.

       

      Please refer here for the codes. This codes also works on WAS 6.1 on Linux.

       

      However, I tried deploying the same code on WAS 6.1 in Solaris and I encountered a "Content is not allowed in prolog" error. The error occurs after clicking the "Upload", please see below:

      1.JPG

       

      And here is the error:

       

      [1/13/12 13:16:03:473 GMT+04:00] 00000031 viewhandler   E   Error Rendering View[]
                                       com.sun.facelets.FaceletException: Error Parsing /: Error Traced[line: 1] Content is not allowed in prolog.
              at com.sun.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:234)
              at com.sun.facelets.compiler.Compiler.compile(Compiler.java:105)
              at com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:197)
              at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:144)
              at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:95)
              at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:517)
              at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:567)
              at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:100)
              at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:176)
              at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110)
              at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
              at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:907)
              at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:145)
              at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:206)
              at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
              at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:367)
              at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:515)
              at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
              at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
              at aiu.memsa.jsf.tracker.RequestFilter.doFilter(RequestFilter.java:206)
              at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
              at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
              at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)
              at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
              at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
              at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:87)
              at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:701)
              at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:646)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:475)
              at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
              at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:92)
              at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:744)
              at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
              at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
              at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
              at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
              at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
              at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
              at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
              at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
              at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
              at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
              at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
              at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
              at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
      
      

       

      I am quite sure that the usual culprits (preceeding characters in xml declaration) are not one of the causes of my problem since it has been deployed twice already and I did check it using Hex Editor.

       

      Any help would be greatly appreciated.

       

       

      Thanks!
      Eric

       

      Message was edited by: Eric Leron