Hello Carsten, answering between lines: On Sun, Dec 13, 2009 at 4:18 AM, Carsten Lohmann <c_lohm...@gmx.net> wrote: > Hello Fabian, > > which resource is supposed to match the > http://localhost:9000/workspaces/W1 > request? > > From looking at your source code, I guess that you intended this Route to > match: > wrouter.attach("/{wksp}", WorkspaceResource.class); >
Yes, the resource handling requests to that URL is indeed WorkspaceResource > But that doesn't work because the new default matching mode for Routers (as > of M6) is > Template.MODE_EQUALS and not Template.MODE_STARTS_WITH any more. > > So, in order to retain the old behaviour, you have to set: > wrouter.setDefaultMatchingMode(Template.MODE_STARTS_WITH); > (for the other Routers as well). > > Another thing is, that the new default routingMode is FIRST instead of BEST. > Seeing the order in which you attach the Resources > > wrouter.attach("/{wksp}", WorkspaceResource.class); > wrouter.attach("/{wksp}/content/{langOrFile}/properties", > PropertiesResource.class); > > I guess that the PropertiesResource cannot be reached with this setting. > So either set > wrouter.setRoutingMode(Router.MODE_BEST_MATCH); > or put the line > wrouter.attach("/{wksp}", WorkspaceResource.class); > below the other /{wksp}/* lines. > I've set MODE_STARTS_WITH and MODE_BEST_MATCH for the 3 routers I have and it now works as usual (or so it seems with the quick tests I've done), thanks a lot! > Cheers, > Carsten > Thanks, bye. -- Fabián Mandelbaum IS Engineer ------------------------------------------------------ http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2430153