Using the xforms-submission processor in a command line

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

Using the xforms-submission processor in a command line

Marco Lebel-2
Hello,

Does the xforms-submission processor work in a command line mode?

All my attempts so far resulted in an error message:

 "Cannot read from file /ops/xforms/xforms-submission.xpl"

There is obviously something I do not get!!!

Marco



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Using the xforms-submission processor in a command line

Erik Bruchez
Administrator
Marco,

This file is stored in orbeon-resources-private.jar. Could this be  
that this JAR is not in the classpath in the manifest of orbeon-cli.jar?

-Erik

On Jun 5, 2009, at 8:09 AM, Marco Lebel wrote:

> Hello,
>
> Does the xforms-submission processor work in a command line mode?
>
> All my attempts so far resulted in an error message:
>
> "Cannot read from file /ops/xforms/xforms-submission.xpl"
>
> There is obviously something I do not get!!!
>
> Marco
>
>
> --
> You receive this message as a subscriber of the [hidden email]  
> mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> OW2 mailing lists service home page: http://www.ow2.org/wws
--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Re: Using the xforms-submission processor in a command line

Marco Lebel-2
Erik,

I have looked at it and tried your suggestion but got the same error
message... The reality is that I do not know where to go from here.  
Like I said in another thread I have no success as soon as the pipeline
makes a reference to another pipeline!!!!  Here is the content of my
other thread that exposes my problem... I clearly have an issue but
can't figure out how to fix it :-[

Hello all,

I am trying to build a command line application using XPL and all of its
processors.  So as a test I created this XPL file inspired from the
sandbox:

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

   <!-- Validate input document with schema -->
   <p:processor name="oxf:validation">
       <p:input name="data" href="../schema/registration.xml"/>
       <p:input name="schema" href="../schema/registration.xsd"/>
       <p:input name="config">
           <config>
               <decorate>true</decorate>
           </config>
       </p:input>
       <p:output name="data" id="validation"/>
   </p:processor>
     <p:processor name="oxf:xml-converter">
       <p:input name="config"><config/></p:input>
       <p:input name="data" href="#validation"/>
       <p:output name="data" id="xml"/>
   </p:processor>

   <!-- Serialize -->
   <p:processor name="oxf:http-serializer">
       <p:input name="config"><config/></p:input>
       <p:input name="data" href="#xml"/>
   </p:processor>

</p:config>


This file can be call in command mode and works...  Then for testing
purposes I decided to split that file in two in order to try the
sub-pipeline concept.
So I have the following file being the sub-pipeline(validation.xpl):
<p:config xmlns:p="http://www.orbeon.com/oxf/pipeline"
   xmlns:oxf="http://www.orbeon.com/oxf/processors">

   <p:param name="instance" type="input"/>
   <p:param name="schema" type="input"/>
   <p:param name="decorated" type="output"/>

   <!-- Validate input document with schema -->
   <p:processor name="oxf:validation">
       <p:input name="data" href="#instance"/>
       <p:input name="schema" href="#schema"/>
       <p:input name="config">
           <config>
               <decorate>true</decorate>
           </config>
       </p:input>
       <p:output name="data" id="validation"/>
   </p:processor>
     <p:processor name="oxf:xml-converter">
       <p:input name="config"><config/></p:input>
       <p:input name="data" href="#validation"/>
       <p:output name="data" ref="decorated"/>
   </p:processor>

</p:config>

and this calling pipeline file(test.xpl):
<p:config xmlns:p="http://www.orbeon.com/oxf/pipeline"
   xmlns:oxf="http://www.orbeon.com/oxf/processors">

   <p:processor name="oxf:pipeline">
       <p:input name="config" href="validation.xpl"/>
       <p:input name="schema" href="../schema/registration.xsd"/>
       <p:input name="instance" href="../schema/registration.xml"/>
       <p:output name="decorated" id="result"/>
   </p:processor>

   <p:processor name="oxf:http-serializer">
       <p:input name="config"><config/></p:input>
       <p:input name="data" href="#result"/>
   </p:processor>

</p:config>


When I run this pipeline in command mode I get the following error:
2009-06-09 18:31:24,639 INFO  org.orbeon.oxf.main.OPS  - Running processor
2009-06-09 18:31:24,737 ERROR org.orbeon.oxf.main.OPS  - Exception at
line 8, column 49 of oxf:/local/vlc/proof/xpl/test.xpl (reading
processor output: name='decorated', id='result')
org.orbeon.oxf.resources.ResourceNotFoundException: Cannot read from
file /local/vlc/proof/xpl/validation.xpl
   at
org.orbeon.oxf.resources.FilesystemResourceManagerImpl.getContentAsStream(FilesystemResourceManagerImpl.java:67)

   at
org.orbeon.oxf.resources.ResourceManagerBase.getContentAsSAX(ResourceManagerBase.java:128)

   at
org.orbeon.oxf.resources.PriorityResourceManagerImpl$4.run(PriorityResourceManagerImpl.java:122)

   at
org.orbeon.oxf.resources.PriorityResourceManagerImpl.delegate(PriorityResourceManagerImpl.java:271)

:
:

This is the same error I get when I try to call from the command line a
pipeline containing a reference to the xform-submission processor
mention in another thread.

Any help will be appreciated and thanks in advance.


Erik Bruchez wrote:

> Marco,
>
> This file is stored in orbeon-resources-private.jar. Could this be
> that this JAR is not in the classpath in the manifest of orbeon-cli.jar?
>
> -Erik
>
> On Jun 5, 2009, at 8:09 AM, Marco Lebel wrote:
>
>> Hello,
>>
>> Does the xforms-submission processor work in a command line mode?
>>
>> All my attempts so far resulted in an error message:
>>
>> "Cannot read from file /ops/xforms/xforms-submission.xpl"
>>
>> There is obviously something I do not get!!!
>>
>> Marco
>>
>>
>> --
>> You receive this message as a subscriber of the [hidden email]
>> mailing list.
>> To unsubscribe: mailto:[hidden email]
>> For general help: mailto:[hidden email]?subject=help
>> OW2 mailing lists service home page: http://www.ow2.org/wws
>
> --
> Orbeon Forms - Web Forms for the Enterprise Done the Right Way
> http://www.orbeon.com/
>


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Re: Using the xforms-submission processor in a command line

Alessandro Vernet
Administrator
Marco,

Marco Lebel-2 wrote
I have looked at it and tried your suggestion but got the same error
message... The reality is that I do not know where to go from here.  
Like I said in another thread I have no success as soon as the pipeline
makes a reference to another pipeline!!!!  Here is the content of my
other thread that exposes my problem... I clearly have an issue but
can't figure out how to fix it :-[
Since you posted in this other thread, we'll follow-up there:

http://www.nabble.com/Command-line-XPL---help-needed-td23952617.html#a23952617

Alex