URL protocol versioning in Tapestry 5

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

URL protocol versioning in Tapestry 5

abangkis
Hi all, i would like to create some kind of URL protocol versioning in my
apps. The URL generated would be something like this

http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam

I'm thinking between of using Service Advisor or RequestFilter to handle the
case. Can anyone advise me what is the advantage of using one to the other
?

Treating the version as the first param for each method would also work. But
i think the two other alternative above will give a better an cleaner
approach.


Thanks a lot

Abangkis

--
http://www.mreunion-labs.net/
twitter : @mreunionlabs
blog : mreunion.wordpress.com
Follow our android survey at :
http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

abangkis
Hello, i try to rephrase my question. If i click an action link in my page,
the generated URL would look like this in T5.

http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3<http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam>

My question. Is there any way i can do this, without have to include
protocol_version as the first parameter for each method ?


Thanks In Advance

Abangkis

<http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam>

On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:

> Hi all, i would like to create some kind of URL protocol versioning in my
> apps. The URL generated would be something like this
>
>
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
>
> I'm thinking between of using Service Advisor or RequestFilter to handle
> the case. Can anyone advise me what is the advantage of using one to the
> other ?
>
> Treating the version as the first param for each method would also work.
> But i think the two other alternative above will give a better an cleaner
> approach.
>
>
> Thanks a lot
>
> Abangkis
>
> --
> http://www.mreunion-labs.net/
> twitter : @mreunionlabs
> blog : mreunion.wordpress.com
> Follow our android survey at :
> http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>



--
http://www.mreunion-labs.net/
twitter : @mreunionlabs
blog : mreunion.wordpress.com
Follow our android survey at :
http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

Igor Drobiazko
What do you mean by protocol version? You need to be more precise if you
need help. Usually posting some code helps to help you.

On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]> wrote:

> Hello, i try to rephrase my question. If i click an action link in my page,
> the generated URL would look like this in T5.
>
>
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> <
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >
>
> My question. Is there any way i can do this, without have to include
> protocol_version as the first parameter for each method ?
>
>
> Thanks In Advance
>
> Abangkis
>
> <
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >
>
> On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:
>
> > Hi all, i would like to create some kind of URL protocol versioning in my
> > apps. The URL generated would be something like this
> >
> >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >
> > I'm thinking between of using Service Advisor or RequestFilter to handle
> > the case. Can anyone advise me what is the advantage of using one to the
> > other ?
> >
> > Treating the version as the first param for each method would also work.
> > But i think the two other alternative above will give a better an cleaner
> > approach.
> >
> >
> > Thanks a lot
> >
> > Abangkis
> >
> > --
> > http://www.mreunion-labs.net/
> > twitter : @mreunionlabs
> > blog : mreunion.wordpress.com
> > Follow our android survey at :
> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >
>
>
>
> --
> http://www.mreunion-labs.net/
> twitter : @mreunionlabs
> blog : mreunion.wordpress.com
> Follow our android survey at :
> http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>



--
Best regards,

Igor Drobiazko
http://tapestry5.de
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

abangkis
Hi igor thanks for the reply. The protocol_version is just a string. For
example,

http://www.myserver.com/myapps/page_name.method_name/1.0/param2/param3<http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3>

<http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3>This
url will be accessed by a mobile client. So if the url in the server is
changed to :

http://www.myserver.com/myapps/page_name.method_name/2.0/param2/param3<http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3>

And the client accessed it using the first URL. Then the server would know
and give the appropriate response (for example notified a newer version of
the client apps).

I don't have any code at the moment, since I'm just planning to implement
it. I know that if I use ActionLink i can do this, the protocol_version
would just be another parameter in the onActionFromXXX method. But that
means i would have to write the same code for each of the method that is
accessed by the mobile client. I'm wondering if i could do this only in one
place. I hope my intention is clear enough.



Cheers

Abangkis

On Wed, Mar 9, 2011 at 7:46 PM, Igor Drobiazko <[hidden email]>wrote:

