Pycoon

 

List of implemented features

Page history last edited by anrienord 2 yrs ago

List of implemented features

 

This list covers Pycoon trunk r120. For additional info about particular sitemap nodes, their parameters, sitemap components, sources, variable resolving, etc. refer to the Apache Cocoon documentation.

 


 

Sitemap nodes

 

map:pipelines element and its content

 

NodePycoon 0.2Apache Cocoon 2.1
map:pipelines100%100%
map:pipeline100%100%
map:match100%100%
map:select100%100%
map:call100%100%
map:component-configurations100%100%
map:read100%100%
map:handle-errors100%100%
map:act100%100%
map:mount90%
check-reload is always "yes"
100%
map:generate90%
label is not supported
100%
map:aggregate90%
label is not supported
100%
map:transform90%
label is not supported
100%
map:serialize90%
label is not supported
100%
map:redirect-to80%
Internal redirects are not supported
100%
map:views0%100%
.........

 

Some of them have nested non-node elements such as <map:parameter>, <map:part>, etc.

 

map:components element and its content

 

TODO: Add info about components nodes

 

Sitemap components

 

Interfaces

 

Component interfaces hierarchy (module pycoon.components):

 

  • Component
    • Serializer
    • Selector
    • Generator
    • Transformer
    • Matcher
    • Reader
    • Action

 

Standard Cocoon components

 

The following components provide functionality similar to standard Cocoon components:

 

  • Component
    • Serializer
      • XmlSerializer
    • Selector
      • RequestMethodSelector
      • RequestParameterSelector
      • ExceptionSelector
    • Generator
      • FileGenerator
      • ExceptionGenerator
    • Transformer
      • TraxTransformer
    • Matcher
      • WildcardUriMatcher
    • Reader
      • ResourceReader
    • Pipeline
    • Action
      • SendmailAction

 

Sources

 

Source resolving schemes

 

Three source resolving schemes are supported:

 

  • file: (default if no scheme is given) -- for accessing files on the local filesystem
    • Note: At this moment the file: URI scheme must be used iff the file path is absolute. Otherwise the scheme must not be specified at all
    • Note: Relative file URIs are relative to the context path. Context path is the directory of the current sitemap file
    • Examples:
      • file:///var/www/pycoon/webapp/sitemap.xconf -- absolute file URI on UNIX
      • file:///d:/pycoon/sitemap.xconf -- absolute file URI on Microsoft Windows
      • webapp/sitemap.xconf -- file URI relative to the context path
  • http: -- for accessing files via HTTP GET method
  • cocoon: -- for accessing various parts of sitemap files (e. g. reading the output of a pipeline)
    • Examples:
      • cocoon:/internal/sidebar?mode={request-param:sidebar-type} -- select pipeline from the current sitemap via matching
      • cocoon://api/news/{1} -- select pipeline from the root sitemap via matching
  • (Pycoon-specific) rawegg: -- for accessing files in Python eggs
    • Example:
      • rawegg:mysite:/webapp/sitemap.xmap -- access sitemap file in mysite egg (e. g. in <map:mount>

 

Source classes

 

Following source classes are available (all don't support caching at this moment):

 

  • FileSource -- supports getLastModified()
  • HttpSource
  • SitemapSource

 

Variable resolving schemes

 

Supported resolving schemes:

 

  • empty -- (default) for accessing positional and named parameters (passed by parent node via <map:parameter> and as positional <map:match> args)
    • Ex. {1}, {my-variable}
    • Note: Relative paths for accessing parameter stack are not supported at this moment (e. g. {../1})
  • request-param: -- for accessing parameters passed via cocoon: or http: URI query (GET and POST application/x-www-form-urlencoded)
    • Ex. {request-param:count}
  • global: -- for accessing global parameters specified in <map:component-configurations> section as <global-variables>
  • Ex. {global:my-site-uri}

 

Configuration files

 

TODO:

 

Dependencies and deployment

 

Software feature set

 

Some dependencies are required and some are optional.

 

  • (req) Pycoon framework and core components
  • (req) Front-end server (at least one)
    • (opt) CherryPy standalone WSGI server
    • (opt) Apache HTTP Server with mod_python as WSGI server

 

Dependencies of each of these features are presented below. For more formal description of deployment see the Pycoon deployment descriptor written in RDF/Notation 3 syntax.

 

Pycoon framework and core components

 

 

CherryPy standalone WSGI server

 

 

Apache HTTP Server with mod_python as WSGI server

 

 

TODO: Describe library dependencies and deployment options

 

Standard logging hierarchy

 

The standard logging module is used for all tasks related to logging.

 

Logging facilities are configured in the /cocoon/logging XML element of a pycoon.xconf file. See example configuration file in the Pycoon distribution.

 

  • root (empty string) -- the root of the hierarchy in logging module
    • request -- HTTP client requests
    • source -- Sources
    • component-manager -- ComponentManager
    • environment -- Environment
    • sitemap -- sitemap nodes and components
      • builder -- TreeBuilder
      • processor -- TreeProcessor
      • generator -- Generator components
      • reader -- Reader components
      • aggregator -- ContentAggregator components
      • transformer -- Transformer components
      • serializer -- Serializer components
      • selector -- Selector components
      • mount -- MountNode nodes

Comments (0)

You don't have permission to comment on this page.