How to invoke acceptRepresent in GET

2009-04-22 Thread Rick
Hi, I'm fetchin the input from form in accpetRepresent method then processing the details from database then sending the repsonse back in XML. This is the POST implementation. Now I want to do the same stuff for GET operation as well. How can I do it without replicating this code

Re: CRUD Items pattern

2009-04-22 Thread Tim Peierls
The Restlet introductory material is excellent but it could spend more time emphasizing that Resource classes are not (usually) the domain objects but rather the means for mapping the RESTful world into domain objects. If that mapping is similar across several domain types, as Rob says is often

Errors regarding entities in 304 responses

2009-04-22 Thread Nicholas Brown
I'm seeing errors in my logs whenever I return a 304 (not modified response) that have the following message: Responses with a 304 (Not modified) status can\'t have an entity. Only adding entity headers for resource... I've confirmed that my resource is not returning an entity, in fact it looks

Re: How to Fetch Request XML in Java Restlet

2009-04-22 Thread Jose Javier García Zornoza
I'll tell you what I'm doing, if somebody knows about a better aproach, please, tell something. With this code you can read and write xml with a GWT client and with a Restlet Resource: Client: import org.restlet.gwt.Callback; import org.restlet.gwt.Client; import

Re: How to Fetch Request XML in Java Restlet

2009-04-22 Thread Rob Heittman
This looks quite nice, good example! 2009/4/21 Jose Javier García Zornoza jgzorn...@gmail.com I'll tell you what I'm doing, if somebody knows about a better aproach, please, tell something. --

Best Practice regarding root/home page of web service

2009-04-22 Thread Simon Earnshaw
At the root of my web service there is no resource attached - so it just returns a 404 error in the browser - nothing is returned from the GET response - what would you commonly have at the root of your web application - a nice HTML human readable page explaining that you are at the home of the

At the root of my webservice - what's best practice

2009-04-22 Thread webpost
At the root of my web service there is no resource attached - so it just returns a 404 error - nothing is returned from the GET response - what would you commonly have at the root of your web application - a nice HTML human readable page explaining that you are at the home of the webservice and

Re: Distributed Observer Pattern

2009-04-22 Thread Stephan Koops
Hi, in the REST architecture style this is not allowed, because the server holds no state between requests. You could model the notifications as part of your business logic. Than it is fine with Restlet. There was an extension for Restlet proposed by Rohit Khare, which allows nearly exactly

Setting WWW-Authenticate Header with a 401 Response

2009-04-22 Thread John Prystash
Hello, I'm extending Guard (Restlet 1.1.1) and would like to make sure the WWW-Authenticate header back in the Response. I was wondering if someone could recommend a place in my extension that I can override to set the header. I believe the header is added with setChallengeRequest() but I