> What do you mean by protocol version? You need to be more precise if you
> need help. Usually posting some code helps to help you.
>
> On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]> wrote:
>
> > Hello, i try to rephrase my question. If i click an action link in my
> page,
> > the generated URL would look like this in T5.
> >
> >
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > <
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > >
> >
> > My question. Is there any way i can do this, without have to include
> > protocol_version as the first parameter for each method ?
> >
> >
> > Thanks In Advance
> >
> > Abangkis
> >
> > <
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > >
> >
> > On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:
> >
> > > Hi all, i would like to create some kind of URL protocol versioning in
> my
> > > apps. The URL generated would be something like this
> > >
> > >
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > >
> > > I'm thinking between of using Service Advisor or RequestFilter to
> handle
> > > the case. Can anyone advise me what is the advantage of using one to
> the
> > > other ?
> > >
> > > Treating the version as the first param for each method would also
> work.
> > > But i think the two other alternative above will give a better an
> cleaner
> > > approach.
> > >
> > >
> > > Thanks a lot
> > >
> > > Abangkis
> > >
> > > --
> > > http://www.mreunion-labs.net/
> > > twitter : @mreunionlabs
> > > blog : mreunion.wordpress.com
> > > Follow our android survey at :
> > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> > >
> >
> >
> >
> > --
> > http://www.mreunion-labs.net/
> > twitter : @mreunionlabs
> > blog : mreunion.wordpress.com
> > Follow our android survey at :
> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >
>
>
>
> --
> Best regards,
>
> Igor Drobiazko
> http://tapestry5.de
>



--
http://www.mreunion-labs.net/
twitter : @mreunionlabs
blog : mreunion.wordpress.com
Follow our android survey at :
http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

Igor Drobiazko
You can contribute your own ComponentEventLinkTransformer:

http://tapestry.apache.org/tapestry5.2-dev/apidocs/org/apache/tapestry5/services/linktransform/ComponentEventLinkTransformer.html

On Wed, Mar 9, 2011 at 2:03 PM, abangkis <[hidden email]> wrote:

> Hi igor thanks for the reply. The protocol_version is just a string. For
> example,
>
> http://www.myserver.com/myapps/page_name.method_name/1.0/param2/param3<
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >
>
> <
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >This
> url will be accessed by a mobile client. So if the url in the server is
> changed to :
>
> http://www.myserver.com/myapps/page_name.method_name/2.0/param2/param3<
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >
>
> And the client accessed it using the first URL. Then the server would know
> and give the appropriate response (for example notified a newer version of
> the client apps).
>
> I don't have any code at the moment, since I'm just planning to implement
> it. I know that if I use ActionLink i can do this, the protocol_version
> would just be another parameter in the onActionFromXXX method. But that
> means i would have to write the same code for each of the method that is
> accessed by the mobile client. I'm wondering if i could do this only in one
> place. I hope my intention is clear enough.
>
>
>
> Cheers
>
> Abangkis
>
> On Wed, Mar 9, 2011 at 7:46 PM, Igor Drobiazko <[hidden email]
> >wrote:
>
> > What do you mean by protocol version? You need to be more precise if you
> > need help. Usually posting some code helps to help you.
> >
> > On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]> wrote:
> >
> > > Hello, i try to rephrase my question. If i click an action link in my
> > page,
> > > the generated URL would look like this in T5.
> > >
> > >
> > >
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > > <
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > >
> > >
> > > My question. Is there any way i can do this, without have to include
> > > protocol_version as the first parameter for each method ?
> > >
> > >
> > > Thanks In Advance
> > >
> > > Abangkis
> > >
> > > <
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > >
> > >
> > > On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:
> > >
> > > > Hi all, i would like to create some kind of URL protocol versioning
> in
> > my
> > > > apps. The URL generated would be something like this
> > > >
> > > >
> > > >
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > >
> > > > I'm thinking between of using Service Advisor or RequestFilter to
> > handle
> > > > the case. Can anyone advise me what is the advantage of using one to
> > the
> > > > other ?
> > > >
> > > > Treating the version as the first param for each method would also
> > work.
> > > > But i think the two other alternative above will give a better an
> > cleaner
> > > > approach.
> > > >
> > > >
> > > > Thanks a lot
> > > >
> > > > Abangkis
> > > >
> > > > --
> > > > http://www.mreunion-labs.net/
> > > > twitter : @mreunionlabs
> > > > blog : mreunion.wordpress.com
> > > > Follow our android survey at :
> > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> > > >
> > >
> > >
> > >
> > > --
> > > http://www.mreunion-labs.net/
> > > twitter : @mreunionlabs
> > > blog : mreunion.wordpress.com
> > > Follow our android survey at :
> > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> > >
> >
> >
> >
> > --
> > Best regards,
> >
> > Igor Drobiazko
> > http://tapestry5.de
> >
>
>
>
> --
> http://www.mreunion-labs.net/
> twitter : @mreunionlabs
> blog : mreunion.wordpress.com
> Follow our android survey at :
> http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>



