[PEAK] Does a PEAK-ized webware esist ?

Phillip J. Eby pje at telecommunity.com
Thu Jan 29 18:45:15 EST 2004


At 05:33 PM 1/29/04 -0600, Ian Bicking wrote:
>* When option values are retrieved, type information is given.  So there's 
>no configuration schema.

FWIW, PEAK offers both .ini files (that use Python expressions and are 
therefore dynamically typed) and ZConfig (which is schema-driven).  And of 
course there's absolutely nothing stopping you from hooking in other 
formats, and telling the base system to use them, e.g. via the 
[peak.config.loaders] property namespace.  You can also extend the .ini 
format by adding custom section parsers to 
[peak.config.iniFile.sectionParsers].  These two sections in fact are at 
the very start of 'peak.ini', in order to bootstrap the built-in loaders 
and parsers!



>>This last step is where I'm at right now - I would like to enable a
>>structure like:
>>ServletRoot/main.ini
>>ServletRoot/Site1/
>>ServletRoot/Site1/site.ini
>>ServletRoot/Site1/index.py
>>ServletRoot/Site1/page1.py
>>ServletRoot/Site1/subdir/resource.ini
>>ServletRoot/Site1/subdir/page2.py
>>ServletRoot/Site2/
>>ServletRoot/Site2/site.ini
>>ServletRoot/Site2/index.py
>>...
>
>What's the meaning of main.ini, site.ini, and resource.ini?  I.e., what 
>distinguishes them, when do they get loaded, what's their scope?  Is this 
>a PEAK convention?

No.  peak.web has a 'resources.ini' (not 'resource.ini') file that's used 
for configuring skinnable and internationalizable "resources" such as 
images, HTML, templates, etc.  'resources.ini' files can go in directories 
that are being used as sources of such resources.

So, I can only guess at what Wayne means by those.




More information about the PEAK mailing list