[Seaside-dev] Re: [Seaside Commits] Seaside 2.9: Seaside-RenderLoop-lr.62.mcz

Julian Fitzell jfitzell at gmail.com
Mon Mar 9 11:50:44 UTC 2009


My initial response to this change is that I don't like it and I would
like to see it reverted.

While I agree that the updateUrl: concept is kind of flawed (you can't
easily ask a tree of components to safely map their state to a flat
URL), it's purpose is to bring the user back as close as possible to
where they were if they click on a link to an expired session.

In the case of a callback url, we can't possibly know what that
expired callback would have done. But we can know (by virtue of
updateUrl:) where the user was when the the callback was generated.
Given that information we can (as Seaside has done since updateUrl:
was introduced) allow the application to build a new component tree at
that point and re-render the page. If the application doesn't want to
rebuild back to that state it could just as easily display a message
saying the session is expired or ignore the URL and generate a new
default session.

With this change, however, there is no longer any choice. Every single
callback link will result in a new default session. That sucks.

I would be more than happy to see some new mechanism for generating
friendly semantic URLs that somehow allows the callback URLs to more
accurately represent (in the case where the callback is just doing a
#show:, for example) the state that will exist after the callback.
Colin's Altitude is doing some experiments around this, for example.
But until we have a better solution, crippling the current one
entirely makes no sense to me.

Julian

On Sun, Mar 8, 2009 at 10:58 AM,
<squeak-dev-noreply at lists.squeakfoundation.org> wrote:
> Lukas Renggli uploaded a new version of Seaside-RenderLoop to project Seaside 2.9:
> http://www.squeaksource.com/Seaside29/Seaside-RenderLoop-lr.62.mcz
>
> ==================== Summary ====================
>
> Name: Seaside-RenderLoop-lr.62
> Author: lr
> Time: 8 March 2009, 10:58 am
> UUID: 9defb186-5b65-4870-9603-68548aae13ec
> Ancestors: Seaside-RenderLoop-jf.61
>
> - don't call #updateUrl: for callback URLs used in the rendering pass
>
> =============== Diff against Seaside-RenderLoop-jf.61 ===============
>
> Item was changed:
>  ----- Method: WARenderPhaseContinuation>>processRendering: (in category 'processing') -----
>  processRendering: aResponse
>        | document htmlRoot renderContext actionContinuation |
>        "Prepare the response"
>        aResponse contentType: self application contentType.
>
>        "Create objects we need"
>        document := self requestContext newDocument.
>        actionContinuation := self createActionContinuation.
>        renderContext := self createRenderContext.
>
>        "Hook objects together"
>        renderContext
>                document: document;
> +               actionUrl: (actionContinuation registerForUrl: false);
> -               actionUrl: actionContinuation registerForUrl;
>                resourceUrl: self application resourceBaseUrl.
>        actionContinuation renderContext: renderContext.
>        htmlRoot := self createHtmlRootWithContext: renderContext.
>
>        "Render"
>        document open: htmlRoot.
>        self presenter renderWithContext: renderContext.
>        document close.
>        renderContext destroy!
>
>
> _______________________________________________
> commits mailing list
> To unsubscribe, email commits-leave at lists.seaside.st
> http://lists.seaside.st/listinfo/commits
>


More information about the seaside-dev mailing list