Search code examples
exist-dbxproc

Error from XProcxq module in eXist-db


We're running eXist-db version 3.0 and want to try running XProc within it.

We found that the XProcxq Module is now part of eXist: http://exist-db.org/exist/apps/doc/extensions.xml#module_xprocxq

However, in attempting to use it we get the error below and wondered if anyone had suggestions for where we could be going wrong?

As specified at the top of the module page linked to, we added the module to the conf.xml file and restarted eXist. (This could be where we went wrong, but that's a guess on our part)

This is what the module we added looks like in conf.xml:

<module uri="http://xproc.net/xproc" class="org.exist.xquery.modules.xprocxq.XProcxq/>

Here is the simple started XQuery I've attempted to use:

xquery version "1.0" encoding "UTF-8";

import module namespace const = "http://xproc.net/xproc/const";
import module namespace xproc = "http://xproc.net/xproc";
import module namespace u = "http://xproc.net/xproc/util";

declare variable $local:XPROCXQ_EXAMPLES := "/db/examples"; (:CHANGE ME:)  

let $stdin :=document{<test>Hello World</test>}

let $pipeline :=document{
                    <p:pipeline name="pipeline"
                                xmlns:p="http://www.w3.org/ns/xproc"
                                xmlns:c="http://www.w3.org/ns/xproc-step">
                        <p:identity/>
                    </p:pipeline>
                }

return
     xproc:run($pipeline,$stdin)

Here is the error: error found while loading module xproc: IO exception while loading module 'http://xproc.net/xproc' from 'http://xproc.net/xproc'


Solution

  • I posed your question to the exist-open mailing list (where I'd encourage you to join for future eXist-db questions), and it appears XProc support in eXist is currently between a rock and a hard place. The xprocxq library you mentioned is woefully underdeveloped (abandoned by its original creator), and the much better developed Calabash module is incompatible with the current version of Saxon used in eXist, due to a dependency on that version of Saxon. I'd welcome you to join exist-open to discuss further. Perhaps there's some other workaround for you.