Re: Exist REST Problems

Posted by Alessandro Vernet on
URL: https://discuss.orbeon.com/Exist-REST-Problems-tp31201p31219.html

Ryan,

Point taken. Let us know if you find a solution through the eXist list
or otherwise.

Alex

On 11/10/06, Ryan Puddephatt <[hidden email]> wrote:

> Alex,
>         I can see your argument, but all my queries are simple, /product
> etc. This means I can get all the products in my application for listing
> (similar to the DMV Summary). This saves me having to create a query
> instance or use XPL because I can do it all in the src (well in theory)
>
> Thanks
>
> Ryan
>
> Ryan Puddephatt
> Software Engineer
>
> Teleflex Group - IT UK
> 1 Michaelson Square
> Livingston
> West Lothian
> Scotland
> EH54 7DP
>
> e> [hidden email]
> t> +44(0)1506 407 110
> f> +44(0)1506 407 108
>
>
>
> >-----Original Message-----
> >From: [hidden email] [mailto:[hidden email]] On Behalf
> >Of Alessandro Vernet
> >Sent: 11 November 2006 01:29
> >To: [hidden email]
> >Subject: Re: [ops-users] Exist REST Problems
> >
> >Ryan,
> >
> >Here I am posting the query from XForms. That is posting a
> >query embedded in a <query> document as the one shown on the
> >page linked below. Would you get the text/xml content type
> >when doing a POST vs. a GET? Is it OK in your case to do a POST?
> >
> >http://exist.sourceforge.net/devguide.html#N10385
> >
> >(Unless I am sending trivial queries, I don't like very much
> >the idea of sending them in a query string with a GET, because
> >I know that one day the query will become too long, exceed the
> >URL length limit and lead to a bug that is hard to find.)
> >
> >Alex
> >
> >On 11/10/06, Ryan Puddephatt <[hidden email]> wrote:
> >> Alex,
> >>         Apart from the fact I'm using an internal exist the only
> >> difference I can see is that I'm using the _query parameter to query
> >> the DB rather than pulling a single document, I believe that this is
> >> the cause for the change in content type
> >>
> >> Thanks
> >>
> >> Ryan
> >>
> >> Ryan Puddephatt
> >> Software Engineer
> >>
> >> Teleflex Group - IT UK
> >> 1 Michaelson Square
> >> Livingston
> >> West Lothian
> >> Scotland
> >> EH54 7DP
> >>
> >> e> [hidden email]
> >> t> +44(0)1506 407 110
> >> f> +44(0)1506 407 108
> >>
> >>
> >>
> >> >-----Original Message-----
> >> >From: [hidden email] [mailto:[hidden email]] On Behalf Of
> >> >Alessandro Vernet
> >> >Sent: 10 November 2006 21:53
> >> >To: [hidden email]
> >> >Subject: Re: [ops-users] Exist REST Problems
> >> >
> >> >On 11/10/06, Ryan Puddephatt <[hidden email]> wrote:
> >> >> I now have another problem, the REST API always returns text/html.
> >> >> There is a parameter that can change it, by adding the
> >following to
> >> >> the EXistServlet
> >> >
> >> >Ryan,
> >> >
> >> >I don't have this problem. I am using a verbatim 1.1.1
> >deployed as a
> >> >separate war, and if I access
> >http://localhost:8090/exist/rest/, the
> >> >response I get is:
> >> >
> >> >HTTP/1.1 200 OK
> >> >Server: Apache-Coyote/1.1
> >> >Content-Type: text/xml;charset=UTF-8
> >> >Content-Length: 321
> >> >Date: Fri, 10 Nov 2006 21:50:24 GMT
> >> >
> >> ><exist:result xmlns:exist="http://exist.sourceforge.net/NS/exist">
> >> >...
> >> >
> >> >Do you see anything that could be different in your case?
> >> >
> >> >Alex
> >> >--
> >> >Blog (XML, Web apps, Open Source):
> >> >http://www.orbeon.com/blog/
> >> >
> >> >
> >>
> >>
> >>
> >>
> >>
> >> --
> >> 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
> >> ObjectWeb mailing lists service home page:
> >> http://www.objectweb.org/wws
> >>
> >>
> >>
> >
> >
> >--
> >Blog (XML, Web apps, Open Source):
> >http://www.orbeon.com/blog/
> >
> >
>
>
>
>
>
> --
> 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
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>

--
Blog (XML, Web apps, Open Source):
http://www.orbeon.com/blog/



--
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
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet