You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Al Maw <wi...@almaw.com> on 2007/07/25 14:49:28 UTC
wicket:interface, etc. in generated URLs
Hi folks,
Although some people don't really care what their URLs look like, lots
of people do.
If you use UrlCompressingWebCodingStrategy you can get the actual
parameter values for interface/behaviour/etc. URLs looking pretty small
and inoffensive.
But the name is still something large, like "wicket:interface". I'm
wondering if for 1.3 we could replace that with just:
wicket:interface --> w:i
wicket:behaviourId --> w:b
wicket:bookmarkablePage --> w:p
wicket:pageMapName --> w:m
It'd make the URLs shorter and not really any less comprehensible (this
stuff only really means anything to people who understand the internals
anyway).
It'd make things very marginally quicker (less string matching).
In short, I can't really see any disadvantage to it, other than that it
will break any existing bookmarks to non-mounted pages. I'm pretty sure
that the upgrade from 1.2 to 1.3 breaks these anyway.
It's a trivial fix (just update the constants in
WebRequestCodingStrategy and a bunch of expected unit test results).
What do people think?
Regards,
Al
--
Alastair Maw
Wicket-biased blog at http://herebebeasties.com
Re: wicket:interface, etc. in generated URLs
Posted by Eelco Hillenius <ee...@gmail.com>.
On 7/25/07, Al Maw <wi...@almaw.com> wrote:
> Hi folks,
>
> Although some people don't really care what their URLs look like, lots
> of people do.
>
> If you use UrlCompressingWebCodingStrategy you can get the actual
> parameter values for interface/behaviour/etc. URLs looking pretty small
> and inoffensive.
>
> But the name is still something large, like "wicket:interface". I'm
> wondering if for 1.3 we could replace that with just:
>
> wicket:interface --> w:i
> wicket:behaviourId --> w:b
> wicket:bookmarkablePage --> w:p
> wicket:pageMapName --> w:m
>
> It'd make the URLs shorter and not really any less comprehensible (this
> stuff only really means anything to people who understand the internals
> anyway).
>
> It'd make things very marginally quicker (less string matching).
>
> In short, I can't really see any disadvantage to it, other than that it
> will break any existing bookmarks to non-mounted pages. I'm pretty sure
> that the upgrade from 1.2 to 1.3 breaks these anyway.
>
> It's a trivial fix (just update the constants in
> WebRequestCodingStrategy and a bunch of expected unit test results).
>
> What do people think?
+1
Eelco
Re: wicket:interface, etc. in generated URLs
Posted by Johan Compagner <jc...@gmail.com>.
that would be even better
or make a Jira issue with the things discussed in this thread
then i will look at asap.
Currently to busy debugging those stupid browsers :(
johan
On Feb 13, 2008 11:31 AM, Serge! <ne...@mail.ru> wrote:
>
> Hi,
>
> Are there any news or plans to implement it?
> Or maybe you just need someone to contribute a patch?
>
> Sergey.
> --
> View this message in context:
> http://www.nabble.com/wicket%3Ainterface%2C-etc.-in-generated-URLs-tp11782012p15453486.html
> Sent from the Wicket - Dev mailing list archive at Nabble.com<http://nabble.com/>
> .
>
>
Re: wicket:interface, etc. in generated URLs
Posted by Serge! <ne...@mail.ru>.
Hi,
Are there any news or plans to implement it?
Or maybe you just need someone to contribute a patch?
Sergey.
--
View this message in context: http://www.nabble.com/wicket%3Ainterface%2C-etc.-in-generated-URLs-tp11782012p15453486.html
Sent from the Wicket - Dev mailing list archive at Nabble.com.
Re: wicket:interface, etc. in generated URLs
Posted by Igor Vaynberg <ig...@gmail.com>.
just waiting for you to check it in johan!
-igor
On 10/3/07, Johan Compagner <jc...@gmail.com> wrote:
>
> there where a lot of +1
> are we going to change this?
> Or better let it be configureable?
>
> johan
>
>
>
> On 10/3/07, Serge! <ne...@mail.ru> wrote:
> >
> >
> > +1
> > Sounds like an important feature. We tried to get rid of wicket:xxx
> meat,
> > and we ended up copy-pasting UrlCompressingWebRequestProcessor. However,
> > stateless forms still provide bad URLs (and URL compression does not
> work
> > for them at all). Form URLs will not be easy to fix, as some encoding
> > stuff
> > is done inside RequestTarget itself. Hacking this looks even more ugly
> > now.
> > Of course we may go ahead with just patching Wicket sources...
> > Regards,
> > Sergey.
> >
> >
> > Al Maw wrote:
> > >
> > > Hi folks,
> > >
> > > Although some people don't really care what their URLs look like, lots
> > > of people do.
> > >
> > > If you use UrlCompressingWebCodingStrategy you can get the actual
> > > parameter values for interface/behaviour/etc. URLs looking pretty
> small
> > > and inoffensive.
> > >
> > > But the name is still something large, like "wicket:interface". I'm
> > > wondering if for 1.3 we could replace that with just:
> > >
> > > wicket:interface --> w:i
> > > wicket:behaviourId --> w:b
> > > wicket:bookmarkablePage --> w:p
> > > wicket:pageMapName --> w:m
> > >
> > > It'd make the URLs shorter and not really any less comprehensible
> (this
> > > stuff only really means anything to people who understand the
> internals
> > > anyway).
> > >
> > > It'd make things very marginally quicker (less string matching).
> > >
> > > In short, I can't really see any disadvantage to it, other than that
> it
> > > will break any existing bookmarks to non-mounted pages. I'm pretty
> sure
> > > that the upgrade from 1.2 to 1.3 breaks these anyway.
> > >
> > > It's a trivial fix (just update the constants in
> > > WebRequestCodingStrategy and a bunch of expected unit test results).
> > >
> > > What do people think?
> > >
> > > Regards,
> > >
> > > Al
> > >
> > > --
> > > Alastair Maw
> > > Wicket-biased blog at http://herebebeasties.com
> > >
> > >
> >
> > --
> > View this message in context:
> >
> http://www.nabble.com/wicket%3Ainterface%2C-etc.-in-generated-URLs-tf4142021.html#a13027542
> > Sent from the Wicket - Dev mailing list archive at Nabble.com.
> >
> >
>
Re: wicket:interface, etc. in generated URLs
Posted by Johan Compagner <jc...@gmail.com>.
there where a lot of +1
are we going to change this?
Or better let it be configureable?
johan
On 10/3/07, Serge! <ne...@mail.ru> wrote:
>
>
> +1
> Sounds like an important feature. We tried to get rid of wicket:xxx meat,
> and we ended up copy-pasting UrlCompressingWebRequestProcessor. However,
> stateless forms still provide bad URLs (and URL compression does not work
> for them at all). Form URLs will not be easy to fix, as some encoding
> stuff
> is done inside RequestTarget itself. Hacking this looks even more ugly
> now.
> Of course we may go ahead with just patching Wicket sources...
> Regards,
> Sergey.
>
>
> Al Maw wrote:
> >
> > Hi folks,
> >
> > Although some people don't really care what their URLs look like, lots
> > of people do.
> >
> > If you use UrlCompressingWebCodingStrategy you can get the actual
> > parameter values for interface/behaviour/etc. URLs looking pretty small
> > and inoffensive.
> >
> > But the name is still something large, like "wicket:interface". I'm
> > wondering if for 1.3 we could replace that with just:
> >
> > wicket:interface --> w:i
> > wicket:behaviourId --> w:b
> > wicket:bookmarkablePage --> w:p
> > wicket:pageMapName --> w:m
> >
> > It'd make the URLs shorter and not really any less comprehensible (this
> > stuff only really means anything to people who understand the internals
> > anyway).
> >
> > It'd make things very marginally quicker (less string matching).
> >
> > In short, I can't really see any disadvantage to it, other than that it
> > will break any existing bookmarks to non-mounted pages. I'm pretty sure
> > that the upgrade from 1.2 to 1.3 breaks these anyway.
> >
> > It's a trivial fix (just update the constants in
> > WebRequestCodingStrategy and a bunch of expected unit test results).
> >
> > What do people think?
> >
> > Regards,
> >
> > Al
> >
> > --
> > Alastair Maw
> > Wicket-biased blog at http://herebebeasties.com
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/wicket%3Ainterface%2C-etc.-in-generated-URLs-tf4142021.html#a13027542
> Sent from the Wicket - Dev mailing list archive at Nabble.com.
>
>
Re: wicket:interface, etc. in generated URLs
Posted by Serge! <ne...@mail.ru>.
+1
Sounds like an important feature. We tried to get rid of wicket:xxx meat,
and we ended up copy-pasting UrlCompressingWebRequestProcessor. However,
stateless forms still provide bad URLs (and URL compression does not work
for them at all). Form URLs will not be easy to fix, as some encoding stuff
is done inside RequestTarget itself. Hacking this looks even more ugly now.
Of course we may go ahead with just patching Wicket sources...
Regards,
Sergey.
Al Maw wrote:
>
> Hi folks,
>
> Although some people don't really care what their URLs look like, lots
> of people do.
>
> If you use UrlCompressingWebCodingStrategy you can get the actual
> parameter values for interface/behaviour/etc. URLs looking pretty small
> and inoffensive.
>
> But the name is still something large, like "wicket:interface". I'm
> wondering if for 1.3 we could replace that with just:
>
> wicket:interface --> w:i
> wicket:behaviourId --> w:b
> wicket:bookmarkablePage --> w:p
> wicket:pageMapName --> w:m
>
> It'd make the URLs shorter and not really any less comprehensible (this
> stuff only really means anything to people who understand the internals
> anyway).
>
> It'd make things very marginally quicker (less string matching).
>
> In short, I can't really see any disadvantage to it, other than that it
> will break any existing bookmarks to non-mounted pages. I'm pretty sure
> that the upgrade from 1.2 to 1.3 breaks these anyway.
>
> It's a trivial fix (just update the constants in
> WebRequestCodingStrategy and a bunch of expected unit test results).
>
> What do people think?
>
> Regards,
>
> Al
>
> --
> Alastair Maw
> Wicket-biased blog at http://herebebeasties.com
>
>
--
View this message in context: http://www.nabble.com/wicket%3Ainterface%2C-etc.-in-generated-URLs-tf4142021.html#a13027542
Sent from the Wicket - Dev mailing list archive at Nabble.com.
Re: wicket:interface, etc. in generated URLs
Posted by Igor Vaynberg <ig...@gmail.com>.
+1
-igor
On 7/25/07, Gwyn Evans <gw...@gmail.com> wrote:
>
> On Wednesday, July 25, 2007, 2:01:49 PM, Johan <jc...@gmail.com>
> wrote:
>
> > but this rename is fine by me
> > except the wicket:bookmarkablePage that can be shorted like
> > w:bookmarkablePage
> > because the urls really says that it is bookmarkable
> > (and all old urls must still work so wicket:bookmarkablePage must keep
> > working)
>
> I think we'd need to support the parsing of "wicket:bookmarkablePage"
> URLs, even if new links were generated using "w:p".
>
> I'd be fine with it if that were possible, whether or not it would
> require an explicit setting to enable.
>
> /Gwyn
>
>
Re: wicket:interface, etc. in generated URLs
Posted by Gwyn Evans <gw...@gmail.com>.
On Wednesday, July 25, 2007, 2:01:49 PM, Johan <jc...@gmail.com> wrote:
> but this rename is fine by me
> except the wicket:bookmarkablePage that can be shorted like
> w:bookmarkablePage
> because the urls really says that it is bookmarkable
> (and all old urls must still work so wicket:bookmarkablePage must keep
> working)
I think we'd need to support the parsing of "wicket:bookmarkablePage"
URLs, even if new links were generated using "w:p".
I'd be fine with it if that were possible, whether or not it would
require an explicit setting to enable.
/Gwyn
Re: wicket:interface, etc. in generated URLs
Posted by Frank Bille <fr...@apache.org>.
On 7/25/07, Johan Compagner <jc...@gmail.com> wrote:
>
> i think i already proposed something like this long time ago
> But i think it was to avoid collisions in the url and more expressive
> urls?
>
> but this rename is fine by me
> except the wicket:bookmarkablePage that can be shorted like
> w:bookmarkablePage
> because the urls really says that it is bookmarkable
> (and all old urls must still work so wicket:bookmarkablePage must keep
> working)
>
> better would it in my eyes if developers could customize this them self.
> So have a settings class where they can be configured
> We (servoy) already had this for a large part but this we do by completely
> subclassing/copying WebRequestCodingStrategy
>
> so these should change:
>
> /** Name of interface target query parameter */
> public static final String NAME_SPACE = "wicket:";
>
> /** Name of interface target query parameter */
> public static final String INTERFACE_PARAMETER_NAME = NAME_SPACE +
> "interface";
>
> /** AJAX query parameter name */
> public static final String BEHAVIOR_ID_PARAMETER_NAME = NAME_SPACE +
> "behaviorId";
>
> /** Parameter name used all over the place */
> public static final String BOOKMARKABLE_PAGE_PARAMETER_NAME =
> NAME_SPACE
> + "bookmarkablePage";
>
> /** Pagemap parameter constant */
> public static final String PAGEMAP = NAME_SPACE + "pageMapName";
>
>
> into something like
>
> public static final String NAME_SPACE = Application.get
> ().getSettings().getNameSpace();
>
> But ofcourse directly that can't be done so i guess we need to push them
> from our init phase
>
+1
Much nicer solution.
Frank
Re: wicket:interface, etc. in generated URLs
Posted by Johan Compagner <jc...@gmail.com>.
i think i already proposed something like this long time ago
But i think it was to avoid collisions in the url and more expressive urls?
but this rename is fine by me
except the wicket:bookmarkablePage that can be shorted like
w:bookmarkablePage
because the urls really says that it is bookmarkable
(and all old urls must still work so wicket:bookmarkablePage must keep
working)
better would it in my eyes if developers could customize this them self.
So have a settings class where they can be configured
We (servoy) already had this for a large part but this we do by completely
subclassing/copying WebRequestCodingStrategy
so these should change:
/** Name of interface target query parameter */
public static final String NAME_SPACE = "wicket:";
/** Name of interface target query parameter */
public static final String INTERFACE_PARAMETER_NAME = NAME_SPACE +
"interface";
/** AJAX query parameter name */
public static final String BEHAVIOR_ID_PARAMETER_NAME = NAME_SPACE +
"behaviorId";
/** Parameter name used all over the place */
public static final String BOOKMARKABLE_PAGE_PARAMETER_NAME = NAME_SPACE
+ "bookmarkablePage";
/** Pagemap parameter constant */
public static final String PAGEMAP = NAME_SPACE + "pageMapName";
into something like
public static final String NAME_SPACE = Application.get
().getSettings().getNameSpace();
But ofcourse directly that can't be done so i guess we need to push them
from our init phase
johan
On 7/25/07, Al Maw <wi...@almaw.com> wrote:
>
> Hi folks,
>
> Although some people don't really care what their URLs look like, lots
> of people do.
>
> If you use UrlCompressingWebCodingStrategy you can get the actual
> parameter values for interface/behaviour/etc. URLs looking pretty small
> and inoffensive.
>
> But the name is still something large, like "wicket:interface". I'm
> wondering if for 1.3 we could replace that with just:
>
> wicket:interface --> w:i
> wicket:behaviourId --> w:b
> wicket:bookmarkablePage --> w:p
> wicket:pageMapName --> w:m
>
> It'd make the URLs shorter and not really any less comprehensible (this
> stuff only really means anything to people who understand the internals
> anyway).
>
> It'd make things very marginally quicker (less string matching).
>
> In short, I can't really see any disadvantage to it, other than that it
> will break any existing bookmarks to non-mounted pages. I'm pretty sure
> that the upgrade from 1.2 to 1.3 breaks these anyway.
>
> It's a trivial fix (just update the constants in
> WebRequestCodingStrategy and a bunch of expected unit test results).
>
> What do people think?
>
> Regards,
>
> Al
>
> --
> Alastair Maw
> Wicket-biased blog at http://herebebeasties.com
>
Re: wicket:interface, etc. in generated URLs
Posted by Martijn Dashorst <ma...@gmail.com>.
+0
You will need to fix a lot of unit tests I figure.
Martijn
On 7/25/07, Al Maw <wi...@almaw.com> wrote:
> Hi folks,
>
> Although some people don't really care what their URLs look like, lots
> of people do.
>
> If you use UrlCompressingWebCodingStrategy you can get the actual
> parameter values for interface/behaviour/etc. URLs looking pretty small
> and inoffensive.
>
> But the name is still something large, like "wicket:interface". I'm
> wondering if for 1.3 we could replace that with just:
>
> wicket:interface --> w:i
> wicket:behaviourId --> w:b
> wicket:bookmarkablePage --> w:p
> wicket:pageMapName --> w:m
>
> It'd make the URLs shorter and not really any less comprehensible (this
> stuff only really means anything to people who understand the internals
> anyway).
>
> It'd make things very marginally quicker (less string matching).
>
> In short, I can't really see any disadvantage to it, other than that it
> will break any existing bookmarks to non-mounted pages. I'm pretty sure
> that the upgrade from 1.2 to 1.3 breaks these anyway.
>
> It's a trivial fix (just update the constants in
> WebRequestCodingStrategy and a bunch of expected unit test results).
>
> What do people think?
>
> Regards,
>
> Al
>
> --
> Alastair Maw
> Wicket-biased blog at http://herebebeasties.com
>
--
Wicket joins the Apache Software Foundation as Apache Wicket
Apache Wicket 1.3.0-beta2 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta2/