Changes between Version 14 and Version 15 of WebDevelopmentWithTwisted


Ignore:
Timestamp:
03/11/11 05:11:50 (11 years ago)
Author:
washort
Comment:

goodify descriptions, remove reference to things that don't exist

Legend:

Unmodified
Added
Removed
Modified
  • WebDevelopmentWithTwisted

    v14 v15  
    11= Web Development with Twisted =
    2 
    3 Twisted has a long and checkered past in web development.  This page is a roadmap to the wilderness that the landscape of web development with Twisted has become.
    4 
    5 For an explanation of what's going on in the ''future'' of the web with Twisted, check out our [wiki:TwistedWebPlan plan for development of twisted.web].
    6 
    7 == What's Going On Around Here ==
    82
    93There are a number of packages in and around Twisted that do things with the web:
    104
    11  * [http://twistedmatrix.com/documents/current/web/ Twisted Web] provides a simple, stable resource publishing API, on top of an HTTP/1.0 server implementation with some HTTP/1.1 features.  '''Twisted Web is extremely stable.'''
    12    * Several deprecated templating toolkits included with twisted.web, such as "woven" and "twisted web widgets".  Don't use these!  They're only there for compatibility.
    13  * [wiki:TwistedWeb2 Twisted Web 2] was (emphasis past tense!) a complete re-write of [http://twistedmatrix.com/documents/current/web/ Twisted Web], with a new HTTP/1.1 implementation and a new resource publishing model.  We decided this was a mistake and development focus has shifted to porting the best parts of Twisted Web 2 back to Twisted Web where existing applications will benefit from them.
    14  * [http://divmod.org/trac/wiki/DivmodNevow Divmod Nevow] is a templating toolkit that provides its own resource model and simple application server API.  It requires Twisted, is fully integrated with the Twisted reactor, provides mechanisms for asynchronous page rendering, and an event-driven [http://en.wikipedia.org/wiki/COMET_(programming) COMET]/AJAX implementation called [http://divmod.org/trac/wiki/DivmodNevow/Athena "Nevow Athena"].  Nevow uses Twisted Web, but provides its own Request and resource model on top of it.
     5 * [http://twistedmatrix.com/documents/current/web/ Twisted Web] provides a simple, stable HTTP server, suitable for all types of web apps and web services. It provides a flexible resource publishing API, and implements HTTP 1.0 with some 1.1 features.  '''Twisted Web is extremely stable.'''
     6 * [http://divmod.org/trac/wiki/DivmodNevow Divmod Nevow] is a templating toolkit that provides its own resource model and simple application server API.  It requires Twisted, is fully integrated with the Twisted reactor, provides mechanisms for asynchronous page rendering, and an event-driven [http://en.wikipedia.org/wiki/COMET_(programming) COMET]/AJAX implementation called [http://divmod.org/trac/wiki/DivmodNevow/Athena "Nevow Athena"].  Nevow uses Twisted Web, but provides its own request objects and resource model on top of it.
    157 * [http://divmod.org/trac/wiki/DivmodMantissa Divmod Mantissa] is a full-featured multi-protocol application server, with a built-in object database, authentication model based on Twisted Cred, a capability-based security model, and many more features.  It integrates Nevow (and therefore Twisted Web) and a number of other Twisted-related technologies to provide a full-featured system.
    168
     
    2012
    2113You can always ask about these kinds of issues on the [http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web Twisted Web mailing list], but here's a cheat-sheet that you may want to read in advance, listing some of the things that you might want to be doing with Twisted and the consensus as to the correct (or multiple possible correct) solutions for each case.
     14
     15
     16=== I want a container for my WSGI application ===
     17
     18In this case, '''use the Twisted Web (8.2 or newer) WSGI module''' (`twistd web --wsgi=application`).
    2219
    2320=== I want a web UI for my existing Twisted networking application ===
     
    3734==== I want to write a Wiki ====
    3835==== I want to write a blog ====
    39 ==== I want something to compare to Zope or TurboGears or Django or Ruby on Rails ====
     36==== I want something to compare to Flask or Django or Ruby on Rails ====
    4037
    4138The short version is that this is more complicated in Twisted than in other tools at the moment.  Sadly, you aren't going to find a straight-up competitor  with the sort of polished web presence and easy instant integration with your SQL database and existing environment that the aforementioned products offer.
    4239
    43 Zope 3 uses Twisted now, and the next version of Zope 2 will have experimental Twisted support!  You ''can'' just use that, if you are willing to delve into their innards to find the appropriate integration point for Twisted code and Zope code :).
    44 
    4540[http://divmod.org/trac/wiki/DivmodMantissa Divmod Mantissa] is a full-featured Twisted-powered application server and will likely appeal to you if you want an integrated database and other high-level framework support.
    46 
    47 === I want a container for my WSGI application ===
    48 
    49 In this case, '''use the Twisted Web (8.2 or newer) WSGI module''' (`twistd web --wsgi=application`).