--
Best regards,

Igor Drobiazko
http://tapestry5.de
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

abangkis
Great :D Thanks a lot igor. I know there's an easier way to do this in
tapestry :)

On Wed, Mar 9, 2011 at 8:22 PM, Igor Drobiazko <[hidden email]>wrote:

> You can contribute your own ComponentEventLinkTransformer:
>
>
> http://tapestry.apache.org/tapestry5.2-dev/apidocs/org/apache/tapestry5/services/linktransform/ComponentEventLinkTransformer.html
>
> On Wed, Mar 9, 2011 at 2:03 PM, abangkis <[hidden email]> wrote:
>
> > Hi igor thanks for the reply. The protocol_version is just a string. For
> > example,
> >
> > http://www.myserver.com/myapps/page_name.method_name/1.0/param2/param3<
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > >
> >
> > <
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > >This
> > url will be accessed by a mobile client. So if the url in the server is
> > changed to :
> >
> > http://www.myserver.com/myapps/page_name.method_name/2.0/param2/param3<
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > >
> >
> > And the client accessed it using the first URL. Then the server would
> know
> > and give the appropriate response (for example notified a newer version
> of
> > the client apps).
> >
> > I don't have any code at the moment, since I'm just planning to implement
> > it. I know that if I use ActionLink i can do this, the protocol_version
> > would just be another parameter in the onActionFromXXX method. But that
> > means i would have to write the same code for each of the method that is
> > accessed by the mobile client. I'm wondering if i could do this only in
> one
> > place. I hope my intention is clear enough.
> >
> >
> >
> > Cheers
> >
> > Abangkis
> >
> > On Wed, Mar 9, 2011 at 7:46 PM, Igor Drobiazko <[hidden email]
> > >wrote:
> >
> > > What do you mean by protocol version? You need to be more precise if
> you
> > > need help. Usually posting some code helps to help you.
> > >
> > > On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]> wrote:
> > >
> > > > Hello, i try to rephrase my question. If i click an action link in my
> > > page,
> > > > the generated URL would look like this in T5.
> > > >
> > > >
> > > >
> > >
> >
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> > > > <
> > > >
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > > >
> > > >
> > > > My question. Is there any way i can do this, without have to include
> > > > protocol_version as the first parameter for each method ?
> > > >
> > > >
> > > > Thanks In Advance
> > > >
> > > > Abangkis
> > > >
> > > > <
> > > >
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > > >
> > > >
> > > > On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:
> > > >
> > > > > Hi all, i would like to create some kind of URL protocol versioning
> > in
> > > my
> > > > > apps. The URL generated would be something like this
> > > > >
> > > > >
> > > > >
> > > >
> > >
> >
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> > > > >
> > > > > I'm thinking between of using Service Advisor or RequestFilter to
> > > handle
> > > > > the case. Can anyone advise me what is the advantage of using one
> to
> > > the
> > > > > other ?
> > > > >
> > > > > Treating the version as the first param for each method would also
> > > work.
> > > > > But i think the two other alternative above will give a better an
> > > cleaner
> > > > > approach.
> > > > >
> > > > >
> > > > > Thanks a lot
> > > > >
> > > > > Abangkis
> > > > >
> > > > > --
> > > > > http://www.mreunion-labs.net/
> > > > > twitter : @mreunionlabs
> > > > > blog : mreunion.wordpress.com
> > > > > Follow our android survey at :
> > > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > http://www.mreunion-labs.net/
> > > > twitter : @mreunionlabs
> > > > blog : mreunion.wordpress.com
> > > > Follow our android survey at :
> > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> > > >
> > >
> > >
> > >
> > > --
> > > Best regards,
> > >
> > > Igor Drobiazko
> > > http://tapestry5.de
> > >
> >
> >
> >
> > --
> > http://www.mreunion-labs.net/
> > twitter : @mreunionlabs
> > blog : mreunion.wordpress.com
> > Follow our android survey at :
> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >
>
>
>
> --
> Best regards,
>
> Igor Drobiazko
> http://tapestry5.de
>



