Hi Bertrand, Am Dienstag, den 06.05.2008, 13:49 +0200 schrieb Bertrand Delacretaz: > 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.
Ah yes. I didn't remember that use case. In this case, keeping the "/*" notation is probably a good - and required - thing. But then, should we support the trailing slash case at all ? Maybe it would be a good thing for some users ? > > 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 ;-) Surely so.... But we should be careful nevertheless ;-) Regards Felix
