Hello all,

I'm wondering what a best practice would be for the following usage:

I have an application that has a configuration interface that allows
configurations to be POSTED to it. To get the current configuration, the
requestor simply does a GET on the same URI: E.g.

GET /configuration -> textual representation of current config
POST /configuration -> input textual representation of configuration changes

The configuration includes connection configuration information for remote
databases.  The users would now like to be able to perform a test of the
database configuration information prior to actually saving the configuration
(posting to the above URL).  The way which I see as the easiest to do this is to
allow a post to a configuration test url (e.g. /configuration/test) with the
configuration parameters that should be used for a test and then use the
response to get the result of the test with the posted content.  However,
looking at the restlet API, I don't see how I can return the results of the POST
in the response to the request. I could store the test parameters and then
return the results if the client did a subsequent GET on the URL, but this seems
sub-ideal with room for transactional corruption.

What is the best way to accomplish this in a RESTful way that can actually be
done in the Restlet API.  I plan on moving to 1.1 with this release.

Thanks,
Travis



Reply via email to