Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

fl.schmitt(ops-users)
Hi,

next issue while migrating 3.9 to 4.9: I'm trying to trigger a xpl service (page flow entry has only model, pointing to xpl; no data output) from inside an XForm. The xpl service does some db operations in a sql database; after this is done, the originating XForm has to be refreshed (ths is done by another submission).

In 3.9, this worked perfectly by "chaining" two submissions: the first submission issued a POST request to the XPL service. On xforms-submit-done, the second submission was triggered. (NB: i would prefer to keep both submissions separate, because this way, i can (and do) re-use them at different places in my application)

In 4.9, the first submission results in an error:

+----------------------------------------------------------------------------------------------------------------------+
|An Error has Occurred                                                                                                 |
|----------------------------------------------------------------------------------------------------------------------|
|Error tag name "documents" is not allowed. Possible tag names are: <event-request>(schema: oxf:/ops/xforms/xforms-serv|
|er-request.rng)                                                                                                       |
|----------------------------------------------------------------------------------------------------------------------|
|Application Call Stack                                                                                                |
|----------------------------------------------------------------------------------------------------------------------|
|oxf:/ops/xforms/xforms-server.xpl                                                 |reading processor output      |  37|
|······················································································································|
|element=<p:output name="data" id="xforms-request"/>                                                                   |
|name   =data                                                                                                          |
|id     =xforms-request                                                                                                |
|----------------------------------------------------------------------------------------------------------------------|
|file:/tmp/tomcat8-tmp/upload__3b6ef3d8_14e636f6077__7ff8_00000009.tmp             |validating document           |   1|
|······················································································································|
|element=<documents source="browse" ...  (deleted some content)                                                                           |
|----------------------------------------------------------------------------------------------------------------------|
|file:/tmp/tomcat8-tmp/upload__3b6ef3d8_14e636f6077__7ff8_00000009.tmp             |                              |   1|
|----------------------------------------------------------------------------------------------------------------------|
|Exception: org.orbeon.oxf.processor.validation.SchemaValidationException                                              |
|----------------------------------------------------------------------------------------------------------------------|
|oxf.processor.validation.MSVValidationProcessor$3$2|error                         |MSVValidationProcessor.java   | 201|
|org.orbeon.msv.verifier.Verifier                   |onError                       |Verifier.java                 | 371|
|org.orbeon.msv.verifier.Verifier                   |onError                       |Verifier.java                 | 363|
|org.orbeon.msv.verifier.Verifier                   |startElement                  |Verifier.java                 | 203|
|org.orbeon.oxf.xml.SimpleForwardingXMLReceiver     |startElement                  |SimpleForwardingXMLReceiver.ja|  83|
|org.orbeon.oxf.xml.ExceptionWrapperXMLReceiver     |startElement                  |ExceptionWrapperXMLReceiver.ja|  52|
|org.orbeon.oxf.xml.TeeXMLReceiver                  |startElement                  |TeeXMLReceiver.java           |  85|
|org.orbeon.oxf.xml.ForwardingXMLReceiver           |startElement                  |ForwardingXMLReceiver.java    | 125|
|org.orbeon.oxf.xml.SAXStore                        |startElement                  |SAXStore.java                 | 538|
|orbeon.apache.xerces.parsers.AbstractSAXParser     |startElement                  |                              |    |
|orbeon.apache.xerces.impl.XMLNSDocumentScannerImpl |scanStartElement              |                              |    |
|s.impl.XMLNSDocumentScannerImpl$NSContentDispatcher|scanRootElementHook           |                              |    |
|cumentFragmentScannerImpl$FragmentContentDispatcher|dispatch                      |                              |    |
|n.apache.xerces.impl.XMLDocumentFragmentScannerImpl|scanDocument                  |                              |    |
|orbeon.apache.xerces.parsers.XML11Configuration    |parse                         |                              |    |
|orbeon.apache.xerces.parsers.XML11Configuration    |parse                         |                              |    |
|orbeon.apache.xerces.parsers.XMLParser             |parse                         |                              |    |
|orbeon.apache.xerces.parsers.AbstractSAXParser     |parse                         |                              |    |
|processor.generator.URLGenerator$URLResourceHandler|readXML                       |URLGenerator.java             |1012|
|org.orbeon.oxf.processor.generator.URLGenerator$1  |readImpl                      |URLGenerator.java             | 538|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|eteRuntimeOutputFilter$ForwarderRuntimeOutputOutput|read                          |ProcessorOutputImpl.java      | 218|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|n.oxf.processor.validation.MSVValidationProcessor$3|readImpl                      |MSVValidationProcessor.java   | 221|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|mpl.ProcessorOutputImpl$ConcreteRuntimeOutputFilter|read                          |ProcessorOutputImpl.java      | 241|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsDOM4J              |ProcessorImpl.java            | 279|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsDOM4J              |ProcessorImpl.java            | 294|
|org.orbeon.oxf.xforms.processor.XFormsServer       |doIt                          |XFormsServer.java             | 122|
|org.orbeon.oxf.xforms.processor.XFormsServer       |access$000                    |XFormsServer.java             |  63|
|org.orbeon.oxf.xforms.processor.XFormsServer$1     |readImpl                      |XFormsServer.java             |  90|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|eteRuntimeOutputFilter$ForwarderRuntimeOutputOutput|read                          |ProcessorOutputImpl.java      | 218|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|n.oxf.processor.validation.MSVValidationProcessor$3|readImpl                      |MSVValidationProcessor.java   | 221|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|---8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<---|
|org.orbeon.oxf.processor.pipeline.PipelineProcessor|start                         |PipelineProcessor.java        | 615|
|org.orbeon.oxf.pipeline.InitUtils$                 |runProcessor                  |InitUtils.scala               |  82|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply$mcV$sp                  |ProcessorService.scala        |  45|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEvent                     |LifecycleLogger.scala         | 124|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEventAssumingRequest      |LifecycleLogger.scala         | 117|
|org.orbeon.oxf.webapp.ProcessorService             |service                       |ProcessorService.scala        |  40|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply$mcV$sp                  |OrbeonServlet.scala           |  79|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.ScalaUtils$                    |withRootException             |ScalaUtils.scala              |  83|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply$mcV$sp                  |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.DynamicVariable                |withValue                     |DynamicVariable.scala         |  42|
|org.orbeon.oxf.servlet.OrbeonServlet               |service                       |OrbeonServlet.scala           |  71|
|javax.servlet.http.HttpServlet                     |service                       |HttpServlet.java              | 725|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 291|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.tomcat.websocket.server.WsFilter        |doFilter                      |WsFilter.java                 |  52|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 239|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.catalina.core.StandardWrapperValve      |invoke                        |StandardWrapperValve.java     | 219|
|org.apache.catalina.core.StandardContextValve      |invoke                        |StandardContextValve.java     | 106|
|org.apache.catalina.authenticator.AuthenticatorBase|invoke                        |AuthenticatorBase.java        | 616|
|org.apache.catalina.valves.AbstractAccessLogValve  |invoke                        |AbstractAccessLogValve.java   | 610|
|org.apache.catalina.core.StandardHostValve         |invoke                        |StandardHostValve.java        | 142|
|org.apache.catalina.valves.ErrorReportValve        |invoke                        |ErrorReportValve.java         |  79|
|org.apache.catalina.core.StandardEngineValve       |invoke                        |StandardEngineValve.java      |  88|
|org.apache.catalina.connector.CoyoteAdapter        |service                       |CoyoteAdapter.java            | 534|
|org.apache.coyote.http11.AbstractHttp11Processor   |process                       |AbstractHttp11Processor.java  |1081|
|e.coyote.AbstractProtocol$AbstractConnectionHandler|process                       |AbstractProtocol.java         | 658|
|te.http11.Http11NioProtocol$Http11ConnectionHandler|process                       |Http11NioProtocol.java        | 222|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|doRun                         |NioEndpoint.java              |1566|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|run                           |NioEndpoint.java              |1523|
|java.util.concurrent.ThreadPoolExecutor            |runWorker                     |ThreadPoolExecutor.java       |1142|
|java.util.concurrent.ThreadPoolExecutor$Worker     |run                           |ThreadPoolExecutor.java       | 617|
|che.tomcat.util.threads.TaskThread$WrappingRunnable|run                           |TaskThread.java               |  61|
|java.lang.Thread                                   |run                           |Thread.java                   | 745|
+----------------------------------------------------------------------------------------------------------------------+
Here's the submission:
<xforms:submission id="removelocks-submission"
			    nodeset="instance('doc-infos')"
				method="post"
				replace="none"
				validate="false"
  				relevant="false"
  				resource="/removelocks">
				<xforms:send ev:event="xforms-submit-done"
					submission="submRefresh" />
			</xforms:submission>

