Hi Felix,

I agree with the suggested changes, but see comments inline:

On Tue, May 6, 2008 at 11:36 AM, Felix Meschberger <[EMAIL PROTECTED]> wrote:

> ... Special treatment for resource creation happens if the path is
>  terminated by a slash (as proposed by Carsten and Roy in earlier
>  messages) or by a slash-star (/*, like currently). Maybe we should
>  deprecate the /* behaviour and just support the trailing slash behaviour
>  for consistency with the general perception....

I'd like to keep the current semantics of the "magic star" resource,
based on the following use case.

When creating a simple CRUD application, one usually has to provide
different client forms for the "create" and "update" operations.

The magic star makes this more consistent: to create a new resource,
you simply request (say) *.edit.html, where you would request
foo.edit.html to edit the existing "foo" resource.

If Sling (like currently) allows a POST to *.edit.html to create a new
resource, the "create" operation can be programmed exactly like the
"update" operation, the only differences being that it operates on the
"magic star" resource, and that when loading the form fields one
initially gets no values.

I think this is useful, the code is easy to isolate within the
SlingPostServlet, and fully testable. The only downside is that it's
slightly unusual - like the Ford model T when it first came out, so
that's not necessarily a bad sign ;-)

-Bertrand

Reply via email to