<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Jun 13, 2011, at 9:18 AM, Laurens Van Houtven wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Hey!<br><br>In relation to my recent getChild problem (specifically, I want to return deferred resources from it), it has become evident that IResource just won't cut it for a number of reasons and we should probably replace the API with something else.<br>

<br>The issues we should take care of in this new API:<br><br>1. <a href="http://tm.tl/3711">http://tm.tl/3711</a> (returning deferreds from render methods)<br clear="all">2. <a href="http://tm.tl/3621">http://tm.tl/3621</a> (returning deferreds from getChild and friends)<br>

3. <a href="http://tm.tl/288">http://tm.tl/288</a> (accessing uploaded data while in progress)<br></blockquote><div><br></div><div>A new IResource means an opportunity for a new IRequest, since implementing that new interface is the easiest way for a resource to say "I require the new IRequest interface as a parameter to these methods". &nbsp;This long-standing enhancement would be a nice thing to get in there:</div><div><br></div><div><a href="http://tm.tl/1569">http://tm.tl/1569</a> (IRequest&nbsp;should have a uri&nbsp;object)</div><div><br></div><div>This ticket predates my understanding of many of the nuances of URIs, URLs, URNs, IRIs, IDNA, etc, so URLPath is probably not quite up to the job. &nbsp;<a href="http://bazaar.launchpad.net/~divmod-dev/divmod.org/trunk/view/head:/Nevow/nevow/url.py">nevow.url</a>&nbsp;is closer, but probably needs some fixing (<a href="https://code.launchpad.net/~divmod-dev/divmod.org/URL-IRI-2409">especially in the area of IRIs</a>).</div><div><br></div><div>And, for that matter, some compatibility between the request object used by Agent and the request object used by the server would be great. &nbsp;That's not necessary for a new interface, but in any design of a new interface, that should be taken into account so that it can satisfy requirements on both sides.</div><br><blockquote type="cite">If there are any missing tickets I'm forgetting about that are only fixable by breaking the interface, now would be a good time to speak up.<br>

<br>I have created a new ticket (<a href="http://tm.tl/5152">http://tm.tl/5152</a>) for the new interface using an integration branch that addresses the issues in the individual tickets on a new interface as Glyph proposed. I've also commented on #3711 to say that it just won't work that way and that we need a new interface, referring them to the new ticket number.<br>

<br>What should the migration plan look like? At least from the code point of view, exarkun has already partially answered this question: <a href="http://twistedmatrix.com/trac/ticket/288#comment:31">http://twistedmatrix.com/trac/ticket/288#comment:31</a><br>

<br><br><br>cheers<div>lvh</div><br>
_______________________________________________<br>Twisted-Python mailing list<br><a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python<br></blockquote></div><br></body></html>