--
http://www.mreunion-labs.net/
twitter : @mreunionlabs
blog : mreunion.wordpress.com
Follow our android survey at :
http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

Howard Lewis Ship
The philosophy in Tapestry is that action links are transient ...
their value is dependent on the exact structure of the page which can
change between deployments ... and that's OK because component event
links (ActionLink is a specific application of a component event
request) are NOT bookmarkable; because of Tapestry's
redirect-after-event strategy, the only URLs that a user will see in
the browser's URL field will be a page render request URLs, and
Tapestry has facilities (generally, advanced usage of the activate and
passivate events) to keep those stable even when underlying
implementation of the pages evolve.

On Wed, Mar 9, 2011 at 5:39 AM, abangkis <[hidden email]> wrote:

> Great :D Thanks a lot igor. I know there's an easier way to do this in
> tapestry :)
>
> On Wed, Mar 9, 2011 at 8:22 PM, Igor Drobiazko <[hidden email]>wrote:
>
>> You can contribute your own ComponentEventLinkTransformer:
>>
>>
>> http://tapestry.apache.org/tapestry5.2-dev/apidocs/org/apache/tapestry5/services/linktransform/ComponentEventLinkTransformer.html
>>
>> On Wed, Mar 9, 2011 at 2:03 PM, abangkis <[hidden email]> wrote:
>>
>> > Hi igor thanks for the reply. The protocol_version is just a string. For
>> > example,
>> >
>> > http://www.myserver.com/myapps/page_name.method_name/1.0/param2/param3<
>> >
>> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
>> > >
>> >
>> > <
>> >
>> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
>> > >This
>> > url will be accessed by a mobile client. So if the url in the server is
>> > changed to :
>> >
>> > http://www.myserver.com/myapps/page_name.method_name/2.0/param2/param3<
>> >
>> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
>> > >
>> >
>> > And the client accessed it using the first URL. Then the server would
>> know
>> > and give the appropriate response (for example notified a newer version
>> of
>> > the client apps).
>> >
>> > I don't have any code at the moment, since I'm just planning to implement
>> > it. I know that if I use ActionLink i can do this, the protocol_version
>> > would just be another parameter in the onActionFromXXX method. But that
>> > means i would have to write the same code for each of the method that is
>> > accessed by the mobile client. I'm wondering if i could do this only in
>> one
>> > place. I hope my intention is clear enough.
>> >
>> >
>> >
>> > Cheers
>> >
>> > Abangkis
>> >
>> > On Wed, Mar 9, 2011 at 7:46 PM, Igor Drobiazko <[hidden email]
>> > >wrote:
>> >
>> > > What do you mean by protocol version? You need to be more precise if
>> you
>> > > need help. Usually posting some code helps to help you.
>> > >
>> > > On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]> wrote:
>> > >
>> > > > Hello, i try to rephrase my question. If i click an action link in my
>> > > page,
>> > > > the generated URL would look like this in T5.
>> > > >
>> > > >
>> > > >
>> > >
>> >
>> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
>> > > > <
>> > > >
>> > >
>> >
>> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
>> > > > >
>> > > >
>> > > > My question. Is there any way i can do this, without have to include
>> > > > protocol_version as the first parameter for each method ?
>> > > >
>> > > >
>> > > > Thanks In Advance
>> > > >
>> > > > Abangkis
>> > > >
>> > > > <
>> > > >
>> > >
>> >
>> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
>> > > > >
>> > > >
>> > > > On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]> wrote:
>> > > >
>> > > > > Hi all, i would like to create some kind of URL protocol versioning
>> > in
>> > > my
>> > > > > apps. The URL generated would be something like this
>> > > > >
>> > > > >
>> > > > >
>> > > >
>> > >
>> >
>> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
>> > > > >
>> > > > > I'm thinking between of using Service Advisor or RequestFilter to
>> > > handle
>> > > > > the case. Can anyone advise me what is the advantage of using one
>> to
>> > > the
>> > > > > other ?
>> > > > >
>> > > > > Treating the version as the first param for each method would also
>> > > work.
>> > > > > But i think the two other alternative above will give a better an
>> > > cleaner
>> > > > > approach.
>> > > > >
>> > > > >
>> > > > > Thanks a lot
>> > > > >
>> > > > > Abangkis
>> > > > >
>> > > > > --
>> > > > > http://www.mreunion-labs.net/
>> > > > > twitter : @mreunionlabs
>> > > > > blog : mreunion.wordpress.com
>> > > > > Follow our android survey at :
>> > > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>> > > > >
>> > > >
>> > > >
>> > > >
>> > > > --
>> > > > http://www.mreunion-labs.net/
>> > > > twitter : @mreunionlabs
>> > > > blog : mreunion.wordpress.com
>> > > > Follow our android survey at :
>> > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>> > > >
>> > >
>> > >
>> > >
>> > > --
>> > > Best regards,
>> > >
>> > > Igor Drobiazko
>> > > http://tapestry5.de
>> > >
>> >
>> >
>> >
>> > --
>> > http://www.mreunion-labs.net/
>> > twitter : @mreunionlabs
>> > blog : mreunion.wordpress.com
>> > Follow our android survey at :
>> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>> >
>>
>>
>>
>> --
>> Best regards,
>>
>> Igor Drobiazko
>> http://tapestry5.de
>>
>
>
>
> --
> http://www.mreunion-labs.net/
> twitter : @mreunionlabs
> blog : mreunion.wordpress.com
> Follow our android survey at :
> http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
>



