I general, the integration of JaxRx has been simplified and generalized a lot since Version 6.1. If you're working with the sources, you can checkout the main and api package and directly run the contained basexrest(.bat) script. Otherwise, you'll need to...
1. get basex.jar and basex-jar.api: http://basex.org/download
2. get one of the start scripts (win or linux/mac): https://svn.uni-konstanz.de/dbis/basex/trunk/api/etc/basexrest.bat https://svn.uni-konstanz.de/dbis/basex/trunk/api/etc/basexrest
3. get the external libraries referenced from the start script: https://svn.uni-konstanz.de/dbis/basex/trunk/api/lib/
Hope this helps, Christian
2010/12/13 Mahender Didwania mahender@didwania.co.uk:
Hi,
Two things:
Earlier I was using version 6.2.9 and the class StartJaxRx.java seemed to=
work fine. =C2=A0The need is to have the ability to invoke the server from= a script.
I can't find the StartJaxRx in 6.3.3 any more. =C2=A0Using the old class =
with 6.3.3, the server says it started up fine, but when I attempt to acces= s it over HTTP/REST, I get error for /basex/jax-rx (note that /basex/ is ok= ay):
Problem accessing /basex/jax-rx/. Reason:
=C2=A0 =C2=A0tried to access method org.basex.server.ClientSession.execut=
e(Ljava/lang/String;Ljava/io/OutputStream;)V from class org.basex.api.jaxrx= .BXOutput
Caused by:
java.lang.IllegalAccessError: tried to access method org.basex.server.Cli=
entSession.execute(Ljava/lang/String;Ljava/io/OutputStream;)V from class or= g.basex.api.jaxrx.BXOutput
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.basex.api.jaxrx.BXOutput.exec(BXOutput.=
java:62)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.basex.api.jaxrx.BXJaxRx$1.code(BXJaxRx.=
java:61)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.basex.api.jaxrx.BXCode.run(BXCode.java:=
56)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.basex.api.jaxrx.BXOutput.write(BXOutput=
.java:51)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.core.impl.provider.entity.St=
reamingOutputProvider.writeTo(StreamingOutputProvider.java:71)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.core.impl.provider.entity.St=
reamingOutputProvider.writeTo(StreamingOutputProvider.java:57)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.spi.container.ContainerRespo=
nse.write(ContainerResponse.java:299)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.server.impl.application.WebA=
pplicationImpl._handleRequest(WebApplicationImpl.java:1326)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.server.impl.application.WebA=
pplicationImpl.handleRequest(WebApplicationImpl.java:1239)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.server.impl.application.WebA=
pplicationImpl.handleRequest(WebApplicationImpl.java:1229)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.spi.container.servlet.WebCom=
ponent.service(WebComponent.java:420)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.spi.container.servlet.Servle=
tContainer.service(ServletContainer.java:497)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at com.sun.jersey.spi.container.servlet.Servle=
tContainer.service(ServletContainer.java:684)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at javax.servlet.http.HttpServlet.service(Http=
Servlet.java:820)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.servlet.ServletHolder.han=
dle(ServletHolder.java:511)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.servlet.ServletHandler.ha=
ndle(ServletHandler.java:401)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.servlet.SessionHandler.ha=
ndle(SessionHandler.java:182)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.handler.ContextHandler.ha=
ndle(ContextHandler.java:766)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.handler.HandlerWrapper.ha=
ndle(HandlerWrapper.java:152)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.Server.handle(Server.java=
:326)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.HttpConnection.handleRequ=
est(HttpConnection.java:542)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.HttpConnection$RequestHan=
dler.headerComplete(HttpConnection.java:928)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.HttpParser.parseNext(Http=
Parser.java:549)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.HttpParser.parseAvailable=
(HttpParser.java:212)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.HttpConnection.handle(Htt=
pConnection.java:404)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.jetty.bio.SocketConnector$Conne=
ction.run(SocketConnector.java:228)
=C2=A0 =C2=A0 =C2=A0 =C2=A0at org.mortbay.thread.QueuedThreadPool$PoolThr=
ead.run(QueuedThreadPool.java:582)
For version 6.1, you provide various files, including a .zip, on your web=
site; for 6.3.3, you only provide basex.jar and basex-api.jar. =C2=A0I had = earlier created my own maven build to include all dependencies (including t= he ones from java.net repository), but as noted above, I cannot get 6.3.3 t= o work. =C2=A0Could you please provide a .zip file for every release like y= ou have for 6.1 on your web-site (merely replacing BaseX61.jar with basex.j= ar and BaseX61-jaxrx.jar with basex-api.jar (for 6.3.3 versions) does not s= eem to help)?
Thanks, Mahender. _______________________________________________ BaseX-Talk mailing list BaseX-Talk@mailman.uni-konstanz.de https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk
basex-talk@mailman.uni-konstanz.de