portlet.xml :-) Basically you have content (may be space or blank lines) before the prolog <?xml version="1.0"?>. I've also heard of this error message showing up if you had content after the prolog but before the open root. (I've never seen that though ;-) Here's a forum that discusses this issue.
http://forum.java.sun.com/thread.jsp?forum=34&thread=465472&tstart=15&trange=15 - Mike On Tue, 2004-10-05 at 08:57, Xavier Lawrence wrote: > Hi, > > I am getting these stange org.xml.sax.SAXParseException: Content is not > allowed in prolog and I don't understand why... > > Anybody would have a clue where I shoul start looking ? (I see nothing wrong in > my config XML files...) > > I am trying to make a simple struts-portlet work... > > Thanks in advance > > Xavier > > > INFO: Loading portlet application from web archive C:\Tomcat5\webapps\jetspeed\ > WEB-INF\deploy\FirstStrutsPortlet-demo.war > INFO: Preparing to (re) deploy portlet app "FirstStrutsPortlet-demo" > INFO: Deploying portlet applicaion WAR FirstStrutsPortlet-demo.war > INFO: Portlet application deployment target directory is > C:\Tomcat5\webapps\jet > speed/..//FirstStrutsPortlet-demo > Writing out infused web.xml for FirstStrutsPortlet-demo > org.xml.sax.SAXParseException: Content is not allowed in prolog. > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > at org.apache.commons.digester.Digester.parse(Digester.java:1586) > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:148) > at > org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortl > etApp(PortletApplicationWar.java:208) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:355) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSyste > mPAM.java:304) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPA > M.java:120) > at > org.apache.jetspeed.tools.pamanager.ApplicationServerPAM.deploy(Appli > cationServerPAM.java:81) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.doD > eploy(DeployPortletAppEventListener.java:262) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.inv > okeDeploy(DeployPortletAppEventListener.java:165) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.dispatc > h(StandardDeploymentManager.java:305) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.fireDep > loymentEvent(StandardDeploymentManager.java:196) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager$FileSys > temScanner.run(StandardDeploymentManager.java:459) > ERROR: Unable to register portlet application, FirstStrutsPortlet-demo, through > the portlet registry: > org.apache.jetspeed.tools.pamanager.PortletApplicationExce > ption: Could not unmarshal portlet.xml. org.xml.sax.SAXParseException: Content > i > s not allowed in prolog. > org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could not > unmar > shal portlet.xml. org.xml.sax.SAXParseException: Content is not allowed in > prolo > g. > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:178) > at > org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortl > etApp(PortletApplicationWar.java:208) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:355) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSyste > mPAM.java:304) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPA > M.java:120) > at > org.apache.jetspeed.tools.pamanager.ApplicationServerPAM.deploy(Appli > cationServerPAM.java:81) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.doD > eploy(DeployPortletAppEventListener.java:262) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.inv > okeDeploy(DeployPortletAppEventListener.java:165) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.dispatc > h(StandardDeploymentManager.java:305) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.fireDep > loymentEvent(StandardDeploymentManager.java:196) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager$FileSys > temScanner.run(StandardDeploymentManager.java:459) > Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog. > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > at org.apache.commons.digester.Digester.parse(Digester.java:1586) > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:148) > ... 10 more > ERROR: Unexpected exception deploying portlet application: > org.apache.jetspeed.e > xception.RegistryException: Unable to register portlet application, > FirstStrutsP > ortlet-demo, through the portlet registry: > org.apache.jetspeed.tools.pamanager.P > ortletApplicationException: Could not unmarshal portlet.xml. > org.xml.sax.SAXPars > eException: Content is not allowed in prolog. attempting rollback... > org.apache.jetspeed.exception.RegistryException: Unable to register portlet > appl > ication, FirstStrutsPortlet-demo, through the portlet registry: > org.apache.jetsp > eed.tools.pamanager.PortletApplicationException: Could not unmarshal > portlet.xml > . org.xml.sax.SAXParseException: Content is not allowed in prolog. > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:394) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSyste > mPAM.java:304) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPA > M.java:120) > at > org.apache.jetspeed.tools.pamanager.ApplicationServerPAM.deploy(Appli > cationServerPAM.java:81) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.doD > eploy(DeployPortletAppEventListener.java:262) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.inv > okeDeploy(DeployPortletAppEventListener.java:165) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.dispatc > h(StandardDeploymentManager.java:305) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.fireDep > loymentEvent(StandardDeploymentManager.java:196) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager$FileSys > temScanner.run(StandardDeploymentManager.java:459) > Caused by: org.apache.jetspeed.tools.pamanager.PortletApplicationException: > Coul > d not unmarshal portlet.xml. org.xml.sax.SAXParseException: Content is not > allow > ed in prolog. > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:178) > at > org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortl > etApp(PortletApplicationWar.java:208) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:355) > ... 8 more > Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog. > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > at org.apache.commons.digester.Digester.parse(Digester.java:1586) > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:148) > ... 10 more > INFO: Exception in deploy. Rollback of application deployment... > INFO: Rollback: Remove C:\Tomcat5\webapps\jetspeed/..//FirstStrutsPortlet-demo > and all sub-directories. > ERROR: org.apache.jetspeed.deployment.DeploymentException: Error (re)deploying > p > ortlet app: org.apache.jetspeed.tools.pamanager.PortletApplicationException: > org > .apache.jetspeed.exception.RegistryException: Unable to register portlet > applica > tion, FirstStrutsPortlet-demo, through the portlet registry: > org.apache.jetspeed > .tools.pamanager.PortletApplicationException: Could not unmarshal portlet.xml. > o > rg.xml.sax.SAXParseException: Content is not allowed in prolog. > org.apache.jetspeed.deployment.DeploymentException: Error (re)deploying portlet > app: org.apache.jetspeed.tools.pamanager.PortletApplicationException: > org.apache > .jetspeed.exception.RegistryException: Unable to register portlet application, > F > irstStrutsPortlet-demo, through the portlet registry: > org.apache.jetspeed.tools. > pamanager.PortletApplicationException: Could not unmarshal portlet.xml. > org.xml. > sax.SAXParseException: Content is not allowed in prolog. > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.doD > eploy(DeployPortletAppEventListener.java:302) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.inv > okeDeploy(DeployPortletAppEventListener.java:165) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.dispatc > h(StandardDeploymentManager.java:305) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager.fireDep > loymentEvent(StandardDeploymentManager.java:196) > at > org.apache.jetspeed.deployment.impl.StandardDeploymentManager$FileSys > temScanner.run(StandardDeploymentManager.java:459) > Caused by: org.apache.jetspeed.tools.pamanager.PortletApplicationException: > org. > apache.jetspeed.exception.RegistryException: Unable to register portlet > applicat > ion, FirstStrutsPortlet-demo, through the portlet registry: > org.apache.jetspeed. > tools.pamanager.PortletApplicationException: Could not unmarshal portlet.xml. > or > g.xml.sax.SAXParseException: Content is not allowed in prolog. > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSyste > mPAM.java:327) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPA > M.java:120) > at > org.apache.jetspeed.tools.pamanager.ApplicationServerPAM.deploy(Appli > cationServerPAM.java:81) > at > org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.doD > eploy(DeployPortletAppEventListener.java:262) > ... 4 more > Caused by: org.apache.jetspeed.exception.RegistryException: Unable to register > p > ortlet application, FirstStrutsPortlet-demo, through the portlet registry: > org.a > pache.jetspeed.tools.pamanager.PortletApplicationException: Could not unmarshal > portlet.xml. org.xml.sax.SAXParseException: Content is not allowed in prolog. > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:394) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSyste > mPAM.java:304) > ... 7 more > Caused by: org.apache.jetspeed.tools.pamanager.PortletApplicationException: > Coul > d not unmarshal portlet.xml. org.xml.sax.SAXParseException: Content is not > allow > ed in prolog. > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:178) > at > org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortl > etApp(PortletApplicationWar.java:208) > at > org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication > (FileSystemPAM.java:355) > ... 8 more > Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog. > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > at org.apache.commons.digester.Digester.parse(Digester.java:1586) > at > org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.crea > tePortletApplication(PortletApplicationDescriptor.java:148) > ... 10 more > ERROR: Error deploying > C:\Tomcat5\webapps\jetspeed\WEB-INF\deploy\FirstStrutsPor > tlet-demo.war > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED]