--
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: URL protocol versioning in Tapestry 5

abangkis
Hi Howard. Thanks a lot for your explanation.

On Thu, Mar 10, 2011 at 1:23 AM, Howard Lewis Ship <[hidden email]> wrote:

> The philosophy in Tapestry is that action links are transient ...
> their value is dependent on the exact structure of the page which can
> change between deployments ... and that's OK because component event
> links (ActionLink is a specific application of a component event
> request) are NOT bookmarkable; because of Tapestry's
> redirect-after-event strategy, the only URLs that a user will see in
> the browser's URL field will be a page render request URLs, and
> Tapestry has facilities (generally, advanced usage of the activate and
> passivate events) to keep those stable even when underlying
> implementation of the pages evolve.
>
> On Wed, Mar 9, 2011 at 5:39 AM, abangkis <[hidden email]> wrote:
> > Great :D Thanks a lot igor. I know there's an easier way to do this in
> > tapestry :)
> >
> > On Wed, Mar 9, 2011 at 8:22 PM, Igor Drobiazko <[hidden email]
> >wrote:
> >
> >> You can contribute your own ComponentEventLinkTransformer:
> >>
> >>
> >>
> http://tapestry.apache.org/tapestry5.2-dev/apidocs/org/apache/tapestry5/services/linktransform/ComponentEventLinkTransformer.html
> >>
> >> On Wed, Mar 9, 2011 at 2:03 PM, abangkis <[hidden email]> wrote:
> >>
> >> > Hi igor thanks for the reply. The protocol_version is just a string.
> For
> >> > example,
> >> >
> >> >
> http://www.myserver.com/myapps/page_name.method_name/1.0/param2/param3<
> >> >
> >>
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >> > >
> >> >
> >> > <
> >> >
> >>
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >> > >This
> >> > url will be accessed by a mobile client. So if the url in the server
> is
> >> > changed to :
> >> >
> >> >
> http://www.myserver.com/myapps/page_name.method_name/2.0/param2/param3<
> >> >
> >>
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >> > >
> >> >
> >> > And the client accessed it using the first URL. Then the server would
> >> know
> >> > and give the appropriate response (for example notified a newer
> version
> >> of
> >> > the client apps).
> >> >
> >> > I don't have any code at the moment, since I'm just planning to
> implement
> >> > it. I know that if I use ActionLink i can do this, the
> protocol_version
> >> > would just be another parameter in the onActionFromXXX method. But
> that
> >> > means i would have to write the same code for each of the method that
> is
> >> > accessed by the mobile client. I'm wondering if i could do this only
> in
> >> one
> >> > place. I hope my intention is clear enough.
> >> >
> >> >
> >> >
> >> > Cheers
> >> >
> >> > Abangkis
> >> >
> >> > On Wed, Mar 9, 2011 at 7:46 PM, Igor Drobiazko <
> [hidden email]
> >> > >wrote:
> >> >
> >> > > What do you mean by protocol version? You need to be more precise if
> >> you
> >> > > need help. Usually posting some code helps to help you.
> >> > >
> >> > > On Wed, Mar 9, 2011 at 12:51 PM, abangkis <[hidden email]>
> wrote:
> >> > >
> >> > > > Hello, i try to rephrase my question. If i click an action link in
> my
> >> > > page,
> >> > > > the generated URL would look like this in T5.
> >> > > >
> >> > > >
> >> > > >
> >> > >
> >> >
> >>
> http://www.myserver.com/myapps/page_name.method_name/protocol_version/param2/param3
> >> > > > <
> >> > > >
> >> > >
> >> >
> >>
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >> > > > >
> >> > > >
> >> > > > My question. Is there any way i can do this, without have to
> include
> >> > > > protocol_version as the first parameter for each method ?
> >> > > >
> >> > > >
> >> > > > Thanks In Advance
> >> > > >
> >> > > > Abangkis
> >> > > >
> >> > > > <
> >> > > >
> >> > >
> >> >
> >>
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >> > > > >
> >> > > >
> >> > > > On Tue, Mar 8, 2011 at 2:24 PM, abangkis <[hidden email]>
> wrote:
> >> > > >
> >> > > > > Hi all, i would like to create some kind of URL protocol
> versioning
> >> > in
> >> > > my
> >> > > > > apps. The URL generated would be something like this
> >> > > > >
> >> > > > >
> >> > > > >
> >> > > >
> >> > >
> >> >
> >>
> http://www.myserver.com/myapps/page.method/protocol_version/param2/param3/moreparam
> >> > > > >
> >> > > > > I'm thinking between of using Service Advisor or RequestFilter
> to
> >> > > handle
> >> > > > > the case. Can anyone advise me what is the advantage of using
> one
> >> to
> >> > > the
> >> > > > > other ?
> >> > > > >
> >> > > > > Treating the version as the first param for each method would
> also
> >> > > work.
> >> > > > > But i think the two other alternative above will give a better
> an
> >> > > cleaner
> >> > > > > approach.
> >> > > > >
> >> > > > >
> >> > > > > Thanks a lot
> >> > > > >
> >> > > > > Abangkis
> >> > > > >
> >> > > > > --
> >> > > > > http://www.mreunion-labs.net/
> >> > > > > twitter : @mreunionlabs
> >> > > > > blog : mreunion.wordpress.com
> >> > > > > Follow our android survey at :
> >> > > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >> > > > >
> >> > > >
> >> > > >
> >> > > >
> >> > > > --
> >> > > > http://www.mreunion-labs.net/
> >> > > > twitter : @mreunionlabs
> >> > > > blog : mreunion.wordpress.com
> >> > > > Follow our android survey at :
> >> > > > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >> > > >
> >> > >
> >> > >
> >> > >
> >> > > --
> >> > > Best regards,
> >> > >
> >> > > Igor Drobiazko
> >> > > http://tapestry5.de
> >> > >
> >> >
> >> >
> >> >
> >> > --
> >> > http://www.mreunion-labs.net/
> >> > twitter : @mreunionlabs
> >> > blog : mreunion.wordpress.com
> >> > Follow our android survey at :
> >> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >> >
> >>
> >>
> >>
> >> --
> >> Best regards,
> >>
> >> Igor Drobiazko
> >> http://tapestry5.de
> >>
> >
> >
> >
> > --
> > http://www.mreunion-labs.net/
> > twitter : @mreunionlabs
> > blog : mreunion.wordpress.com
> > Follow our android survey at :
> > http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk
> >
>
>
>
> --
> Howard M. Lewis Ship
>
> Creator of Apache Tapestry
>
> The source for Tapestry training, mentoring and support. Contact me to
> learn how I can get you up and productive in Tapestry fast!
>
> (971) 678-5210
> http://howardlewisship.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>


--
http://www.mreunion-labs.net/
twitter : @mreunionlabs
blog : mreunion.wordpress.com
Follow our android survey at :
http://www.mreunion-labs.net/downloads:dlapk/MySurvey.apk