In Exist 2.2, When I try to access any .xpl files with REST GET, I get the following error:
/db/beheer/pipe.xpl err:XPST0003 error found while loading module xproc: Error while loading module http://xproc.net/xproc: unexpected token: ! (while expecting closing tag for element constructor: null) [at line 1, column 2]
It seems to me that Exist is processing the *.xpl as if it was something it could execute (like a stored xquery) but then it cannot do so and returns an error.
Is there an easy way to let it return just the XML (the XProc as is instead of error message)?
Indeed, eXist consults its list of Internet Media Types when you do a HTTP GET using the REST Server and if it thinks that it is an XProc it will attempt to execute it as such.
You can change what eXist thinks is an XProc by editing $EXIST_HOME/mime-type.xml
and then restarting eXist. You most likely want to move the .xpl extension from the mimetype application/xml+xproc
to application/xml
.