[Subversion] / PEAK / CHANGES.txt  

Diff of /PEAK/CHANGES.txt

Parent Directory | Revision Log

version 526, Fri Oct 4 15:59:34 2002 UTC version 1752, Fri Jun 4 22:34:24 2004 UTC
Line 1 
Line 1 
 Version 0.5 alpha 1 -- First public release of PEAK  Fixes and Enhancements since Version 0.5 alpha 3
   
    - 'peak.web' no longer uses Zope X3 for HTTP publishing support; it has been
      refactored to use a "simpler, more uniform architecture":http://www.eby-sarna.com/pipermail/peak/2004-May/001462.html
      See also "more on the architecture":http://www.eby-sarna.com/pipermail/peak/2004-June/001482.html
      and subsequent posts in that thread.
   
      As a consequence, "various features have been removed":http://www.eby-sarna.com/pipermail/peak/2004-June/001500.html
      from 'peak.web', for possible return at a future date.  Here is a rough
      outline of the changes made so far:
   
       * The 'pageProtocol', 'pathProtocol', and 'errorProtocol' machinery are
         gone.  They will be replaced in the future with an explicit "controller"
         wrapping mechanism to allow application-specific renderings of the same
         underlying components.
   
       * The Zope 'request' and 'response' objects are gone, along with all of
         their special handling for cookies, character sets, form variables,
         automatically marshalling parameters to functions, etc.  These items of
         functionality will be gradually replaced by functions in 'peak.web.api'.
   
         As a result of this, arbitrary functions and methods can no longer be
         used as web pages; instead, functions and methods to be published must
         use the same inputs and outputs as the 'IHTTPHandler.handle_http()'
         method.
   
       * The 'IWebPage', 'IWebInteraction', 'ITraversalContext', 'Traversal',
         'TraversalContext', and 'Interaction' interfaces and classes no longer
         exist, as they are unneeded in the new architecture.  Instead of
         having a central 'IWebInteraction' that's referenced by numerous
         'ITraversalContext' objects, the new approach uses an 'environ' mapping
         for most functions.  For access control, a 'security.IInteraction' is
         now used, whose function is limited to security checks.  Most
         functions previously performed by 'IWebInteraction' have moved to
         'IInteractionPolicy' or to 'peak.web.api' functions operating on
         'environ' mappings.
   
       * Web exceptions can define a 'levelName' attribute that determines the
         severity level with which the exception will be logged.  This allows
         one to e.g. avoid logging tracebacks for 'NotFound' errors.
   
       * Various interface calling signatures have changed slightly.  For example,
         'IAuthService.getUser()' now accepts an 'environ' mapping instead of
         an interaction.  'IInteractionPolicy.newInteraction()' now takes keyword
         arguments, but not a 'request'.  The 'IWebTraversable' interface no longer
         has a 'getObject()' method, and the 'IWebException.handleException()'
         method signature has changed as well.  Finally, all methods that
         previously accepted 'ITraversalContext' (such as
         'IDOMletState.renderFor()') now expect 'environ' mappings.
   
       * 'web.TestInteraction' was replaced with 'web.TestPolicy', and
         'web.Interaction' was removed, since 'IWebInteraction' is no longer part
         of the architecture.
   
    - The 'log()' method of PEAK loggers ('logs.ILogger') now accepts a level name
      *or* a number, for convenient invocation.
   
    - SQL transaction semantics have changed.  Now, issuing an SQL statement
      *always* causes the connection to join the active PEAK transaction, even if
      you request that the SQL be issued "outside" a transaction.  Such SQL will
      be issued outside of the *database* transaction, but not outside of the
      PEAK transaction.  This simplifies the overall processing model for dealing
      with "untransacted" SQL such as Sybase DDL or read-only Oracle transactions.
      (In particular, the requirement that triggered this change was to allow
      Oracle read-only transactions to be released at the end of the current PEAK
      transaction.)  Also, got rid of the now-meaningless 'begin' command in n2.
   
    - The 'events.IEventSource' interface now returns a 'canceller' function from
      the 'addCallback()' method, allowing you to cancel a previously-scheduled
      callback.  This fixes a memory leak and performance problem with
      'events.AnyOf()', which previously could accumulate unneeded callbacks on
      the sources it was monitoring.  Note that if you have developed any custom
      event sources with 'addCallback()' methods, you must make sure that they
      return a canceller from now on.
   
    - Added 'ref:factory@addr1||addr2' URL scheme that maps to a corresponding
      'naming.Reference("factory",["addr1","addr2"])'.  'factory' can be either a
      dotted import string referencing a 'naming.IObjectFactory', or you can
      define a factory in the 'peak.naming.factories' property space.
   
    - Added a 'zconfig.schema' factory, so that 'ref:zconfig.schema@streamURL'
      will load a schema loader.  Schema loaders are themselves object factories,
      so you can do something like:
   
        [Named Services]
        peak.naming.factories.myschema = \
            naming.LinkRef('ref:zconfig.schema@pkgfile:mypkg/Schema.xml')
   
      in order to make URLs like 'ref:myschema@filename' work.  Note, by the way,
      that the above could also read:
   
        [Named Services]
        peak.naming.factories.myschema = \
            naming.Reference('zconfig.schema',['pkgfile:mypkg/Schema.xml'])
   
      which runs somewhat faster at lookup time.  Similarly, one can also use
      'naming.Reference("myschema",["somefile"])' in place of a
      'naming.LinkRef("ref:myschema@filename")'.  As well as being faster, for
      some use cases it's easier to 'Reference' directly than to glue together
      a 'ref:' URL string.
   
   


Generate output suitable for use with a patch program
Legend:
Removed from v.526  
changed lines
  Added in v.1752

cvs-admin@eby-sarna.com

Powered by ViewCVS 1.0-dev

ViewCVS and CVS Help