If i replace the replace attribute's value from "none" to "all", the first submission seems to run, but the second one fails. Anyway, i can't use replace "all" since the first submission has no output.

It seems that when using replace="none", the POSTed instance is validated as some sort of event (?!?), wich fails of course. So, i've tried to add the "validate" attribute to refrain the xforms engine from validating the posted instance, but it doensn't change anything.

Any ideas? Thanks in advance!

fs PS Not sure how to markup the plain-text content when using the web interface at discuss.orbeon.com ... hope the log is formatted correctly...
Reply | Threaded
Open this post in threaded view
|

Re: Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

fl.schmitt(ops-users)

I've tried to create a minimal test case for this:

XForm Page:

<xh:html
	xmlns:xh="http://www.w3.org/1999/xhtml"
            xmlns:ev="http://www.w3.org/2001/xml-events"
            xmlns:xf="http://www.w3.org/2002/xforms"
            xmlns:xs="http://www.w3.org/2001/XMLSchema"
            xmlns:fr="http://orbeon.org/oxf/xml/form-runner">
	<xh:head>
		<xh:title>XPL Service Test</xh:title>
		<xf:model id="main">
			<xf:instance id="instance">
				<test1 xmlns="">
					<test2>bla</test2>
				</test1>
			</xf:instance>
			<xf:submission 
				id="test"
				replace="none"
				method="post"
				validate="false"
				relevant="false"
				resource="/mirror" />
		</xf:model>
	</xh:head>
	<xh:body>
		<xh:h1>Test</xh:h1>
		<xh:div>
			<xh:p>
			<xf:submit submission="test">
				<xf:label>Test-Submission</xf:label>
				<xf:help>Test submission to test XPL services</xf:help>
			</xf:submit>
			</xh:p>
			<xf:output ref="instance('instance')//test2" />
		</xh:div>
		<xh:div>
		    <fr:xforms-inspector />
	    </xh:div>	
	</xh:body>
