Hi Adrian, we also have a similar system test under org.apache.cxf.systest.rest.RestClientServerBookTest. If you don't mind playing around with CXF source code, you can modify this test case to reproduce the problem you reported and submit the modified test case as a patch.
Cheers, Jervis > -----Original Message----- > From: Trenaman, Adrian [mailto:[EMAIL PROTECTED] > Sent: 2007?6?1? 0:53 > To: [email protected] > Subject: Problem matching URI templates with RESTful binding > > > Hi there, > > Does anyone know if there's some problems with RESTful > bindings in CXF? > I'm writing an app around the info on the wiki page - it's a RESTful > addressbook application. Am attaching key classes ContactService and > GetContact (the bean for the getContact parameters, i.e., the > ID) below. > > When I use the following URL > > http://localhost:9000/xml/contacts > > I get what I expect: an XML file like this: > > <ns4:Contacts > xmlns:ns4="http://easyrest/" > xmlns:ns3="http://www.iona.com/demo/contact" > xmlns:ns2="http://www.w3.org/2005/08/addressing/wsdl"> > <contact /> > </ns4:Contacts> > > However, when I use > > http://localhost:9000/xml/contacts/123 > > ... I get the same response as the original URL without the '/123' > suffix. It's as if the URI template isn't getting matched, and instead > the whole thing is going to the original URL. > > Anyone got any ideas on this? > > Thanks, > Ade. > > ----- > > > > @WebService > public interface ContactService { > > @Get > @HttpResource(location="/contacts") > @WebResult(name = "Contacts") > Contacts getContacts(); > > @Get > @HttpResource(location="/contacts/{id}") > Contact getContact(GetContact params); > > } > > public class GetContact { > > String id; > > public String getId() { > return id; > } > > public void setId(String id) { > this.id = id; > } > > } > > >
