[Twisted-web] fragments with child lookup

Manlio Perillo manlio_perillo at libero.it
Thu Oct 12 12:30:18 CDT 2006


L. Daniel Burr ha scritto:
> [...]
>
> Ok, first things first.  The reason I hate "template per segment" designs
> is the same reason that I hate Zope acquisition.  They both suffer from
> the same illness, which is complexity. Take the following URL:
> 
> http://myhost.com/foo/bar/baz
> 
> This URL identifies a resource, and when some client requests this URL,
> a representation of that resource will be sent to the client.  In order
> to render this representation in "template-per-segment" design, I have
> to first traverse the tree and render "foo", then "bar" then lastly,
> "baz".  This enforces a needless dependency upon containment.  Why does
> the resource living at "baz" have to depend upon "foo" and "bar" in
> order to produce a representation of "baz"?  

Because it is a child of foo and bar.

It is thanks to "template per segment" design, that guard can do its job...

And, IMHO, guard is a great semplification for handling authentication.






Regards  Manlio Perillo



More information about the Twisted-web mailing list