</xh:html>

Page Flow entries for page and service:

<page id="test"
    		path="/test"
    		view="pages/test/test.xhtml"></page>
    <page id="mirror"
    		path="/mirror"
    		view="services/mirror.xpl" />

mirror.xpl:

<p:config 
  xmlns:p="http://www.orbeon.com/oxf/pipeline"
  xmlns:oxf="http://www.orbeon.com/oxf/processors">

    <!-- The XML submission is available on the "instance" input -->
    <p:param name="instance" type="input" schema-href="schema.rng" />
    <p:param name="data" type="output" schema-href="schema.rng" />

    <!-- Processing of the XML submission (here we just return the request) -->
    <p:processor name="oxf:identity">
        <p:input name="data" href="#instance"/>
        <p:output name="data" ref="data"/>
    </p:processor>

</p:config>

schema.rng:

<?xml version="1.0" encoding="UTF-8"?>
<grammar ns="" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
  <start>
    <element name="test1">
      <element name="test2">
        <data type="NCName"/>
      </element>
    </element>
  </start>
</grammar>

When the test submission is triggered, the log shows the following errors:

2015-07-07 10:02:50,836 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - start submission {id: "test"}
2015-07-07 10:02:50,837 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   start connecting {type: "regular"}
2015-07-07 10:02:50,838 http-nio-8443-exec-17 INFO  webapp.ProcessorService  - /mirror - Received request
2015-07-07 10:02:50,847 http-nio-8443-exec-17 ERROR processor.XFormsServer  - 
+----------------------------------------------------------------------------------------------------------------------+
|An Error has Occurred                                                                                                 |
|----------------------------------------------------------------------------------------------------------------------|
|Error tag name "test1" is not allowed. Possible tag names are: <event-request>(schema: oxf:/ops/xforms/xforms-server-r|
|equest.rng)                                                                                                           |
|----------------------------------------------------------------------------------------------------------------------|
|Application Call Stack                                                                                                |
|----------------------------------------------------------------------------------------------------------------------|
|oxf:/ops/xforms/xforms-server.xpl                                                 |reading processor output      |  37|
|······················································································································|
|element=<p:output name="data" id="xforms-request"/>                                                                   |
|name   =data                                                                                                          |
|id     =xforms-request                                                                                                |
|----------------------------------------------------------------------------------------------------------------------|
|file:/tmp/tomcat8-tmp/upload__51694abf_14e676eecaa__7fff_00000047.tmp             |validating document           |   1|
|······················································································································|
|element=<test1>[...]</test1>                                                                                          |
|----------------------------------------------------------------------------------------------------------------------|
|file:/tmp/tomcat8-tmp/upload__51694abf_14e676eecaa__7fff_00000047.tmp             |                              |   1|
|----------------------------------------------------------------------------------------------------------------------|
|Exception: org.orbeon.oxf.processor.validation.SchemaValidationException                                              |
|----------------------------------------------------------------------------------------------------------------------|
|oxf.processor.validation.MSVValidationProcessor$3$2|error                         |MSVValidationProcessor.java   | 201|
|org.orbeon.msv.verifier.Verifier                   |onError                       |Verifier.java                 | 371|
|org.orbeon.msv.verifier.Verifier                   |onError                       |Verifier.java                 | 363|
|org.orbeon.msv.verifier.Verifier                   |startElement                  |Verifier.java                 | 203|
|org.orbeon.oxf.xml.SimpleForwardingXMLReceiver     |startElement                  |SimpleForwardingXMLReceiver.ja|  83|
|org.orbeon.oxf.xml.ExceptionWrapperXMLReceiver     |startElement                  |ExceptionWrapperXMLReceiver.ja|  52|
|org.orbeon.oxf.xml.TeeXMLReceiver                  |startElement                  |TeeXMLReceiver.java           |  85|
|org.orbeon.oxf.xml.ForwardingXMLReceiver           |startElement                  |ForwardingXMLReceiver.java    | 125|
|org.orbeon.oxf.xml.SAXStore                        |startElement                  |SAXStore.java                 | 538|
|orbeon.apache.xerces.parsers.AbstractSAXParser     |startElement                  |                              |    |
|orbeon.apache.xerces.impl.XMLNSDocumentScannerImpl |scanStartElement              |                              |    |
|s.impl.XMLNSDocumentScannerImpl$NSContentDispatcher|scanRootElementHook           |                              |    |
|cumentFragmentScannerImpl$FragmentContentDispatcher|dispatch                      |                              |    |
|n.apache.xerces.impl.XMLDocumentFragmentScannerImpl|scanDocument                  |                              |    |
|orbeon.apache.xerces.parsers.XML11Configuration    |parse                         |                              |    |
|orbeon.apache.xerces.parsers.XML11Configuration    |parse                         |                              |    |
|orbeon.apache.xerces.parsers.XMLParser             |parse                         |                              |    |
|orbeon.apache.xerces.parsers.AbstractSAXParser     |parse                         |                              |    |
|processor.generator.URLGenerator$URLResourceHandler|readXML                       |URLGenerator.java             |1012|
|org.orbeon.oxf.processor.generator.URLGenerator$1  |readImpl                      |URLGenerator.java             | 538|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|eteRuntimeOutputFilter$ForwarderRuntimeOutputOutput|read                          |ProcessorOutputImpl.java      | 218|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|n.oxf.processor.validation.MSVValidationProcessor$3|readImpl                      |MSVValidationProcessor.java   | 221|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|mpl.ProcessorOutputImpl$ConcreteRuntimeOutputFilter|read                          |ProcessorOutputImpl.java      | 241|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsDOM4J              |ProcessorImpl.java            | 279|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsDOM4J              |ProcessorImpl.java            | 294|
|org.orbeon.oxf.xforms.processor.XFormsServer       |doIt                          |XFormsServer.java             | 122|
|org.orbeon.oxf.xforms.processor.XFormsServer       |access$000                    |XFormsServer.java             |  63|
|org.orbeon.oxf.xforms.processor.XFormsServer$1     |readImpl                      |XFormsServer.java             |  90|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|eteRuntimeOutputFilter$ForwarderRuntimeOutputOutput|read                          |ProcessorOutputImpl.java      | 218|
|org.orbeon.oxf.processor.ProcessorImpl             |readInputAsSAX                |ProcessorImpl.java            | 262|
|n.oxf.processor.validation.MSVValidationProcessor$3|readImpl                      |MSVValidationProcessor.java   | 221|
|essor.impl.ProcessorOutputImpl$TopLevelOutputFilter|read                          |ProcessorOutputImpl.java      | 257|
|org.orbeon.oxf.processor.impl.ProcessorOutputImpl  |read                          |ProcessorOutputImpl.java      | 394|
|---8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<---|
|org.orbeon.oxf.processor.pipeline.PipelineProcessor|executeChildren               |PipelineProcessor.java        | 680|
|org.orbeon.oxf.processor.pipeline.PipelineProcessor|start                         |PipelineProcessor.java        | 615|
|org.orbeon.oxf.pipeline.InitUtils$                 |runProcessor                  |InitUtils.scala               |  82|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply$mcV$sp                  |ProcessorService.scala        |  45|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEvent                     |LifecycleLogger.scala         | 124|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEventAssumingRequest      |LifecycleLogger.scala         | 117|
|org.orbeon.oxf.webapp.ProcessorService             |service                       |ProcessorService.scala        |  40|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply$mcV$sp                  |OrbeonServlet.scala           |  79|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.ScalaUtils$                    |withRootException             |ScalaUtils.scala              |  83|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply$mcV$sp                  |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.DynamicVariable                |withValue                     |DynamicVariable.scala         |  42|
|org.orbeon.oxf.servlet.OrbeonServlet               |service                       |OrbeonServlet.scala           |  71|
|javax.servlet.http.HttpServlet                     |service                       |HttpServlet.java              | 725|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 291|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.tomcat.websocket.server.WsFilter        |doFilter                      |WsFilter.java                 |  52|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 239|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.catalina.core.StandardWrapperValve      |invoke                        |StandardWrapperValve.java     | 219|
|org.apache.catalina.core.StandardContextValve      |invoke                        |StandardContextValve.java     | 106|
|org.apache.catalina.authenticator.AuthenticatorBase|invoke                        |AuthenticatorBase.java        | 616|
|org.apache.catalina.core.StandardHostValve         |invoke                        |StandardHostValve.java        | 142|
|org.apache.catalina.valves.ErrorReportValve        |invoke                        |ErrorReportValve.java         |  79|
|org.apache.catalina.core.StandardEngineValve       |invoke                        |StandardEngineValve.java      |  88|
|org.apache.catalina.connector.CoyoteAdapter        |service                       |CoyoteAdapter.java            | 534|
|org.apache.coyote.http11.AbstractHttp11Processor   |process                       |AbstractHttp11Processor.java  |1081|
|e.coyote.AbstractProtocol$AbstractConnectionHandler|process                       |AbstractProtocol.java         | 658|
|te.http11.Http11NioProtocol$Http11ConnectionHandler|process                       |Http11NioProtocol.java        | 222|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|doRun                         |NioEndpoint.java              |1566|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|run                           |NioEndpoint.java              |1523|
|java.util.concurrent.ThreadPoolExecutor            |runWorker                     |ThreadPoolExecutor.java       |1142|
|java.util.concurrent.ThreadPoolExecutor$Worker     |run                           |ThreadPoolExecutor.java       | 617|
|che.tomcat.util.threads.TaskThread$WrappingRunnable|run                           |TaskThread.java               |  61|
|java.lang.Thread                                   |run                           |Thread.java                   | 745|
+----------------------------------------------------------------------------------------------------------------------+
2015-07-07 10:02:50,848 http-nio-8443-exec-17 INFO  webapp.ProcessorService  - /mirror - Timing: 10
2015-07-07 10:02:50,848 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   end connecting {time (ms): "11"}
2015-07-07 10:02:50,849 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   start handling result
2015-07-07 10:02:50,849 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   end handling result {time (ms): "0"}
2015-07-07 10:02:50,849 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - end submission {time (ms): "13"}
2015-07-07 10:02:50,850 http-nio-8443-exec-17 ERROR processor.XFormsServer  - xforms-submit-error - setting throwable {throwable: "
+----------------------------------------------------------------------------------------------------------------------+
|An Error has Occurred                                                                                                 |
|----------------------------------------------------------------------------------------------------------------------|
|xf:submission for submission id: test, error code received when submitting instance: 500                              |
|----------------------------------------------------------------------------------------------------------------------|
|Application Call Stack                                                                                                |
|----------------------------------------------------------------------------------------------------------------------|
|oxf:/pages/test/test.xhtml                                                        |processing submission response|  21|
|······················································································································|
|element=<xf:submission id="test" replace="none" method="post" validate="false" relevant="false" resource="/mirror"/>  |
|----------------------------------------------------------------------------------------------------------------------|
|----------------------------------------------------------------------------------------------------------------------|
|Exception: org.orbeon.oxf.xforms.submission.XFormsSubmissionException                                                 |
|----------------------------------------------------------------------------------------------------------------------|
|.orbeon.oxf.xforms.submission.XFormsModelSubmission|getReplacer                   |XFormsModelSubmission.java    | 729|
|rg.orbeon.oxf.xforms.submission.RegularSubmission$1|call                          |RegularSubmission.java        | 106|
|rg.orbeon.oxf.xforms.submission.RegularSubmission$1|call                          |RegularSubmission.java        |  76|
|org.orbeon.oxf.xforms.submission.BaseSubmission    |submitCallable                |BaseSubmission.scala          |  89|
|org.orbeon.oxf.xforms.submission.RegularSubmission |connect                       |RegularSubmission.java        | 129|
|.orbeon.oxf.xforms.submission.XFormsModelSubmission|doSubmit                      |XFormsModelSubmission.java    | 460|
|.orbeon.oxf.xforms.submission.XFormsModelSubmission|performDefaultAction          |XFormsModelSubmission.java    | 292|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply$mcV$sp                  |Dispatch.scala                | 137|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply                         |Dispatch.scala                |  73|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply                         |Dispatch.scala                |  73|
|org.orbeon.oxf.xforms.event.Dispatch$              |withEvent$1                   |Dispatch.scala                |  38|
|org.orbeon.oxf.xforms.event.Dispatch$              |dispatchEvent                 |Dispatch.scala                |  72|
|eon.oxf.xforms.control.controls.XFormsSubmitControl|performDefaultAction          |XFormsSubmitControl.scala     |  45|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply$mcV$sp                  |Dispatch.scala                | 137|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply                         |Dispatch.scala                |  73|
|.oxf.xforms.event.Dispatch$$anonfun$dispatchEvent$1|apply                         |Dispatch.scala                |  73|
|org.orbeon.oxf.xforms.event.Dispatch$              |withEvent$1                   |Dispatch.scala                |  38|
|org.orbeon.oxf.xforms.event.Dispatch$              |dispatchEvent                 |Dispatch.scala                |  72|
|org.orbeon.oxf.xforms.event.ClientEvents$          |org$orbeon$oxf$xforms$event$Cl|ClientEvents.scala            | 532|
|f.xforms.event.ClientEvents$$anonfun$processEvent$1|apply$mcV$sp                  |ClientEvents.scala            | 576|
|f.xforms.event.ClientEvents$$anonfun$processEvent$1|apply                         |ClientEvents.scala            | 539|
|f.xforms.event.ClientEvents$$anonfun$processEvent$1|apply                         |ClientEvents.scala            | 539|
|org.orbeon.oxf.util.Logging$class                  |withDebug                     |Logging.scala                 |  50|
|org.orbeon.oxf.xforms.event.ClientEvents$          |withDebug                     |ClientEvents.scala            |  37|
|org.orbeon.oxf.xforms.event.ClientEvents$          |processEvent                  |ClientEvents.scala            | 539|
|.xforms.event.ClientEvents$$anonfun$processEvents$1|apply                         |ClientEvents.scala            | 144|
|.xforms.event.ClientEvents$$anonfun$processEvents$1|apply                         |ClientEvents.scala            | 143|
|scala.collection.immutable.List                    |foreach                       |List.scala                    | 318|
|org.orbeon.oxf.xforms.event.ClientEvents$          |processEvents                 |ClientEvents.scala            | 143|
|org.orbeon.oxf.xforms.event.ClientEvents           |processEvents                 |ClientEvents.scala            |    |
|org.orbeon.oxf.xforms.processor.XFormsServer$2     |run                           |XFormsServer.java             | 271|
|ion.XFormsAPI$$anonfun$withContainingDocumentJava$1|apply$mcV$sp                  |XFormsAPI.scala               |  55|
|ion.XFormsAPI$$anonfun$withContainingDocumentJava$1|apply                         |XFormsAPI.scala               |  55|
|ion.XFormsAPI$$anonfun$withContainingDocumentJava$1|apply                         |XFormsAPI.scala               |  55|
|org.orbeon.oxf.util.DynamicVariable                |withValue                     |DynamicVariable.scala         |  42|
|org.orbeon.oxf.xforms.action.XFormsAPI$            |withContainingDocument        |XFormsAPI.scala               |  60|
|org.orbeon.oxf.xforms.action.XFormsAPI$            |withContainingDocumentJava    |XFormsAPI.scala               |  54|
|org.orbeon.oxf.xforms.action.XFormsAPI             |withContainingDocumentJava    |XFormsAPI.scala               |    |
|org.orbeon.oxf.xforms.processor.XFormsServer       |doIt                          |XFormsServer.java             | 254|
|org.orbeon.oxf.xforms.processor.XFormsServer       |access$000                    |XFormsServer.java             |  63|
|---8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<--------8<---|
|org.orbeon.oxf.processor.pipeline.PipelineProcessor|executeChildren               |PipelineProcessor.java        | 680|
|org.orbeon.oxf.processor.pipeline.PipelineProcessor|start                         |PipelineProcessor.java        | 615|
|org.orbeon.oxf.pipeline.InitUtils$                 |runProcessor                  |InitUtils.scala               |  82|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply$mcV$sp                  |ProcessorService.scala        |  45|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|beon.oxf.webapp.ProcessorService$$anonfun$service$1|apply                         |ProcessorService.scala        |  40|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEvent                     |LifecycleLogger.scala         | 124|
|org.orbeon.oxf.logging.LifecycleLogger$            |withEventAssumingRequest      |LifecycleLogger.scala         | 117|
|org.orbeon.oxf.webapp.ProcessorService             |service                       |ProcessorService.scala        |  40|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply$mcV$sp                  |OrbeonServlet.scala           |  79|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|nServlet$$anonfun$service$1$$anonfun$apply$mcV$sp$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.ScalaUtils$                    |withRootException             |ScalaUtils.scala              |  83|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply$mcV$sp                  |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|orbeon.oxf.servlet.OrbeonServlet$$anonfun$service$1|apply                         |OrbeonServlet.scala           |  72|
|org.orbeon.oxf.util.DynamicVariable                |withValue                     |DynamicVariable.scala         |  42|
|org.orbeon.oxf.servlet.OrbeonServlet               |service                       |OrbeonServlet.scala           |  71|
|javax.servlet.http.HttpServlet                     |service                       |HttpServlet.java              | 725|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 291|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.tomcat.websocket.server.WsFilter        |doFilter                      |WsFilter.java                 |  52|
|org.apache.catalina.core.ApplicationFilterChain    |internalDoFilter              |ApplicationFilterChain.java   | 239|
|org.apache.catalina.core.ApplicationFilterChain    |doFilter                      |ApplicationFilterChain.java   | 206|
|org.apache.catalina.core.StandardWrapperValve      |invoke                        |StandardWrapperValve.java     | 219|
|org.apache.catalina.core.StandardContextValve      |invoke                        |StandardContextValve.java     | 106|
|org.apache.catalina.authenticator.AuthenticatorBase|invoke                        |AuthenticatorBase.java        | 616|
|org.apache.catalina.core.StandardHostValve         |invoke                        |StandardHostValve.java        | 142|
|org.apache.catalina.valves.ErrorReportValve        |invoke                        |ErrorReportValve.java         |  79|
|org.apache.catalina.core.StandardEngineValve       |invoke                        |StandardEngineValve.java      |  88|
|org.apache.catalina.connector.CoyoteAdapter        |service                       |CoyoteAdapter.java            | 534|
|org.apache.coyote.http11.AbstractHttp11Processor   |process                       |AbstractHttp11Processor.java  |1081|
|e.coyote.AbstractProtocol$AbstractConnectionHandler|process                       |AbstractProtocol.java         | 658|
|te.http11.Http11NioProtocol$Http11ConnectionHandler|process                       |Http11NioProtocol.java        | 222|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|doRun                         |NioEndpoint.java              |1566|
|.apache.tomcat.util.net.NioEndpoint$SocketProcessor|run                           |NioEndpoint.java              |1523|
|java.util.concurrent.ThreadPoolExecutor            |runWorker                     |ThreadPoolExecutor.java       |1142|
|java.util.concurrent.ThreadPoolExecutor$Worker     |run                           |ThreadPoolExecutor.java       | 617|
|che.tomcat.util.threads.TaskThread$WrappingRunnable|run                           |TaskThread.java               |  61|
|java.lang.Thread                                   |run                           |Thread.java                   | 745|
+----------------------------------------------------------------------------------------------------------------------+"}
2015-07-07 10:02:50,850 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - state manager - Document is dirty. Generating new dynamic state.
2015-07-07 10:02:50,851 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - response - start handling regular Ajax response
2015-07-07 10:02:50,851 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   start computing differences
2015-07-07 10:02:50,852 http-nio-8443-exec-17 DEBUG processor.XFormsServer  -   end computing differences {time (ms): "1"}
2015-07-07 10:02:50,854 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - response - end handling regular Ajax response {time (ms): "3"}
2015-07-07 10:02:50,854 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - state manager - Keeping document in cache.
2015-07-07 10:02:50,854 http-nio-8443-exec-17 DEBUG processor.XFormsServer  - state manager - Document cache enabled. Storing document in cache.
2015-07-07 10:02:50,855 http-nio-8443-exec-17 INFO  webapp.ProcessorService  - /xforms-server - Timing: 29

If i change the replace attribute of the submission element from "none" to "all", no error occurs, and my form is replaced by an empty page. If i modify the page flow and declare the mirror.xpl as view instead as model, there's no error and my form is replaced by the submitted / mirrored instance. So, only if replace="none" is set, the request isn't processed correctly. Thus, you can't implement any sort of service that doesn't affect at least the model of the current form. And that's exactly what i need in my application

fs
Reply | Threaded
Open this post in threaded view
|

Re: Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

Erik Bruchez
Administrator
The error comes from the XForms Server (at /xforms-server). It is as if the service call, instead of reaching your service, was reaching /xforms-server.

When you upgraded, did you keep the Orbeon Forms 4.9 web.xml as is? Or are there maybe remnants of your 3.9 web.xml in there?

-Erik
Reply | Threaded
Open this post in threaded view
|

Re: Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

fl.schmitt(ops-users)
Hi Erik,

you're right - it was a web.xml issue. I tried to adapt the 4.9 web.xml to my needs, and obviously, i made some mistakes. I'm not sure about the exact cause - maybe i've removed too much of the form runner stuff that i estimated to be irrelevant, since i don't use the form runner in my application. Anyway - the issue is solved, submission@method="post" and replace="none" works fine now.

fs
Reply | Threaded
Open this post in threaded view
|

Re: Migration 3.9 -> 4.9: XPL Service - Validation error when replace="none"

Erik Bruchez
Administrator
Great, that's the kind of resolution I like! -Erik