AnsweredAssumed Answered

Status 500 -Internel error on POST createFolder

Question asked by flosk8 on Nov 30, 2009
Latest reply on Dec 1, 2009 by flosk8
Hi

currently I checkout the first steps with cmis http://ecmarchitect.com/images/articles/cmis/cmis-article.pdf
when I post the following xml to create a new folder I get the following error. Pleas help me solve.
Sitting here for hours   :(



<?xml version="1.0" encoding="utf-8"?>
<entry xmlns="http://www.w3.org/2005/Atom"
xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/"
xmlns:cmis="http://www.cmis.org/2008/05" >
   <title>myfolder</title>
   <cmisra:object>
      <cmis:properties>
         <cmis:propertyId propertyDefinitionId="cmis:objectTypeId">
            <cmis:value>cmis:folder</cmis:value>
         </cmis:propertyId>
      </cmis:properties>
   </cmisra:object>
</entry>


Error:

D:\>curl -X POST -uadmin:admin "http://localhost:8080/alfresco/s/cmis/p/children
" -H "Content-Type:application/atom+xml" -d createFolder.atom.xml
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/x
html1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
   <head>
      <title>Web Script Status 500 - Internal Error</title>
      <link rel="stylesheet" href="/alfresco/css/base.css" type="text/css" />
   </head>
   <body>
      <div>
         <table>
            <tr>
               <td><img src="/alfresco/images/logo/AlfrescoLogo32.png" alt="Alfr
esco" /></td>
               <td><span class="title">Web Script Status 500 - Internal Error</s
pan></td>
            </tr>
         </table>
         <br/>
         <table>
            <tr><td>The Web Script <a href="%2Falfresco%2Fs%2Fcmis%2Fp%2Fchildre
n">/alfresco/s/cmis/p/children</a> has responded with a status of 500 - Internal
Error.</td></tr>
         </table>
         <br/>
         <table>
            <tr><td><b>500 Description:</b></td><td> An error inside the HTTP se
rver which prevented it from fulfilling the request.</td></tr>
            <tr><td> </td></tr>
            <tr><td><b>Message:</b></td><td>10300041 Wrapped Exception (with sta
tus template): com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected characte
r 'c' (code 99) in prolog; expected '&lt;'
at [row,col {unknown-source}]: [1,1]</td></tr>
            <tr><td></td><td> </td></tr>
   <tr><td><b>Exception:</b></td><td>com.ctc.wstx.exc.WstxUnexpectedCharExceptio
n - Unexpected character 'c' (code 99) in prolog; expected '&lt;'
at [row,col {unknown-source}]: [1,1]</td></tr>
   <tr><td></td><td> </td></tr>
         <tr><td></td><td>com.ctc.wstx.sr.StreamScanner.throwUnexpectedChar(Stre
amScanner.java:623)</td></tr>
         <tr><td></td><td>com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(Basic
StreamReader.java:2047)</td></tr>
         <tr><td></td><td>com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamRead
er.java:1069)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMBuilder.getNextElemen
tToParse(FOMBuilder.java:163)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMBuilder.next(FOMBuild
er.java:187)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMBuilder.getFomDocumen
t(FOMBuilder.java:333)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMParser.getDocument(FO
MParser.java:72)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMParser.parse(FOMParse
r.java:207)</td></tr>
         <tr><td></td><td>org.apache.abdera.parser.stax.FOMParser.parse(FOMParse
r.java:145)</td></tr>
         <tr><td></td><td>org.apache.abdera.util.AbstractParser.parse(AbstractPa
rser.java:101)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.atom.AbderaServiceImpl.parse(
AbderaServiceImpl.java:158)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.atom.AtomReader.read(AtomRead
er.java:91)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.atom.AtomReader.createScriptP
arameters(AtomReader.java:105)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.AbstractWebScript.createScrip
tParameters(AbstractWebScript.java:375)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.DeclarativeWebScript.execute(
DeclarativeWebScript.java:85)</td></tr>
         <tr><td></td><td>org.alfresco.repo.web.scripts.RepositoryContainer$2.ex
