The factory for twisted.web.resource Resources is twisted.web.server.Site<br><br><div class="gmail_quote">On Thu, Mar 31, 2011 at 4:45 AM, Aljoša Mohorović <span dir="ltr">&lt;<a href="mailto:aljosa.mohorovic@gmail.com">aljosa.mohorovic@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">now i looking at adding an wsgi app to this setup.<br>
i&#39;m reading <a href="http://twistedmatrix.com/documents/current/web/howto/web-in-60/wsgi.html" target="_blank">http://twistedmatrix.com/documents/current/web/howto/web-in-60/wsgi.html</a><br>
but can&#39;t figure out howto get factory for wsgi if i have:<br>
<br>
===<br>
def application(environ, start_response):<br>
    start_response(&#39;200 OK&#39;, [(&#39;Content-type&#39;, &#39;text/plain&#39;)])<br>
    return [&#39;Hello, world!&#39;]<br>
resource = WSGIResource(reactor, reactor.getThreadPool(), application)<br>
===<br>
<br>
i&#39;m looking for something like &quot;reactor.listenTCP(10000,<br>
wsgi_factory)&quot; but don&#39;t know howto do it.<br>
please point me to proper docs.<br></blockquote><div><br>factory = Site(resource)<br>reactor.listenTCP(10000, factory)<br>reactor.run()<br><br>see here: <a href="http://twistedmatrix.com/documents/current/web/howto/web-in-60/dynamic-content.html">http://twistedmatrix.com/documents/current/web/howto/web-in-60/dynamic-content.html</a><br>

 </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div class="h5">thanks<br>
<br>
Aljosa<br>
<br>
_______________________________________________<br>
Twisted-Python mailing list<br>
<a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>
<a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python</a><br>
</div></div></blockquote></div><br>