title: XML parsing exception org.xml.sax.SAXParseException cvc-elt.1
body: <p>My XML contains</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;organization:Organization xmlns:organization="http://www.bonitasoft.org/ns/organization/6.0.0-beta-016"&gt;
  ......
  &lt;/organization:Organization&gt;
  </code></pre>
  
  <p>For complete XML file, Please have a look at :
  <a href="https://github.com/bonitasoft/bonita-examples/blob/master/rest-api-example/src/main/resources/ACME.xml" rel="nofollow">https://github.com/bonitasoft/bonita-examples/blob/master/rest-api-example/src/main/resources/ACME.xml</a></p>
  
  <p>I get this error on server side (JAVA &amp; Tomcat) : </p>
  
  <p><strong>org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 106; cvc-elt.1: Cannot find the declaration of element 'organization:Organization'.</strong>
  (Full stack trace is below)</p>
  
  <p>I changed the 'organization' tag to just <code>&lt;organization&gt; ... &lt;/organization&gt;</code></p>
  
  <p>Still I get same error:
   <strong>cvc-elt.1: Cannot find the declaration of element 'organization'</strong></p>
  
  <h2><strong><em>EDIT</em></strong></h2>
  
  <hr>
  
  <p>It works when I change the xmlns URI as</p>
  
  <pre><code>&lt;organization:Organization xmlns:organization="http://documentation.bonitasoft.com/organization-xml-schema/1.1"&gt;
  </code></pre>
  
  <p>Can someone please explain.</p>
  
  <hr>
  
  <p>I am trying to run the REST API example mentioned in the Bonitasoft documentation : <a href="http://documentation.bonitasoft.com/create-your-first-project-web-rest-api-and-maven-0" rel="nofollow">http://documentation.bonitasoft.com/create-your-first-project-web-rest-api-and-maven-0</a>
  (I guess it is pure XML parsing problem &amp; it has nothing to do with Bonitasoft code)</p>
  
  <p>Can some one help me to resolve this.</p>
  
  <p>Thank you very much for your time.</p>
  
  <p><strong>FULL STACK TRACE :</strong> </p>
  
  <pre><code>2015-08-25 16:37:19.885 +0900 org.bonitasoft.web.toolkit.server.servlet.ToolkitHttpServlet org.bonitasoft.web.toolkit.server.servlet.ToolkitHttpServlet catchAllExceptions 
  SEVERE: Can't import organization. Please check that your file is well-formed
  org.bonitasoft.web.toolkit.server.ServiceException: Can't import organization. Please check that your file is well-formed
      at org.bonitasoft.console.server.service.OrganizationImportService.run(OrganizationImportService.java:62)
      at org.bonitasoft.web.toolkit.server.ServiceServletCall.run(ServiceServletCall.java:92)
      at org.bonitasoft.web.toolkit.server.ServiceServletCall.doPost(ServiceServletCall.java:72)
      at org.bonitasoft.web.toolkit.server.servlet.ToolkitHttpServlet.doPost(ToolkitHttpServlet.java:188)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:646)
      at org.bonitasoft.web.toolkit.server.servlet.ToolkitHttpServlet.service(ToolkitHttpServlet.java:75)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      at org.bonitasoft.web.toolkit.server.servlet.ToolkitHttpServlet.service(ToolkitHttpServlet.java:226)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
      at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
      at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
      at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:394)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.bonitasoft.console.common.server.login.filter.AuthenticationFilter.isAuthorized(AuthenticationFilter.java:152)
      at org.bonitasoft.console.common.server.login.filter.AuthenticationFilter.doAuthenticationFiltering(AuthenticationFilter.java:134)
      at org.bonitasoft.console.common.server.login.filter.AuthenticationFilter.doFilter(AuthenticationFilter.java:119)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
      at org.bonitasoft.console.security.SessionFixationValve.invoke(SessionFixationValve.java:77)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
      at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
  Caused by: org.bonitasoft.engine.identity.OrganizationImportException: USERNAME=install | org.bonitasoft.engine.xml.SValidationException:
  
  **org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 106; cvc-elt.1: Cannot find the declaration of element 'organization:Organization'.**
      at org.bonitasoft.engine.api.impl.IdentityAPIImpl.importOrganization(IdentityAPIImpl.java:1427)
      at org.bonitasoft.engine.api.impl.IdentityAPIImpl.importOrganization(IdentityAPIImpl.java:1414)
      at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeAPI(ServerAPIImpl.java:467)
      at org.bonitasoft.engine.api.impl.ServerAPIImpl$2.call(ServerAPIImpl.java:436)
      at org.bonitasoft.engine.transaction.JTATransactionServiceImpl.executeInTransaction(JTATransactionServiceImpl.java:312)
      at org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeAPIInTransaction(ServerAPIImpl.java:443)
      at org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeAPI(ServerAPIImpl.java:278)
      at org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeMethod(ServerAPIImpl.java:131)
      at org.bonitasoft.engine.api.impl.ClientInterceptor.invoke(ClientInterceptor.java:88)
      at com.sun.proxy.$Proxy18.importOrganization(Unknown Source)
      at org.bonitasoft.console.server.service.OrganizationImportService.run(OrganizationImportService.java:60)
      ... 38 more
  
  **Caused by: org.bonitasoft.engine.xml.SValidationException: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 106; cvc-elt.1: Cannot find the declaration of element 'organization:Organization'.**
      at org.bonitasoft.engine.xml.SAXValidator.validate(SAXValidator.java:91)
      at org.bonitasoft.engine.xml.SAXValidator.validate(SAXValidator.java:80)
      at org.bonitasoft.engine.xml.parse.SAXParser.validate(SAXParser.java:138)
      at org.bonitasoft.engine.identity.xml.ImportOrganization.execute(ImportOrganization.java:131)
      at org.bonitasoft.engine.api.impl.IdentityAPIImpl.importOrganization(IdentityAPIImpl.java:1425)
      ... 51 more
  
  **Caused by: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 106; cvc-elt.1: Cannot find the declaration of element 'organization:Organization'.**
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:198)
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:134)
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:437)
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:368)
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:325)
      at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1906)
      at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:746)
      at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:379)
      at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl$NSContentDriver.scanRootElementHook(XMLNSDocumentScannerImpl.java:605)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3138)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:880)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
      at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:117)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
      at com.sun.org.apache.xerces.internal.jaxp.validation.StreamValidatorHelper.validate(StreamValidatorHelper.java:155)
      at com.sun.org.apache.xerces.internal.jaxp.validation.ValidatorImpl.validate(ValidatorImpl.java:116)
      at javax.xml.validation.Validator.validate(Validator.java:124)
      at org.bonitasoft.engine.xml.SAXValidator.validate(SAXValidator.java:89)
      ... 55 more
  </code></pre>