ecute(RepositoryContainer.java:372)</td></tr>
         <tr><td></td><td>org.alfresco.repo.transaction.RetryingTransactionHelpe
r.doInTransaction(RetryingTransactionHelper.java:327)</td></tr>
         <tr><td></td><td>org.alfresco.repo.web.scripts.RepositoryContainer.tran
sactionedExecute(RepositoryContainer.java:422)</td></tr>
         <tr><td></td><td>org.alfresco.repo.web.scripts.RepositoryContainer.tran
sactionedExecuteAs(RepositoryContainer.java:439)</td></tr>
         <tr><td></td><td>org.alfresco.repo.web.scripts.RepositoryContainer.exec
uteScript(RepositoryContainer.java:303)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.AbstractRuntime.executeScript
(AbstractRuntime.java:306)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.AbstractRuntime.executeScript
(AbstractRuntime.java:183)</td></tr>
         <tr><td></td><td>org.alfresco.web.scripts.servlet.WebScriptServlet.serv
ice(WebScriptServlet.java:122)</td></tr>
         <tr><td></td><td>javax.servlet.http.HttpServlet.service(HttpServlet.jav
a:717)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.ApplicationFilterChain.intern
alDoFilter(ApplicationFilterChain.java:290)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.ApplicationFilterChain.doFilt
er(ApplicationFilterChain.java:206)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.StandardWrapperValve.invoke(S
tandardWrapperValve.java:233)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.StandardContextValve.invoke(S
tandardContextValve.java:191)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.StandardHostValve.invoke(Stan
dardHostValve.java:128)</td></tr>
         <tr><td></td><td>org.apache.catalina.valves.ErrorReportValve.invoke(Err
orReportValve.java:102)</td></tr>
         <tr><td></td><td>org.apache.catalina.core.StandardEngineValve.invoke(St
andardEngineValve.java:109)</td></tr>
         <tr><td></td><td>org.apache.catalina.connector.CoyoteAdapter.service(Co
yoteAdapter.java:286)</td></tr>
         <tr><td></td><td>org.apache.coyote.http11.Http11Processor.process(Http1
1Processor.java:845)</td></tr>
         <tr><td></td><td>org.apache.coyote.http11.Http11Protocol$Http11Connecti
onHandler.process(Http11Protocol.java:583)</td></tr>
         <tr><td></td><td>org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoE
ndpoint.java:447)</td></tr>
         <tr><td></td><td>java.lang.Thread.run(Thread.java:619)</td></tr>
   <tr><td></td><td> </td></tr>
   <tr><td><b>Exception:</b></td><td>org.apache.abdera.parser.ParseException - c
om.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character 'c' (code 99)
in prolog; expected '&lt;'
at [row,col {unknown-source}]: [1,1]</td></tr>
   <tr><td></td><td> </td></tr>
      <tr><td></td><td>org.apache.abdera.parser.stax.FOMBuilder.next(FOMBuilder.
java:260)</td></tr>
   <tr><td></td><td> </td></tr>
   <tr><td><b>Exception:</b></td><td>org.alfresco.web.scripts.WebScriptException
- 10300041 Wrapped Exception (with status template): com.ctc.wstx.exc.WstxUnexp
ectedCharException: Unexpected character 'c' (code 99) in prolog; expected '&lt;
'
at [row,col {unknown-source}]: [1,1]</td></tr>
   <tr><td></td><td> </td></tr>
      <tr><td></td><td>org.alfresco.web.scripts.AbstractWebScript.createStatusEx
ception(AbstractWebScript.java:613)</td></tr>
   <tr><td></td><td> </td></tr>
            <tr><td><b>Server</b>:</td><td>Alfresco Community v3.2.0 (r2 2440) s
chema 3.300</td></tr>
            <tr><td><b>Time</b>:</td><td>30.11.2009 14:16:57</td></tr>
            <tr><td></td><td> </td></tr>
            <tr><td><b>Diagnostics</b>:</td><td><a href="/alfresco/s/script/org/
alfresco/cmis/children.post">Inspect Web Script (org/alfresco/cmis/children.post
)</a></td></tr>
         </table>
      </div>
   </body>
</html>

Outcomes