Index: openacs-4/packages/acs-core-docs/www/acs-admin.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/acs-admin.html,v diff -u -N -r1.41 -r1.41.2.1 --- openacs-4/packages/acs-core-docs/www/acs-admin.html 13 Sep 2009 23:54:39 -0000 1.41 +++ openacs-4/packages/acs-core-docs/www/acs-admin.html 18 Jun 2010 21:29:33 -0000 1.41.2.1 @@ -1,2 +1,2 @@ -Part II. Administrator's Guide

Administrator's Guide

Table of Contents

2. Installation Overview
Basic Steps
Prerequisite Software
3. Complete Installation
Install a Unix-like system and supporting software
Install Oracle 8.1.7
Install PostgreSQL
Install AOLserver 4
Install OpenACS 5.5.0
OpenACS Installation Guide for Windows2000
OpenACS Installation Guide for Mac OS X
4. Configuring a new OpenACS Site
Installing OpenACS packages
Mounting OpenACS packages
Configuring an OpenACS package
Setting Permissions on an OpenACS package
How Do I?
5. Upgrading
Overview
Upgrading 4.5 or higher to 4.6.3
Upgrading OpenACS 4.6.3 to 5.0
Upgrading an OpenACS 5.0.0 or greater installation
Upgrading the OpenACS files
Upgrading Platform components
6. Production Environments
Starting and Stopping an OpenACS instance.
AOLserver keepalive with inittab
Running multiple services on one machine
High Availability/High Performance Configurations
Staged Deployment for Production Networks
Installing SSL Support for an OpenACS service
Set up Log Analysis Reports
External uptime validation
Diagnosing Performance Problems
7. Database Management
Running a PostgreSQL database on another server
Deleting a tablespace
Vacuum Postgres nightly
A. Install Red Hat 8/9
B. Install additional supporting software
Unpack the OpenACS tarball
Initialize CVS (OPTIONAL)
Add PSGML commands to emacs init file (OPTIONAL)
Install Daemontools (OPTIONAL)
Install qmail (OPTIONAL)
Install Analog web file analyzer
Install nspam
Install Full Text Search using Tsearch2
Install Full Text Search using OpenFTS (deprecated see tsearch2)
Install nsopenssl
Install tclwebtest.
Install PHP for use in AOLserver
Install Squirrelmail for use as a webmail system for OpenACS
Install PAM Radius for use as external authentication
Install LDAP for use as external authentication
Install AOLserver 3.3oacs1
C. Credits
Where did this document come from?
Linux Install Guides
Security Information
Resources
Section missing
View comments on this page at openacs.org
+Part II. Administrator's Guide

Administrator's Guide

Table of Contents

2. Installation Overview
Basic Steps
Prerequisite Software
3. Complete Installation
Install a Unix-like system and supporting software
Install Oracle 8.1.7
Install PostgreSQL
Install AOLserver 4
Install OpenACS 5.6.0
OpenACS Installation Guide for Windows2000
OpenACS Installation Guide for Mac OS X
4. Configuring a new OpenACS Site
Installing OpenACS packages
Mounting OpenACS packages
Configuring an OpenACS package
Setting Permissions on an OpenACS package
How Do I?
5. Upgrading
Overview
Upgrading 4.5 or higher to 4.6.3
Upgrading OpenACS 4.6.3 to 5.0
Upgrading an OpenACS 5.0.0 or greater installation
Upgrading the OpenACS files
Upgrading Platform components
6. Production Environments
Starting and Stopping an OpenACS instance.
AOLserver keepalive with inittab
Running multiple services on one machine
High Availability/High Performance Configurations
Staged Deployment for Production Networks
Installing SSL Support for an OpenACS service
Set up Log Analysis Reports
External uptime validation
Diagnosing Performance Problems
7. Database Management
Running a PostgreSQL database on another server
Deleting a tablespace
Vacuum Postgres nightly
8. Backup and Recovery
Backup Strategy
Manual backup and recovery
Automated Backup
Using CVS for backup-recovery
A. Install Red Hat 8/9
B. Install additional supporting software
Unpack the OpenACS tarball
Initialize CVS (OPTIONAL)
Add PSGML commands to emacs init file (OPTIONAL)
Install Daemontools (OPTIONAL)
Install qmail (OPTIONAL)
Install Analog web file analyzer
Install nspam
Install Full Text Search using Tsearch2
Install Full Text Search using OpenFTS (deprecated see tsearch2)
Install nsopenssl
Install tclwebtest.
Install PHP for use in AOLserver
Install Squirrelmail for use as a webmail system for OpenACS
Install PAM Radius for use as external authentication
Install LDAP for use as external authentication
Install AOLserver 3.3oacs1
C. Credits
Where did this document come from?
Linux Install Guides
Security Information
Resources
View comments on this page at openacs.org
Index: openacs-4/packages/acs-core-docs/www/acs-package-dev.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/acs-package-dev.html,v diff -u -N -r1.29 -r1.29.2.1 --- openacs-4/packages/acs-core-docs/www/acs-package-dev.html 13 Sep 2009 23:54:39 -0000 1.29 +++ openacs-4/packages/acs-core-docs/www/acs-package-dev.html 18 Jun 2010 21:29:34 -0000 1.29.2.1 @@ -1,5 +1,3 @@ -Part III. For OpenACS Package Developers

For OpenACS Package Developers

Tutorials and reference material for creating new OpenACS packages. -

Table of Contents

8. Development Tutorial
Setting Up Database Objects
Creating Web Pages
Debugging and Automated Testing
9. Advanced Topics
Write the Requirements and Design Specs
Add the new package to CVS
OpenACS Edit This Page Templates
Adding Comments
Admin Pages
Categories
Profile your code
Prepare the package for distribution.
Distributing upgrades of your package
Notifications
Hierarchical data
Using .vuh files for pretty urls
Laying out a page with CSS instead of tables
Sending HTML email from your application
Basic Caching
Scheduled Procedures
Enabling WYSIWYG
Adding in parameters for your package
Writing upgrade scripts
Connect to a second database
Future Topics
10. Development Reference
OpenACS Packages
OpenACS Data Models and the Object System
The Request Processor
The OpenACS Database Access API
Using Templates in OpenACS
Groups, Context, Permissions
Parties in OpenACS
OpenACS Permissions Tediously Explained
Object Identity
Programming with AOLserver
Using Form Builder: building html forms dynamically
11. Engineering Standards
OpenACS Style Guide
- CVS Guidelines -
Release Version Numbering
Constraint naming standard
ACS File Naming and Formatting Standards
PL/SQL Standards
Variables
Automated Testing
12. Documentation Standards
OpenACS Documentation Guide
Using nXML mode in Emacs
Detailed Design Documentation Template
System/Application Requirements Template
13. Internationalization
Internationalization and Localization Overview
How Internationalization/Localization works in OpenACS
How to Internationalize a Package
Design Notes
Translator's Guide
D. Using CVS with an OpenACS Site
View comments on this page at openacs.org
+Part III. For OpenACS Package Developers

For OpenACS Package Developers

Tutorials and reference material for creating new OpenACS packages. +

Table of Contents

9. Development Tutorial
Creating an Application Package
Setting Up Database Objects
Creating Web Pages
Debugging and Automated Testing
10. Advanced Topics
Write the Requirements and Design Specs
Add the new package to CVS
OpenACS Edit This Page Templates
Adding Comments
Admin Pages
Categories
Profile your code
Prepare the package for distribution.
Distributing upgrades of your package
Notifications
Hierarchical data
Using .vuh files for pretty urls
Laying out a page with CSS instead of tables
Sending HTML email from your application
Basic Caching
Scheduled Procedures
Enabling WYSIWYG
Adding in parameters for your package
Writing upgrade scripts
Connect to a second database
Future Topics
11. Development Reference
OpenACS Packages
OpenACS Data Models and the Object System
The Request Processor
The OpenACS Database Access API
Using Templates in OpenACS
Groups, Context, Permissions
Writing OpenACS Application Pages
Parties in OpenACS
OpenACS Permissions Tediously Explained
Object Identity
Programming with AOLserver
Using Form Builder: building html forms dynamically
12. Engineering Standards
OpenACS Style Guide
Release Version Numbering
Constraint naming standard
ACS File Naming and Formatting Standards
PL/SQL Standards
Variables
Automated Testing
13. Documentation Standards
OpenACS Documentation Guide
Using PSGML mode in Emacs
Using nXML mode in Emacs
Detailed Design Documentation Template
System/Application Requirements Template
14. Internationalization
Internationalization and Localization Overview
How Internationalization/Localization works in OpenACS
How to Internationalize a Package
Design Notes
Translator's Guide
CVS Section missing
View comments on this page at openacs.org
Index: openacs-4/packages/acs-core-docs/www/acs-plat-dev.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/acs-plat-dev.html,v diff -u -N -r1.27 -r1.27.2.1 --- openacs-4/packages/acs-core-docs/www/acs-plat-dev.html 13 Sep 2009 23:54:39 -0000 1.27 +++ openacs-4/packages/acs-core-docs/www/acs-plat-dev.html 18 Jun 2010 21:29:34 -0000 1.27.2.1 @@ -1,2 +1,2 @@ -Part IV. For OpenACS Platform Developers

For OpenACS Platform Developers

Table of Contents

14. Kernel Documentation
Overview
Object Model Requirements
Object Model Design
Permissions Requirements
Permissions Design
Groups Requirements
Groups Design
Subsites Design Document
Package Manager Requirements
Package Manager Design
OpenACS Internationalization Requirements
Security Requirements
Security Design
Security Notes
Request Processor Requirements
Request Processor Design
Documenting Tcl Files: Page Contracts and Libraries
Bootstrapping OpenACS
External Authentication Requirements
15. Releasing OpenACS
OpenACS Core and .LRN
How to Update the OpenACS.org repository
How to package and release an OpenACS Package
How to Update the translations
View comments on this page at openacs.org
+Part IV. For OpenACS Platform Developers

For OpenACS Platform Developers

Table of Contents

15. Kernel Documentation
Overview
Object Model Requirements
Permissions Requirements
Permissions Design
Groups Requirements
Groups Design
Subsites Requirements
Subsites Design Document
Package Manager Requirements
Package Manager Design
Database Access API
OpenACS Internationalization Requirements
Security Requirements
Security Design
Security Notes
Request Processor Requirements
Request Processor Design
Bootstrapping OpenACS
External Authentication Requirements
16. Releasing OpenACS
OpenACS Core and .LRN
How to Update the OpenACS.org repository
How to package and release an OpenACS Package
How to Update the translations
View comments on this page at openacs.org
Index: openacs-4/packages/acs-core-docs/www/aolserver.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/aolserver.html,v diff -u -N -r1.48 -r1.48.2.1 --- openacs-4/packages/acs-core-docs/www/aolserver.html 13 Sep 2009 23:54:39 -0000 1.48 +++ openacs-4/packages/acs-core-docs/www/aolserver.html 18 Jun 2010 21:29:34 -0000 1.48.2.1 @@ -83,17 +83,17 @@ communicate with the database. There is one script each for Oracle and PostgreSQL. They don't conflict, so if you plan to use both databases, install both.

  • Install tDOM. Download the tDOM tarball, unpack it, adjust the configuration file to match our patched distribution of aolserver, and compile it.

    [root root]# cd /usr/local/src
    Index: openacs-4/packages/acs-core-docs/www/aolserver4.html
    ===================================================================
    RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/aolserver4.html,v
    diff -u -N -r1.23 -r1.23.2.1
    --- openacs-4/packages/acs-core-docs/www/aolserver4.html	13 Sep 2009 23:54:39 -0000	1.23
    +++ openacs-4/packages/acs-core-docs/www/aolserver4.html	18 Jun 2010 21:29:34 -0000	1.23.2.1
    @@ -1,5 +1,5 @@
     
    -Install AOLserver 4

    Install AOLserver 4

    by Malte Sussdorff

    +Install AOLserver 4

    Install AOLserver 4

    by Malte Sussdorff

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.
    1. Check suitability of previously installed TCL. Start tcl (type tclsh or find it using which tclsh). @@ -100,16 +100,16 @@ maintainers: this should be moved to the next page and integrated into the text there)

      • Oracle

        [root aolserver]# cd /usr/local/aolserver/bin
        -[root bin]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/nsd-oracle.txt ./nsd-oracle
        +[root bin]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/nsd-oracle.txt ./nsd-oracle
         [root bin]# chmod 750 nsd-oracle
         [root bin]#
         cd /usr/local/aolserver/bin
        -cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/nsd-oracle.txt ./nsd-oracle
        +cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/nsd-oracle.txt ./nsd-oracle
         chmod 750 nsd-oracle
      • PostgreSQL

        [root aolserver]# cd /usr/local/aolserver/bin
        -[root bin]# cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/nsd-postgres.txt ./nsd-postgres
        +[root bin]# cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/nsd-postgres.txt ./nsd-postgres
         [root bin]# chmod 755 nsd-postgres
         [root bin]#
         cd /usr/local/aolserver/bin
        -cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/nsd-postgres.txt ./nsd-postgres
        +cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/nsd-postgres.txt ./nsd-postgres
         chmod 755 nsd-postgres

      You may need to edit these scripts if you are not using - /usr/local/aolserver as the directory of Aolserver4.

    2. Change startup script (optional). If you want to run AOLserver on a port below 1024 (normally, for a webserver you will use 80), you will have to change the /var/lib/aolserver/service0/etc/daemontools/run script according to the documentation found there (namely: Add the -b yourip:yourport switch)

    3. Test AOLserver.

    ($Id$)
    View comments on this page at openacs.org
    + /usr/local/aolserver as the directory of Aolserver4.

  • Change startup script (optional). If you want to run AOLserver on a port below 1024 (normally, for a webserver you will use 80), you will have to change the /var/lib/aolserver/service0/etc/daemontools/run script according to the documentation found there (namely: Add the -b yourip:yourport switch)

  • Test AOLserver.

  • ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/apm-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/apm-design.html,v diff -u -N -r1.36 -r1.36.2.1 --- openacs-4/packages/acs-core-docs/www/apm-design.html 13 Sep 2009 23:54:39 -0000 1.36 +++ openacs-4/packages/acs-core-docs/www/apm-design.html 18 Jun 2010 21:29:34 -0000 1.36.2.1 @@ -1,5 +1,5 @@ -Package Manager Design

    Package Manager Design

    By Bryan Quinn

    +Package Manager Design

    Package Manager Design

    By Bryan Quinn

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Essentials

    Authors

    • System creator: Bryan Quinn, Jon Salz, Michael Yoon, Lars Pind, Todd Nightingale.

    • System owner: Bryan Quinn

    • Documentation author: Bryan Quinn, building from earlier versions by Jon -Salz, Michael Yoon, and Lars Pind.

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation9/25/2000Bryan Quinn
    0.8Ready for QA9/29/2000Bryan Quinn
    0.9Edited for ACS 4 Beta release10/02/2000Kai Wu
    1.0Edited for OpenACS 4.5 Beta release03/02/2002Roberto Mello
    View comments on this page at openacs.org
    +Salz, Michael Yoon, and Lars Pind.

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation9/25/2000Bryan Quinn
    0.8Ready for QA9/29/2000Bryan Quinn
    0.9Edited for ACS 4 Beta release10/02/2000Kai Wu
    1.0Edited for OpenACS 4.5 Beta release03/02/2002Roberto Mello
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/apm-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/apm-requirements.html,v diff -u -N -r1.32 -r1.32.2.1 --- openacs-4/packages/acs-core-docs/www/apm-requirements.html 13 Sep 2009 23:54:39 -0000 1.32 +++ openacs-4/packages/acs-core-docs/www/apm-requirements.html 18 Jun 2010 21:29:34 -0000 1.32.2.1 @@ -1,5 +1,5 @@ -Package Manager Requirements

    Package Manager Requirements

    By Bryan Quinn and Todd Nightingale

    +Package Manager Requirements

    Package Manager Requirements

    By Bryan Quinn and Todd Nightingale

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    The following is a requirements document for the OpenACS Package Manager Index: openacs-4/packages/acs-core-docs/www/automated-backup.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/automated-backup.html,v diff -u -N -r1.10 -r1.10.2.1 --- openacs-4/packages/acs-core-docs/www/automated-backup.html 12 Jul 2009 01:08:24 -0000 1.10 +++ openacs-4/packages/acs-core-docs/www/automated-backup.html 18 Jun 2010 21:29:34 -0000 1.10.2.1 @@ -1,4 +1,4 @@ - -Automated Backup

    Automated Backup

    The recommended backup strategy for a production sit is to use an automated script which first backs up the database to a file in /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup and then backs up all of /var/lib/aolserver/$OPENACS_SERVICE_NAME to a single zip file, and then copies that zip file to another computer.

    1. Make sure that the manual backup process described above works.

    2. Customize the default backup script. Edit /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/backup.sh with your specific parameters.

    3. - Make sure the file is executable:

      chmod +x backup.sh
    4. - Set this file to run automatically by adding a line to root's crontab. (Typically, with export EDITOR=emacs; crontab -e.) This example runs the backup script at 1:30 am every day.

      30 1 * * *        sh /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/backup.sh
    View comments on this page at openacs.org
    + +Automated Backup

    Automated Backup

    The recommended backup strategy for a production sit is to use an automated script which first backs up the database to a file in /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup and then backs up all of /var/lib/aolserver/$OPENACS_SERVICE_NAME to a single zip file, and then copies that zip file to another computer.

    1. Make sure that the manual backup process described above works.

    2. Customize the default backup script. Edit /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/backup.sh with your specific parameters.

    3. + Make sure the file is executable:

      chmod +x backup.sh
    4. + Set this file to run automatically by adding a line to root's crontab. (Typically, with export EDITOR=emacs; crontab -e.) This example runs the backup script at 1:30 am every day.

      30 1 * * *        sh /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/backup.sh
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/automated-testing-best-practices.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/automated-testing-best-practices.html,v diff -u -N -r1.24 -r1.24.2.1 --- openacs-4/packages/acs-core-docs/www/automated-testing-best-practices.html 13 Sep 2009 23:54:39 -0000 1.24 +++ openacs-4/packages/acs-core-docs/www/automated-testing-best-practices.html 18 Jun 2010 21:29:34 -0000 1.24.2.1 @@ -1,5 +1,5 @@ -Automated Testing

    Automated Testing

    By Jeff Davis

    +Automated Testing

    Automated Testing

    By Jeff Davis

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Best practices in writing OpenACS automated tests

    • Special characters in Tcl.  @@ -25,4 +25,4 @@ Make sure that if a duplicate name is entered that there is a reasonable error rather than a server error. Check for insert, move, copy, and rename. -

    ($Id$)
    View comments on this page at openacs.org
    +

    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/backup-recovery.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/backup-recovery.html,v diff -u -N -r1.40 -r1.40.2.1 --- openacs-4/packages/acs-core-docs/www/backup-recovery.html 12 Jul 2009 01:08:24 -0000 1.40 +++ openacs-4/packages/acs-core-docs/www/backup-recovery.html 18 Jun 2010 21:29:34 -0000 1.40.2.1 @@ -1,12 +1,12 @@ - -Chapter 8. Backup and Recovery

    Chapter 8. Backup and Recovery

    ($Id$)

    By Don Baccus with additions - by Joel Aufrecht

    We will cover some basic backup and recovery strategies. These are intended to + +Chapter 8. Backup and Recovery

    Chapter 8. Backup and Recovery

    ($Id$)

    By Don Baccus with additions + by Joel Aufrecht

    We will cover some basic backup and recovery strategies. These are intended to be robust but simple enough to set up. For a large scale production site you would probably need to create your own backup strategies (in particular full dumps from oracle, while easy to set up, are far from the best solution).

    There are three basic things which need to be backed up, the database data, the server source tree, and the acs-content-repository (which is in the server source tree).

    -

    Figure 8.1. Backup and Recovery Strategy

    Backup and Recovery Strategy


    +

    Figure 8.1. Backup and Recovery Strategy

    Backup and Recovery Strategy

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. Index: openacs-4/packages/acs-core-docs/www/backups-with-cvs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/backups-with-cvs.html,v diff -u -N -r1.10 -r1.10.2.1 --- openacs-4/packages/acs-core-docs/www/backups-with-cvs.html 12 Jul 2009 01:08:24 -0000 1.10 +++ openacs-4/packages/acs-core-docs/www/backups-with-cvs.html 18 Jun 2010 21:29:34 -0000 1.10.2.1 @@ -1,31 +1,31 @@ - -Using CVS for backup-recovery

    Using CVS for backup-recovery

    CVS-only backup is often appropriate for development sites. If you are already using CVS and your data is not important, you probably don't + +Using CVS for backup-recovery

    Using CVS for backup-recovery

    CVS-only backup is often appropriate for development sites. If you are already using CVS and your data is not important, you probably don't need to do anything to back up your files. Just make sure that your current work is checked into the system. You can then roll back based on date - note the current system time, down to the minute. For maximum safety, you can apply a tag to your current - files. You will still need to back up your database.

    Note that, if you did the CVS options in this document, the /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc directory is not included in cvs and you may want to add it.

    [root root]# su - $OPENACS_SERVICE_NAME
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs commit -m "last-minute commits before upgrade to 4.6"
    +      files.  You will still need to back up your database.

    Note that, if you did the CVS options in this document, the /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc directory is not included in cvs and you may want to add it.

    [root root]# su - $OPENACS_SERVICE_NAME
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs commit -m "last-minute commits before upgrade to 4.6"
     cvs commit: Examining .
     cvs commit: Examining bin
     (many lines omitted)
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs tag before_upgrade_to_4_6
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs tag before_upgrade_to_4_6
     cvs server: Tagging bin
     T bin/acs-4-0-publish.sh
     T bin/ad-context-server.pl
     (many lines omitted)
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
     [root root]# 
     su - $OPENACS_SERVICE_NAME
     cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
    -cvs commit -m "last-minute commits before upgrade to 4.6"
    +cvs commit -m "last-minute commits before upgrade to 4.6"
     cvs tag before_upgrade_to_4_6
    -exit

    To restore files from a cvs tag such as the one used above:

    [root root]# su - $OPENACS_SERVICE_NAME
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs up -r current
    -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
    +exit

    To restore files from a cvs tag such as the one used above:

    [root root]# su - $OPENACS_SERVICE_NAME
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs up -r current
    +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
     su - $OPENACS_SERVICE_NAME
     cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
     cvs up -r current
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/bootstrap-acs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/bootstrap-acs.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/bootstrap-acs.html 13 Sep 2009 23:54:39 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/bootstrap-acs.html 18 Jun 2010 21:29:34 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -Bootstrapping OpenACS

    Bootstrapping OpenACS

    By Jon Salz

    +Bootstrapping OpenACS

    Bootstrapping OpenACS

    By Jon Salz

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.
    • Tcl code: /tcl/0-acs-init.tcl and /packages/acs-kernel/bootstrap.tcl

    This document describes the startup (bootstrapping) process for an AOLserver @@ -86,4 +86,4 @@ At this point, bootstrap.tcl is done executing. AOLserver proceeds to source the remaining files in the /tcl directory (i.e., unpackaged libraries) and begins listening for connections. -

    ($Id$)
    View comments on this page at openacs.org
    +

    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/complete-install.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/complete-install.html,v diff -u -N -r1.21 -r1.21.2.1 --- openacs-4/packages/acs-core-docs/www/complete-install.html 13 Sep 2009 23:54:39 -0000 1.21 +++ openacs-4/packages/acs-core-docs/www/complete-install.html 18 Jun 2010 21:29:34 -0000 1.21.2.1 @@ -1,2 +1,2 @@ -Chapter 3. Complete Installation
    View comments on this page at openacs.org
    +Chapter 3. Complete Installation
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/configuring-configuring-packages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/configuring-configuring-packages.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/configuring-configuring-packages.html 13 Sep 2009 23:54:39 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/configuring-configuring-packages.html 18 Jun 2010 21:29:34 -0000 1.6.2.1 @@ -2,7 +2,7 @@ Configuring an OpenACS package

    Configuring an OpenACS package

    by Jade Rubick

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Configuring an OpenACS package

    After you've installed and mounted your package, you can +

    Configuring an OpenACS package

    After you've installed and mounted your package, you can configure each instance to act as you would like.

    This is done from the Applications page. Log in, go to the Admin or Control Panel, click on the subsite the application is in, and click on Applications. If you click on the 'Parameters' Index: openacs-4/packages/acs-core-docs/www/configuring-configuring-permissions.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/configuring-configuring-permissions.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/configuring-configuring-permissions.html 13 Sep 2009 23:54:39 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/configuring-configuring-permissions.html 18 Jun 2010 21:29:34 -0000 1.6.2.1 @@ -2,7 +2,7 @@ Setting Permissions on an OpenACS package

    Setting Permissions on an OpenACS package

    by Jade Rubick

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Setting Permission on an OpenACS package

    After you've installed and mounted your package, you can +

    Setting Permission on an OpenACS package

    After you've installed and mounted your package, you can configure each instance to act as you would like.

    This is done from the Applications page. Log in, go to the Admin or Control Panel, click on the subsite the application is in, and click on Applications. If you click on the 'Permissions' Index: openacs-4/packages/acs-core-docs/www/configuring-install-packages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/configuring-install-packages.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/configuring-install-packages.html 13 Sep 2009 23:54:39 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/configuring-install-packages.html 18 Jun 2010 21:29:34 -0000 1.6.2.1 @@ -2,7 +2,7 @@ Installing OpenACS packages

    Installing OpenACS packages

    by Jade Rubick

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Installing OpenACS packages

    An OpenACS package extends your website and lets it do +

    Installing OpenACS packages

    An OpenACS package extends your website and lets it do things it wasn't able to do before. You can have a weblog, a forums, a calendar, or even do sophisticated project-management via your website.

    After you've installed OpenACS, you can congratulate Index: openacs-4/packages/acs-core-docs/www/configuring-mounting-packages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/configuring-mounting-packages.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/configuring-mounting-packages.html 13 Sep 2009 23:54:39 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/configuring-mounting-packages.html 18 Jun 2010 21:29:34 -0000 1.6.2.1 @@ -2,7 +2,7 @@ Mounting OpenACS packages

    Mounting OpenACS packages

    by Jade Rubick

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Mounting OpenACS packages

    After you've installed your packages, you have to 'mount' +

    Mounting OpenACS packages

    After you've installed your packages, you have to 'mount' them in order to make them appear on your website.

    Make sure you are logged in, and then click on the 'Admin' or 'Control Panel' link to get to the Site-Wide Administration page (at /acs-admin). Click on the subsite you'd Index: openacs-4/packages/acs-core-docs/www/db-api-detailed.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/db-api-detailed.html,v diff -u -N -r1.44 -r1.44.2.1 --- openacs-4/packages/acs-core-docs/www/db-api-detailed.html 12 Jul 2009 01:08:26 -0000 1.44 +++ openacs-4/packages/acs-core-docs/www/db-api-detailed.html 18 Jun 2010 21:29:34 -0000 1.44.2.1 @@ -1,24 +1,24 @@ - -Database Access API

    Database Access API

    By Jon Salz. Revised and expanded by Roberto Mello (rmello at fslc dot usu dot edu), July 2002.

    + +Database Access API

    Database Access API

    By Jon Salz. Revised and expanded by Roberto Mello (rmello at fslc dot usu dot edu), July 2002.

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -
    • Tcl procedures: /packages/acs-kernel/10-database-procs.tcl

    • Tcl initialization: /packages/acs-kernel/database-init.tcl

    The Big Picture

    +

    • Tcl procedures: /packages/acs-kernel/10-database-procs.tcl

    • Tcl initialization: /packages/acs-kernel/database-init.tcl

    The Big Picture

    One of OpenACS's great strengths is that code written for it is very close to the database. It is very easy to interact with the database from anywhere within OpenACS. Our goal is to develop a coherent API for database access which makes this even easier.

    There were four significant problems with the way OpenACS previously used the -database (i.e., directly through the ns_db interface):

    1. Handle management. We required code to pass database +database (i.e., directly through the ns_db interface):

      1. Handle management. We required code to pass database handles around, and for routines which needed to perform database access but didn't receive a database handle as input, it was difficult to know from -which of the three "magic pools" (main, subquery, and log) to +which of the three "magic pools" (main, subquery, and log) to allocate a new handle. -

      2. Nested transactions. In our Oracle driver, begin -transaction really means "turn auto-commit mode off" and -end transaction means "commit the current transaction and -turn auto-commit mode on." Thus if transactional code needed to call a +

      3. Nested transactions. In our Oracle driver, begin +transaction really means "turn auto-commit mode off" and +end transaction means "commit the current transaction and +turn auto-commit mode on." Thus if transactional code needed to call a routine which needed to operate transactionally, the semantics were non-obvious. Consider:

         
        @@ -29,47 +29,47 @@
         }
         
         db_transaction {
        -db_dml unused "insert into greeble(bork) values(33)"
        +db_dml unused "insert into greeble(bork) values(33)"
         foo $db
        -db_dml unused "insert into greeble(bork) values(50)"
        +db_dml unused "insert into greeble(bork) values(50)"
         }
         
         

        -This would insert greeble #33 and do all the stuff in foo -transactionally, but the end transaction in foo +This would insert greeble #33 and do all the stuff in foo +transactionally, but the end transaction in foo would actually cause a commit, and greeble #50 would later be inserted in auto-commit mode. This could cause subtle bugs: e.g., in the case that the -insert for greeble #50 failed, part of the "transaction" would have +insert for greeble #50 failed, part of the "transaction" would have already have been committed!. This is not a good thing. -

      4. Unorthodox use of variables. The standard mechanism for +

      5. Unorthodox use of variables. The standard mechanism for mapping column values into variables involved the use of the -set_variables_after_query routine, which relies on an uplevel -variable named selection (likewise for -set_variables_after_subquery and subselection). +set_variables_after_query routine, which relies on an uplevel +variable named selection (likewise for +set_variables_after_subquery and subselection). -

      6. Hard-coded reliance on Oracle. It's difficult to +

      7. Hard-coded reliance on Oracle. It's difficult to write code supporting various different databases (dynamically using the appropriate dialect based on the type of database being used, e.g., using -DECODE on Oracle and CASE ... WHEN on +DECODE on Oracle and CASE ... WHEN on Postgres).

      The Database Access API addresses the first three problems by: -

      1. making use of database handles transparent

      2. wrapping common database operations (including transaction management) in +

        1. making use of database handles transparent

        2. wrapping common database operations (including transaction management) in Tcl control structures (this is, after all, what Tcl is good at!)

        It lays the groundwork for addressing the fourth problem by assigning each SQL statement a logical name. In a future version of the OpenACS Core, this API will translate logical statement names into actual SQL, based on the type of database in use. (To smooth the learning curve, we provide a facility for -writing SQL inline for a "default SQL dialect", which we assume to +writing SQL inline for a "default SQL dialect", which we assume to be Oracle for now.)

        To be clear, SQL abstraction is not fully implemented in OpenACS 3.3.1. The statement names supplied to each call are not used by the API at all. The API's design for SQL abstraction is in fact incomplete; -unresolved issues include:

        • how to add WHERE clause criteria dynamically

        • how to build a dynamic ORDER BY clause (Ben Adida has a -proposed solution for this)

        • how to define a statement's formal interface (i.e., what bind -variables it expects, what columns its SELECT clause must +unresolved issues include:

          • how to add WHERE clause criteria dynamically

          • how to build a dynamic ORDER BY clause (Ben Adida has a +proposed solution for this)

          • how to define a statement's formal interface (i.e., what bind +variables it expects, what columns its SELECT clause must contain if it's a query) without actually implementing the statement in a specific SQL dialect

          So why is the incremental change of adding statement naming to the API worth @@ -78,81 +78,81 @@ design. Therefore, we know that the effort will not be wasted, and taking advantage of the new support for bind variables will already require code that uses 3.3.0 version of the API to be updated. -

        The Bell Tolls for set_variables_after_query

        -set_variables_after_query is gone! (Well, it's still there, +

        The Bell Tolls for set_variables_after_query

        +set_variables_after_query is gone! (Well, it's still there, but you'll never need to use it.) The new API routines set local variables automatically. For instance:

         
        -db_1row select_names "select first_names, last_name from users where user_id = [ad_get_user_id]"
        -doc_body_append "Hello, $first_names $last_name!"
        +db_1row select_names "select first_names, last_name from users where user_id = [ad_get_user_id]"
        +doc_body_append "Hello, $first_names $last_name!"
         
         

        -Like ns_db 1row, this will bomb if the query doesn't return +Like ns_db 1row, this will bomb if the query doesn't return any rows (no such user exists). If this isn't what you want, you can write:

         
        -if { [db_0or1row select_names "select first_names, last_name from users where user_id = [ad_get_user_id]"] } {
        -    doc_body_append "Hello, $first_names $last_name!"
        +if { [db_0or1row select_names "select first_names, last_name from users where user_id = [ad_get_user_id]"] } {
        +    doc_body_append "Hello, $first_names $last_name!"
         } else {
             # Executed if the query returns no rows.
        -    doc_body_append "There's no such user!"
        +    doc_body_append "There's no such user!"
         }
         
         

        Selecting a bunch of rows is a lot prettier now:

         
        -db_foreach select_names "select first_names, last_name from users" {
        -     doc_body_append "Say hi to $first_names $last_name for me!<br>"
        +db_foreach select_names "select first_names, last_name from users" {
        +     doc_body_append "Say hi to $first_names $last_name for me!<br>"
         }
         
         

        -That's right, db_foreach is now like ns_db -select plus a while loop plus -set_variables_after_query plus an if statement +That's right, db_foreach is now like ns_db +select plus a while loop plus +set_variables_after_query plus an if statement (containing code to be executed if no rows are returned).

         
        -db_foreach select_names "select first_names, last_name from users where last_name like 'S%'" {
        -     doc_body_append "Say hi to $first_names $last_name for me!<br>"
        +db_foreach select_names "select first_names, last_name from users where last_name like 'S%'" {
        +     doc_body_append "Say hi to $first_names $last_name for me!<br>"
         } if_no_rows {
        -     doc_body_append "There aren't any users with last names beginnings with S!"
        +     doc_body_append "There aren't any users with last names beginnings with S!"
         }
         
        -

        Handle Management

        +

        Handle Management

        The new API keeps track of which handles are in use, and automatically allocates new handles when they are necessary (e.g., to perform subqueries while a select is active). For example:

         
        -doc_body_append "<ul>"
        -db_foreach select_names "select first_names, last_name, user_id from users" {
        +doc_body_append "<ul>"
        +db_foreach select_names "select first_names, last_name, user_id from users" {
             # Automatically allocated a database handle from the main pool.
        -    doc_body_append "<li>User $first_names $last_name\n<ul>"
        +    doc_body_append "<li>User $first_names $last_name\n<ul>"
         
        -    db_foreach select_groups "select group_id from user_group_map where user_id = $user_id" {
        +    db_foreach select_groups "select group_id from user_group_map where user_id = $user_id" {
                 # There's a selection in progress, so we allocated a database handle
                 # from the subquery pool for this selection.
        -        doc_body_append "<li>Member of group #$group_id.\n"
        +        doc_body_append "<li>Member of group #$group_id.\n"
             } if_no_rows {
                 # Not a member of any groups.
        -        doc_body_append "<li>Not a member of any group.\n"
        +        doc_body_append "<li>Not a member of any group.\n"
             }
         }
        -doc_body_append "</ul>"
        +doc_body_append "</ul>"
         db_release_unused_handles
         
         

        A new handle isn't actually allocated and released for every selection, of course - as a performance optimization, the API keeps old handles around -until db_release_unused_handles is invoked (or the script +until db_release_unused_handles is invoked (or the script terminates). -

        Note that there is no analogue to ns_db gethandle - the -handle is always automatically allocated the first time it's needed.

        Bind Variables

        Introduction

        +

        Note that there is no analogue to ns_db gethandle - the +handle is always automatically allocated the first time it's needed.

        Bind Variables

        Introduction

        Most SQL statements require that the code invoking the statement pass along data associated with that statement, usually obtained from the user. For instance, in order to delete a WimpyPoint presentation, a Tcl script might @@ -162,10 +162,10 @@ delete from wp_presentations where presentation_id = some_presentation_id

        -where some_presentation_id is a number which is a valid +where some_presentation_id is a number which is a valid presentation ID of the presentation I want to delete. It's easy to write code handling situations like this since SQL statements can include -bind variables, which represent placeholders for actual +bind variables, which represent placeholders for actual data. A bind variable is specified as a colon followed by an identifier, so the statement above can be coded as:

        @@ -176,43 +176,43 @@
         
         

        When this SQL statement is invoked, the value for the bind variable -:some_presentation_id is pulled from the Tcl variable -$some_presentation_id (in the caller's environment). Note +:some_presentation_id is pulled from the Tcl variable +$some_presentation_id (in the caller's environment). Note that bind variables are not limited to one per statement; you can use an arbitrary number, and each will pull from the correspondingly named Tcl -variable. (Alternatively, you can also specify an list or ns_set +variable. (Alternatively, you can also specify an list or ns_set providing bind variables' values; see Usage.)

        The value of a bind variable is taken literally by the database driver, so there is never any need to put single-quotes around the value for a bind -variable, or to use db_quote to escape single-quotes contained +variable, or to use db_quote to escape single-quotes contained in the value. The following works fine, despite the apostrophe:

         
        -set exclamation "That's all, folks!"
        +set exclamation "That's all, folks!"
         db_dml exclamation_insert { insert into exclamations(exclamation) values(:exclamation) }
         
         

        Note that you can use a bind variable in a SQL statement only where you could use a literal (a number or single-quoted string). Bind variables cannot be placeholders for things like SQL keywords, table names, or column names, -so the following will not work, even if $table_name is set +so the following will not work, even if $table_name is set properly:

         
         select * from :table_name
         
        -

        Why Bind Variables Are Useful

        +

        Why Bind Variables Are Useful

        Why bother with bind variables at all - why not just write the Tcl statement above like this:

         
        -db_dml presentation_delete "
        +db_dml presentation_delete "
             delete from wp_presentations where presentation_id = $some_presentation_id
        -"
        +"
         
         

        (Note the use of double-quotes to allow the variable reference to -$some_presentation_id to be interpolated in.) This will work, +$some_presentation_id to be interpolated in.) This will work, but consider the case where some devious user causes -some_presentation_id to be set to something like '3 or -1 = 1', which would result in the following statement being +some_presentation_id to be set to something like '3 or +1 = 1', which would result in the following statement being executed:

         
        @@ -222,24 +222,24 @@
         This deletes every presentation in the database! Using bind variables
         eliminates this gaping security hole: since bind variable values are taken
         literally. Oracle will attempt to delete presentations whose presentation ID
        -is literally '3 or 1 = 1' (i.e., no presentations, since
        -'3 or 1 = 1' can't possibly be a valid integer
        -primary key for wp_presentations. In general, since Oracle
        +is literally '3 or 1 = 1' (i.e., no presentations, since
        +'3 or 1 = 1' can't possibly be a valid integer
        +primary key for wp_presentations. In general, since Oracle
         always considers the values of bind variables to be literals, it becomes more
         difficult for users to perform URL surgery to trick scripts into running
         dangerous queries and DML. 
        -

        Usage

        Every db_* command accepting a SQL command as an argument -supports bind variables. You can either

        • specify the -bind switch to provide a set with bind variable -values, or

        • specify the -bind switch to explicitly provide a list of -bind variable names and values, or

        • not specify a bind variable list at all, in which case Tcl variables are +

          Usage

          Every db_* command accepting a SQL command as an argument +supports bind variables. You can either

          • specify the -bind switch to provide a set with bind variable +values, or

          • specify the -bind switch to explicitly provide a list of +bind variable names and values, or

          • not specify a bind variable list at all, in which case Tcl variables are used as bind variables.

          -The default behavior (i.e., if the -bind switch is omitted) is +The default behavior (i.e., if the -bind switch is omitted) is that these procedures expect to find local variables that correspond in name to the referenced bind variables, e.g.:

           
           set user_id 123456
          -set role "administrator"
          +set role "administrator"
           
           db_foreach user_group_memberships_by_role {
               select g.group_id, g.group_name
          @@ -249,18 +249,18 @@
               and map.role = :role
           } {
               # do something for each group of which user 123456 is in the role
          -    # of "administrator"
          +    # of "administrator"
           }
           
           

          -The value of the local Tcl variable user_id (123456) is bound to -the user_id bind variable. -

          The -bind switch can takes the name of an ns_set +The value of the local Tcl variable user_id (123456) is bound to +the user_id bind variable. +

          The -bind switch can takes the name of an ns_set containing keys for each bind variable named in the query, e.g.:

           
           set bind_vars [ns_set create]
           ns_set put $bind_vars user_id 123456
          -ns_set put $bind_vars role "administrator"
          +ns_set put $bind_vars role "administrator"
           
           db_foreach user_group_memberships_by_role {
               select g.group_id, g.group_name
          @@ -270,11 +270,11 @@
               and map.role = :role
           } -bind $bind_vars {
               # do something for each group in which user 123456 has the role
          -    # of "administrator"
          +    # of "administrator"
           }
           
           

          -Alternatively, as an argument to -bind you can specify a list of +Alternatively, as an argument to -bind you can specify a list of alternating name/value pairs for bind variables:

           
          @@ -284,22 +284,22 @@
               where g.group_id = map.user_id
               and map.user_id = :user_id
               and map.role = :role
          -} -bind [list user_id 123456 role "administrator"] {
          +} -bind [list user_id 123456 role "administrator"] {
               # do something for each group in which user 123456 has the role
          -    # of "administrator"
          +    # of "administrator"
           }
           
          -

          Nulls and Bind Variables

          +

        Nulls and Bind Variables

        When processing a DML statement, Oracle coerces empty strings into -null. (This coercion does not occur in the -WHERE clause of a query, i.e. -col = '' and -col is null are not equivalent.) +null. (This coercion does not occur in the +WHERE clause of a query, i.e. +col = '' and +col is null are not equivalent.)

        As a result, when using bind variables, the only way to make Oracle set a -column value to null is to set the corresponding bind variable +column value to null is to set the corresponding bind variable to the empty string, since a bind variable whose value is the string -"null" will be interpreted as the literal string -"null".

        These Oracle quirks complicate the process of writing clear and abstract +"null" will be interpreted as the literal string +"null".

        These Oracle quirks complicate the process of writing clear and abstract DML difficult. Here is an example that illustrates why:

         
         #
        @@ -311,259 +311,259 @@
         #   );
         #
         
        -set bar ""
        -set baz ""
        +set bar ""
        +set baz ""
         
        -db_dml foo_create "insert into foo(bar, baz) values(:bar, :baz)"
        +db_dml foo_create "insert into foo(bar, baz) values(:bar, :baz)"
         #
        -# the values of the "bar" and "baz" columns in the new row are both
        +# the values of the "bar" and "baz" columns in the new row are both
         # null, because Oracle has coerced the empty string (even for the
        -# numeric column "bar") into null in both cases
        +# numeric column "bar") into null in both cases
         
         

        Since databases other than Oracle do not coerce empty strings into -null, this code has different semantics depending on the +null, this code has different semantics depending on the underlying database (i.e., the row that gets inserted may not have null as its column values), which defeats the purpose of SQL abstraction.

        Therefore, the Database Access API provides a database-independent way to -represent null (instead of the Oracle-specific idiom of the -empty string): db_null.

        Use it instead of the empty string whenever you want to set a column value -explicitly to null, e.g.:

        +represent null (instead of the Oracle-specific idiom of the
        +empty string): db_null.

        Use it instead of the empty string whenever you want to set a column value +explicitly to null, e.g.:

         
         set bar [db_null]
         set baz [db_null]
         
        -db_dml foo_create "insert into foo(bar, baz) values(:bar, :baz)"
        +db_dml foo_create "insert into foo(bar, baz) values(:bar, :baz)"
         #
        -# sets the values for both the "bar" and "baz" columns to null
        +# sets the values for both the "bar" and "baz" columns to null
         
        -

        SQL Abstraction

        +

        SQL Abstraction

        We now require that each SQL statement be assigned a logical name for the statement that is unique to the procedure or page in which it is defined. This is so that (eventually) we can implement logically named statements with alternative SQL for non-Oracle databases (e.g., Postgres). More on this later. -

        Placing Column Values in Arrays and Sets

        -Normally, db_foreach, db_0or1row, and -db_1row places the results of queries in Tcl variables, so you +

        Placing Column Values in Arrays and Sets

        +Normally, db_foreach, db_0or1row, and +db_1row places the results of queries in Tcl variables, so you can say:

         
        -db_foreach users_select "select first_names, last_name from users" {
        -    doc_body_append "<li>$first_names $last_name\n"
        +db_foreach users_select "select first_names, last_name from users" {
        +    doc_body_append "<li>$first_names $last_name\n"
         }
         
         

        However, sometimes this is not sufficient: you may need to examine the rows returned, to dynamically determine the set of columns returned by the query, or to avoid collisions with existing variables. You can use the --column_array and -column_set switches to -db_foreach, db_0or1row, and db_1row to +-column_array and -column_set switches to +db_foreach, db_0or1row, and db_1row to instruct the database routines to place the results in a Tcl array or -ns_set, respectively, where the keys are the column names and +ns_set, respectively, where the keys are the column names and the values are the column values. For example:

         
        -db_foreach users_select "select first_names, last_name from users" -column_set columns {
        +db_foreach users_select "select first_names, last_name from users" -column_set columns {
             # Now $columns is an ns_set.
        -    doc_body_append "<li>"
        +    doc_body_append "<li>"
             for { set i 0 } { $i < [ns_set size $columns] } { incr i } {
        -        doc_body_append "[ns_set key $columns $i] is [ns_set value $columns $i]. \n"
        +        doc_body_append "[ns_set key $columns $i] is [ns_set value $columns $i]. \n"
             }
         }
         
         

        will write something like: -

        • first_names is Jon. last_name is Salz.

        • first_names is Lars. last_name is Pind.

        • first_names is Michael. last_name is Yoon.

        API

        -Note that you never have to use ns_db anymore (including -ns_db gethandle)! Just start doing stuff, and (if you want) call -db_release_unused_handles when you're done as a hint to +

        • first_names is Jon. last_name is Salz.

        • first_names is Lars. last_name is Pind.

        • first_names is Michael. last_name is Yoon.

        API

        +Note that you never have to use ns_db anymore (including +ns_db gethandle)! Just start doing stuff, and (if you want) call +db_release_unused_handles when you're done as a hint to release the database handle. -

        db_null +

        db_null
        -db_null
        +db_null
         

        Returns a value which can be used in a bind variable to represent the SQL -value null. See Nulls and Bind Variables +value null. See Nulls and Bind Variables above.

        -db_foreach +db_foreach
        -db_foreach statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
        +db_foreach statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
             [ -column_array array_name | -column_set set_name ] \
             code_block [ if_no_rows if_no_rows_block ]
        -

        Performs the SQL query sql, executing -code_block once for each row with variables set to -column values (or a set or array populated if -column_array or -column_set is specified). If the query returns no rows, executes -if_no_rows_block (if provided).

        Example:

        +

        Performs the SQL query sql, executing +code_block once for each row with variables set to +column values (or a set or array populated if -column_array or +column_set is specified). If the query returns no rows, executes +if_no_rows_block (if provided).

        Example:

         
        -db_foreach select_foo "select foo, bar from greeble" {
        -    doc_body_append "<li>foo=$foo; bar=$bar\n"
        +db_foreach select_foo "select foo, bar from greeble" {
        +    doc_body_append "<li>foo=$foo; bar=$bar\n"
         } if_no_rows {
        -    doc_body_append "<li>There are no greebles in the database.\n"
        +    doc_body_append "<li>There are no greebles in the database.\n"
         }
         
         

        -The code block may contain break statements (which terminate the -loop and flush the database handle) and continue statements -(which continue to the next row of the loop).

        db_1row
        -db_1row statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
        +The code block may contain break statements (which terminate the
        +loop and flush the database handle) and continue statements
        +(which continue to the next row of the loop). 

        db_1row
        +db_1row statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
             [ -column_array array_name | -column_set set_name ]
        -

        Performs the SQL query sql, setting variables to +

        Performs the SQL query sql, setting variables to column values. Raises an error if the query does not return exactly 1 row.

        Example:

         
        -db_1row select_foo "select foo, bar from greeble where greeble_id = $greeble_id"
        +db_1row select_foo "select foo, bar from greeble where greeble_id = $greeble_id"
         # Bombs if there's no such greeble!
         # Now $foo and $bar are set.
         
        -
        db_0or1row
        -db_0or1row statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
        +
        db_0or1row
        +db_0or1row statement-name sql [ -bind bind_set_id | -bind bind_value_list ] \
             [ -column_array array_name | -column_set set_name ]
        -

        Performs the SQL query sql. If a row is returned, +

        Performs the SQL query sql. If a row is returned, sets variables to column values and returns 1. If no rows are returned, -returns 0. If more than one row is returned, throws an error.

        db_string
        -db_string statement-name sql [ -default default ] [ -bind bind_set_id | -bind bind_value_list ]
        +returns 0. If more than one row is returned, throws an error. 

        db_string
        +db_string statement-name sql [ -default default ] [ -bind bind_set_id | -bind bind_value_list ]
         

        Returns the first column of the result of SQL query -sql. If sql doesn't return a -row, returns default (or throws an error if -default is unspecified). Analogous to -database_to_tcl_string and -database_to_tcl_string_or_null. +sql. If sql doesn't return a +row, returns default (or throws an error if +default is unspecified). Analogous to +database_to_tcl_string and +database_to_tcl_string_or_null. -

        db_nextval
        -db_nextval sequence-name
        +

        db_nextval
        +db_nextval sequence-name
         

        Returns the next value for the sequence sequence-name (using a -SQL statement like SELECT sequence-name.nextval FROM -DUAL). If sequence pooling is enabled for the sequence, transparently +SQL statement like SELECT sequence-name.nextval FROM +DUAL). If sequence pooling is enabled for the sequence, transparently uses a value from the pool if available to save a round-trip to the database. -

        db_list
        -db_list statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        +

        db_list
        +db_list statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
         

        Returns a Tcl list of the values in the first column of the result of SQL -query sql. If sql doesn't +query sql. If sql doesn't return any rows, returns an empty list. Analogous to -database_to_tcl_list. +database_to_tcl_list. -

        db_list_of_lists
        -db_list_of_lists statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        +

        db_list_of_lists
        +db_list_of_lists statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
         

        Returns a Tcl list, each element of which is a list of all column values -in a row of the result of SQL query sql. If -sql doesn't return any rows, returns an empty list. -(Analogous to database_to_tcl_list_list.) +in a row of the result of SQL query sql. If +sql doesn't return any rows, returns an empty list. +(Analogous to database_to_tcl_list_list.) -

        db_list_of_ns_sets
        -db_list_of_ns_sets statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        +

        db_list_of_ns_sets
        +db_list_of_ns_sets statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
         

        Returns a list of ns_sets with the values of each column of each row - returned by the sql query specified. -

        db_dml
        -db_dml statement-name sql \
        +	returned by the sql query specified.
        +  

        db_dml
        +db_dml statement-name sql \
             [ -bind bind_set_id | -bind bind_value_list ] \
             [ -blobs blob_list | -clobs clob_list |
               -blob_files blob_file_list | -clob_files clob_file_list ]
        -

        Performs the DML or DDL statement sql.

        If a length-n list of blobs or clobs is provided, then the SQL +

        Performs the DML or DDL statement sql.

        If a length-n list of blobs or clobs is provided, then the SQL should return n blobs or clobs into the bind variables -:1, :2, ... :n. -blobs or clobs, if specified, +:1, :2, ... :n. +blobs or clobs, if specified, should be a list of individual BLOBs or CLOBs to insert; -blob_files or clob_files, if +blob_files or clob_files, if specified, should be a list of paths to files containing the data to -insert. Only one of -blobs, -clobs, --blob_files, and -clob_files may be provided.

        Example:

        +insert. Only one of -blobs, -clobs,
        +-blob_files, and -clob_files may be provided.

        Example:

         
        -db_dml insert_photos "
        +db_dml insert_photos "
                 insert photos(photo_id, image, thumbnail_image)
                 values(photo_id_seq.nextval, empty_blob(), empty_blob())
                 returning image, thumbnail_image into :1, :2
        -    "  -blob_files [list "/var/tmp/the_photo" "/var/tmp/the_thumbnail"] 
        +    "  -blob_files [list "/var/tmp/the_photo" "/var/tmp/the_thumbnail"] 
         
         

        -This inserts a new row into the photos table, with the contents -of the files /var/tmp/the_photo and -/var/tmp/the_thumbnail in the image and -thumbnail columns, respectively. +This inserts a new row into the photos table, with the contents +of the files /var/tmp/the_photo and +/var/tmp/the_thumbnail in the image and +thumbnail columns, respectively.

        -db_write_clob, -db_write_blob, -db_blob_get_file +db_write_clob, +db_write_blob, +db_blob_get_file
        -db_write_clob statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        +db_write_clob statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
         
        -db_write_blob statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        +db_write_blob statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
         
        -db_blob_get_file statement-name sql [ -bind bind_set_id | -bind bind_value_list ]
        -

        Analagous to ns_ora write_clob/write_blob/blob_get_file. +db_blob_get_file statement-name sql [ -bind bind_set_id | -bind bind_value_list ] +

        Analagous to ns_ora write_clob/write_blob/blob_get_file. -

        db_release_unused_handles
        -db_release_unused_handles
        -

        Releases any allocated, unused database handles.

        db_transaction
        -db_transaction code_block [ on_error { code_block } ]
        -

        Executes code_block transactionally. Nested -transactions are supported (end transaction is transparently -ns_db dml'ed when the outermost transaction completes). The -db_abort_transaction command can be used to abort all levels of -transactions. It is possible to specify an optional on_error +

        db_release_unused_handles
        +db_release_unused_handles
        +

        Releases any allocated, unused database handles.

        db_transaction
        +db_transaction code_block [ on_error { code_block } ]
        +

        Executes code_block transactionally. Nested +transactions are supported (end transaction is transparently +ns_db dml'ed when the outermost transaction completes). The +db_abort_transaction command can be used to abort all levels of +transactions. It is possible to specify an optional on_error code block that will be executed if some code in code_block throws -an exception. The variable errmsg will be bound in that scope. -If there is no on_error code, any errors will be propagated.

        Example:

        +an exception. The variable errmsg will be bound in that scope.
        +If there is no on_error code, any errors will be propagated. 

        Example:

         
         proc replace_the_foo { col } {
             db_transaction {
        -        db_dml "delete from foo"
        -        db_dml "insert into foo(col) values($col)"
        +        db_dml "delete from foo"
        +        db_dml "insert into foo(col) values($col)"
             }
         }
         
         proc print_the_foo {} {
        -    doc_body_append "foo is [db_string "select col from foo"]<br>\n"
        +    doc_body_append "foo is [db_string "select col from foo"]<br>\n"
         }
         
         replace_the_foo 8
        -print_the_foo ; # Writes out "foo is 8"
        +print_the_foo ; # Writes out "foo is 8"
         
         db_transaction {
             replace_the_foo 14
        -    print_the_foo ; # Writes out "foo is 14"
        -    db_dml "insert into some_other_table(col) values(999)"
        +    print_the_foo ; # Writes out "foo is 14"
        +    db_dml "insert into some_other_table(col) values(999)"
             ...
             db_abort_transaction
         } on_error {
        -    doc_body_append "Error in transaction: $errmsg"
        +    doc_body_append "Error in transaction: $errmsg"
         }
             
         
        -print_the_foo ; # Writes out "foo is 8"
        +print_the_foo ; # Writes out "foo is 8"
         
        -
        db_abort_transaction +
        db_abort_transaction
        -db_abort_transaction
        +db_abort_transaction
         

        Aborts all levels of a transaction. That is if this is called within several nested transactions, all of them are terminated. Use this insetead of -db_dml "abort" "abort transaction". +db_dml "abort" "abort transaction". -

        db_multirow
        -db_multirow [ -local ] [ -append ] [ -extend column_list ] \
        +

        db_multirow
        +db_multirow [ -local ] [ -append ] [ -extend column_list ] \
             var-name statement-name sql \
             [ -bind bind_set_id | -bind bind_value_list ] \
             code_block [ if_no_rows if_no_rows_block ]
         

        - Performs the SQL query sql, saving results in variables + Performs the SQL query sql, saving results in variables of the form - var_name:1, var_name:2, etc, - setting var_name:rowcount to the total number - of rows, and setting var_name:columns to a + var_name:1, var_name:2, etc, + setting var_name:rowcount to the total number + of rows, and setting var_name:columns to a list of column names.

        Each row also has a column, rownum, automatically added and set to the row number, starting with 1. Note that this will override any column in the SQL statement named 'rownum', also if you're using the Oracle rownum pseudo-column.

        - If the -local is passed, the variables defined + If the -local is passed, the variables defined by db_multirow will be set locally (useful if you're compiling dynamic templates in a function or similar situations).

        @@ -576,19 +576,19 @@ multirow.

        You may also add additional, computed columns to the multirow, using the - -extend { col_1 col_2 ... } switch. This is + -extend { col_1 col_2 ... } switch. This is useful for things like constructing a URL for the object retrieved by the query.

        If you're constructing your multirow through multiple queries with the same set of columns, but with different rows, you can use the - -append switch. This causes the rows returned by this query + -append switch. This causes the rows returned by this query to be appended to the rows already in the multirow, instead of starting a clean multirow, as is the normal behavior. The columns must match the columns in the original multirow, or an error will be thrown.

        - Your code block may call continue in order to skip a row - and not include it in the multirow. Or you can call break + Your code block may call continue in order to skip a row + and not include it in the multirow. Or you can call break to skip this row and quit looping.

        @@ -603,28 +603,28 @@ } { set user_url [acs_community_member_url -user_id $user_id] } -

        db_resultrows
        -db_resultrows
        +    
        db_resultrows
        +db_resultrows
         

        Returns the number of rows affected or returned by the previous statement. -

        db_with_handle
        -db_with_handle var code_block
        -

        Places a database handle into the variable var and -executes code_block. This is useful when you don't -want to have to use the new API (db_foreach, -db_1row, etc.), but need to use database handles explicitly.

        Example:

        +

        db_with_handle
        +db_with_handle var code_block
        +

        Places a database handle into the variable var and +executes code_block. This is useful when you don't +want to have to use the new API (db_foreach, +db_1row, etc.), but need to use database handles explicitly.

        Example:

         
         proc lookup_the_foo { foo } {
             db_with_handle db {
        -        return [db_string unused "select ..."]
        +        return [db_string unused "select ..."]
             }
         }
         
         db_with_handle db {
             # Now there's a database handle in $db.
        -    set selection [ns_db select $db "select foo from bar"]
        +    set selection [ns_db select $db "select foo from bar"]
             while { [ns_db getrow $db $selection] } {
                 set_variables_after_query
         
        @@ -633,96 +633,96 @@
         }
         
         
        - - + + db_name - - + +
        -			
        -				db_name
        -			
        +			
        +				db_name
        +			
         		

        Returns the name of the database, as returned by the driver.

        - - + + db_type - - + +
        -			
        -				db_type
        -			
        +			
        +				db_type
        +			
         		

        Returns the RDBMS type (i.e. oracle, postgresql) this OpenACS installation is using. The nsv ad_database_type is set up during the bootstrap process.

        - - + + db_compatible_rdbms_p - - + +
        -			db_compatible_rdbms_p db_type
        +			db_compatible_rdbms_p db_type
         		

        Returns 1 if the given db_type is compatible with the current RDBMS.

        - - + + db_package_supports_rdbms_p - - + +
        -			db_package_supports_rdbms_p db_type_list
        +			db_package_supports_rdbms_p db_type_list
         		

        Returns 1 if db_type_list contains the current RDMBS type. A package intended to run with a given RDBMS must note this in it's package info file regardless of whether or not it actually uses the database.

        - - + + db_legacy_package_p - - + +
        -			db_legacy_package_p db_type_list
        +			db_legacy_package_p db_type_list
         		

        Returns 1 if the package is a legacy package. We can only tell for certain if it explicitly supports Oracle 8.1.6 rather than the OpenACS more general oracle.

        - - + + db_version - - + +
        -			db_version
        +			db_version
         		

        Returns the RDBMS version (i.e. 8.1.6 is a recent Oracle version; 7.1 a recent PostgreSQL version.

        - - + + db_current_rdbms - - + +
        -			db_current_rdbms
        +			db_current_rdbms
         		

        Returns the current rdbms type and version.

        - - + + db_known_database_types - - + +
        -			db_known_database_types
        +			db_known_database_types
         		

        Returns a list of three-element lists describing the database engines known to OpenACS. Each sublist contains the internal database name (used in file - paths, etc), the driver name, and a "pretty name" to be used in selection + paths, etc), the driver name, and a "pretty name" to be used in selection forms displayed to the user.

        The nsv containing the list is initialized by the bootstrap script and should Index: openacs-4/packages/acs-core-docs/www/db-api.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/db-api.html,v diff -u -N -r1.46 -r1.46.2.1 --- openacs-4/packages/acs-core-docs/www/db-api.html 13 Sep 2009 23:54:39 -0000 1.46 +++ openacs-4/packages/acs-core-docs/www/db-api.html 18 Jun 2010 21:29:34 -0000 1.46.2.1 @@ -1,5 +1,5 @@ -The OpenACS Database Access API

        The OpenACS Database Access API

        +The OpenACS Database Access API

        The OpenACS Database Access API

        By Pete Su and Jon Salz. Modified by Roberto Mello.

        Overview

        One of OpenACS's great strengths is that code written for it is @@ -8,7 +8,7 @@ coherent API for database access which makes this even easier.

        More detailed information about the DB api is available at - ???. + Database Access API.

        DB API Examples

        The OpenACS database API is meant to save developers from making common mistakes and to provide a more structured syntax for Index: openacs-4/packages/acs-core-docs/www/dev-guide.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/dev-guide.html,v diff -u -N -r1.32 -r1.32.2.1 --- openacs-4/packages/acs-core-docs/www/dev-guide.html 13 Sep 2009 23:54:39 -0000 1.32 +++ openacs-4/packages/acs-core-docs/www/dev-guide.html 18 Jun 2010 21:29:34 -0000 1.32.2.1 @@ -1,2 +1,2 @@ -Chapter 10. Development Reference

        View comments on this page at openacs.org
        +Chapter 11. Development Reference
        View comments on this page at openacs.org
        Index: openacs-4/packages/acs-core-docs/www/doc-standards.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/doc-standards.html,v diff -u -N -r1.14 -r1.14.2.1 --- openacs-4/packages/acs-core-docs/www/doc-standards.html 13 Sep 2009 23:54:39 -0000 1.14 +++ openacs-4/packages/acs-core-docs/www/doc-standards.html 18 Jun 2010 21:29:34 -0000 1.14.2.1 @@ -1,2 +1,2 @@ -Chapter 12. Documentation Standards
        View comments on this page at openacs.org
        +Chapter 13. Documentation Standards
        View comments on this page at openacs.org
        Index: openacs-4/packages/acs-core-docs/www/docbook-primer.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/docbook-primer.html,v diff -u -N -r1.48 -r1.48.2.1 --- openacs-4/packages/acs-core-docs/www/docbook-primer.html 13 Sep 2009 23:54:39 -0000 1.48 +++ openacs-4/packages/acs-core-docs/www/docbook-primer.html 18 Jun 2010 21:29:34 -0000 1.48.2.1 @@ -1,5 +1,5 @@ -OpenACS Documentation Guide

        OpenACS Documentation Guide

        +OpenACS Documentation Guide

        OpenACS Documentation Guide

        By Claus Rasmussen, with additions by Roberto Mello, Vinod Kurup, and the OpenACS Community

        Overview of OpenACS Documentation

        OpenACS™ is a powerful system with @@ -557,7 +557,7 @@

    OpenACS Documentation Strategy

    OpenACS documentation development is subject to the constraints of the software project development and release - methods and cycles (Section , “Using CVS with OpenACS”). + methods and cycles (???). Essentially, all phases of work may be active to accommodate the asynchronous nature of multiple subprojects evolving by the efforts of a global base of participants with culturally @@ -578,7 +578,7 @@ DTD. The remaining discussion is about publishing using Docbook.

    - + is a publishing standard based on XML with similar goals to the OpenACS Documentation project. Some specific reasons why we are using DocBook:

    • @@ -641,7 +641,7 @@ list of elements and use more exotic features in your documents. The list is made up of SGML-elements but basically the same elements are valid in the XML DTD as long as you remember to: - +

      • Always close your tags with corresponding end-tags and to not use other tag minimization @@ -690,7 +690,7 @@ The documentation for each package will make up a little "book" that is structured like this - examples are emphasized: - +

             book                        : Docs for one package - templating
        @@ -714,20 +714,20 @@
               sources of these DocBook documents
               to get an idea of how they are tied together.
             

      Headlines, Sections

      - + Given that your job starts at the sect1-level, all your documents should open with a <sect1>-tag and end with the corresponding </sect1>.

      - + You need to feed every <sect1> two attributes. The first attribute, id, is standard and can be used with all elements. It comes in very handy when interlinking between documents (more about this when talking about links in Section , “Links”). The value of id has to be unique throughout the book you're making since the id's in your sect1's will turn into filenames when the book is parsed into HTML.

      - + The other attribute is xreflabel. The value of this is the text that will appear as the link when referring to this sect1.

      @@ -742,7 +742,7 @@ </sect1>

      - + Inside this container your document will be split up into <sect2>'s, each with the same requirements - id and xreflabel @@ -751,7 +751,7 @@ When it comes to naming your sect2's and below, prefix them with some abbreviation of the id in the sect1 such as requirements-overview.

      Code

      - + For displaying a snippet of code, a filename or anything else you just want to appear as a part of a sentence, we use <computeroutput> @@ -769,12 +769,12 @@ tag around text that has been wrapped by combinations of <computeroutput> and <userinput>

      Links

      - + Linking falls into two different categories: inside the book you're making and outside:

      1. Inside linking, cross-referencing other parts of your book

      By having unique id's you can cross-reference any part of your book with a simple tag, regardless of where that part is. -

      Check out how I link to a subsection of the Developer's Guide:

      Put this in your XML:

      +      

      Check out how I link to a subsection of the Developer's Guide:

      Put this in your XML:

       - Find information about creating a package in
       <xref linkend="packages-making-a-package"></xref>.
       

      And the output is:

      @@ -798,7 +798,7 @@
               packages-looks, the
               parser will try its best to explain where the link takes you.
             

      2. Linking outside the documentation

      - + If you're hyper-linking out of the documentation, it works almost the same way as HTML - the tag is just a little different @@ -819,7 +819,7 @@ for you.

      - + To insert a graphic we use the elements <mediaobject>, <imageobject>, @@ -845,7 +845,7 @@ Put your graphics in a separate directory ("images") and link to them only with relative paths.

      Lists

      - + Here's how you make the DocBook equivalent of the three usual HTML-lists:

      1. How to make an <ul>

      Making an unordered list is pretty much like doing the same thing in HTML - if you close your <li>, that is. The only differences are that each list item has to be wrapped in something more, such as @@ -890,7 +890,7 @@ </variablelist>

      Tables

      - + DocBook supports several types of tables, but in most cases, the <informaltable> is enough: @@ -927,7 +927,7 @@ <table> for an example.

      Emphasis

      - + Our documentation uses two flavors of emphasis - italics and bold type. DocBook uses one - <emphasis>.

      @@ -981,7 +981,7 @@ to PSGML Mode. nXML Mode can validate a file as it is edited.

    • David Lutterkort - wrote an intro to the PSGML Mode in Emacs + wrote an intro to the PSGML Mode in Emacs

    • James Clark's free Java parser XP. Note that @@ -1003,4 +1003,4 @@ script with directions (now via archive.org) that gets you most of the way. -

    View comments on this page at openacs.org
    +

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/eng-standards-constraint-naming.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/eng-standards-constraint-naming.html,v diff -u -N -r1.44 -r1.44.2.1 --- openacs-4/packages/acs-core-docs/www/eng-standards-constraint-naming.html 13 Sep 2009 23:54:39 -0000 1.44 +++ openacs-4/packages/acs-core-docs/www/eng-standards-constraint-naming.html 18 Jun 2010 21:29:34 -0000 1.44.2.1 @@ -1,5 +1,5 @@ -Constraint naming standard

    Constraint naming standard

    By Michael Bryzek

    +Constraint naming standard

    Constraint naming standard

    By Michael Bryzek

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    The Big Picture

    Index: openacs-4/packages/acs-core-docs/www/eng-standards-filenaming.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/eng-standards-filenaming.html,v diff -u -N -r1.44 -r1.44.2.1 --- openacs-4/packages/acs-core-docs/www/eng-standards-filenaming.html 13 Sep 2009 23:54:39 -0000 1.44 +++ openacs-4/packages/acs-core-docs/www/eng-standards-filenaming.html 18 Jun 2010 21:29:34 -0000 1.44.2.1 @@ -1,5 +1,5 @@ -ACS File Naming and Formatting Standards

    ACS File Naming and Formatting Standards

    By Michael Yoon and Aurelius Prochazka

    +ACS File Naming and Formatting Standards

    ACS File Naming and Formatting Standards

    By Michael Yoon and Aurelius Prochazka

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    @@ -95,7 +95,7 @@ This can be at the top or bottom of the file.

    Using ad_page_contract

    For non-library Tcl files (those not in the private Tcl directory), -use ad_page_contract +use ad_page_contract after the file path comment (this supersedes set_the_usual_form_variables and ad_return_complaint). Here is an example of using ad_page_contract, which serves both documentation and page input @@ -141,7 +141,7 @@ set_the_usual_form_variables. The use of bind variables makes such previous variable syntax obsolete.

    Using ad_library

    -For shared Tcl library files, use ad_library after +For shared Tcl library files, use ad_library after the file path comment. Its only argument is a doc_string in the standard (javadoc-style) format, like ad_page_contract. Don't forget to put the @cvs-id in Index: openacs-4/packages/acs-core-docs/www/eng-standards-plsql.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/eng-standards-plsql.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/eng-standards-plsql.html 13 Sep 2009 23:54:39 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/eng-standards-plsql.html 18 Jun 2010 21:29:34 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -PL/SQL Standards

    PL/SQL Standards

    +PL/SQL Standards

    PL/SQL Standards

    By Richard Li and Yon Feldman

    OpenACS docs are written by the named authors, and may be edited Index: openacs-4/packages/acs-core-docs/www/eng-standards-versioning.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/eng-standards-versioning.html,v diff -u -N -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-core-docs/www/eng-standards-versioning.html 13 Sep 2009 23:54:39 -0000 1.47 +++ openacs-4/packages/acs-core-docs/www/eng-standards-versioning.html 18 Jun 2010 21:29:34 -0000 1.47.2.1 @@ -1,7 +1,5 @@ -Release Version Numbering

    Release Version Numbering

    ($Id$)

    By Ron Henderson, Revised by Joel Aufrecht

    +Release Version Numbering

    Release Version Numbering

    ($Id$)

    By Ron Henderson, Revised by Joel Aufrecht

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    @@ -91,6 +89,4 @@

  • If you are working on a pre-release version of a package, use the current package version as OLDVERSION. Increment the package version as appropriate (see above) and use the new version as NEWVERSION. For example, if you are working on 2.0.1d3, make it 2.0.1d4 and use upgrade-2.0.1d3-2.0.1d4.sql.

  • Database upgrades should be confined to development releases, not alpha or beta releases.

  • Never use a final release number as a NEWVERSION. If you do, then it is impossible to add any more database upgrades without incrementing the overall package version.

  • Use only the d, a, and b letters in OLDVERSION and NEWVERSION. rc is not supported by OpenACS APM.

  • The distance from OLDVERSION to NEWVERSION should never span a release. For example if we had a bug fix in acs-kernel on 5.1.0 you wouldn't want a file upgrade-5.0.4-5.1.0d1.sql since if you subsequently need to provide a 5.0.4-5.0.5 upgrade you will have to rename the 5.0.4-5.1.0 upgrade since you can't have upgrades which overlap like that. Instead, use upgrade-5.1.0d1-5.1.0d2.sql -

  • View comments on this page at openacs.org
    +

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/eng-standards.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/eng-standards.html,v diff -u -N -r1.28 -r1.28.2.1 --- openacs-4/packages/acs-core-docs/www/eng-standards.html 13 Sep 2009 23:54:39 -0000 1.28 +++ openacs-4/packages/acs-core-docs/www/eng-standards.html 18 Jun 2010 21:29:34 -0000 1.28.2.1 @@ -1,4 +1,2 @@ -Chapter 11. Engineering Standards
    View comments on this page at openacs.org
    +Chapter 12. Engineering Standards
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/ext-auth-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/ext-auth-requirements.html,v diff -u -N -r1.36 -r1.36.2.1 --- openacs-4/packages/acs-core-docs/www/ext-auth-requirements.html 13 Sep 2009 23:54:40 -0000 1.36 +++ openacs-4/packages/acs-core-docs/www/ext-auth-requirements.html 18 Jun 2010 21:29:34 -0000 1.36.2.1 @@ -1,5 +1,5 @@ -External Authentication Requirements

    External Authentication Requirements

    Vision

    People have plenty of usernames and passwords already, we +External Authentication Requirements

    External Authentication Requirements

    Vision

    People have plenty of usernames and passwords already, we don't want them to have yet another. We want people to be able to log in to OpenACS with the same password they use to log in to any other system.

    Besides, administrators have better things to do than create @@ -45,7 +45,7 @@ only one implementation of the authentication API, namly the one included in OpenACS Core.

  • Authentication Driver API: The service contract which authentication drivers implement.

  • Conceptual Pictures

    Authentication:

    -

    Account Management (NO PICTURE YET)

    Batch Synchronization (NO PICTURE YET)

    Requirements

    New API

    FeatureStatusDescription
    New API
    EXT-AUTH-01AExtend Authentication/Acct Status API
    EXT-AUTH-03AAccount Creation API
    EXT-AUTH-05APassword Management API
    EXT-AUTH-30AAuthority Management API

    Login

    FeatureStatusDescription
    Login
    EXT-AUTH-04ARewrite login, register, and admin pages to use APIs
    EXT-AUTH-38Aad_form complain feature
    EXT-AUTH-19ARewrite password recovery to use API
    EXT-AUTH-21ARewrite email verification with API
    EXT-AUTH-28AUsername is email switch

    Users will log in using a username, a authority, and a +

    Account Management (NO PICTURE YET)

    Batch Synchronization (NO PICTURE YET)

    Requirements

    New API

    FeatureStatusDescription
    New API
    EXT-AUTH-01AExtend Authentication/Acct Status API
    EXT-AUTH-03AAccount Creation API
    EXT-AUTH-05APassword Management API
    EXT-AUTH-30AAuthority Management API

    Login

    FeatureStatusDescription
    Login
    EXT-AUTH-04ARewrite login, register, and admin pages to use APIs
    EXT-AUTH-38Aad_form complain feature
    EXT-AUTH-19ARewrite password recovery to use API
    EXT-AUTH-21ARewrite email verification with API
    EXT-AUTH-28AUsername is email switch

    Users will log in using a username, a authority, and a password. The authority is the source for user/password verification. OpenACS can be an authority itself.

    Each user in OpenACS will belong to exactly one authority, which can either be the "local" OpenACS users table, in which case the @@ -376,4 +376,4 @@ PAM specification

  • Draft Proposal by Andrew Grumet.

  • Yale CAS, a centrl authentication service a' la - Passport.

  • Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    1Updated work-in-progress for consortium-sponsored ext-auth work at Collaboraid.20 Aug 2003Joel Aufrecht
    View comments on this page at openacs.org
    + Passport.

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    1Updated work-in-progress for consortium-sponsored ext-auth work at Collaboraid.20 Aug 2003Joel Aufrecht
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/filename.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/filename.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/filename.html 13 Sep 2009 23:54:40 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/filename.html 18 Jun 2010 21:29:34 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -Detailed Design Documentation Template

    Detailed Design Documentation Template

    By You

    Start Note

    +Detailed Design Documentation Template

    Detailed Design Documentation Template

    By You

    Start Note

    NOTE: Some of the sections of this template may not apply to your package, e.g. there may be no user-visible UI elements for a component of the OpenACS Core. Furthermore, it may be easier in some circumstances @@ -115,7 +115,7 @@ within the OpenACS, this section's details are likely to shift from UI specifics to template interface specifics.

    Configuration/Parameters

    - Under OpenACS 5.5.0, parameters are set at two levels: at the global level by + Under OpenACS 5.6.0, parameters are set at two levels: at the global level by the OpenACS-admin, and at the subsite level by a sub-admin. In this section, list and discuss both levels of parameters.

    Future Improvements/Areas of Likely Change

    Index: openacs-4/packages/acs-core-docs/www/form-builder.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/form-builder.html,v diff -u -N -r1.26 -r1.26.2.1 --- openacs-4/packages/acs-core-docs/www/form-builder.html 13 Sep 2009 23:54:40 -0000 1.26 +++ openacs-4/packages/acs-core-docs/www/form-builder.html 18 Jun 2010 21:29:34 -0000 1.26.2.1 @@ -1,12 +1,12 @@ -Using Form Builder: building html forms dynamically

    Using Form Builder: building html forms dynamically

    Overview

    ($Id$)
    +Using Form Builder: building html forms dynamically

    Using Form Builder: building html forms dynamically

    Overview

    ($Id$)
    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    OpenACS has a form manager called ad_form. Ad_form has an adaptable UI. Error handling includes inline error reporting, and is customizable. However, ad_form can be tricky to use. In addition to this document, the ad_form api - documentation is helpful.

    Multi-part Elements

    Some elements have more than one choice, or can submit more than one value.

    SELECT elements

    1. Creating the form element. Populate a list of lists with values for the option list.

      set foo_options [db_list_of_lists foo_option_list "
      + documentation is helpful.

    Multi-part Elements

    Some elements have more than one choice, or can submit more than one value.

    SELECT elements

    1. Creating the form element. Populate a list of lists with values for the option list.

      set foo_options [db_list_of_lists foo_option_list "
           select foo,
                  foo_id
             from foos
      @@ -51,5 +51,5 @@
           ns_set print $mypage
       }
           

    Tips for form widgets

    Here are some tips for dealing with some of the form widgets:

    Current widget

    Common Errors

    Here are some common errors and what to do when you - encounter them:

    Error when selecting values

    This generally happens when there is an error in your - query.

    View comments on this page at openacs.org
    + encounter them:

    Error when selecting values

    This generally happens when there is an error in your + query.

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/groups-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/groups-design.html,v diff -u -N -r1.30 -r1.30.2.1 --- openacs-4/packages/acs-core-docs/www/groups-design.html 13 Sep 2009 23:54:40 -0000 1.30 +++ openacs-4/packages/acs-core-docs/www/groups-design.html 18 Jun 2010 21:29:34 -0000 1.30.2.1 @@ -1,5 +1,5 @@ -Groups Design

    Groups Design

    By Rafael H. Schloming and Mark Thomas

    +Groups Design

    Groups Design

    By Rafael H. Schloming and Mark Thomas

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Essentials

    View comments on this page at openacs.org
    +
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/groups-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/groups-requirements.html,v diff -u -N -r1.30 -r1.30.2.1 --- openacs-4/packages/acs-core-docs/www/groups-requirements.html 13 Sep 2009 23:54:40 -0000 1.30 +++ openacs-4/packages/acs-core-docs/www/groups-requirements.html 18 Jun 2010 21:29:34 -0000 1.30.2.1 @@ -1,5 +1,5 @@ -Groups Requirements

    Groups Requirements

    By Rafael H. Schloming, Mark Thomas

    +Groups Requirements

    Groups Requirements

    By Rafael H. Schloming, Mark Thomas

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    Almost all database-backed websites have users, and need to model the Index: openacs-4/packages/acs-core-docs/www/high-avail.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/high-avail.html,v diff -u -N -r1.20 -r1.20.2.1 --- openacs-4/packages/acs-core-docs/www/high-avail.html 13 Sep 2009 23:54:40 -0000 1.20 +++ openacs-4/packages/acs-core-docs/www/high-avail.html 18 Jun 2010 21:29:34 -0000 1.20.2.1 @@ -1,2 +1,2 @@ -High Availability/High Performance Configurations

    High Availability/High Performance Configurations

    See also Section , “Running a PostgreSQL database on another server”.

    Figure 6.1. Multiple-server configuration

    Multiple-server configuration
    View comments on this page at openacs.org
    +High Availability/High Performance Configurations

    High Availability/High Performance Configurations

    See also Section , “Running a PostgreSQL database on another server”.

    Figure 6.1. Multiple-server configuration

    Multiple-server configuration
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/how-do-I.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/how-do-I.html,v diff -u -N -r1.23 -r1.23.2.1 --- openacs-4/packages/acs-core-docs/www/how-do-I.html 13 Sep 2009 23:54:40 -0000 1.23 +++ openacs-4/packages/acs-core-docs/www/how-do-I.html 18 Jun 2010 21:29:34 -0000 1.23.2.1 @@ -1,7 +1,7 @@ -How Do I?

    How Do I?

    How do I edit the front page of a new site through a web interface?

    The easiest way is to install the Edit-This-Page package.

    1. Log in to the web site as an administrator.

    2. Click on Admin > Install Software > Install from OpenACS Repository / Install new application

    3. Choose Edit This Page and install

    4. Follow the instructions within Edit This Page (the link will only work after Edit This Page is installed).

    How do I let anybody who registers post to a weblog?

    Go to /admin/permissions and grant Create to Registered Users

    How do I replace the front page of a new site with the front page of an application on that site

    Suppose you install a new site and install Weblogger, and you want all visitors to see weblogger automatically.

    1. On the front page, click the Admin button.

    2. On the administration page, click Parameters link.

    3. Change the parameter IndexRedirectUrl to be the URI of the desired application. For a default weblogger installation, this would be weblogger/. Note the trailing slash.

    How do I put custom functionality on front page of a new site?

    Every page within an OpenACS site is part of a subsite More information). The home page of the entire site is the front page is a special, default instance of a subsite, served from /var/lib/aolserver/$OPENACS_SERVICE_NAME/www. If an index page is not found there, the default index page for all subsites is used. To customize the code on the front page, copy the default index page from the Subsite package to the Main site and edit it:

    1. cp /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-subsite/www/index* /var/lib/aolserver/$OPENACS_SERVICE_NAME/www
    2. Edit the new index.adp to change the text; you shouldn't need to edit index.tcl unless you are adding new functionality.

    How do I change the site-wide style?

    Almost all pages on an OpenACS site use ACS Templating, and so their appearance is driven by a layer of different files. Let's examine how this works:

    • +How Do I?

      How Do I?

      How do I edit the front page of a new site through a web interface?

      The easiest way is to install the Edit-This-Page package.

      1. Log in to the web site as an administrator.

      2. Click on Admin > Install Software > Install from OpenACS Repository / Install new application

      3. Choose Edit This Page and install

      4. Follow the instructions within Edit This Page (the link will only work after Edit This Page is installed).

      How do I let anybody who registers post to a weblog?

      Go to /admin/permissions and grant Create to Registered Users

      How do I replace the front page of a new site with the front page of an application on that site

      Suppose you install a new site and install Weblogger, and you want all visitors to see weblogger automatically.

      1. On the front page, click the Admin button.

      2. On the administration page, click Parameters link.

      3. Change the parameter IndexRedirectUrl to be the URI of the desired application. For a default weblogger installation, this would be weblogger/. Note the trailing slash.

      How do I put custom functionality on front page of a new site?

      Every page within an OpenACS site is part of a subsite More information). The home page of the entire site is the front page is a special, default instance of a subsite, served from /var/lib/aolserver/$OPENACS_SERVICE_NAME/www. If an index page is not found there, the default index page for all subsites is used. To customize the code on the front page, copy the default index page from the Subsite package to the Main site and edit it:

      1. cp /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-subsite/www/index* /var/lib/aolserver/$OPENACS_SERVICE_NAME/www
      2. Edit the new index.adp to change the text; you shouldn't need to edit index.tcl unless you are adding new functionality.

      How do I change the site-wide style?

      Almost all pages on an OpenACS site use ACS Templating, and so their appearance is driven by a layer of different files. Let's examine how this works:

      • A templated page uses an ADP/TCL pair. The first line in the ADP file is usually:

        <master>

        If it appears exactly like this, without any arguments, the template processer uses default-master for that subsite. For pages in /var/lib/aolserver/$OPENACS_SERVICE_NAME/www, this is /var/lib/aolserver/$OPENACS_SERVICE_NAME/www/default-master.adp and the associated .tcl file. -

      • The default-master is itself a normal ADP page. It draws the subsite navigation elements and invokes site-master (/var/lib/aolserver/$OPENACS_SERVICE_NAME/www/site-master.adp and .tcl)

      • The site-master draws site-wide navigation elements and invokes blank-master (/var/lib/aolserver/$OPENACS_SERVICE_NAME/www/blank-master.adp and .tcl).

      • Blank-master does HTML housekeeping and provides a framework for special sitewide navigation "meta" elements such as Translator widgets and Admin widgets.

      Figure 4.1. Site Templates

      Site Templates

      How do I diagnose a permissions problem?

      • Steps to Reproduce. The events package does not allow users to register for new events.

        1. Go to the http://yourserver.net/events as a visitor (ie, log out and, if necessary, clear cookies). This in on a 4.6.3 site with events version 0.1d3.

        2. Select an available event

        3. A link such as Registration: Deadline is 03/15/2004 10:00am. +

        4. The default-master is itself a normal ADP page. It draws the subsite navigation elements and invokes site-master (/var/lib/aolserver/$OPENACS_SERVICE_NAME/www/site-master.adp and .tcl)

        5. The site-master draws site-wide navigation elements and invokes blank-master (/var/lib/aolserver/$OPENACS_SERVICE_NAME/www/blank-master.adp and .tcl).

        6. Blank-master does HTML housekeeping and provides a framework for special sitewide navigation "meta" elements such as Translator widgets and Admin widgets.

      Figure 4.1. Site Templates

      Site Templates

      How do I diagnose a permissions problem?

      • Steps to Reproduce. The events package does not allow users to register for new events.

        1. Go to the http://yourserver.net/events as a visitor (ie, log out and, if necessary, clear cookies). This in on a 4.6.3 site with events version 0.1d3.

        2. Select an available event

        3. A link such as Registration: Deadline is 03/15/2004 10:00am. » Login or sign up to register for this event. is visible. Click on "Login or sign up" -

        4. Complete a new registration. Afterwards, you should be redirected back to the same page.

        Actual Results: The page says "You do not have permission to register for this event."

        Expected results: A link or form to sign up for the event is shown.

      • Finding the problem. We start with the page that has the error. In the URL it's http://myserver.net/events/event-info.tcl, so open the file /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/events/www/event-info.tcl. It contains this line:

        set can_register_p [events::security::can_register_for_event_p -event_id $event_id]

        We need to know what that procedure does, so go to /api-doc, paste events::security::can_register_for_event_p into the ACS Tcl API Search box, and click Feeling Lucky. The next pages shows the proc, and we click "show source" to see more information. The body of the proc is simply

        return [permission::permission_p -party_id $user_id -object_id $event_id -privilege write]

        This means that a given user must have the write privilige on the event in order to register. Let's assume that the priviliges inherit, so that if a user has the write privilige on the whole package, they will have the write privilege on the event.

      • Setting Permissions. A permission has three parts: the privilige, the object of the privilige, and the subject being granted the privilige. In this case the privilige is "write," the object is the Events package, and the subject is all Registered Users.

        1. To grant permissions on a package, start at the site map. Find the event package and click "Set permissions".

        2. Click "Grant Permission"

        3. Grant the write permission to Registered Users.

          Figure 4.2. Granting Permissions

          Granting Permissions

        OpenACS 5.0 offers a prettier version at /admin/applications.

        Figure 4.3. Granting Permissions in 5.0

        Granting Permissions in 5.0
      View comments on this page at openacs.org
      +

    • Complete a new registration. Afterwards, you should be redirected back to the same page.

    Actual Results: The page says "You do not have permission to register for this event."

    Expected results: A link or form to sign up for the event is shown.

  • Finding the problem. We start with the page that has the error. In the URL it's http://myserver.net/events/event-info.tcl, so open the file /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/events/www/event-info.tcl. It contains this line:

    set can_register_p [events::security::can_register_for_event_p -event_id $event_id]

    We need to know what that procedure does, so go to /api-doc, paste events::security::can_register_for_event_p into the ACS Tcl API Search box, and click Feeling Lucky. The next pages shows the proc, and we click "show source" to see more information. The body of the proc is simply

    return [permission::permission_p -party_id $user_id -object_id $event_id -privilege write]

    This means that a given user must have the write privilige on the event in order to register. Let's assume that the priviliges inherit, so that if a user has the write privilige on the whole package, they will have the write privilege on the event.

  • Setting Permissions. A permission has three parts: the privilige, the object of the privilige, and the subject being granted the privilige. In this case the privilige is "write," the object is the Events package, and the subject is all Registered Users.

    1. To grant permissions on a package, start at the site map. Find the event package and click "Set permissions".

    2. Click "Grant Permission"

    3. Grant the write permission to Registered Users.

      Figure 4.2. Granting Permissions

      Granting Permissions

    OpenACS 5.0 offers a prettier version at /admin/applications.

    Figure 4.3. Granting Permissions in 5.0

    Granting Permissions in 5.0
  • View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/i18n-convert.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/i18n-convert.html,v diff -u -N -r1.22 -r1.22.2.1 --- openacs-4/packages/acs-core-docs/www/i18n-convert.html 13 Sep 2009 23:54:40 -0000 1.22 +++ openacs-4/packages/acs-core-docs/www/i18n-convert.html 18 Jun 2010 21:29:34 -0000 1.22.2.1 @@ -1,5 +1,5 @@ -How to Internationalize a Package

    How to Internationalize a Package

    Tip

    +How to Internationalize a Package

    How to Internationalize a Package

    Tip

    For multilingual websites we recommend using the UTF8 charset. In order for AOLserver to use utf8 you need to set the config parameters OutputCharset and @@ -72,7 +72,7 @@ test. If you don't provide the package_key argument then all packages with catalog files will be checked. The script will run its checks primarily on en_US xml catalog files. -

    Avoiding common i18n mistakes

    • Replace complicated keys with longer, simpler keys. When writing in one language, it is possible to create clever code to make correct text. In English, for example, you can put an if command at the end of a word which adds "s" if a count is anything but 1. This pluralizes nouns correctly based on the data. However, it is confusing to read and, when internationalized, may result in message keys that are both confusing and impossible to set correctly in some languages. While internationalizing, watch out that the automate converter does not create such keys. Also, refactor compound text as you encounter it.

      The automated system can easily get confused by tags within message texts, so that it tries to create two or three message keys for one long string with a tag in the middle. In these cases, uncheck those keys during the conversion and then edit the files directly. For example, this code:

        <p class="form-help-text"><b>Invitations</b> are sent,
      +      

    Avoiding common i18n mistakes

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/install-openacs-keepalive.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/install-openacs-keepalive.html,v diff -u -N -r1.20 -r1.20.2.1 --- openacs-4/packages/acs-core-docs/www/install-openacs-keepalive.html 13 Sep 2009 23:54:40 -0000 1.20 +++ openacs-4/packages/acs-core-docs/www/install-openacs-keepalive.html 18 Jun 2010 21:29:35 -0000 1.20.2.1 @@ -64,6 +64,6 @@ Most of this information comes from Tom Jackson's AOLserver+Daemontools Mini-HOWTO. -

    Table 6.1. How it Works

    ProgramInvoked by this program ...... using this fileWhere to find errorsLog goes toUse these commands to control it
    svscanboot +

    Table 6.1. How it Works

    ProgramInvoked by this program ...... using this fileWhere to find errorsLog goes toUse these commands to control it
    svscanboot init/etc/inittabps -auxw | grep readproctitlen/a 
    aolserversupervise (a child of svscanboot)/service/$OPENACS_SERVICE_NAME/run/var/lib/aolserver/$OPENACS_SERVICE_NAME/log/error.log/var/lib/aolserver/$OPENACS_SERVICE_NAME/log/$OPENACS_SERVICE_NAME.logsvc -k /service/$OPENACS_SERVICE_NAME
    postgresqlRedhat init scripts during boot/etc/init.d/postgresql/usr/local/pgsql/data/server.log service postgresql start (Red Hat), /etc/init.d/postgresql start (Debian)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/install-qmail.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/install-qmail.html,v diff -u -N -r1.37 -r1.37.2.1 --- openacs-4/packages/acs-core-docs/www/install-qmail.html 13 Sep 2009 23:54:40 -0000 1.37 +++ openacs-4/packages/acs-core-docs/www/install-qmail.html 18 Jun 2010 21:29:35 -0000 1.37.2.1 @@ -30,7 +30,7 @@ tcpserver: usage: tcpserver [ -1UXpPhHrRoOdDqQv ] [ -c limit ] [ -x rules.cdb ] [ -B banner ] [ -g gid ] [ -u uid ] [ -b backlog ] [ -l localname ] [ -t timeout ] host port program [root ucspi-tcp-0.88]# -

    +

    (I'm not sure if this next step is 100% necessary, but when I skip it I get problems. If you get the error 553 sorry, that domain isn't in my list of allowed rcpthosts (#5.7.1) then you need to do this.) AOLserver sends outgoing mail via the ns_sendmail command, which pipes a command to the sendmail executable. Or, in our @@ -41,10 +41,10 @@ Unless this mail is addressed to the same machine, qmail thinks that it's an attempt to relay mail, and rejects it. So these two commands set up an exception so that any mail sent from 127.0.0.1 is allowed to -send outgoing mail.

    [root ucspi-tcp-0.88]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/tcp.smtp.txt /etc/tcp.smtp
    +send outgoing mail.

    [root ucspi-tcp-0.88]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/tcp.smtp.txt /etc/tcp.smtp
     [root ucspi-tcp-0.88]# tcprules /etc/tcp.smtp.cdb /etc/tcp.smtp.tmp < /etc/tcp.smtp
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/tcp.smtp.txt /etc/tcp.smtp 
    -tcprules /etc/tcp.smtp.cdb /etc/tcp.smtp.tmp < /etc/tcp.smtp 
  • Install Qmail. 

    Download qmail, +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/tcp.smtp.txt /etc/tcp.smtp +tcprules /etc/tcp.smtp.cdb /etc/tcp.smtp.tmp < /etc/tcp.smtp

  • Install Qmail. 

    Download qmail, set up the standard supporting users and build the binaries:

    [root root]# cd /usr/local/src
     [root src]# wget http://www.qmail.org/netqmail-1.04.tar.gz
     [root src]# tar xzf netqmail-1.04.tar.gz
    @@ -103,7 +103,7 @@
     cd netqmail-1.04
     ./collate.sh
     cd netqmail-1.04
    -make setup check

    Replace sendmail with qmail's wrapper.

    [root qmail-1.03]# rm -f /usr/bin/sendmail /usr/sbin/sendmail
    +make setup check

    Replace sendmail with qmail's wrapper.

    [root qmail-1.03]# rm -f /usr/bin/sendmail /usr/sbin/sendmail
     [root qmail-1.03]# ln -s /var/qmail/bin/sendmail /usr/sbin/sendmail
     [root qmail-1.03]#
     rm -f /usr/bin/sendmail /usr/sbin/sendmail
    @@ -125,13 +125,13 @@
     cd ~alias; touch .qmail-postmaster .qmail-mailer-daemon .qmail-root 
     chmod 644 ~alias/.qmail* 
     /var/qmail/bin/maildirmake ~alias/Maildir/ 
    -chown -R alias.nofiles /var/qmail/alias/Maildir

    Configure qmail to use the Maildir delivery format +chown -R alias.nofiles /var/qmail/alias/Maildir

    Configure qmail to use the Maildir delivery format (instead of mbox), and install a version of the qmail startup script modified to use Maildir.

    [root alias]# echo "./Maildir" > /var/qmail/bin/.qmail
    -[root alias]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail.rc.txt /var/qmail/rc
    +[root alias]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail.rc.txt /var/qmail/rc
     [root alias]# chmod 755 /var/qmail/rc
     [root alias]# 
     echo "./Maildir" > /var/qmail/bin/.qmail 
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail.rc.txt /var/qmail/rc 
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail.rc.txt /var/qmail/rc 
     chmod 755 /var/qmail/rc 
     

    Set up the skeleton directory so that new users will be configured for qmail.

    [root root]# /var/qmail/bin/maildirmake /etc/skel/Maildir
    @@ -143,13 +143,13 @@
     [root root]# mkdir -p /var/qmail/supervise/qmail-smtpd/log
     [root root]# mkdir /var/log/qmail
     [root root]# chown qmaill /var/log/qmail
    -[root root]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmailctl.txt /var/qmail/bin/qmailctl
    +[root root]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmailctl.txt /var/qmail/bin/qmailctl
     [root root]# chmod 755 /var/qmail/bin/qmailctl
     [root root]# ln -s /var/qmail/bin/qmailctl /usr/bin
    -[root root]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-send-run.txt /var/qmail/supervise/qmail-send/run 
    -[root root]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-send-log-run.txt /var/qmail/supervise/qmail-send/log/run
    -[root root]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-smtpd-run.txt /var/qmail/supervise/qmail-smtpd/run
    -[root root]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-smtpd-log-run.txt /var/qmail/supervise/qmail-smtpd/log/run
    +[root root]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-send-run.txt /var/qmail/supervise/qmail-send/run 
    +[root root]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-send-log-run.txt /var/qmail/supervise/qmail-send/log/run
    +[root root]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-smtpd-run.txt /var/qmail/supervise/qmail-smtpd/run
    +[root root]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-smtpd-log-run.txt /var/qmail/supervise/qmail-smtpd/log/run
     [root root]# chmod 755 /var/qmail/supervise/qmail-send/run
     [root root]# chmod 755 /var/qmail/supervise/qmail-send/log/run
     [root root]# chmod 755 /var/qmail/supervise/qmail-smtpd/run
    @@ -160,13 +160,13 @@
     mkdir -p /var/qmail/supervise/qmail-smtpd/log
     mkdir /var/log/qmail
     chown qmaill /var/log/qmail
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmailctl.txt /var/qmail/bin/qmailctl
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmailctl.txt /var/qmail/bin/qmailctl
     chmod 755 /var/qmail/bin/qmailctl
     ln -s /var/qmail/bin/qmailctl /usr/bin
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-send-run.txt /var/qmail/supervise/qmail-send/run
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-send-log-run.txt /var/qmail/supervise/qmail-send/log/run
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-smtpd-run.txt /var/qmail/supervise/qmail-smtpd/run
    -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/qmail-smtpd-log-run.txt /var/qmail/supervise/qmail-smtpd/log/run
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-send-run.txt /var/qmail/supervise/qmail-send/run
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-send-log-run.txt /var/qmail/supervise/qmail-send/log/run
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-smtpd-run.txt /var/qmail/supervise/qmail-smtpd/run
    +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/qmail-smtpd-log-run.txt /var/qmail/supervise/qmail-smtpd/log/run
     chmod 755 /var/qmail/supervise/qmail-send/run
     chmod 755 /var/qmail/supervise/qmail-send/log/run
     chmod 755 /var/qmail/supervise/qmail-smtpd/run
    Index: openacs-4/packages/acs-core-docs/www/install-redhat.html
    ===================================================================
    RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/install-redhat.html,v
    diff -u -N -r1.37 -r1.37.2.1
    --- openacs-4/packages/acs-core-docs/www/install-redhat.html	13 Sep 2009 23:54:40 -0000	1.37
    +++ openacs-4/packages/acs-core-docs/www/install-redhat.html	18 Jun 2010 21:29:35 -0000	1.37.2.1
    @@ -1,5 +1,5 @@
     
    -Appendix A. Install Red Hat 8/9

    Appendix A. Install Red Hat 8/9

    by Joel Aufrecht

    +Appendix A. Install Red Hat 8/9

    Appendix A. Install Red Hat 8/9

    by Joel Aufrecht

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    This section takes a blank PC and sets up some supporting @@ -27,7 +27,7 @@

    1. Unplug the network cable from your computer. We don't want to connect to the network until we're sure the computer is secure. - + (Wherever you see the word secure, you should always read it as, "secure enough for our purposes, given the amount of work we're @@ -55,7 +55,7 @@ Review (and modify if needed) the partitions created and click Next

    2. On the pop-up window asking "Are you sure you want to do this?" click Yes - IF YOU ARE WIPING YOUR HARD DRIVE.

    3. Click Next on the boot loader screen

  • Configure Networking. + IF YOU ARE WIPING YOUR HARD DRIVE.

  • Click Next on the boot loader screen

  • Configure Networking. Again, if you know what you're doing, do this step yourself, being sure to note the firewall holes. Otherwise, follow the instructions in this step to set up a computer directly connected to the internet with a dedicated IP address.

    1. DHCP is a system by which a computer that @@ -76,7 +76,7 @@ Mail (SMTP). In the Other ports box, enter 443, 8000, 8443. Click Next. -Port 443 is for https (http over ssl), and 8000 and 8443 are http and https access to the development server we'll be setting up.

  • Select any additional languages you want the +Port 443 is for https (http over ssl), and 8000 and 8443 are http and https access to the development server we'll be setting up.

  • Select any additional languages you want the computer to support and then click Next

  • Choose your time zone and click Next.

  • Type in a root password, twice.

  • On the Package selection page, we're going to @@ -88,13 +88,13 @@ risk that's still screened by the firewall, or a resource hog. Just don't install a database or web server, because that would conflict with the database and web server we'll install later. -

    check Editors (this installs emacs),
    click Details next to Text-based Internet, check lynx, and click OK;
    check Authoring and Publishing (this installs docbook),
    uncheck Server Configuration Tools,
    uncheck Web Server,
    uncheck Windows File Server,
    check SQL Database Server (this installs PostgreSQL),
    check Development Tools (this installs gmake and other build tools),
    uncheck Administration Tools, and
    uncheck Printing Support.

    At the bottom, check Select Individual Packages and click Next

  • We need to fine-tune the exact list of packages. +

    check Editors (this installs emacs),
    click Details next to Text-based Internet, check lynx, and click OK;
    check Authoring and Publishing (this installs docbook),
    uncheck Server Configuration Tools,
    uncheck Web Server,
    uncheck Windows File Server,
    check SQL Database Server (this installs PostgreSQL),
    check Development Tools (this installs gmake and other build tools),
    uncheck Administration Tools, and
    uncheck Printing Support.

    At the bottom, check Select Individual Packages and click Next

  • We need to fine-tune the exact list of packages. The same rules apply as in the last step - you can add more stuff, but you shouldn't remove anything the guide adds. We're going to go through all the packages in one big list, so select Flat View and wait. In a minute, a -list of packages will appear.

    uncheck apmd (monitors power, not very useful for servers),
    check ImageMagick (required for the photo-album packages,
    uncheckisdn4k-utils (unless you are using isdn, this installs a useless daemon),
    check mutt (a mail program that reads Maildir),
    uncheck nfs-utils (nfs is a major security risk),
    uncheck pam-devel (I don't remember why, but we don't want this),
    uncheck portmap,
    uncheck postfix (this is an MTA, but we're going to install qmail later),
    check postgresql-devel,
    uncheck rsh (rsh is a security hole),
    uncheck sendmail (sendmail is an insecure MTA; we're going to install qmail instead later),
    check tcl (we need tcl), and
    uncheck xinetd (xinetd handles incoming tcp connections. We'll install a different, more secure program, ucspi-tcp).
    Click Next
  • Red Hat isn't completely happy with the combination +list of packages will appear.

    uncheck apmd (monitors power, not very useful for servers),
    check ImageMagick (required for the photo-album packages,
    uncheckisdn4k-utils (unless you are using isdn, this installs a useless daemon),
    check mutt (a mail program that reads Maildir),
    uncheck nfs-utils (nfs is a major security risk),
    uncheck pam-devel (I don't remember why, but we don't want this),
    uncheck portmap,
    uncheck postfix (this is an MTA, but we're going to install qmail later),
    check postgresql-devel,
    uncheck rsh (rsh is a security hole),
    uncheck sendmail (sendmail is an insecure MTA; we're going to install qmail instead later),
    check tcl (we need tcl), and
    uncheck xinetd (xinetd handles incoming tcp connections. We'll install a different, more secure program, ucspi-tcp).
    Click Next
  • Red Hat isn't completely happy with the combination of packages we've selected, and wants to satisfy some dependencies. Don't let it. On the next screen, choose Ignore Package @@ -120,7 +120,7 @@ upgrading all of that. Since you are upgrading the kernel, reboot after this step.

  • Lock down SSH

    1. - + SSH is the protocol we use to connect securely to the computer (replacing telnet, which is insecure). sshd is the daemon that listens for incoming @@ -201,4 +201,4 @@ cd /var/tmp wget http://updates.redhat.com/7.1/en/os/i686/kernel-2.4.18-27.7.x.i686.rpm rpm -Uvh kernel-2.4.18-27.7.x.i686.rpm -reboot

    View comments on this page at openacs.org
    +reboot
  • View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/install-steps.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/install-steps.html,v diff -u -N -r1.31 -r1.31.2.1 --- openacs-4/packages/acs-core-docs/www/install-steps.html 13 Sep 2009 23:54:40 -0000 1.31 +++ openacs-4/packages/acs-core-docs/www/install-steps.html 18 Jun 2010 21:29:35 -0000 1.31.2.1 @@ -5,7 +5,7 @@ Install PostgreSQL).

  • Install AOLserver (Install AOLserver 4) .

  • Create a unique database and system user. Install the OpenACS tarball, start and AOLserver instance, and use the OpenACS web pages to complete installation - (see Install OpenACS 5.5.0).

  • Specific instructions are available for Mac OS X and + (see Install OpenACS 5.6.0).

    Specific instructions are available for Mac OS X and Windows2000 (see Section , “OpenACS Installation Guide for Mac OS X” or Section , “OpenACS Installation Guide for Windows2000”).

    Binaries and other shortcuts

    You can try out OpenACS using some binary installers. In general, they are not yet supported by the community, so they are @@ -41,9 +41,9 @@ su - $OPENACS_SERVICE_NAME svc -d /service/$OPENACS_SERVICE_NAME dropdb $OPENACS_SERVICE_NAME -createdb $OPENACS_SERVICE_NAME

    Setting a global shell variable for cut and paste. In order to cut and paste the instructions into your shell, you must set the environment variable $OPENACS_SERVICE_NAME. In order to set it globally so that it works for any new users or special service users you may create, edit the file /etc/profile ( /etc/share/skel/dot.profile for FreeBSD) and add this line:

    export OPENACS_SERVICE_NAME=service0

    Paths and Users

    Table 2.1. Default directories for a standard install

    Fully qualified domain name of your serveryourserver.test
    name of administrative access accountremadmin
    OpenACS service$OPENACS_SERVICE_NAME (set to service0 in default install)
    OpenACS service account$OPENACS_SERVICE_NAME
    OpenACS database name$OPENACS_SERVICE_NAME
    Root of OpenACS service file tree (SERVERROOT)/var/lib/aolserver/$OPENACS_SERVICE_NAME
    Location of source code tarballs for new software/var/tmp
    The OpenACS tarball contains some files which +createdb $OPENACS_SERVICE_NAME

    Setting a global shell variable for cut and paste. In order to cut and paste the instructions into your shell, you must set the environment variable $OPENACS_SERVICE_NAME. In order to set it globally so that it works for any new users or special service users you may create, edit the file /etc/profile ( /etc/share/skel/dot.profile for FreeBSD) and add this line:

    export OPENACS_SERVICE_NAME=service0

    Paths and Users

    Table 2.1. Default directories for a standard install

    Fully qualified domain name of your serveryourserver.test
    name of administrative access accountremadmin
    OpenACS service$OPENACS_SERVICE_NAME (set to service0 in default install)
    OpenACS service account$OPENACS_SERVICE_NAME
    OpenACS database name$OPENACS_SERVICE_NAME
    Root of OpenACS service file tree (SERVERROOT)/var/lib/aolserver/$OPENACS_SERVICE_NAME
    Location of source code tarballs for new software/var/tmp
    The OpenACS tarball contains some files which are useful while setting up other software. Those - files are located at:/var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files
    Database backup directory/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup
    Service config files/var/lib/aolserver/$OPENACS_SERVICE_NAME/etc
    Service log files/var/lib/aolserver/$OPENACS_SERVICE_NAME/log
    Compile directory/usr/local/src
    PostgreSQL directory/usr/local/pgsql
    AOLserver directory/usr/local/aolserver

    + files are located at:

    /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files
    Database backup directory/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup
    Service config files/var/lib/aolserver/$OPENACS_SERVICE_NAME/etc
    Service log files/var/lib/aolserver/$OPENACS_SERVICE_NAME/log
    Compile directory/usr/local/src
    PostgreSQL directory/usr/local/pgsql
    AOLserver directory/usr/local/aolserver

    None of these locations are set in stone - they're simply the values that we've chosen. The values that you'll probably want to change, such as service name, are Index: openacs-4/packages/acs-core-docs/www/ix01.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/ix01.html,v diff -u -N -r1.25 -r1.25.2.1 --- openacs-4/packages/acs-core-docs/www/ix01.html 13 Sep 2009 23:54:40 -0000 1.25 +++ openacs-4/packages/acs-core-docs/www/ix01.html 18 Jun 2010 21:29:35 -0000 1.25.2.1 @@ -1,3 +1,3 @@ -Index

    Index

    Symbols

    $OPENACS_SERVICE_NAME, Paths and Users

    C

    computeroutput
    code, Code
    cvs
    initializing, Initialize CVS (OPTIONAL)
    setup, Using CVS with an OpenACS Site

    E

    emacs
    installation, Install Red Hat 8/9
    emphasis
    bold, italics, Emphasis

    G

    Graphics
    Images, Graphics

    I

    informaltable
    table, Tables

    L

    language
    installation, Install Red Hat 8/9
    Linking, Links
    lists, Lists

    O

    OpenACS Package, What a Package Looks Like

    P

    photo-album
    installation (see ImageMagick)
    Postgres
    Vacuuming, Installation Option 2: Install from tarball

    Q

    qmail
    installation, Install qmail (OPTIONAL)
    Maildir, Install qmail (OPTIONAL)
    rcpthosts error message, Install qmail (OPTIONAL)

    T

    The publish point for new packages should be +Index

    Index

    Symbols

    $OPENACS_SERVICE_NAME, Paths and Users

    C

    computeroutput
    code, Code
    cvs
    initializing, Initialize CVS (OPTIONAL)

    E

    emacs
    installation, Install Red Hat 8/9
    emphasis
    bold, italics, Emphasis

    G

    Graphics
    Images, Graphics

    I

    informaltable
    table, Tables

    L

    language
    installation, Install Red Hat 8/9
    Linking, Links
    lists, Lists

    O

    OpenACS Package, What a Package Looks Like

    P

    photo-album
    installation (see ImageMagick)
    Postgres
    Vacuuming, Installation Option 2: Install from tarball

    Q

    qmail
    installation, Install qmail (OPTIONAL)
    Maildir, Install qmail (OPTIONAL)
    rcpthosts error message, Install qmail (OPTIONAL)

    T

    The publish point for new packages should be fixed., Prepare the package for distribution.

    U

    ulink, Links
    upgrade
    OpenACS 4.5 to 4.6.x
    Linux/Unix, Upgrading 4.5 or higher to 4.6.3
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/kernel-doc.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/kernel-doc.html,v diff -u -N -r1.33 -r1.33.2.1 --- openacs-4/packages/acs-core-docs/www/kernel-doc.html 13 Sep 2009 23:54:40 -0000 1.33 +++ openacs-4/packages/acs-core-docs/www/kernel-doc.html 18 Jun 2010 21:29:35 -0000 1.33.2.1 @@ -1,2 +1,2 @@ -Chapter 14. Kernel Documentation
    View comments on this page at openacs.org
    +Chapter 15. Kernel Documentation
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/kernel-overview.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/kernel-overview.html,v diff -u -N -r1.27 -r1.27.2.1 --- openacs-4/packages/acs-core-docs/www/kernel-overview.html 13 Sep 2009 23:54:40 -0000 1.27 +++ openacs-4/packages/acs-core-docs/www/kernel-overview.html 18 Jun 2010 21:29:35 -0000 1.27.2.1 @@ -1,5 +1,5 @@ -Overview

    Overview

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/maint-performance.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/maint-performance.html,v diff -u -N -r1.25 -r1.25.2.1 --- openacs-4/packages/acs-core-docs/www/maint-performance.html 13 Sep 2009 23:54:40 -0000 1.25 +++ openacs-4/packages/acs-core-docs/www/maint-performance.html 18 Jun 2010 21:29:35 -0000 1.25.2.1 @@ -2,7 +2,7 @@ Diagnosing Performance Problems

    Diagnosing Performance Problems

    • Did performance problems happen overnight, or did they sneak up on you? Any clue what caused the performance problems (e.g. loading 20K users into .LRN)

    • Is the file system out of space? Is the machine swapping to disk constantly?

    • Isolating and solving database problems.

      • Without daily internal maintenance, most databases slowly degrade in performance. For PostGreSQL, see Section , “Vacuum Postgres nightly”. For Oracle, use exec dbms_stats.gather_schema_stats('SCHEMA_NAME') (Andrew Piskorski's Oracle notes).

      • You can track the exact amount of time each database query on a page takes:

        1. Go to Main Site : Site-Wide Administration : Install Software

        2. Click on "Install New Application" in "Install from OpenACS Repository"

        3. Choose "ACS Developer Support">

        4. After install is complete, restart the server.

        5. Browse to Developer Support, which is automatically mounted at /ds. -

        6. Turn on Database statistics

        7. Browse directly to a slow page and click "Request Information" at the bottom of the page.

        8. This should return a list of database queries on the page, including the exact query (so it can be cut-paste into psql or oracle) and the time each query took.

          Figure 6.8. Query Analysis example

          Query Analysis example
      • Identify a runaway Oracle query: first, use ps aux or top to get the UNIX process ID of a runaway Oracle process.

        Log in to SQL*Plus as the admin:

        [$OPENACS_SERVICE_NAME ~]$ svrmgrl
        +              

      • Turn on Database statistics

      • Browse directly to a slow page and click "Request Information" at the bottom of the page.

      • This should return a list of database queries on the page, including the exact query (so it can be cut-paste into psql or oracle) and the time each query took.

        Figure 6.8. Query Analysis example

        Query Analysis example
    • Identify a runaway Oracle query: first, use ps aux or top to get the UNIX process ID of a runaway Oracle process.

      Log in to SQL*Plus as the admin:

      [$OPENACS_SERVICE_NAME ~]$ svrmgrl
       
       Oracle Server Manager Release 3.1.7.0.0 - Production
       
      @@ -59,7 +59,7 @@
           

      To be able to get a overview of how Oracle executes a particular query, install "autotrace". I usually follow the instructions here http://asktom.oracle.com/~tkyte/article1/autotrace.html. -

      Make sure, that the Oracle CBO works with adequate statistics

      +

      Make sure, that the Oracle CBO works with adequate statistics

      The Oracle Cost Based optimizer is a piece of software that tries to find the "optimal" execution plan for a given SQL statement. For that it estimates the costs of running a SQL query in a particular way (by default Index: openacs-4/packages/acs-core-docs/www/maintenance-deploy.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/maintenance-deploy.html,v diff -u -N -r1.20 -r1.20.2.1 --- openacs-4/packages/acs-core-docs/www/maintenance-deploy.html 13 Sep 2009 23:54:40 -0000 1.20 +++ openacs-4/packages/acs-core-docs/www/maintenance-deploy.html 18 Jun 2010 21:29:35 -0000 1.20.2.1 @@ -2,7 +2,7 @@ Staged Deployment for Production Networks

      Staged Deployment for Production Networks

      ($Id$)

      By Joel Aufrecht

      OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

      This section describes two minimal-risk methods for deploying changes on a production network. The important characteristics of a safe change deployment include: (THIS SECTION IN DEVELOPMENT)

      • Control: You know for sure that the change you are making is the change that you intend to make and is the change that you tested.

      • Rollback: If anything goes wrong, you can return to the previous working configuration safely and quickly.

      Method 1: Deployment with CVS

      With this method, we control the files on a site via +

      This section describes two minimal-risk methods for deploying changes on a production network. The important characteristics of a safe change deployment include: (THIS SECTION IN DEVELOPMENT)

      • Control: You know for sure that the change you are making is the change that you intend to make and is the change that you tested.

      • Rollback: If anything goes wrong, you can return to the previous working configuration safely and quickly.

      Method 1: Deployment with CVS

      With this method, we control the files on a site via CVS. This example uses one developmental server (service0-dev) and one production server (service0). Depending on your needs, you can also have a staging server for extensive testing before you go @@ -67,4 +67,4 @@ cvs up -Pd index.adp

      If you make changes that require changes to the database, test them out first on service0-dev, using either -create.sql or upgrade scripts. Once you've tested them, you then update and - run the upgrade scripts from the package manager.

      The production site can run "HEAD" from cvs.

      The drawback to using HEAD as the live code is that you cannot commit new work on the development server without erasing the definition of 'working production code.' So a better method is to use a tag. This guarantees that, at any time in the future, you can retrieve exactly the same set of code. This is useful for both of the characteristics of safe change deployment. For control, you can use tags to define a body of code, test that code, and then know that what you are deploying is exactly that code. For rollback, you can use return to the last working tag if the new tag (or new, untagged changes) cause problems. .... example of using tags to follow ...

    Method 2: A/B Deployment

    The approach taken in this section is to always create a new service with the desired changes, running in parallel with the existing site. This guarantees control, at least at the final step of the process: you know what changes you are about to make because you can see them directly. It does not, by itself, guarantee the entire control chain. You need additional measures to make sure that the change you are making is exactly and completely the change you intended to make and tested previously, and nothing more. Those additional measures typically take the form of source control tags and system version numbers. The parallel-server approach also guarantees rollback because the original working service is not touched; it is merely set aside.

    This approach can has limitations. If the database or file system regularly receiving new data, you must interrupt this function or risk losing data in the shuffle. It also requires extra steps if the database will be affected.

    Simple A/B Deployment: Database is not changed

    Figure 6.2. Simple A/B Deployment - Step 1

    Simple A/B Deployment - Step 1

    Figure 6.3. Simple A/B Deployment - Step 2

    Simple A/B Deployment - Step 2

    Figure 6.4. Simple A/B Deployment - Step 3

    Simple A/B Deployment - Step 3

    Complex A/B Deployment: Database is changed

    Figure 6.5. Complex A/B Deployment - Step 1

    Complex A/B Deployment - Step 1

    Figure 6.6. Complex A/B Deployment - Step 2

    Complex A/B Deployment - Step 2

    Figure 6.7. Complex A/B Deployment - Step 3

    Complex A/B Deployment - Step 3
    View comments on this page at openacs.org
    + run the upgrade scripts from the package manager.

    The production site can run "HEAD" from cvs.

    The drawback to using HEAD as the live code is that you cannot commit new work on the development server without erasing the definition of 'working production code.' So a better method is to use a tag. This guarantees that, at any time in the future, you can retrieve exactly the same set of code. This is useful for both of the characteristics of safe change deployment. For control, you can use tags to define a body of code, test that code, and then know that what you are deploying is exactly that code. For rollback, you can use return to the last working tag if the new tag (or new, untagged changes) cause problems. .... example of using tags to follow ...

    Method 2: A/B Deployment

    The approach taken in this section is to always create a new service with the desired changes, running in parallel with the existing site. This guarantees control, at least at the final step of the process: you know what changes you are about to make because you can see them directly. It does not, by itself, guarantee the entire control chain. You need additional measures to make sure that the change you are making is exactly and completely the change you intended to make and tested previously, and nothing more. Those additional measures typically take the form of source control tags and system version numbers. The parallel-server approach also guarantees rollback because the original working service is not touched; it is merely set aside.

    This approach can has limitations. If the database or file system regularly receiving new data, you must interrupt this function or risk losing data in the shuffle. It also requires extra steps if the database will be affected.

    Simple A/B Deployment: Database is not changed

    Figure 6.2. Simple A/B Deployment - Step 1

    Simple A/B Deployment - Step 1

    Figure 6.3. Simple A/B Deployment - Step 2

    Simple A/B Deployment - Step 2

    Figure 6.4. Simple A/B Deployment - Step 3

    Simple A/B Deployment - Step 3

    Complex A/B Deployment: Database is changed

    Figure 6.5. Complex A/B Deployment - Step 1

    Complex A/B Deployment - Step 1

    Figure 6.6. Complex A/B Deployment - Step 2

    Complex A/B Deployment - Step 2

    Figure 6.7. Complex A/B Deployment - Step 3

    Complex A/B Deployment - Step 3
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/nxml-mode.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/nxml-mode.html,v diff -u -N -r1.14 -r1.14.2.1 --- openacs-4/packages/acs-core-docs/www/nxml-mode.html 13 Sep 2009 23:54:40 -0000 1.14 +++ openacs-4/packages/acs-core-docs/www/nxml-mode.html 18 Jun 2010 21:29:35 -0000 1.14.2.1 @@ -1,5 +1,5 @@ -Using nXML mode in Emacs

    Using nXML mode in Emacs

    By Jeff Davis

    +Using nXML mode in Emacs

    Using nXML mode in Emacs

    By Jeff Davis

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    @@ -8,4 +8,4 @@

    View comments on this page at openacs.org
    +

  • The nXML download page at thaiopensource.com.

  • View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/object-identity.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/object-identity.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/object-identity.html 13 Sep 2009 23:54:40 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/object-identity.html 18 Jun 2010 21:29:35 -0000 1.45.2.1 @@ -1,19 +1,19 @@ -Object Identity

    Object Identity

    By Rafael H. Schloming

    +Object Identity

    Object Identity

    By Rafael H. Schloming

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    One of the major design features of OpenACS 5.5.0 is the explicit representation +

    One of the major design features of OpenACS 5.6.0 is the explicit representation of object identity. The reason I say "explicit representation" is because the concept of object identity has been around forever. It is inherent to our problem domain. Consider the example of 3.x style scoping. The 3.x data models use the triple (user_id, group_id, -scope) to identify an object. In the 5.5.0 data model this +scope) to identify an object. In the 5.6.0 data model this object is explicitly represented by a single party_id.

    Another good example of this is can be found in the user groups data model. The 3.x user groups data model contains another example of an implied identity. Every mapping between a user and a group could have an arbitrary number of attached values (user_group_member_fields, etc.). In this case it is the pair (group_id, user_id) that implicitly refers to an -object (the person's membership in a group). In the 5.5.0 data model this +object (the person's membership in a group). In the 5.6.0 data model this object identity is made explicit by adding an integer primary key to the table that maps users to groups.

    Coming from a purely relational world, this might seem slightly weird at first. The pair (group_id, user_id) is sufficient to uniquely identify the Index: openacs-4/packages/acs-core-docs/www/object-system-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/object-system-requirements.html,v diff -u -N -r1.30 -r1.30.2.1 --- openacs-4/packages/acs-core-docs/www/object-system-requirements.html 13 Sep 2009 23:54:40 -0000 1.30 +++ openacs-4/packages/acs-core-docs/www/object-system-requirements.html 18 Jun 2010 21:29:35 -0000 1.30.2.1 @@ -1,5 +1,5 @@ -Object Model Requirements

    Object Model Requirements

    By Pete Su

    +Object Model Requirements

    Object Model Requirements

    By Pete Su

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    I. Introduction

    A major goal in OpenACS 4 is to unify and normalize many of the core services @@ -85,7 +85,7 @@ between data.

    Design Note: While this doesn't really belong in a requirements document, the fact that we are constrained to using relational databases means that certain constraints on the overall design of the object -data model exist, which you can read about in Summary and Design Considerations.

    Modifiable Data Models

    Another recurring applications problem is how to store a modifiable data +data model exist, which you can read about in ???.

    Modifiable Data Models

    Another recurring applications problem is how to store a modifiable data model, or how to store information that may change extensively between releases or in different client installations. Furthermore, we want to avoid changes to an application's database queries in the face of any custom @@ -126,7 +126,7 @@ that store metadata on application objects. The object type system supports subtyping with inheritance, so new object types can be defined in terms of existing object types.

    The OM data model forms the main part of the OpenACS 4 Kernel data model. The -other parts of the Kernel data model include:

    • Parties and Groups

    • Permissions

    Each of these is documented elsewhere at length.

    Use-cases and User-scenarios

    (Pending as of 8/27/00)

    Requirements: Data Model

    The data model for the object system provides support for the following +other parts of the Kernel data model include:

    • Parties and Groups

    • Permissions

    Each of these is documented elsewhere at length.

    Use-cases and User-scenarios

    (Pending as of 8/27/00)

    Requirements: Data Model

    The data model for the object system provides support for the following kinds of schema patterns that are used by many existing OpenACS modules:

    10.0 Object Identification and Storage

    Object identification is a central mechanism in the new metadata system. The fact that every object has a known unique identifier means that the core can deal with all objects in a generic way. Thus the only action required of @@ -202,7 +202,7 @@ developers to represent a hierarchy of object contexts. These contexts are used as the basis for the permissions system. In general, if an object has no explicit permissions attached to it, then it inherits -permissions from its context.

    The context data model also forms the basis of the subsites system, and is +permissions from its context.

    The context data model also forms the basis of the subsites system, and is a basic part of the permissions system, described in separate documents.

    The context data model should provide the following facilities:

    50.10 Unique ID

    Every context should have a unique ID in the system.

    50.20 Tree Structure

    The data model should support a tree structured organization of contexts. That is, contexts can be logically "contained" within other @@ -264,4 +264,4 @@ this integrate with application level SQL queries?

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation08/10/2000Bryan Quinn
    0.2Major re-write08/11/2000Pete Su
    0.3Draft completed after initial reviews08/22/2000Pete Su
    0.4Edited, updated to conform to requirements template, pending freeze08/23/2000Kai Wu
     Final edits before freeze08/24/2000Pete Su
    0.5Edited for consistency08/27/2000Kai Wu
    0.6Put Object ID stuff first, because it makes more sense08/28/2000Pete Su
    0.7Added requirement that knowledge-level objects must be moveable between databases.08/29/2000Richard Li
    0.8Rewrote intro to match language and concepts in the design document. Also cleaned up usage a bit in the requirements section. Added short vague -requirements on relation types.09/06/2000Pete Su
    0.9Edited for ACS 4 Beta release.09/30/2000Kai Wu
    View comments on this page at openacs.org
    +requirements on relation types.
    09/06/2000Pete Su
    0.9Edited for ACS 4 Beta release.09/30/2000Kai Wu
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/objects.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/objects.html,v diff -u -N -r1.48 -r1.48.2.1 --- openacs-4/packages/acs-core-docs/www/objects.html 13 Sep 2009 23:54:40 -0000 1.48 +++ openacs-4/packages/acs-core-docs/www/objects.html 18 Jun 2010 21:29:35 -0000 1.48.2.1 @@ -1,9 +1,9 @@ -OpenACS Data Models and the Object System

    OpenACS Data Models and the Object System

    By Pete Su

    +OpenACS Data Models and the Object System

    OpenACS Data Models and the Object System

    By Pete Su

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Overview

    -Developing data models in OpenACS 5.5.0 is much like developing data models +Developing data models in OpenACS 5.6.0 is much like developing data models for OpenACS 3, save for the implementation. As usual, you need to examine how to model the information that the application must store and manipulate, and define a suitable set of SQL tables. In our Notes @@ -79,7 +79,7 @@ Fire up your text editor and open the ROOT/packages/notes/sql/oracle/notes-create.sql (ROOT/packages/notes/sql/postgresql/notes-create.sql for the PG version) file created when we created the package. Then, do the following: -

    Describe the new type to the type system

    +

    Describe the new type to the type system

    First, add an entry to the acs_object_types table with the following PL/SQL call:

     begin  
    @@ -139,7 +139,7 @@
     because the new type note is a subtype of
     acs_object, it will inherit these attributes, so there is
     no need for us to define them.
    -

    Define a table in which to store your objects

    +

    Define a table in which to store your objects

    The next thing we do is make a small modification to the data model to reflect the fact that each row in the notes table represents something that is not only an object of type @@ -164,7 +164,7 @@ use the acs_objects table to find objects will transparently find any objects that are instances of any subtype of acs_objects. -

    Define a package for type specific procedures

    +

    Define a package for type specific procedures

    The next step is to define a PL/SQL package for your new type, and write some basic procedures to create and delete objects. Here is a package definition for our new type: @@ -212,7 +212,7 @@ object OBJ was "read only", then any other object that used OBJ as its context would also be "read only" by default. We'll talk about this more later. -

    Define a package body for type specific procedures

    +

    Define a package body for type specific procedures

    The PL/SQL package body contains the implementations of the procedures defined above. The only subtle thing going on here is that we must use acs_object.new to insert a row into @@ -315,7 +315,7 @@ models that are meant to be integrated with the OpenACS object system.

    -There are two basic rules you should follow when designing OpenACS 5.5.0 data +There are two basic rules you should follow when designing OpenACS 5.6.0 data models: @@ -370,7 +370,7 @@ requires a good amount of thought at design time even for simple applications.

    Summary

    -Hooking into the OpenACS 5.5.0 object system brings the application developer +Hooking into the OpenACS 5.6.0 object system brings the application developer numerous benefits, and doing it involves only four easy steps: Index: openacs-4/packages/acs-core-docs/www/openacs-unpack.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/openacs-unpack.html,v diff -u -N -r1.25 -r1.25.2.1 --- openacs-4/packages/acs-core-docs/www/openacs-unpack.html 13 Sep 2009 23:54:40 -0000 1.25 +++ openacs-4/packages/acs-core-docs/www/openacs-unpack.html 18 Jun 2010 21:29:35 -0000 1.25.2.1 @@ -2,17 +2,17 @@ Unpack the OpenACS tarball

    Unpack the OpenACS tarball

    The OpenACS tarball contains sample configuration files for some of the packages listed below. In order to access those files, unpack the tarball now.

    [root root]# cd /tmp
    -[root tmp]# tar xzf openacs-5.5.0.tgz
    +[root tmp]# tar xzf openacs-5.6.0.tgz
     cd /tmp
    -tar xzf openacs-5.5.0.tgz

    If you are installing from a different method and just need the configuration files, you can instead get them from CVS:

    [root root]# cd /tmp
    +tar xzf openacs-5.6.0.tgz

    If you are installing from a different method and just need the configuration files, you can instead get them from CVS:

    [root root]# cd /tmp
     [root tmp]# cvs -d :pserver:anonymous@cvs.openacs.org:/cvsroot co openacs-4/packages/acs-core-docs/www/files/
     cvs checkout: warning: failed to open /root/.cvspass for reading: No such file or directory
     cvs server: Updating openacs-4/packages/acs-core-docs/www/files
     U openacs-4/packages/acs-core-docs/www/files/README.TXT
     (many lines omitted)
     U openacs-4/packages/acs-core-docs/www/files/template-ini.ini
     U openacs-4/packages/acs-core-docs/www/files/winnsd.txt
    -[root tmp]# mv openacs-4 openacs-5.5.0
    +[root tmp]# mv openacs-4 openacs-5.6.0
     cd /tmp
     cvs -d :pserver:anonymous@cvs.openacs.org:/cvsroot co openacs-4/packages/acs-core-docs/www/files/
     mv openacs-4 openacs-5.0.0a4
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/openacs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/openacs.html,v diff -u -N -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-core-docs/www/openacs.html 13 Sep 2009 23:54:40 -0000 1.47 +++ openacs-4/packages/acs-core-docs/www/openacs.html 18 Jun 2010 21:29:35 -0000 1.47.2.1 @@ -1,5 +1,5 @@ -Install OpenACS 5.5.0

    Install OpenACS 5.5.0

    by Vinod Kurup

    +Install OpenACS 5.6.0

    Install OpenACS 5.6.0

    by Vinod Kurup

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Set up a user account for each site.

    @@ -87,8 +87,8 @@ /var/tmp and proceed:

    1. Unpack the OpenACS tarball and rename it to $OPENACS_SERVICE_NAME. Secure the directory so that only the owner can access it. Check the permissions by listing the directory.

      FreeBSD note: Change the period in chown -R $OPENACS_SERVICE_NAME.$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME to a colon: chown -R $OPENACS_SERVICE_NAME:$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME

      [root root]# su - $OPENACS_SERVICE_NAME
       [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver
      -[$OPENACS_SERVICE_NAME aolserver]$ tar xzf /var/tmp/openacs-5.5.0.tgz
      -[$OPENACS_SERVICE_NAME aolserver]$ mv openacs-5.5.0 $OPENACS_SERVICE_NAME
      +[$OPENACS_SERVICE_NAME aolserver]$ tar xzf /var/tmp/openacs-5.6.0.tgz
      +[$OPENACS_SERVICE_NAME aolserver]$ mv openacs-5.6.0 $OPENACS_SERVICE_NAME
       [$OPENACS_SERVICE_NAME aolserver]$ chmod -R 775 $OPENACS_SERVICE_NAME
       [$OPENACS_SERVICE_NAME aolserver]$ chown -R $OPENACS_SERVICE_NAME.$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME
       [$OPENACS_SERVICE_NAME aolserver]$ ls -al
      @@ -101,11 +101,11 @@
       [root root]#
       su - $OPENACS_SERVICE_NAME
       cd /var/lib/aolserver
      -tar xzf /var/tmp/openacs-5.5.0.tgz
      -mv openacs-5.5.0 $OPENACS_SERVICE_NAME
      +tar xzf /var/tmp/openacs-5.6.0.tgz
      +mv openacs-5.6.0 $OPENACS_SERVICE_NAME
       chmod -R 755 $OPENACS_SERVICE_NAME
       chown -R $OPENACS_SERVICE_NAME.$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME
      -exit
    2. Add the Service to CVS (OPTIONAL)

    3. Prepare the database

      • Prepare Oracle for OpenACS. If you won't be using Oracle, skip to Prepare PostgreSQL for an OpenACS Service

        +exit

      • Add the Service to CVS (OPTIONAL)

      • Prepare the database

        • Prepare Oracle for OpenACS. If you won't be using Oracle, skip to Prepare PostgreSQL for an OpenACS Service

          You should be sure that your user account (e.g. $OPENACS_SERVICE_NAME) is in the dba group. @@ -238,7 +238,7 @@ CREATE DATABASE [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ su - $OPENACS_SERVICE_NAME -/usr/local/pgsql/bin/createdb -E UNICODE $OPENACS_SERVICE_NAME

        • Automate daily database Vacuuming. This is a process which cleans out discarded data from the database. A quick way to automate vacuuming is to edit the cron file for the database user. Recommended: VACUUM ANALYZE every hour and VACUUM FULL ANALYZE every day.

          [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ export EDITOR=emacs;crontab -e

          Add these lines to the file. The vacuum command cleans up temporary structures within a PostGreSQL database, and can improve performance. We vacuum gently every hour and completely every day. The numbers and stars at the beginning are cron columns that specify when the program should be run - in this case, whenever the minute is 0 and the hour is 1, i.e., 1:00 am every day, and every (*) day of month, month, and day of week. Type man 5 crontab for more information.

          0 1-23 * * * /usr/local/pgsql/bin/vacuumdb --analyze $OPENACS_SERVICE_NAME
          +/usr/local/pgsql/bin/createdb -E UNICODE $OPENACS_SERVICE_NAME
        • Automate daily database Vacuuming. This is a process which cleans out discarded data from the database. A quick way to automate vacuuming is to edit the cron file for the database user. Recommended: VACUUM ANALYZE every hour and VACUUM FULL ANALYZE every day.

          [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ export EDITOR=emacs;crontab -e

          Add these lines to the file. The vacuum command cleans up temporary structures within a PostGreSQL database, and can improve performance. We vacuum gently every hour and completely every day. The numbers and stars at the beginning are cron columns that specify when the program should be run - in this case, whenever the minute is 0 and the hour is 1, i.e., 1:00 am every day, and every (*) day of month, month, and day of week. Type man 5 crontab for more information.

          0 1-23 * * * /usr/local/pgsql/bin/vacuumdb --analyze $OPENACS_SERVICE_NAME
           0 0 * * * /usr/local/pgsql/bin/vacuumdb --full --analyze $OPENACS_SERVICE_NAME

          Depending on your distribution, you may receive email when the crontab items are executed. If you don't want to receive email for those crontab items, @@ -251,7 +251,7 @@ need to configure a virtual server. The Reference Platform uses a configuration file included in the OpenACS tarball, /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/config.tcl. - Open it in an editor to adjust the parameters.

          [root root]# su - $OPENACS_SERVICE_NAME
          +	   Open it in an editor to adjust the parameters.

          [root root]# su - $OPENACS_SERVICE_NAME
           [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc
           [$OPENACS_SERVICE_NAME etc]$ emacs config.tcl
           

          @@ -294,7 +294,7 @@ [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ [08/Mar/2003:18:13:29][32131.8192][-main-] Notice: nsd.tcl: starting to read config file... [08/Mar/2003:18:13:29][32131.8192][-main-] Notice: nsd.tcl: finished reading config file.

        • Attempt to connect to the service from a web browser. You should specify a URL like: http://yourserver.test:8000

          - You should see a page that looks like this. If you imported your files into + You should see a page that looks like this. If you imported your files into cvs, now that you know it worked you can erase the temp directory with rm -rf /var/lib/aolserver/$OPENACS_SERVICE_NAME.orig.

          @@ -312,7 +312,7 @@ AOLserver keepalive (OPTIONAL)

  • Configure a Service with the OpenACS Installer.  Now that you've got AOLserver up and running, let's install OpenACS - 5.5.0. + 5.6.0.

    • You should see a page from the webserver titled OpenACS Installation: @@ -368,14 +368,14 @@ Give the server a few minutes to start up. Then reload the final page above. You should see the front page, with an area to login near the upper right. Congratulations, OpenACS - 5.5.0 is now up and running! -

  • Installation Option 3: Install from CVS

    If you want to track fresh code developments inbetween releases, or you are an OpenACS core developer, you may want to install from CVS. This is identical to Option 2 except that you get the files from CVS instead of the tarball: CVS Checkout Instructions. So, instead of tar xzf /var/tmp/openacs-5.5.0.tgz, cvs -z3 -d :pserver:anonymous@openacs.org:/cvsroot co acs-core.

    Next Steps

    Installation Option 3: Install from CVS

    If you want to track fresh code developments inbetween releases, or you are an OpenACS core developer, you may want to install from CVS. This is identical to Option 2 except that you get the files from CVS instead of the tarball: CVS Checkout Instructions. So, instead of tar xzf /var/tmp/openacs-5.6.0.tgz, cvs -z3 -d :pserver:anonymous@openacs.org:/cvsroot co acs-core.

    Next Steps

    • Use daemontools supervise and svc, or inittab, to automate server startup and shutdown.

    • Install Full Text Search (OPTIONAL). If you have installed OpenFTS and enabled OpenFTS, you can now install the OpenFTS Driver package and - Full Text Search Engine package in the OpenACS service.

    • This is a good time to make a backup of your service. If this is a - production site, you should set up automatic nightly backups.

    • If you want traffic reports, set up analog or another log + Full Text Search Engine package in the OpenACS service.

    • This is a good time to make a backup of your service. If this is a + production site, you should set up automatic nightly backups.

    • If you want traffic reports, set up analog or another log processing program.

    • Follow the instruction on the home page to change the appearance of your service or add more - packages. (more information)

    • Proceed to the tutorial to learn how to develop your own packages.

    • Set up database environment variables for the site + packages. (more information)

    • Proceed to the tutorial to learn how to develop your own packages.

    • Set up database environment variables for the site user. Depending on how you installed Oracle or PostGreSQL, these settings may be necessary for working with the database while logged in as the service user. They do not directly affect the service's run-time connection with the @@ -407,4 +407,4 @@ LD_LIBRARY_PATH=/ora8/m01/app/oracle/product/8.1.7/lib:/lib:/usr/lib ORACLE_SID=ora8 ORACLE_TERM=vt100 -ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data

  • Test your backup and recovery procedure.

  • Set up Section , “External uptime validation”.

  • ($Id$)
    View comments on this page at openacs.org
    +ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
  • Test your backup and recovery procedure.

  • Set up Section , “External uptime validation”.

  • ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/oracle.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/oracle.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/oracle.html 13 Sep 2009 23:54:40 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/oracle.html 18 Jun 2010 21:29:35 -0000 1.45.2.1 @@ -5,7 +5,7 @@

    If you are installing PostGreSQL instead of Oracle, skip this section.

    - OpenACS 5.5.0 will install with Oracle 9i but has not been extensively tested so may still have bugs or tuning issues. See Andrew Piskorski's Oracle 9i notes for guidance. + OpenACS 5.6.0 will install with Oracle 9i but has not been extensively tested so may still have bugs or tuning issues. See Andrew Piskorski's Oracle 9i notes for guidance.

    This installation guide attempts to present all of the information necessary to complete an OpenACS installation. We try hard to make all of the steps possible in one pass, rather than having a step which amounts to "go away and develop a profound understanding of software X and then come back and, in 99% of all cases, type these two lines." The exception to our rule is Oracle production systems. This page describes a set of steps to get a working Oracle development server, but it is unsuitable for production systems. If you will be using OpenACS on Oracle in a production environment, you will experience many problems unless you develop a basic understanding of Oracle which is outside the scope of this document. T

    Index: openacs-4/packages/acs-core-docs/www/packages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/packages.html,v diff -u -N -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-core-docs/www/packages.html 13 Sep 2009 23:54:40 -0000 1.47 +++ openacs-4/packages/acs-core-docs/www/packages.html 18 Jun 2010 21:29:35 -0000 1.47.2.1 @@ -1,5 +1,5 @@ -OpenACS Packages

    OpenACS Packages

    By Pete Su and Bryan Quinn

    +OpenACS Packages

    OpenACS Packages

    By Pete Su and Bryan Quinn

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Overview

    @@ -13,7 +13,7 @@

    Server file layout

    Here is how an OpenACS 5 server is laid out starting from the Server root (ROOT): -

    Figure 10.1. Server file layout diagram

    +    

    Figure 11.1. Server file layout diagram

     ROOT/
         bin/
             Various executables and scripts for server maintanence.
    @@ -51,7 +51,7 @@
           
           To illustrate the general structure of a package, let's see what the
           package for the "notes" application should look like.
    -    

    Figure 10.2. Package file layout diagram

    +    

    Figure 11.2. Package file layout diagram

     ROOT/
       +-- packages/    APM Root
             |
    @@ -124,7 +124,7 @@
           directories.  This makes it suitable for storing icons, css
           files, javascript, and other static content which can be treated
           this way.
    -    

    Table 10.1. Package files

    File TypeIts UseNaming Convention
    Package Specification FileThe package specification file is an XML file generated and +

    Table 11.1. Package files

    File TypeIts UseNaming Convention
    Package Specification FileThe package specification file is an XML file generated and maintained by the OpenACS Package Manager (APM). It specifies information about the package including its parameters and its files.notes.info
    Data Model Creation Script @@ -333,7 +333,7 @@ this point, you should add your package files to your CVS repository. I'll assume that you have set up your development repository according to the standards described in - this appendix. If so, then you just do this: + this appendix. If so, then you just do this:

    % cd ROOT/packages
     % cvs add notes
     % cd notes
    @@ -345,7 +345,7 @@
     % cvs commit -m "add new package for notes"
         
  • Now you can start developing the package. In addition to writing code, - you should also consider the tasks outlined in the package development tutorial. + you should also consider the tasks outlined in the package development tutorial.

  • The Site Map and Package Instances

    At this point, you are probably excited to see your new package in action. But, we haven't added any user visible pages yet. By @@ -373,7 +373,7 @@ of many indedendent applications that actually run on a single shared code base. The request-processor document shows you how OpenACS figures out which instance of your application was - requested by the user at any given time. The page development tutorial shows you how to use this + requested by the user at any given time. The page development tutorial shows you how to use this information in your user interface.

    In order to make the new notes application visible to @@ -395,7 +395,7 @@ yet written Notes application at various places in the site. In a later document, we'll see how to write your application so that the code can detect from what URL it was invoked. This is the key - to supporting subsites. + to supporting subsites.

    Summary

    The APM performs the following tasks in an OpenACS site:

    • @@ -411,4 +411,4 @@

    • Writes out package distribution files for other people to download and install. We'll cover this later. -

    View comments on this page at openacs.org
    +

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/parties.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/parties.html,v diff -u -N -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-core-docs/www/parties.html 13 Sep 2009 23:54:40 -0000 1.47 +++ openacs-4/packages/acs-core-docs/www/parties.html 18 Jun 2010 21:29:35 -0000 1.47.2.1 @@ -1,5 +1,5 @@ -Parties in OpenACS

    Parties in OpenACS

    By Rafael H. Schloming

    +Parties in OpenACS

    Parties in OpenACS

    By Rafael H. Schloming

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    While many applications must deal with individuals and many applications @@ -345,4 +345,4 @@ single integer primary key in what could be thought of as a pure relation. Because a membership relation is an ordinary acs object with object identity, it is as easy to extend the membership relation to store extra information as it is to extend the users -table or the groups table.

    ($Id$)
    View comments on this page at openacs.org
    +table or the groups table.

    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/permissions-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/permissions-design.html,v diff -u -N -r1.30 -r1.30.2.1 --- openacs-4/packages/acs-core-docs/www/permissions-design.html 13 Sep 2009 23:54:40 -0000 1.30 +++ openacs-4/packages/acs-core-docs/www/permissions-design.html 18 Jun 2010 21:29:35 -0000 1.30.2.1 @@ -1,5 +1,5 @@ -Permissions Design

    Permissions Design

    By John Prevost and Rafael H. Schloming

    +Permissions Design

    Permissions Design

    By John Prevost and Rafael H. Schloming

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Essentials

    8/26/2000Kai Wu
    0.4Edited for ACS 4 Beta release.10/03/2000Kai Wu
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/permissions-tediously-explained.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/permissions-tediously-explained.html,v diff -u -N -r1.43 -r1.43.2.1 --- openacs-4/packages/acs-core-docs/www/permissions-tediously-explained.html 13 Sep 2009 23:54:40 -0000 1.43 +++ openacs-4/packages/acs-core-docs/www/permissions-tediously-explained.html 18 Jun 2010 21:29:35 -0000 1.43.2.1 @@ -1,5 +1,5 @@ -OpenACS Permissions Tediously Explained

    OpenACS Permissions Tediously Explained

    +OpenACS Permissions Tediously Explained

    OpenACS Permissions Tediously Explained

    by Vadim Nasardinov. Modified and converted to Docbook XML by Roberto Mello

    The code has been modified since this document was written so it is now out of date. See this forum thread.

    Permissions Overview

    Who (grantee_id) can do what @@ -105,7 +105,7 @@

    Context Hierarchy

    Suppose objects A, B, ..., and F form the following hierarchy. -

    Table 10.2. Context Hierarchy Example

    A

    +

    Table 11.2. Context Hierarchy Example

    A

    object_id=10

    B

    object_id=20 @@ -121,7 +121,7 @@ This can be represented in the acs_objects table by the following entries: -

    Table 10.3. acs_objects example data

    object_idcontext_id
    2010
    3010
    4020
    5020
    6030

    +

    Table 11.3. acs_objects example data

    object_idcontext_id
    2010
    3010
    4020
    5020
    6030

    The first entry tells us that object 20 is the descendant of object 10, and the third entry shows that object 40 is the descendant of object 20. By running a CONNECT BY query, Index: openacs-4/packages/acs-core-docs/www/permissions.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/permissions.html,v diff -u -N -r1.46 -r1.46.2.1 --- openacs-4/packages/acs-core-docs/www/permissions.html 13 Sep 2009 23:54:41 -0000 1.46 +++ openacs-4/packages/acs-core-docs/www/permissions.html 18 Jun 2010 21:29:35 -0000 1.46.2.1 @@ -1,9 +1,9 @@ -Groups, Context, Permissions

    Groups, Context, Permissions

    By Pete Su

    +Groups, Context, Permissions

    Groups, Context, Permissions

    By Pete Su

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Overview

    -The OpenACS 5.5.0 Permissions system allows developers and administrators to +The OpenACS 5.6.0 Permissions system allows developers and administrators to set access control policies at the object level, that is, any application or system object represented by a row in the acs_objects table can be access-controlled via a @@ -21,7 +21,7 @@

    The rest of this document discusses each of these parts, and how they fit together with the permissions system.

    Groups

    -OpenACS 5.5.0 has an abstraction called a party. Parties have a recursive +OpenACS 5.6.0 has an abstraction called a party. Parties have a recursive definition. We can illustrate how it works with the following simplified data model. First, we define the parties table, where each party has an email address and a URL for contact @@ -84,14 +84,14 @@ some object. Privileges are the basic units out of which we build access control policies. For example in the Unix filesystem, access is controlled by granting users some combination of read, write, or execute privileges on files and directories. In -OpenACS 5.5.0, +OpenACS 5.6.0, the table of privileges is organized hierarchically so that developers can define privileges that aggregate some set of privileges together. For example, if we have read, write, create and delete privileges, it might be convenient to combine them into a new privilege called "admin". Then, when a user is granted "admin" privilege, she is automatically granted all the child privileges that the privilege -contains. The OpenACS 5.5.0 kernel data model defines these +contains. The OpenACS 5.6.0 kernel data model defines these privileges:

     # 
    @@ -136,7 +136,7 @@
     OpenACS provides a object contexts as a means for controlling permissions of a large group
     of objects at the same time. 
     

    Object Context

    -In OpenACS 5.5.0, object context is a scoping +In OpenACS 5.6.0, object context is a scoping mechanism. "Scoping" and "scope" are terms best explained by example: consider some hypothetical rows in the address_book table: @@ -199,7 +199,7 @@

    See the package developer tutorials for examples on how to use permissions code.

    Summary

    -OpenACS 5.5.0 defines three separate mechanisms for specifying access control +OpenACS 5.6.0 defines three separate mechanisms for specifying access control in applications.

    1. The Groups data model allows you to define hierarchical organizations of users and groups of users. @@ -211,4 +211,4 @@ permissions in a hierarchical fashion.

    A PL/SQL or Tcl API is then used to check permissions in application pages. -

    ($Id$)
    View comments on this page at openacs.org
    +

    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/postgres.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/postgres.html,v diff -u -N -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-core-docs/www/postgres.html 13 Sep 2009 23:54:41 -0000 1.47 +++ openacs-4/packages/acs-core-docs/www/postgres.html 18 Jun 2010 21:29:35 -0000 1.47.2.1 @@ -2,7 +2,7 @@ Install PostgreSQL

    Install PostgreSQL

    by Vinod Kurup

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Skip this section if you will run only Oracle.

    OpenACS 5.5.0 will run with PostgreSQL 7.3.2, 7.3.3, and 7.3.4 and 7.4.x. 7.4.7 is the recommended version of PostgreSQL.

    • Special notes for Mac OS X. If you are running Mac OS X prior to 10.3, you should be +

    Skip this section if you will run only Oracle.

    OpenACS 5.6.0 will run with PostgreSQL 7.3.2, 7.3.3, and 7.3.4 and 7.4.x. 7.4.7 is the recommended version of PostgreSQL.

    • Special notes for Mac OS X. If you are running Mac OS X prior to 10.3, you should be able to install and use PostGreSQL 7.3.x. Mac OS X 10.3 requires PostGreSQL 7.4.

    • Special Notes for Debian. 

      Debian stable user should install PostGreSQL from source as detailed below, or they should use the www.backports.org @@ -215,11 +215,11 @@ state. Red Hat and Debian and SuSE each work a little differently. If you haven't untarred the OpenACS tarball, you will need to do so now to access the postgresql.txt file.

      • Red Hat RPM:

        The init script is already installed; just turn it on for the appropriate run levels.

        [root root]# chkconfig --level 345 postgresql on
        -[root root]# 
      • Red Hat from source:

        [root src]# cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
        +[root root]# 
      • Red Hat from source:

        [root src]# cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
         [root src]# chown root.root /etc/rc.d/init.d/postgresql
         [root src]# chmod 755 /etc/rc.d/init.d/postgresql
         [root src]# 
        -cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
        +cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
         chown root.root /etc/rc.d/init.d/postgresql
         chmod 755 /etc/rc.d/init.d/postgresql

        Test the script.

        [root root]# service postgresql stop
         Stopping PostgreSQL: ok
        @@ -242,7 +242,7 @@
         [root ~]# chown root.root /etc/init.d/postgresql
         [root ~]# chmod 755 /etc/init.d/postgresql
         [root ~]# 
        -cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
        +cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /etc/init.d/postgresql
         chown root.root /etc/init.d/postgresql
         chmod 755 /etc/init.d/postgresql

        Test the script

        [root ~]# /etc/init.d/postgresql stop
         Stopping PostgreSQL: ok
        @@ -260,11 +260,11 @@
            /etc/rc5.d/S20postgresql -> ../init.d/postgresql
         [root ~]# /etc/init.d/postgresql start
         Starting PostgreSQL: ok
        -[root ~]#
      • FreeBSD:

        [root ~]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /usr/local/etc/rc.d/postgresql.sh
        +[root ~]#
      • FreeBSD:

        [root ~]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /usr/local/etc/rc.d/postgresql.sh
         [root ~]# chown root:wheel /usr/local/etc/rc.d/postgresql.sh
         [root ~]# chmod 755 /usr/local/etc/rc.d/postgresql.sh
         [root ~]# 
        -cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /usr/local/etc/rc.d/postgresql.sh
        +cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /usr/local/etc/rc.d/postgresql.sh
         chown root:wheel /usr/local/etc/rc.d/postgresql.sh
         chmod 755 /usr/local/etc/rc.d/postgresql.sh

        Test the script

        [root ~]# /usr/local/etc/rc.d/postgresql.sh stop
         Stopping PostgreSQL: ok
        @@ -282,7 +282,7 @@
                     rc.d/ part in each of the
                     following commands.
         
        -          

      [root ~]# cp /var/tmp/openacs-5.5.0/packages/acs-core-docs/www/files/postgresql.txt /etc/rc.d/init.d/postgresql
      +          

    [root ~]# cp /var/tmp/openacs-5.6.0/packages/acs-core-docs/www/files/postgresql.txt /etc/rc.d/init.d/postgresql
     [root ~]# chown root.root /etc/rc.d/init.d/postgresql
     [root ~]# chmod 755 /etc/rc.d/init.d/postgresql

    Index: openacs-4/packages/acs-core-docs/www/profile-code.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/profile-code.html,v diff -u -N -r1.11 -r1.11.2.1 --- openacs-4/packages/acs-core-docs/www/profile-code.html 13 Sep 2009 23:54:41 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/profile-code.html 18 Jun 2010 21:29:35 -0000 1.11.2.1 @@ -1,5 +1,5 @@ -Profile your code

    Profile your code

    by Jade Rubick

    +Profile your code

    Profile your code

    by Jade Rubick

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    There are several facilities for profiling your code in Index: openacs-4/packages/acs-core-docs/www/programming-with-aolserver.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/programming-with-aolserver.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/programming-with-aolserver.html 13 Sep 2009 23:54:41 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/programming-with-aolserver.html 18 Jun 2010 21:29:35 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -Programming with AOLserver

    Programming with AOLserver

    By Michael Yoon, Jon Salz and Lars Pind.

    +Programming with AOLserver

    Programming with AOLserver

    By Michael Yoon, Jon Salz and Lars Pind.

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    The global command

    Index: openacs-4/packages/acs-core-docs/www/psgml-for-emacs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/psgml-for-emacs.html,v diff -u -N -r1.37 -r1.37.2.1 --- openacs-4/packages/acs-core-docs/www/psgml-for-emacs.html 13 Sep 2009 23:54:41 -0000 1.37 +++ openacs-4/packages/acs-core-docs/www/psgml-for-emacs.html 18 Jun 2010 21:29:35 -0000 1.37.2.1 @@ -1,9 +1,9 @@ -Add PSGML commands to emacs init file (OPTIONAL)

    Add PSGML commands to emacs init file (OPTIONAL)

    +Add PSGML commands to emacs init file (OPTIONAL)

    Add PSGML commands to emacs init file (OPTIONAL)

    If you plan to write or edit any documentation with emacs, install a customized emacs configuration file with DocBook commands in the skeleton directory, so it will be used for all new users. The file also fixes the backspace -> help mis-mapping that often occurs in - terminals.

    [root tmp]# cp /tmp/openacs-5.5.0/packages/acs-core-docs/www/files/emacs.txt /etc/skel/.emacs
    +      terminals.

    [root tmp]# cp /tmp/openacs-5.6.0/packages/acs-core-docs/www/files/emacs.txt /etc/skel/.emacs
     cp: overwrite `/etc/skel/.emacs'? y
     [root tmp]# 

    Debian users:

    apt-get install psgml

    Note: The new nxml mode for emacs, when used in combination with psgml, provides a pretty good set of functionality that makes DocBook editing much less painless. In particular, nxml does syntax testing in real-time so that you can see syntax errors immediately instead of in the output of the xsltproc hours or days later. For debian, apt-get install nxml.

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/psgml-mode.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/psgml-mode.html,v diff -u -N -r1.44 -r1.44.2.1 --- openacs-4/packages/acs-core-docs/www/psgml-mode.html 12 Jul 2009 01:08:29 -0000 1.44 +++ openacs-4/packages/acs-core-docs/www/psgml-mode.html 18 Jun 2010 21:29:35 -0000 1.44.2.1 @@ -1,53 +1,53 @@ - -Using PSGML mode in Emacs

    Using PSGML mode in Emacs

    By David Lutterkort

    + +Using PSGML mode in Emacs

    Using PSGML mode in Emacs

    By David Lutterkort

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Note: nxml mode replaces and/or complements psgml mode. More information.

    What it is

    PSGML Mode is a mode for editing, umm, SGML and XML documents in emacs. It +

    Note: nxml mode replaces and/or complements psgml mode. More information.

    What it is

    PSGML Mode is a mode for editing, umm, SGML and XML documents in emacs. It can parse a DTD and help you insert the right tags in the right place, knows about tags' attributes and can tell you in which contexts a tag can be used. If you give it the right DTD, that is. But even without a DTD, -it can save you some typing since pressing C-c/ will close an open -tag automatically.

    Where to get it

    Most newer emacsen come with PSGML mode preinstalled. You can find out -whether your emacs has it with the locate-library command. In Emacs, -type M-x locate-library and enter psgml. Emacs will tell +it can save you some typing since pressing C-c/ will close an open +tag automatically.

    Where to get it

    Most newer emacsen come with PSGML mode preinstalled. You can find out +whether your emacs has it with the locate-library command. In Emacs, +type M-x locate-library and enter psgml. Emacs will tell you if it found it or not.

    If you don't have PSGML preinstalled in your Emacs, there are two -things you can do:

    1. On Linux: Get the -psgml rpm from RedHat's -docbook-tools and install it as usual.

    2. On other systems: Get the tarball from the PSGML Website. -Unpack it and follow the install instructions.

    Using CATALOG files

    The easiest way to teach PSGML mode about a DTD is by adding it to your -own CATALOG. Here is an example of how you can set that up for the -Docbook XML DTD.

    1. Get the Docbook XML DTD -zip archive from docbook.org

    2. Go somewhere in your working directory and do

      +things you can do:

      1. On Linux: Get the +psgml rpm from RedHat's +docbook-tools and install it as usual.

      2. On other systems: Get the tarball from the PSGML Website. +Unpack it and follow the install instructions.

    Using CATALOG files

    The easiest way to teach PSGML mode about a DTD is by adding it to your +own CATALOG. Here is an example of how you can set that up for the +Docbook XML DTD.

    1. Get the Docbook XML DTD +zip archive from docbook.org

    2. Go somewhere in your working directory and do

             mkdir -p dtd/docbook-xml
             cd dtd/docbook-xml
             unzip -a <docbook XML DTD zip archive>
          
      -
    3. Create a file with the name CATALOG in the dtd +

    4. Create a file with the name CATALOG in the dtd directory and put the line

      -      CATALOG "docbook-xml/docbook.cat"
      +      CATALOG "docbook-xml/docbook.cat"
       

      -in it. By maintaining your own CATALOG, it is easy to add more +in it. By maintaining your own CATALOG, it is easy to add more DTD's without changing your emacs settings. (How about that HTML 4.01 DTD you -always wanted to get from W3C ? The +always wanted to get from W3C ? The DTD is in the zip archives and tarballs available on the site.)

    That's it. Now you are ready to tell emacs all about PSGML mode and -that funky CATALOG

    What to tell emacs

    If you installed PSGML mode in a non-standard location, e.g., somewhere in -your home directory, you need to add this to the load-path by adding -this line to your .emacs file:

    -      (add-to-list 'load-path "/some/dir/that/contains/psgml.elc")
    +that funky CATALOG

    What to tell emacs

    If you installed PSGML mode in a non-standard location, e.g., somewhere in +your home directory, you need to add this to the load-path by adding +this line to your .emacs file:

    +      (add-to-list 'load-path "/some/dir/that/contains/psgml.elc")
        
    -

    To let PSGML mode find your CATALOG and to enable PSGML mode for -all your editing, add these lines to your .emacs:

    +

    To let PSGML mode find your CATALOG and to enable PSGML mode for +all your editing, add these lines to your .emacs:

           (require 'psgml)
     
    -      (add-to-list 'auto-mode-alist '("\\.html" . sgml-mode))
    -      (add-to-list 'auto-mode-alist '("\\.adp" . xml-mode))
    -      (add-to-list 'auto-mode-alist '("\\.xml" . xml-mode))
    -      (add-to-list 'auto-mode-alist '("\\.xsl" . xml-mode))
    +      (add-to-list 'auto-mode-alist '("\\.html" . sgml-mode))
    +      (add-to-list 'auto-mode-alist '("\\.adp" . xml-mode))
    +      (add-to-list 'auto-mode-alist '("\\.xml" . xml-mode))
    +      (add-to-list 'auto-mode-alist '("\\.xsl" . xml-mode))
           
    -      (add-to-list 'sgml-catalog-files "/path/to/your/dtd/CATALOG")
    +      (add-to-list 'sgml-catalog-files "/path/to/your/dtd/CATALOG")
        
     

    If you want font-locking and indentation, you can also add these lines -into the .emacs file:

    +into the .emacs file:

           (setq sgml-markup-faces '((start-tag . font-lock-function-name-face)
                                     (end-tag . font-lock-function-name-face)
                     (comment . font-lock-comment-face)
    @@ -59,28 +59,28 @@
           (setq sgml-set-face t)
           (setq-default sgml-indent-data t)
           ;; Some convenient key definitions:
    -      (define-key sgml-mode-map "\C-c\C-x\C-e" 'sgml-describe-element-type)
    -      (define-key sgml-mode-map "\C-c\C-x\C-i" 'sgml-general-dtd-info)
    -      (define-key sgml-mode-map "\C-c\C-x\C-t" 'sgml-describe-entity)
    +      (define-key sgml-mode-map "\C-c\C-x\C-e" 'sgml-describe-element-type)
    +      (define-key sgml-mode-map "\C-c\C-x\C-i" 'sgml-general-dtd-info)
    +      (define-key sgml-mode-map "\C-c\C-x\C-t" 'sgml-describe-entity)
        
    -

    What is a DOCTYPE ?

    All SGML and XML documents that should conform to a DTD have to declare a -doctype. For the docbook XML, all your .xml files whould start with +

    What is a DOCTYPE ?

    All SGML and XML documents that should conform to a DTD have to declare a +doctype. For the docbook XML, all your .xml files whould start with the line

    -      <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "docbookx.dtd">
    +      <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "docbookx.dtd">
        
     

    If your document is only part of a larger XML document, you can tell PSGML mode about it by appending the following lines to your file. In this case, do not include a DOCTYPE declaration in your file.

           <!--
            Local Variables:
    -       sgml-parent-document: ("top.xml" "book" "sect1")
    +       sgml-parent-document: ("top.xml" "book" "sect1")
            End:
           -->
        
     

    Which says that the parent of this document can be found in the file -top.xml, that the element in the parent that will enclose the -current document is a book and that the current file's topmost -element is a sect1.

    How to use it

    Of course, you should read the emacs texinfo pages that come with PSGML -mode from start to finish. Barring that, here are some handy commands:

    KeyCommand
    C-c C-eInsert an element. Uses completion and only lets you insert elements that -are valid
    C-c C-aEdit attributes of enclosing element.
    C-c C-x C-iShow information about the document's DTD.
    C-c C-x C-eDescribe element. Shows for one element which elements can be parents, -what its contents can be and lists its attributes.

    Further reading

    Start with the the section called “OpenACS Documentation Guide”

    ($Id$)
    View comments on this page at openacs.org
    +top.xml, that the element in the parent that will enclose the +current document is a book and that the current file's topmost +element is a sect1.

    How to use it

    Of course, you should read the emacs texinfo pages that come with PSGML +mode from start to finish. Barring that, here are some handy commands:

    KeyCommand
    C-c C-eInsert an element. Uses completion and only lets you insert elements that +are valid
    C-c C-aEdit attributes of enclosing element.
    C-c C-x C-iShow information about the document's DTD.
    C-c C-x C-eDescribe element. Shows for one element which elements can be parents, +what its contents can be and lists its attributes.

    Further reading

    Start with the Section , “OpenACS Documentation Guide”

    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/release-notes.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/release-notes.html,v diff -u -N -r1.51 -r1.51.2.1 --- openacs-4/packages/acs-core-docs/www/release-notes.html 13 Sep 2009 23:54:41 -0000 1.51 +++ openacs-4/packages/acs-core-docs/www/release-notes.html 18 Jun 2010 21:29:35 -0000 1.51.2.1 @@ -1,6 +1,35 @@ OpenACS Release Notes

    OpenACS Release Notes

    The ChangeLogs include an annotated list of changes (Section , “Changelog (most recent release only)”) since the last release and in the -entire 5.5 release sequence Section , “Changelog for oacs-5-5”.

    Release 5.5.0

    • PostgreSQL 8.3 is now fully supported, including the use of the built-in +entire 5.6 release sequence Section , “Changelog for oacs-5-6”.

      Release 5.6.0

      • + Added new package dependency type, "embeds". This is a variant of the + "extends" package dependency type added in OpenACS 5.5.0. It allows one + to write embeddable packages, with scripts made visible in client packages + using URLs which include the embedded package's package key. An example + embeddable package might be a rewritten "attachments" package. The current + implementation requires a global instance be mounted, and client packages + generate urls to that global instance. Among other things, this leads to + the user navigating to the top-level subsite, losing any subsite theming + that might be associated with a community. Using "embeds", a rewritten + package would run in the client package's context, maintaining theming and + automatically associating attachments with the client package. +

        + Added global package parameters - parameters can now have scope "local" or "global", + with "local" being the default.. +

        + Fixes for ns_proxy handling +

        + Significant speedup for large sites +

        + Optional support for selenium remote control (acs-automated-tests) +

        + New administration UI to manage mime types and extension map +

        + Added acs-mail-lite package params for rollout support +

        + Support for 3-chars language codes in acs-lang +

        + Added OOXML mime types in acs-content-repository +

      Release 5.5.0

      • PostgreSQL 8.3 is now fully supported, including the use of the built-in standard version of tsearch2.

        TinyMCE has been upgraded to 3.2.4.1 with language pack support.

        acs-mail-lite now correctly implements rollout support. @@ -47,14 +76,14 @@

        Templates have been modified to comply with HTML strict

        The Search package's results page has been improved

        TinyMCE WYSIWYG support has been added, RTE and HTMLArea support dropped

        acs-mail-lite's send has been cleaned up to properly encode content, to handle file attachments, etc. "complex-send" will disappear from acs-core in a future release.

      The ChangeLogs include an annotated list of changes (Section , “Changelog (most recent release only)”) since the last release and in the -entire 5.5 release sequence Section , “Changelog for oacs-5-5”.

      Release 5.3.1

      • Bug fixes.

        New TIPs implemented.

        All Core Automated Tests for Postgres pass.

        New Site and Blank master templates and CSS compatible with the .LRN Zen +entire 5.6 release sequence Section , “Changelog for oacs-5-6”.

        Release 5.3.1

        • Bug fixes.

          New TIPs implemented.

          All Core Automated Tests for Postgres pass.

          New Site and Blank master templates and CSS compatible with the .LRN Zen work. Compatibility master templates are provided for existing sites.

        The ChangeLogs include an annotated list of changes (Section , “Changelog (most recent release only)”) since the last release and in the -entire 5.5 release sequence Section , “Changelog for oacs-5-5”.

        Release 5.3.0

        • Bug fixes.

          New TIPs implemented.

          All Core Automated Tests for Postgres pass.

        Release 5.2.0

        • Bug fixes.

          New TIPs implemented.

          This release does not include new translations.

        Release 5.1.4

        • Bug fixes.

          The missing CR TCL API has been filled in, thanks to Rocael and +entire 5.6 release sequence Section , “Changelog for oacs-5-6”.

          Release 5.3.0

          • Bug fixes.

            New TIPs implemented.

            All Core Automated Tests for Postgres pass.

          Release 5.2.0

          • Bug fixes.

            New TIPs implemented.

            This release does not include new translations.

          Release 5.1.4

          • Bug fixes.

            The missing CR TCL API has been filled in, thanks to Rocael and his team and Dave Bauer.

            This release does not include new translations.

          Release 5.1.3

          • Bug fixes, primarily for .LRN compatibility in support of upcoming .LRN 2.1.0 releases. This release does not include new translations since 5.1.2.

          Release 5.1.2

          Release 5.1.1

          • This is the first release using the newest adjustment to the versioning convention. The OpenACS 5.1.1 tag will apply to OpenACS core as well as to the most recent released version of every package, including .LRN.

          • Translations syncronized with the translation server. + 5.1.0 in Section , “Changelog for oacs-5-6”.

          Release 5.1.1

          • This is the first release using the newest adjustment to the versioning convention. The OpenACS 5.1.1 tag will apply to OpenACS core as well as to the most recent released version of every package, including .LRN.

          • Translations syncronized with the translation server.

          • Bug 1519 fixed. This involved renaming all catalog files for ch_ZH, TH_TH, AR_EG, AR_LB, ms_my, RO_RO, FA_IR, @@ -65,7 +94,7 @@ the files and database before upgrading.)

          • Other bug fixes since 5.1.0: 1785, 1793, and over a dozen additional bug fixes.

          • For a complete change list, see the Change list since - 5.0.0 in Section , “Changelog for oacs-5-5”.

          Release 5.1.0

          • Lots of little tweaks and fixes

          • Complete Change list since 5.0.0 in Changelog

          • Many Bug fixes

          Release 5.0.4

          • New translations, including for .LRN 2.0.2.

          Release 5.0.1

          • All work on the translation server from 7 Nov 2003 to 7 Feb 2004 is now included in catalogs.

          • One new function in acs-tcl, util::age_pretty

          • Complete Change list since 5.0.0 in Changelog

          • Many documentation updates and doc bug fixes

          Release 5.0.0

          + 5.0.0 in Section , “Changelog for oacs-5-6”.

        Release 5.1.0

        • Lots of little tweaks and fixes

        • Complete Change list since 5.0.0 in Changelog

        • Many Bug fixes

        Release 5.0.4

        • New translations, including for .LRN 2.0.2.

        Release 5.0.1

        • All work on the translation server from 7 Nov 2003 to 7 Feb 2004 is now included in catalogs.

        • One new function in acs-tcl, util::age_pretty

        • Complete Change list since 5.0.0 in Changelog

        • Many documentation updates and doc bug fixes

        Release 5.0.0

        This is OpenACS 5.0.0. This version contains no known security, data loss, or crashing bugs, nor any bugs judged release blockers. This version has received manual testing. It has passed current automated testing, which is not comprehensive. This release contains work done on the translation server http://translate.openacs.org through 7 Nov 2003.

        Please report bugs using our @@ -74,7 +103,7 @@

        You may want to begin by reading our installation documentation for Section , “a Unix-like system”. Note that the Windows documentation is - not current for OpenACS 5.5.0, but an alternative is to use John + not current for OpenACS 5.6.0, but an alternative is to use John Sequeira's Oasis VM project.

        @@ -162,199 +191,10 @@

      • Serving backup files and files from the CVS directories is turned off by default via the acs-kernel parameter ExcludedFiles in section request-processor (The variable provides a string match glob list of files and is defaulted to "*/CVS/* *~") -

      ($Id$)

      Changelog (most recent release only)

      ChangeLog missing
      +

    ($Id$)

    Changelog (most recent release only)

    ChangeLog missing
    --> -

    Changelog for oacs-5-5

    -2009-09-05 21:44  donb
    -
    -	* packages/acs-content-repository/tcl/apm-callback-procs.tcl: The
    -	  after upgrade callback needed a documentation block.
    -
    -2009-09-05 16:27  donb
    -
    -	* packages/: acs-admin/acs-admin.info,
    -	  acs-api-browser/acs-api-browser.info,
    -	  acs-authentication/acs-authentication.info,
    -	  acs-automated-testing/acs-automated-testing.info,
    -	  acs-bootstrap-installer/acs-bootstrap-installer.info,
    -	  acs-content-repository/acs-content-repository.info,
    -	  acs-core-docs/acs-core-docs.info, acs-kernel/acs-kernel.info,
    -	  acs-lang/acs-lang.info, acs-mail-lite/acs-mail-lite.info,
    -	  acs-messaging/acs-messaging.info,
    -	  acs-reference/acs-reference.info,
    -	  acs-service-contract/acs-service-contract.info,
    -	  acs-subsite/acs-subsite.info, acs-tcl/acs-tcl.info,
    -	  acs-templating/acs-templating.info,
    -	  acs-translations/acs-translations.info,
    -	  intermedia-driver/intermedia-driver.info,
    -	  notifications/notifications.info,
    -	  openacs-default-theme/openacs-default-theme.info,
    -	  ref-timezones/ref-timezones.info, search/search.info,
    -	  tsearch2-driver/tsearch2-driver.info: Bumped version number to
    -	  5.5.1b1 in preparation for release.
    -
    -2009-09-02 17:32  daveb
    -
    -	* packages/acs-tcl/tcl/request-processor-procs.tcl: Fix redirect
    -	  when ForceHostP is true. Fix redirect to/from HTTP/HTTPS where
    -	  full URLs are used.
    -
    -2009-08-10 23:40  donb
    -
    -	* packages/acs-subsite/tcl/: package-procs-oracle.xql,
    -	  package-procs-postgresql.xql, package-procs.tcl:
    -	  package_exec_plsql didn't work if the sql proc being called has a
    -	  parameter named "package_name"...
    -
    -2009-08-10 18:35  michaels
    -
    -	* packages/acs-templating/tcl/richtext-procs.tcl: remove html
    -	  security check bypass for admins in the richtext validation per
    -	  OCT discussion
    -
    -2009-07-29 22:21  donb
    -
    -	* packages/search/: search.info, tcl/apm-callback-procs.tcl,
    -	  tcl/search-init.tcl: Added a package instantiate callback so when
    -	  someone mounts "search", the search indexer is correctly started
    -	  up without a server restart being required.
    -
    -2009-07-24 14:12  victorg
    -
    -	* packages/acs-templating/: acs-templating.info,
    -	  tcl/apm-callback-procs.tcl: Providing upgrade logic for removing
    -	  Xinha invalid plugins from the parameter XinhaDefaultPlugins.
    -
    -2009-07-22 20:47  emmar
    -
    -	* packages/acs-subsite/acs-subsite.info: Fix dependencies and their
    -	  version
    -
    -2009-07-21 22:14  emmar
    -
    -	* packages/acs-templating/tcl/date-procs.tcl: Localized default
    -	  format for date widget
    -
    -2009-07-20 21:29  emmar
    -
    -	* packages/acs-templating/tcl/richtext-procs.tcl: Close LABEL tag
    -	  before adding the Format and Spellcheck widgets. This HTML should
    -	  be build in the template rather than in the rendering proc. Each
    -	  widget should be computed separately.
    -
    -2009-07-20 12:24  emmar
    -
    -	* packages/acs-content-repository/: acs-content-repository.info,
    -	  sql/common/mime-type-data.sql, tcl/apm-callback-procs.tcl:
    -	  Implements TIP #135 (OOXML formats)
    -
    -2009-07-20 09:32  emmar
    -
    -	* packages/acs-core-docs/www/individual-programs.html: Fix Tcl
    -	  version
    -
    -2009-07-20 08:42  emmar
    -
    -	* packages/acs-core-docs/www/xml/install-guide/software.xml: Fix
    -	  Tcl version
    -
    -2009-07-17 11:48  emmar
    -
    -	* packages/: acs-admin/acs-admin.info,
    -	  acs-api-browser/acs-api-browser.info,
    -	  acs-authentication/acs-authentication.info,
    -	  acs-automated-testing/acs-automated-testing.info,
    -	  acs-bootstrap-installer/acs-bootstrap-installer.info,
    -	  acs-content-repository/acs-content-repository.info,
    -	  acs-core-docs/acs-core-docs.info, acs-kernel/acs-kernel.info,
    -	  acs-lang/acs-lang.info, acs-mail-lite/acs-mail-lite.info,
    -	  acs-messaging/acs-messaging.info,
    -	  acs-reference/acs-reference.info,
    -	  acs-service-contract/acs-service-contract.info,
    -	  acs-subsite/acs-subsite.info, acs-tcl/acs-tcl.info,
    -	  acs-templating/acs-templating.info,
    -	  acs-translations/acs-translations.info,
    -	  intermedia-driver/intermedia-driver.info,
    -	  notifications/notifications.info,
    -	  openacs-default-theme/openacs-default-theme.info,
    -	  ref-timezones/ref-timezones.info, search/search.info,
    -	  tsearch2-driver/tsearch2-driver.info: Bumped version to 5.5.1d1
    -
    -2009-07-14 11:44  emmar
    -
    -	* packages/notifications/:
    -	  catalog/notifications.en_US.ISO-8859-1.xml,
    -	  catalog/notifications.es_ES.ISO-8859-1.xml,
    -	  tcl/notification-procs.tcl, www/manage.adp, www/manage.tcl,
    -	  www/request-change-frequency.adp,
    -	  www/request-change-frequency.tcl, www/request-new.adp,
    -	  www/request-new.tcl: Localization (level AA requirement)
    -
    -2009-07-14 09:47  emmar
    -
    -	* packages/acs-subsite/: catalog/acs-subsite.en_US.ISO-8859-1.xml,
    -	  catalog/acs-subsite.es_ES.ISO-8859-1.xml,
    -	  www/shared/whos-online.adp, www/shared/whos-online.tcl:
    -	  Localization
    -
    -2009-07-06 11:17  emmar
    -
    -	* packages/acs-core-docs/www/: database-management.html,
    -	  docbook-primer.html, install-next-nightly-vacuum.html,
    -	  install-openacs-delete-tablespace.html,
    -	  programming-with-aolserver.html, remote-postgres.html,
    -	  unix-installation.html: Regenerate HTML files after updating
    -	  variables values and the compatibility table
    -
    -2009-07-06 11:14  emmar
    -
    -	* packages/acs-core-docs/www/: acs-admin.html,
    -	  acs-package-dev.html, acs-plat-dev.html, aolserver.html,
    -	  aolserver4.html, apm-design.html, apm-requirements.html,
    -	  automated-backup.html, automated-testing-best-practices.html,
    -	  backup-recovery.html, backups-with-cvs.html,
    -	  complete-install.html, configuring-configuring-packages.html,
    -	  configuring-configuring-permissions.html,
    -	  configuring-install-packages.html,
    -	  configuring-mounting-packages.html, credits.html,
    -	  cvs-guidelines.html, cvs-tips.html, db-api-detailed.html,
    -	  db-api.html, dev-guide.html, doc-standards.html,
    -	  eng-standards-constraint-naming.html,
    -	  eng-standards-filenaming.html, eng-standards-plsql.html,
    -	  eng-standards-versioning.html, ext-auth-requirements.html,
    -	  filename.html, form-builder.html, groups-design.html,
    -	  high-avail.html, how-do-I.html, i18n-convert.html, index.html,
    -	  individual-programs.html, install-cvs.html,
    -	  install-daemontools.html, install-full-text-search-openfts.html,
    -	  install-full-text-search-tsearch2.html,
    -	  install-next-add-server.html, install-next-backups.html,
    -	  install-openacs-keepalive.html, install-qmail.html,
    -	  install-redhat.html, install-steps.html, ix01.html,
    -	  kernel-doc.html, mac-installation.html, maint-performance.html,
    -	  maintenance-deploy.html, object-identity.html,
    -	  object-system-design.html, object-system-requirements.html,
    -	  objects.html, openacs-unpack.html, openacs.html, oracle.html,
    -	  packages.html, parties.html,
    -	  permissions-tediously-explained.html, permissions.html,
    -	  postgres.html, psgml-for-emacs.html, psgml-mode.html,
    -	  release-notes.html, releasing-openacs-core.html,
    -	  request-processor.html, requirements-template.html,
    -	  rp-design.html, security-notes.html, snapshot-backup.html,
    -	  style-guide.html, subsites.html, templates.html,
    -	  tutorial-database.html, tutorial-debug.html,
    -	  tutorial-newpackage.html, tutorial-pages.html, tutorial.html,
    -	  upgrade-4.5-to-4.6.html, upgrade-openacs-files.html,
    -	  upgrade-overview.html, variables.html: Updated with correct
    -	  variable values and last changes in the compatibility table
    -
    -2009-07-06 11:02  emmar
    -
    -	* packages/acs-core-docs/www/xml/: variables.ent,
    -	  install-guide/compatibility.xml, install-guide/software.xml:
    -	  Updated the compatibility table.  Set the variables according to
    -	  the last final release.  Removed unused (and duplicated) file.
    -
    -
    +

    Changelog for oacs-5-6

    +ChangeLog missing
     
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/releasing-openacs-core.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/releasing-openacs-core.html,v diff -u -N -r1.16 -r1.16.2.1 --- openacs-4/packages/acs-core-docs/www/releasing-openacs-core.html 13 Sep 2009 23:54:41 -0000 1.16 +++ openacs-4/packages/acs-core-docs/www/releasing-openacs-core.html 18 Jun 2010 21:29:35 -0000 1.16.2.1 @@ -1,5 +1,5 @@ -OpenACS Core and .LRN

    OpenACS Core and .LRN

    1. Update Translations. Section , “How to Update the translations”

    2. Rebuild the Changelog. Rebuild the Changelog. I use a tool called cvs2cl. Run this command from the package root to automatically generate a Changelog file in the same dir. We generate two changelogs, one for the minor branch and one for the most recent release. The example below is for OpenACS 5.0.2:

      cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
      +OpenACS Core and .LRN

      OpenACS Core and .LRN

      1. Update Translations. Section , “How to Update the translations”

      2. Rebuild the Changelog. Rebuild the Changelog. I use a tool called cvs2cl. Run this command from the package root to automatically generate a Changelog file in the same dir. We generate two changelogs, one for the minor branch and one for the most recent release. The example below is for OpenACS 5.0.2:

        cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
         cvs2cl -F oacs-5-0 --delta openacs-5-0-0-final:oacs-5-0 -f ChangeLog
         cvs2cl -F oacs-5-0 --delta openacs-5-0-1-final:oacs-5-0 -f ChangeLog-recent
      3. Update Version Numbers. The version numbers in the documentation and in the packages must be updated. This should only happen after a release candidate is approved.

        .LRN: this must be repeated for .LRN modules (dotlrn-core in the dotlrn cvs tree) and for any modified modules in the .LRN prerequisites (dotlrn-prereq in openacs cvs tree). My current working model is that I bulk-update .LRN and OpenACS core but that I don't touch dotlrn-prereq modules - I just use the most recent release and it's up to individual package developers to tag and release those packages when they change. This model is already broken because following it means that dotlrn-prereqs don't get new translations.
        1. Update /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/xml/variables.ent with the new version number.

        2. Add new section in /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/xml/for-everyone/release-notes.xml @@ -139,4 +139,4 @@ # Clean up after ourselves... cd $BASE && rm -rf dotlrn-tarball tarball openacs-4 dotlrn-packages -

      ($Id$)
    View comments on this page at openacs.org
    +
    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/releasing-openacs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/releasing-openacs.html,v diff -u -N -r1.25 -r1.25.2.1 --- openacs-4/packages/acs-core-docs/www/releasing-openacs.html 13 Sep 2009 23:54:41 -0000 1.25 +++ openacs-4/packages/acs-core-docs/www/releasing-openacs.html 18 Jun 2010 21:29:35 -0000 1.25.2.1 @@ -1,2 +1,2 @@ -Chapter 15. Releasing OpenACS
    View comments on this page at openacs.org
    +Chapter 16. Releasing OpenACS
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/releasing-package.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/releasing-package.html,v diff -u -N -r1.11 -r1.11.2.1 --- openacs-4/packages/acs-core-docs/www/releasing-package.html 13 Sep 2009 23:54:41 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/releasing-package.html 18 Jun 2010 21:29:35 -0000 1.11.2.1 @@ -1,5 +1,5 @@ -How to package and release an OpenACS Package

    How to package and release an OpenACS Package

    In this example, we are packaging and releasing myfirstpackage as version 1.0.0, which is compatible with OpenACS 5.0.x.

    1. Update the version number, release date, and package maturity of your package in the APM.

    2. Make sure all changes are committed.

    3. Tag the updated work.:

      cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage
      +How to package and release an OpenACS Package

      How to package and release an OpenACS Package

      In this example, we are packaging and releasing myfirstpackage as version 1.0.0, which is compatible with OpenACS 5.0.x.

      1. Update the version number, release date, and package maturity of your package in the APM.

      2. Make sure all changes are committed.

      3. Tag the updated work.:

        cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage
         cvs tag myfirstpackages-1-0-0-final
         cvs tag -F openacs-5-0-compat
         

      Done. The package will be added to the repository automatically. If the correct version does not show up within 24 hours, ask for help on the OpenACS.org development forum.

      View comments on this page at openacs.org
      Index: openacs-4/packages/acs-core-docs/www/request-processor.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/request-processor.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/request-processor.html 13 Sep 2009 23:54:41 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/request-processor.html 18 Jun 2010 21:29:35 -0000 1.45.2.1 @@ -1,13 +1,13 @@ -The Request Processor

      The Request Processor

      By Pete Su

      +The Request Processor

      The Request Processor

      By Pete Su

      OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

      Overview

      -This document is a brief introduction to the OpenACS 5.5.0 Request Processor; +This document is a brief introduction to the OpenACS 5.6.0 Request Processor; more details can be found in the OpenACS 4 Request Processor Design. Here we cover the high level concepts behind the system, and implications and usage for the application developer.

      Request Processor

      -The 5.5.0 Request Processor is a global filter and set of Tcl procs that +The 5.6.0 Request Processor is a global filter and set of Tcl procs that respond to every incoming URL reaching the server. The following diagram summarizes the stages of the request processor assuming a URL request like http://someserver.com/notes/somepage.adp. @@ -18,14 +18,14 @@ The first thing the RP does is to map the given URL to the appropriate physical directory in the filesystem, from which to serve content. We do this by searching the site map data model (touched on in the Packages, and further -discussed in ???). This data model maps URLs to objects representing +discussed in Writing OpenACS Application Pages). This data model maps URLs to objects representing content, and these objects are typically package instances.

      After looking up the appropriate object, the RP stores the URL, the ID of the object it found, and the package and package instance the object belongs to into the environment of the connection. This environment can be queried using the ad_conn procedure, -which is described in detail in OpenACS 4 Request Processor Design. The page +which is described in detail in OpenACS 4 Request Processor Design. The page development tutorial shows you how to use this interface to make your pages aware of which instance was requested.

      Stage 2: Authentication

      @@ -36,7 +36,7 @@ extracts or sets up new session tokens for the user.

      Stage 3: Authorization

      Next, the Request Processor checks if the user has appropriate access -privileges to the requested part of the site. In OpenACS 5.5.0, access control +privileges to the requested part of the site. In OpenACS 5.6.0, access control is dictated by the permissions system. In this case, the RP checks if the user has "read" priviledges on the object in the site map specified by the URL. This object is typically Index: openacs-4/packages/acs-core-docs/www/requirements-template.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/requirements-template.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/requirements-template.html 13 Sep 2009 23:54:41 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/requirements-template.html 18 Jun 2010 21:29:36 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -System/Application Requirements Template

      System/Application Requirements Template

      By You

      +System/Application Requirements Template

      System/Application Requirements Template

      By You

      OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

      Introduction

      @@ -81,4 +81,4 @@ pre-existing system or prototype first, and thus you may want to write some thoughts on implementation, for aiding and guiding yourself or other programmers. -

      Revision History

      Document Revision #Action Taken, NotesWhen?By Whom?
      0.3Edited further, incorporated feedback from Michael Yoon9/05/2000Kai Wu
      0.2Edited8/22/2000Kai Wu
      0.1Created8/21/2000Josh Finkler, Audrey McLoghlin
      ($Id$)
      View comments on this page at openacs.org
      +

      Revision History

      Document Revision #Action Taken, NotesWhen?By Whom?
      0.3Edited further, incorporated feedback from Michael Yoon9/05/2000Kai Wu
      0.2Edited8/22/2000Kai Wu
      0.1Created8/21/2000Josh Finkler, Audrey McLoghlin
      ($Id$)
      View comments on this page at openacs.org
      Index: openacs-4/packages/acs-core-docs/www/rp-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/rp-design.html,v diff -u -N -r1.33 -r1.33.2.1 --- openacs-4/packages/acs-core-docs/www/rp-design.html 13 Sep 2009 23:54:41 -0000 1.33 +++ openacs-4/packages/acs-core-docs/www/rp-design.html 18 Jun 2010 21:29:36 -0000 1.33.2.1 @@ -1,5 +1,5 @@ -Request Processor Design

      Request Processor Design

      By Rafael H. Schloming

      +Request Processor Design

      Request Processor Design

      By Rafael H. Schloming

      OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.
    [ad_conn sec_validated]This becomes "secure" when the connection uses SSL
     
    Database API
    [ad_conn db,handles]What are the list of handles available to AOL?
    [ad_conn db,n_handles_used]How many database handles are currently used?
    [ad_conn db,last_used]Which database handle did we use last?
    [ad_conn db,transaction_level,$db]Specifies what transaction level we are in
    [ad_conn db,db_abort_p,$dbh]Whether the transaction is aborted
     
    APM
    [ad_conn xml_loaded_p]Checks whether the XML parser is loaded so that it only gets loaded once. Set in apm_load_xml_packages
     
    Packages
    [ad_conn package_id]The package_id of the package associated with the URL.
    [ad_conn package_url]The URL on which the package is mounted.
     
    Miscellaneous
    [ad_conn system_p]If true then the request has been made to one of the special directories specified in the config file (somewhere), and no authentication or -authorization has been performed.
     
    Documentation
    [ad_conn api_page_documentation_mode_p] 
    View comments on this page at openacs.org
    +authorization has been performed.
     
    Documentation
    [ad_conn api_page_documentation_mode_p] 
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/rp-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/rp-requirements.html,v diff -u -N -r1.29 -r1.29.2.1 --- openacs-4/packages/acs-core-docs/www/rp-requirements.html 13 Sep 2009 23:54:41 -0000 1.29 +++ openacs-4/packages/acs-core-docs/www/rp-requirements.html 18 Jun 2010 21:29:36 -0000 1.29.2.1 @@ -1,5 +1,5 @@ -Request Processor Requirements

    Request Processor Requirements

    By Rafael H. Schloming

    +Request Processor Requirements

    Request Processor Requirements

    By Rafael H. Schloming

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    The following is a requirements document for the OpenACS 4.0 request Index: openacs-4/packages/acs-core-docs/www/security-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/security-design.html,v diff -u -N -r1.31 -r1.31.2.1 --- openacs-4/packages/acs-core-docs/www/security-design.html 13 Sep 2009 23:54:41 -0000 1.31 +++ openacs-4/packages/acs-core-docs/www/security-design.html 18 Jun 2010 21:29:36 -0000 1.31.2.1 @@ -1,5 +1,5 @@ -Security Design

    Security Design

    By Richard Li and Archit Shah

    +Security Design

    Security Design

    By Richard Li and Archit Shah

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    Index: openacs-4/packages/acs-core-docs/www/security-notes.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/security-notes.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/security-notes.html 13 Sep 2009 23:54:41 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/security-notes.html 18 Jun 2010 21:29:36 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -Security Notes

    Security Notes

    By Richard Li

    +Security Notes

    Security Notes

    By Richard Li

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Index: openacs-4/packages/acs-core-docs/www/security-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/security-requirements.html,v diff -u -N -r1.31 -r1.31.2.1 --- openacs-4/packages/acs-core-docs/www/security-requirements.html 13 Sep 2009 23:54:41 -0000 1.31 +++ openacs-4/packages/acs-core-docs/www/security-requirements.html 18 Jun 2010 21:29:36 -0000 1.31.2.1 @@ -1,5 +1,5 @@ -Security Requirements

    Security Requirements

    By Richard Li

    +Security Requirements

    Security Requirements

    By Richard Li

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Introduction

    Index: openacs-4/packages/acs-core-docs/www/snapshot-backup.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/snapshot-backup.html,v diff -u -N -r1.10 -r1.10.2.1 --- openacs-4/packages/acs-core-docs/www/snapshot-backup.html 12 Jul 2009 01:08:29 -0000 1.10 +++ openacs-4/packages/acs-core-docs/www/snapshot-backup.html 18 Jun 2010 21:29:36 -0000 1.10.2.1 @@ -1,35 +1,35 @@ - -Manual backup and recovery

    Manual backup and recovery

    This section describes how to make a one-time backup and + +Manual backup and recovery

    Manual backup and recovery

    This section describes how to make a one-time backup and restore of the files and database. This is useful for rolling back to known-good versions of a service, such as at initial installation and just before an upgrade. First, you back up the database to a file within the file tree. Then, you back up the file tree. All of the information needed to rebuild the site, including the AOLserver config files, is then in tree for regular - file system backup.

    1. Back up the database to a file. 

      • Oracle. 

        • - Download the backup script. Save the file export-oracle.txt as - /var/tmp/export-oracle.txt -

        • + file system backup.

          1. Back up the database to a file. 

            • Oracle. 

              • + Download the backup script. Save the file export-oracle.txt as + /var/tmp/export-oracle.txt +

              • Login as root. The following commands will install the export script: -

                [joeuser ~]$ su -
                -[root ~]# cp /var/tmp/export-oracle.txt /usr/sbin/export-oracle
                -[root ~]# chmod 700 /usr/sbin/export-oracle
              • +

                [joeuser ~]$ su -
                +[root ~]# cp /var/tmp/export-oracle.txt /usr/sbin/export-oracle
                +[root ~]# chmod 700 /usr/sbin/export-oracle
              • Setup the export directory; this is the directory where backups will be stored. We recommend the directory - /ora8/m02/oracle-exports.

                [root ~]# mkdir /ora8/m02/oracle-exports
                -[root ~]# chown oracle:dba /ora8/m02/oracle-exports
                -[root ~]# chmod 770 /ora8/m02/oracle-exports
              • + /ora8/m02/oracle-exports.

                [root ~]# mkdir /ora8/m02/oracle-exports
                +[root ~]# chown oracle:dba /ora8/m02/oracle-exports
                +[root ~]# chmod 770 /ora8/m02/oracle-exports
              • Now edit - /usr/sbin/export-oracle and - change the SERVICE_NAME and - DATABASE_PASSWORD fields to + /usr/sbin/export-oracle and + change the SERVICE_NAME and + DATABASE_PASSWORD fields to their correct values. If you want to use a directory other than - /ora8/m02/oracle-exports, you + /ora8/m02/oracle-exports, you also need to change the - exportdir setting. + exportdir setting.

                Test the export procedure by running the command: -

                [root ~]# /usr/sbin/export-oracle
                +              

                [root ~]# /usr/sbin/export-oracle
                 mv: /ora8/m02/oracle-exports/oraexport-service_name.dmp.gz: No such file or directory
                 
                 Export: Release 8.1.6.1.0 - Production on Sun Jun 11 18:07:45 2000
                @@ -64,70 +64,70 @@
                   . exporting dimensions
                   . exporting post-schema procedural objects and actions
                   . exporting statistics
                -Export terminated successfully without warnings.
            • PostgreSQL. Create a backup file and verify that it was created and has a reasonable size (several megabytes).

              [root root]# su - $OPENACS_SERVICE_NAME
              -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ pg_dump -f /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp $OPENACS_SERVICE_NAME
              -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ ls -al /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp 
              +Export terminated successfully without warnings.
          2. PostgreSQL. Create a backup file and verify that it was created and has a reasonable size (several megabytes).

            [root root]# su - $OPENACS_SERVICE_NAME
            +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ pg_dump -f /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp $OPENACS_SERVICE_NAME
            +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ ls -al /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp 
             -rw-rw-r-x    1 $OPENACS_SERVICE_NAME  $OPENACS_SERVICE_NAME   4005995 Feb 21 18:28 /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp
            -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
            +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ exit
             [root root]#
             su - $OPENACS_SERVICE_NAME
             pg_dump -f /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp openacs-dev
             ls -al /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/before_upgrade_to_4.6.dmp
            -exit
      • Back up the file system. Back up all of the files in the service, including the +exit

    2. Back up the file system. Back up all of the files in the service, including the database backup file but excluding the auto-generated - supervise directory, which is - unneccesary and has complicated permissions.

      In the tar command,

      • c create a - new tar archive

      • p preserves permissions.

      • s preserves file sort order

      • z compresses the output with gzip.

      • The --exclude clauses skips some daemontools files that + supervise directory, which is + unneccesary and has complicated permissions.

        In the tar command,

        • c create a + new tar archive

        • p preserves permissions.

        • s preserves file sort order

        • z compresses the output with gzip.

        • The --exclude clauses skips some daemontools files that are owned by root and thus cannot be backed up by the service owner. These files are autogenerated and we don't - break anything by omitting them.

        • The --file clause + break anything by omitting them.

        • The --file clause specifies the name of the output file to be generated; we - manually add the correct extensions.

        • The last clause, - /var/lib/aolserver/$OPENACS_SERVICE_NAME/, + manually add the correct extensions.

        • The last clause, + /var/lib/aolserver/$OPENACS_SERVICE_NAME/, specifies the starting point for backup. Tar defaults to - recursive backup.

        [root root]# su - $OPENACS_SERVICE_NAME
        -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ tar -cpsz --exclude /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/daemontools/supervise \
        -   --file /var/tmp/$OPENACS_SERVICE_NAME-backup.tar.gz /var/lib/aolserver/$OPENACS_SERVICE_NAME/
        +            recursive backup.

      [root root]# su - $OPENACS_SERVICE_NAME
      +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ tar -cpsz --exclude /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/daemontools/supervise \
      +   --file /var/tmp/$OPENACS_SERVICE_NAME-backup.tar.gz /var/lib/aolserver/$OPENACS_SERVICE_NAME/
       tar: Removing leading `/' from member names
      -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$
    3. Suffer a catastrophic failure on your production system. (We'll simulate this step)

      [root root]# svc -d /service/$OPENACS_SERVICE_NAME
      -[root root]# mv /var/lib/aolserver/$OPENACS_SERVICE_NAME/ /var/lib/aolserver/$OPENACS_SERVICE_NAME.lost
      -[root root]# rm /service/$OPENACS_SERVICE_NAME
      +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$
    4. Suffer a catastrophic failure on your production system. (We'll simulate this step)

      [root root]# svc -d /service/$OPENACS_SERVICE_NAME
      +[root root]# mv /var/lib/aolserver/$OPENACS_SERVICE_NAME/ /var/lib/aolserver/$OPENACS_SERVICE_NAME.lost
      +[root root]# rm /service/$OPENACS_SERVICE_NAME
       rm: remove symbolic link `/service/$OPENACS_SERVICE_NAME'? y
      -[root root]# ps -auxw | grep $OPENACS_SERVICE_NAME
      +[root root]# ps -auxw | grep $OPENACS_SERVICE_NAME
       root      1496  0.0  0.0  1312  252 ?        S    16:58   0:00 supervise $OPENACS_SERVICE_NAME
      -[root root]# kill 1496
      -[root root]# ps -auxw | grep $OPENACS_SERVICE_NAME
      -[root root]# su - postgres
      -[postgres pgsql]$ dropdb $OPENACS_SERVICE_NAME
      +[root root]# kill 1496
      +[root root]# ps -auxw | grep $OPENACS_SERVICE_NAME
      +[root root]# su - postgres
      +[postgres pgsql]$ dropdb $OPENACS_SERVICE_NAME
       DROP DATABASE
      -[postgres pgsql]$ dropuser $OPENACS_SERVICE_NAME
      +[postgres pgsql]$ dropuser $OPENACS_SERVICE_NAME
       DROP USER
      -[postgres pgsql]$ exit
      +[postgres pgsql]$ exit
       logout
      -[root root]#
    5. Recovery. 

      1. Restore the operating system and required software. +[root root]#

      2. Recovery. 

        1. Restore the operating system and required software. You can do this with standard backup processes or by keeping copies of the install material (OS CDs, OpenACS tarball and supporting software) and repeating the install - guide. Recreate the service user ($OPENACS_SERVICE_NAME).

        2. Restore the OpenACS files and database backup file.

          [root root]# su - $OPENACS_SERVICE_NAME
          -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver
          -[$OPENACS_SERVICE_NAME aolserver]$ tar xzf /var/tmp/$OPENACS_SERVICE_NAME-backup.tar.gz
          -[$OPENACS_SERVICE_NAME aolserver]$ chmod -R 775 $OPENACS_SERVICE_NAME
          -[$OPENACS_SERVICE_NAME aolserver]$ chown -R $OPENACS_SERVICE_NAME.web $OPENACS_SERVICE_NAME
        3. Restore the database

          • Oracle. 

            1. Set up a clean Oracle database user and - tablespace with the same names as the ones exported from (more information).

            2. Invoke the import command

              imp $OPENACS_SERVICE_NAME/$OPENACS_SERVICE_NAME FILE=/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/nighty_backup.dmp FULL=Y
          • Postgres. If the database user does not already exist, create it.

            [root root]# su - postgres
            -[postgres ~]$ createuser $OPENACS_SERVICE_NAME
            -Shall the new user be allowed to create databases? (y/n) y
            -Shall the new user be allowed to create more new users? (y/n) y
            +            guide.  Recreate the service user ($OPENACS_SERVICE_NAME).

          • Restore the OpenACS files and database backup file.

            [root root]# su - $OPENACS_SERVICE_NAME
            +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver
            +[$OPENACS_SERVICE_NAME aolserver]$ tar xzf /var/tmp/$OPENACS_SERVICE_NAME-backup.tar.gz
            +[$OPENACS_SERVICE_NAME aolserver]$ chmod -R 775 $OPENACS_SERVICE_NAME
            +[$OPENACS_SERVICE_NAME aolserver]$ chown -R $OPENACS_SERVICE_NAME.web $OPENACS_SERVICE_NAME
          • Restore the database

            • Oracle. 

              1. Set up a clean Oracle database user and + tablespace with the same names as the ones exported from (more information).

              2. Invoke the import command

                imp $OPENACS_SERVICE_NAME/$OPENACS_SERVICE_NAME FILE=/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/nighty_backup.dmp FULL=Y
            • Postgres. If the database user does not already exist, create it.

              [root root]# su - postgres
              +[postgres ~]$ createuser $OPENACS_SERVICE_NAME
              +Shall the new user be allowed to create databases? (y/n) y
              +Shall the new user be allowed to create more new users? (y/n) y
               CREATE USER
              -[postgres ~]$ exit
              -

              Because of a bug in Postgres backup-recovery, database objects are not guaranteed to be created in the right order. In practice, running the OpenACS initialization script is always sufficient to create any out-of-order database objects. Next, restore the database from the dump file. The restoration will show some error messages at the beginning for objects that were pre-created from the OpenACS initialization script, which can be ignored.

              [root root]# su - $OPENACS_SERVICE_NAME
              -[$OPENACS_SERVICE_NAME ~]$ createdb $OPENACS_SERVICE_NAME
              +[postgres ~]$ exit
              +

              Because of a bug in Postgres backup-recovery, database objects are not guaranteed to be created in the right order. In practice, running the OpenACS initialization script is always sufficient to create any out-of-order database objects. Next, restore the database from the dump file. The restoration will show some error messages at the beginning for objects that were pre-created from the OpenACS initialization script, which can be ignored.

              [root root]# su - $OPENACS_SERVICE_NAME
              +[$OPENACS_SERVICE_NAME ~]$ createdb $OPENACS_SERVICE_NAME
               CREATE DATABASE
              -[$OPENACS_SERVICE_NAME ~]$ psql -f /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-kernel/sql/postgresql/postgresql.sql $OPENACS_SERVICE_NAME
              +[$OPENACS_SERVICE_NAME ~]$ psql -f /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-kernel/sql/postgresql/postgresql.sql $OPENACS_SERVICE_NAME
               (many lines omitted)
              -[$OPENACS_SERVICE_NAME ~]$ psql $OPENACS_SERVICE_NAME < /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/database-backup.dmp
              +[$OPENACS_SERVICE_NAME ~]$ psql $OPENACS_SERVICE_NAME < /var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup/database-backup.dmp
               (many lines omitted)
              -[$OPENACS_SERVICE_NAME ~]$ exit
              -[postgres ~]$ exit
              -logout
          • Activate the service

            [root root]# ln -s /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/daemontools /service/$OPENACS_SERVICE_NAME
            -[root root]# sleep 10
            -[root root]# svgroup web /service/$OPENACS_SERVICE_NAME
    View comments on this page at openacs.org
    +[$OPENACS_SERVICE_NAME ~]$ exit +[postgres ~]$ exit +logout
  • Activate the service

    [root root]# ln -s /var/lib/aolserver/$OPENACS_SERVICE_NAME/etc/daemontools /service/$OPENACS_SERVICE_NAME
    +[root root]# sleep 10
    +[root root]# svgroup web /service/$OPENACS_SERVICE_NAME
  • View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/style-guide.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/style-guide.html,v diff -u -N -r1.24 -r1.24.2.1 --- openacs-4/packages/acs-core-docs/www/style-guide.html 13 Sep 2009 23:54:41 -0000 1.24 +++ openacs-4/packages/acs-core-docs/www/style-guide.html 18 Jun 2010 21:29:36 -0000 1.24.2.1 @@ -1,7 +1,5 @@ -OpenACS Style Guide

    OpenACS Style Guide

    +OpenACS Style Guide

    OpenACS Style Guide

    By Jeff Davis

    Motivation

    Why have coding standards for OpenACS? And if the code works why change it to @@ -90,6 +88,4 @@

  • Solicit code reviews.  Ask others to look over your code and provide feedback and do the same for others. -

  • Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation12/2003Jeff Davis
    ($Id$)
    View comments on this page at openacs.org
    +

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation12/2003Jeff Davis
    ($Id$)
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/subsites-design.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/subsites-design.html,v diff -u -N -r1.31 -r1.31.2.1 --- openacs-4/packages/acs-core-docs/www/subsites-design.html 13 Sep 2009 23:54:41 -0000 1.31 +++ openacs-4/packages/acs-core-docs/www/subsites-design.html 18 Jun 2010 21:29:36 -0000 1.31.2.1 @@ -1,10 +1,10 @@ -Subsites Design Document

    Subsites Design Document

    By Rafael H. Schloming

    +Subsites Design Document

    Subsites Design Document

    By Rafael H. Schloming

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    *Note* This document has not gone through the any of the required QA process yet. It is being tagged as stable due to high -demand.

    Essentials

    • ???

    Introduction

    An OpenACS 4 subsite is a managed suite of applications that work together for +demand.

    Introduction

    An OpenACS 4 subsite is a managed suite of applications that work together for a particular user community. This definition covers a very broad range of requirements: from a Geocities style homepage where a user can install whatever available application he wants (e.g. a single user could have their @@ -211,4 +211,4 @@ a particular configuration of site nodes/packages. As we build more fundamental applications that can be applied in more general areas, this feature will become more and more in demand since more problems will be -solvable by configuration instead of coding.

    View comments on this page at openacs.org
    +solvable by configuration instead of coding.

    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/subsites-requirements.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/subsites-requirements.html,v diff -u -N -r1.30 -r1.30.2.1 --- openacs-4/packages/acs-core-docs/www/subsites-requirements.html 12 Jul 2009 01:08:29 -0000 1.30 +++ openacs-4/packages/acs-core-docs/www/subsites-requirements.html 18 Jun 2010 21:29:36 -0000 1.30.2.1 @@ -1,31 +1,31 @@ - -Subsites Requirements

    Subsites Requirements

    By Rafael H. Schloming and Dennis Gregorovic

    + +Subsites Requirements

    Subsites Requirements

    By Rafael H. Schloming and Dennis Gregorovic

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Introduction

    The following is a requirements document for OpenACS 4 Subsites, part of the +

    Introduction

    The following is a requirements document for OpenACS 4 Subsites, part of the OpenACS 4 Kernel. The Subsites system allows one OpenACS server instance to serve multiple user communities, by enabling the suite of available OpenACS -applications to be customized for defined user communities.

    Vision Statement

    Many online communities are also collections of discrete subcommunities, +applications to be customized for defined user communities.

    Vision Statement

    Many online communities are also collections of discrete subcommunities, reflecting real-world relationships. For example, a corporate intranet/extranet website serves both units within the company (e.g., offices, departments, teams, projects) and external parties (e.g., customers, partners, vendors). Subsites enable a single OpenACS instance to provide each -subcommunity with its own "virtual website," by assembling OpenACS +subcommunity with its own "virtual website," by assembling OpenACS packages that together deliver a feature set tailored to the needs of the -subcommunity.

    System Overview

    The OpenACS subsite system allows a single OpenACS installation to serve multiple +subcommunity.

    System Overview

    The OpenACS subsite system allows a single OpenACS installation to serve multiple communities. At an implementation level this is primarily accomplished by -having an application "scope" its content to a particular package -instance. The request +having an application "scope" its content to a particular package +instance. The request processor then figures out which package_id a particular URL references -and then provides this information through the ad_conn api ([ad_conn -package_id], [ad_conn package_url]).

    The other piece of the subsite system is a subsite package that provides -subsite admins a "control panel" for administering their subsite. +and then provides this information through the ad_conn api ([ad_conn +package_id], [ad_conn package_url]).

    The other piece of the subsite system is a subsite package that provides +subsite admins a "control panel" for administering their subsite. This is the same package used to provide all the community core functionality -available at the "main" site which is in fact simply another -subsite.

    Use-cases and User-scenarios

    The Subsites functionality is intended for use by two different classes of -users:

    1. Package programmers (referred to as 'the programmer') must -develop subcommunity-aware applications.

    2. Site administrators (referred to as 'the administrator') use -subsites to provide tailored "virtual websites" to different +available at the "main" site which is in fact simply another +subsite.

    Use-cases and User-scenarios

    The Subsites functionality is intended for use by two different classes of +users:

    1. Package programmers (referred to as 'the programmer') must +develop subcommunity-aware applications.

    2. Site administrators (referred to as 'the administrator') use +subsites to provide tailored "virtual websites" to different subcommunities.

    Joe Programmer is working on the forum package and wants to make it subsite-aware. Using [ad_conn package_id], Joe adds code that only displays forum messages associated with the current package instance. Joe is happy to @@ -40,18 +40,18 @@ http://www.company.com/offices/boston/forum, and similarly for the Austin office. At this point, the Boston and Austin office admins can customize the configurations for each of their forums, or they can just use the -defaults.

    Related Links

    Requirements: Programmer's API

    A subsite API is required for programmers to ensure their packages are -subsite-aware. The following functions should be sufficient for this:

    10.10.0 Package creation

    The system must provide an API call to create a package, and it must be -possible for the context (to which the package belongs) to be specified.

    10.20.0 Package deletion

    The system must provide an API call to delete a package and all related -objects in the subsite's context.

    10.30.0 Object's package information

    Given an object ID, the system must provide an API call to determine the -package (ID) to which the object belongs.

    10.40.0 URL from package

    Given a package (ID), the system must provide an API call to return the -canonical URL for that package.

    10.50.0 Main subsite's package_id

    The system must provide an API call to return a package ID corresponding -to the main subsite's package ID (the degenerate subsite).

    Requirements: The User Interface

    The Programmer's User Interface

    There is no programmer's UI, other than the API described above.

    The Administrator's User Interface

    The UI for administrators is a set of HTML pages that are used to drive +defaults.

    Related Links

    Requirements: Programmer's API

    A subsite API is required for programmers to ensure their packages are +subsite-aware. The following functions should be sufficient for this:

    10.10.0 Package creation

    The system must provide an API call to create a package, and it must be +possible for the context (to which the package belongs) to be specified.

    10.20.0 Package deletion

    The system must provide an API call to delete a package and all related +objects in the subsite's context.

    10.30.0 Object's package information

    Given an object ID, the system must provide an API call to determine the +package (ID) to which the object belongs.

    10.40.0 URL from package

    Given a package (ID), the system must provide an API call to return the +canonical URL for that package.

    10.50.0 Main subsite's package_id

    The system must provide an API call to return a package ID corresponding +to the main subsite's package ID (the degenerate subsite).

    Requirements: The User Interface

    The Programmer's User Interface

    There is no programmer's UI, other than the API described above.

    The Administrator's User Interface

    The UI for administrators is a set of HTML pages that are used to drive the underlying API for package instance management (i.e. adding, removing, or altering packages). It is restricted to administrators of the current subsite such that administrators can only manage their own subsites. Of course, -Site-Wide Administrators can manage all subsites.

    • 20.10.0 Package creation

      20.10.1 The administrator should be able to create a -package and make it available at a URL underneath the subsite.

    • 20.20.0 Package deactivation

      20.20.1 The administrator should be able to deactivate -any package, causing it to be inaccessible to users.

      20.20.5 Deactivating a package makes the package no +Site-Wide Administrators can manage all subsites.

      • 20.10.0 Package creation

        20.10.1 The administrator should be able to create a +package and make it available at a URL underneath the subsite.

      • 20.20.0 Package deactivation

        20.20.1 The administrator should be able to deactivate +any package, causing it to be inaccessible to users.

        20.20.5 Deactivating a package makes the package no longer accessible, but it does not remove data created within the context of -that package.

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation08/18/2000Dennis Gregorovic
    0.2Edited, reviewed08/29/2000Kai Wu
    View comments on this page at openacs.org
    +that package.

    Revision History

    Document Revision #Action Taken, NotesWhen?By Whom?
    0.1Creation08/18/2000Dennis Gregorovic
    0.2Edited, reviewed08/29/2000Kai Wu
    View comments on this page at openacs.org
    Index: openacs-4/packages/acs-core-docs/www/subsites.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/subsites.html,v diff -u -N -r1.44 -r1.44.2.1 --- openacs-4/packages/acs-core-docs/www/subsites.html 12 Jul 2009 01:08:29 -0000 1.44 +++ openacs-4/packages/acs-core-docs/www/subsites.html 18 Jun 2010 21:29:36 -0000 1.44.2.1 @@ -1,8 +1,8 @@ - -Writing OpenACS Application Pages

    Writing OpenACS Application Pages

    By Rafael H. Schloming and Pete Su

    + +Writing OpenACS Application Pages

    Writing OpenACS Application Pages

    By Rafael H. Schloming and Pete Su

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

    Overview

    +

    Overview

    In this document, we'll examine the user interface pages of the Notes application in more detail, covering two separate aspects of page development in OpenACS. First, we'll talk about the code needed to make @@ -11,8 +11,8 @@ form-based user interfaces in OpenACS. While these seem like unrelated topics, they both come up in the example page that we are going to look at, so it makes sense to address them at the same time. -

    Application Instances and Subsites

    -As you will recall from the packages tutorial, the Request +

    Application Instances and Subsites

    +As you will recall from the packages tutorial, the Request Processor (RP) and Package Manager (APM) allow site administrators to define an arbitrary mapping from URLs in the site to objects representing content. These objects may represent single @@ -22,63 +22,63 @@ particular URL. The tutorial also showed how a given URL is translated into a physical file to serve using the site map. We'll repeat this description here, assuming that you have mounted an -instance of Notes at the URL /notes as we did in the packages-example: -

    • -AOLserver receives your request for the URL /notes/somepage. -

    • +instance of Notes at the URL /notes as we did in the packages-example: +

      • +AOLserver receives your request for the URL /notes/somepage. +

      • This URL is passed to the request processor. -

      • +

      • The RP looks up the URL in the site map, and sees that the object -mounted at that location is an instance of the notes +mounted at that location is an instance of the notes application. -

      • +

      • The RP asks the package manager where in the file system the Notes package lives. In the standard case, this would be -ROOT/packages/notes. -

      • +ROOT/packages/notes. +

      • The RP translates the URL to serve a page relative to the page root of the application, which is -ROOT/packages/notes/www/. Therefore, the page that is -finally served is ROOT/packages/notes/www/hello.html, +ROOT/packages/notes/www/. Therefore, the page that is +finally served is ROOT/packages/notes/www/hello.html, which is what we wanted.

      What is missing from this description is a critical fact for application developers: In addition to working out what file to serve, the RP also stores information about which package instance the file belongs to into the AOLserver connection environment. The following -ad_conn interfaces can be used to extract this +ad_conn interfaces can be used to extract this information: -

      [ad_conn package_url]

      +

      [ad_conn package_url]

      If the URL refers to a package instance, this is the URL to the root of the tree where the package is mounted. -

      [ad_conn package_id]

      +

      [ad_conn package_id]

      If the URL refers to a package instance, this is the ID of that package instance. -

      [ad_conn package_key] +

      [ad_conn package_key]

      If the URL refers to a package instance, this is the unique key name of the package. -

      [ad_conn extra_url] +

      [ad_conn extra_url]

      If we found the URL in the site map, this is the tail of the URL following the part that matched a site map entry.

      In the Notes example, we are particularly interested in the -package_id field. If you study the data model and code, -you'll see why. As we said before in the data modeling tutorial, the Notes application points the -context_id of each Note object that it creates to the -package instance that created it. That is, the context_id -corresponds exactly to the package_id that comes in from +package_id field. If you study the data model and code, +you'll see why. As we said before in the data modeling tutorial, the Notes application points the +context_id of each Note object that it creates to the +package instance that created it. That is, the context_id +corresponds exactly to the package_id that comes in from the RP. This is convenient because it allows the administrator and the owner of the package to easily define access control policies for all the notes in a particular instance just my setting permissions on the package instance itself.

      The code for adding and editing notes, in -notes/www/add-edit.tcl, shows how this works. At the top -of the page, we extract the package_id and use it to do +notes/www/add-edit.tcl, shows how this works. At the top +of the page, we extract the package_id and use it to do permission checks:

       
      @@ -87,11 +87,11 @@
       if {[info exists note_id]} {
             permission::require_permission -object_id $note_id -privilege write
       
      -      set context_bar [ad_context_bar "Edit Note"]
      +      set context_bar [ad_context_bar "Edit Note"]
       } else {
             permission::require_permission -object_id $note_id -privilege create
       
      -      set context_bar [ad_context_bar "New Note"]
      +      set context_bar [ad_context_bar "New Note"]
       }
       
       

      @@ -100,7 +100,7 @@ for each action.

      Later, when we actually create a note, the SQL that we run ensures -that the context_id is set the right way: +that the context_id is set the right way:

       
       db_dml new_note {
      @@ -124,25 +124,25 @@
       without generating a lot of duplicated HTML in your pages. It also
       encapsulates most of the common logic that we use in dealing with
       forms, which we'll discuss next.
      -

    Using Forms

    +

    Using Forms

    The forms API is pretty simple: You use calls in the -template::form namespace in your Tcl script to create +template::form namespace in your Tcl script to create form elements. The final template page then picks this stuff up and lays the form out for the user. The form is set up to route submit buttons and whatnot back to the same Tcl script that set up the form, so your Tcl script will also contain the logic needed to process these requests.

    So, given this outline, here is a breakdown of how the forms code -works in the add-edit.tcl page. First, we create a form object -called new_note: +works in the add-edit.tcl page. First, we create a form object +called new_note:

     
     template::form create new_note
     
     

    All the forms related code in this page will refer back to this -object. In addition, the adp part of this page does +object. In addition, the adp part of this page does nothing but display the form object:

     
    @@ -153,7 +153,7 @@
     <hr>
     
     <center>
    -<formtemplate id="new_note"></formtemplate>
    +<formtemplate id="new_note"></formtemplate>
     </center>
     
     

    @@ -176,31 +176,31 @@ }

    -The if_request call returns true if we are asking the +The if_request call returns true if we are asking the page to render the form for the first time. That is, we are rendering -the form to ask the user for input. The tcl part of a +the form to ask the user for input. The tcl part of a form page can be called in 3 different states: the initial request, the initial submission, and the validated submission. These states reflect the typical logic of a forms based page in OpenACS: -

    • +

      • First render the input form. -

      • +

      • Next, control passes to a validation page that checks and confirms the inputs. -

      • +

      • Finally, control passes to the page that performs the update in the database.

      -The rest of the if condition figures out if we are +The rest of the if condition figures out if we are creating a new note or editing an existing note. If -note_id is passed to us from the calling page, we assume +note_id is passed to us from the calling page, we assume that we are editing an existing note. In this case, we do a database query to grab the data for the note so we can populate the form with it.

      The next two calls create form elements where the user can insert or edit the title and body of the Note. The interface to -template::element is pretty straightforward. +template::element is pretty straightforward.

      Finally, the code at the bottom of the page performs the actual database updates when the form is submitted and validated: @@ -234,7 +234,7 @@ } } - ad_returnredirect "." + ad_returnredirect "." }

      @@ -243,7 +243,7 @@ the HTML rendering, input validation and database transaction logic on your behalf. This means that you can write pages without duplicating all of that code in every set of pages that uses forms. -

    How it All Fits

    +

    How it All Fits

    To watch all of this work, use the installer to update the Notes package with the new code that you grabbed out of CVS or the package repository, mount an instance of Notes somewhere in your server and @@ -254,15 +254,15 @@ visible to that user. The end result is a site where users can come and write notes to themselves.

    -This is a good example of the leverage available in the OpenACS 5.5.0 +This is a good example of the leverage available in the OpenACS 5.6.0 system. The code that we have written for Notes is not at all more complex than a similar application without access control or site map awareness. By adding a small amount of code, we have taken a small, simple, and special purpose application to something that has the potential to be a very useful, general-purpose tool, complete with multi-user features, access control, and centralized administration. -

    Summary

    -In OpenACS 5.5.0, application pages and scripts can be aware of the package +

    Summary

    +In OpenACS 5.6.0, application pages and scripts can be aware of the package instance, or subsite in which they are executing. This is a powerful general purpose mechanism that can be used to structure web services in very flexible ways. Index: openacs-4/packages/acs-core-docs/www/templates.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/templates.html,v diff -u -N -r1.45 -r1.45.2.1 --- openacs-4/packages/acs-core-docs/www/templates.html 13 Sep 2009 23:54:41 -0000 1.45 +++ openacs-4/packages/acs-core-docs/www/templates.html 18 Jun 2010 21:29:36 -0000 1.45.2.1 @@ -1,5 +1,5 @@ -Using Templates in OpenACS

    Using Templates in OpenACS

    By Pete Su

    +Using Templates in OpenACS

    Using Templates in OpenACS

    By Pete Su

    OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

    Overview

    @@ -79,7 +79,7 @@

    Some things to note about this code:

    • -The procedure ad_page_contract is +The procedure ad_page_contract is always the first thing a .tcl file calls, if it's under the www/ directory (i.e. not a Tcl library file). It does validation of input values from the HTTP request (i.e. form variables) and in Index: openacs-4/packages/acs-core-docs/www/tutorial-admin-pages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-admin-pages.html,v diff -u -N -r1.11 -r1.11.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-admin-pages.html 13 Sep 2009 23:54:41 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/tutorial-admin-pages.html 18 Jun 2010 21:29:36 -0000 1.11.2.1 @@ -1,5 +1,5 @@ -Admin Pages

      Admin Pages

      +Admin Pages

      Admin Pages

      There are at least two flavors of admin user interface:

      • Admins use same pages as all other users, except that they are offered admin links and buttons where appropriate. Index: openacs-4/packages/acs-core-docs/www/tutorial-advanced.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-advanced.html,v diff -u -N -r1.32 -r1.32.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-advanced.html 13 Sep 2009 23:54:41 -0000 1.32 +++ openacs-4/packages/acs-core-docs/www/tutorial-advanced.html 18 Jun 2010 21:29:36 -0000 1.32.2.1 @@ -1,5 +1,5 @@ -Chapter 9. Advanced Topics

        Chapter 9. Advanced Topics

        by Joel Aufrecht

        +Chapter 10. Advanced Topics

        Chapter 10. Advanced Topics

        by Joel Aufrecht

        OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

        This tutorial covers topics which are not essential to Index: openacs-4/packages/acs-core-docs/www/tutorial-caching.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-caching.html,v diff -u -N -r1.8 -r1.8.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-caching.html 13 Sep 2009 23:54:41 -0000 1.8 +++ openacs-4/packages/acs-core-docs/www/tutorial-caching.html 18 Jun 2010 21:29:36 -0000 1.8.2.1 @@ -1,5 +1,5 @@ -Basic Caching

        Basic Caching

        Based on a post by Dave Bauer.

        +Basic Caching

        Basic Caching

        Based on a post by Dave Bauer.

        OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

        Caching using the database API is described in the database API tutorial.

        Caching using util_memoize

        1. Implement your proc as my_proc_not_cached

        2. Create a version of your proc called my_proc which wraps the non-cached version in the caching mechanism. In this example, my_proc_not_cached takes one argument, -foo, so the wrapper passes that on. The wrapper also uses the list command, to ensure that the arguments get passed correctly and to prevent commands passed in as arguments from being executed.

          ad_proc my_proc {-foo} {
          Index: openacs-4/packages/acs-core-docs/www/tutorial-categories.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-categories.html,v
          diff -u -N -r1.11 -r1.11.2.1
          --- openacs-4/packages/acs-core-docs/www/tutorial-categories.html	13 Sep 2009 23:54:41 -0000	1.11
          +++ openacs-4/packages/acs-core-docs/www/tutorial-categories.html	18 Jun 2010 21:29:36 -0000	1.11.2.1
          @@ -1,5 +1,5 @@
           
          -Categories

          Categories

          extended by Nima Mazloumi

          +Categories

          Categories

          extended by Nima Mazloumi

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          You can associate any ACS Object with one or more categories. Index: openacs-4/packages/acs-core-docs/www/tutorial-comments.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-comments.html,v diff -u -N -r1.11 -r1.11.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-comments.html 13 Sep 2009 23:54:41 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/tutorial-comments.html 18 Jun 2010 21:29:36 -0000 1.11.2.1 @@ -1,5 +1,5 @@ -Adding Comments

          Adding Comments

          You can track comments for any ACS Object. Here we'll track +Adding Comments

          Adding Comments

          You can track comments for any ACS Object. Here we'll track comments for notes. On the note-edit.tcl/adp pair, which is used to display individual notes, we want to put a link to add comments at the bottom of the screen. If there are any comments, we want to Index: openacs-4/packages/acs-core-docs/www/tutorial-css-layout.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-css-layout.html,v diff -u -N -r1.9 -r1.9.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-css-layout.html 13 Sep 2009 23:54:41 -0000 1.9 +++ openacs-4/packages/acs-core-docs/www/tutorial-css-layout.html 18 Jun 2010 21:29:36 -0000 1.9.2.1 @@ -1,5 +1,5 @@ -Laying out a page with CSS instead of tables

          Laying out a page with CSS instead of tables

          .LRN home page with table-based layout

          A sample of the HTML code (full source)

          <table border="0" width="100%">
          +Laying out a page with CSS instead of tables

          Laying out a page with CSS instead of tables

          .LRN home page with table-based layout

          A sample of the HTML code (full source)

          <table border="0" width="100%">
             <tr>
               <td valign="top" width="50%">
                 <table class="element" border=0 cellpadding="0" cellspacing="0" width="100%">
          @@ -21,7 +21,7 @@
                             <table border="0" bgcolor="white" cellpadding="0" cellspacing="0" width="100%">
                               <tr>
                                 <td class=element-text>
          -                        MBA 101

          .LRN Home with CSS-based layout

          A sample of the HTML code (full source)

          <div class="left">
          +                        MBA 101

          .LRN Home with CSS-based layout

          A sample of the HTML code (full source)

          <div class="left">
             <div class="portlet-wrap-shadow">
               <div class="portlet-wrap-bl">
                 <div class="portlet-wrap-tr">
          Index: openacs-4/packages/acs-core-docs/www/tutorial-cvs.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-cvs.html,v
          diff -u -N -r1.23 -r1.23.2.1
          --- openacs-4/packages/acs-core-docs/www/tutorial-cvs.html	13 Sep 2009 23:54:41 -0000	1.23
          +++ openacs-4/packages/acs-core-docs/www/tutorial-cvs.html	18 Jun 2010 21:29:36 -0000	1.23.2.1
          @@ -1,5 +1,5 @@
           
          -Add the new package to CVS

          Add the new package to CVS

          Before you do any more work, make sure that your work is +Add the new package to CVS

          Add the new package to CVS

          Before you do any more work, make sure that your work is protected by putting it all into cvs. The cvs add command is not recursive, so you'll have to traverse the directory tree manually and add as you go. (More on @@ -59,4 +59,4 @@ initial revision: 1.1 done (many lines omitted) -[$OPENACS_SERVICE_NAME myfirstpackage]$

          Figure 9.1. Upgrading a local CVS repository

          Upgrading a local CVS repository
          View comments on this page at openacs.org
          +[$OPENACS_SERVICE_NAME myfirstpackage]$

          Figure 10.1. Upgrading a local CVS repository

          Upgrading a local CVS repository
          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-database.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-database.html,v diff -u -N -r1.40 -r1.40.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-database.html 13 Sep 2009 23:54:41 -0000 1.40 +++ openacs-4/packages/acs-core-docs/www/tutorial-database.html 18 Jun 2010 21:29:36 -0000 1.40.2.1 @@ -1,8 +1,8 @@ -Setting Up Database Objects

          Setting Up Database Objects

          by Joel Aufrecht

          +Setting Up Database Objects

          Setting Up Database Objects

          by Joel Aufrecht

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

          Code the data model

          We create all database objects with scripts in the +

          Code the data model

          We create all database objects with scripts in the myfirstpackage/sql/ directory. All database scripts are database-specific and are thus in either the myfirstpackage/sql/oracle or @@ -32,13 +32,13 @@ repository functions to simplify our database creation. (More information about ACS Objects. More information about the Content Repository.) -

          Figure 8.1. Tutorial Data Model

          Tutorial Data Model

          The top of each sql file has some +

          Figure 9.2. Tutorial Data Model

          Tutorial Data Model

          The top of each sql file has some standard comments, including doc tags such as @author which will be picked up by the API browser. The string $Id$ will automatically be expanded when the file is checked in to cvs.

          [$OPENACS_SERVICE_NAME ~]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/sql/postgresql
          -[$OPENACS_SERVICE_NAME postgresql]$ emacs myfirstpackage-create.sql

          Paste the text below into the file, save, and close.

          Figure 8.2. The Database Creation Script

          -- creation script
          +[$OPENACS_SERVICE_NAME postgresql]$ emacs myfirstpackage-create.sql

          Paste the text below into the file, save, and close.

          Figure 9.3. The Database Creation Script

          -- creation script
           --
           -- @author joel@aufrecht.org
           -- @cvs-id &Id:$
          @@ -62,7 +62,7 @@
               object.  Notice the use of "mfp."  This is derived from "My
               First Package" and ensures that our object is unlikely to conflict
               with objects from other packages.

          Create a database file to drop everything if the package is uninstalled.

          -[$OPENACS_SERVICE_NAME postgresql]$ emacs myfirstpackage-drop.sql

          Figure 8.3. Database Deletion Script

          -- drop script
          +[$OPENACS_SERVICE_NAME postgresql]$ emacs myfirstpackage-drop.sql

          Figure 9.4. Database Deletion Script

          -- drop script
           --
           -- @author joel@aufrecht.org
           -- @cvs-id &Id:$
          @@ -89,4 +89,4 @@
                                  0
           (1 row)
           
          -[$OPENACS_SERVICE_NAME postgresql]$

          Once both scripts are working without errors, run the create script one last time and proceed.

          [$OPENACS_SERVICE_NAME postgresql]$ psql service0 -f myfirstpackage-create.sql
          View comments on this page at openacs.org
          +[$OPENACS_SERVICE_NAME postgresql]$

          Once both scripts are working without errors, run the create script one last time and proceed.

          [$OPENACS_SERVICE_NAME postgresql]$ psql service0 -f myfirstpackage-create.sql
          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-debug.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-debug.html,v diff -u -N -r1.39 -r1.39.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-debug.html 13 Sep 2009 23:54:41 -0000 1.39 +++ openacs-4/packages/acs-core-docs/www/tutorial-debug.html 18 Jun 2010 21:29:36 -0000 1.39.2.1 @@ -1,8 +1,8 @@ -Debugging and Automated Testing

          Debugging and Automated Testing

          by Joel Aufrecht

          +Debugging and Automated Testing

          Debugging and Automated Testing

          by Joel Aufrecht

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

          Debugging

          Developer Support. The Developer Support package adds several goodies: debug +

          Debugging

          Developer Support. The Developer Support package adds several goodies: debug information for every page; the ability to log comments to the page instead of the error log, and fast user switching so that you can test pages as anonymous and as dummy users without logging @@ -23,16 +23,16 @@ ? searches backward 
          / searches forward. 
                    

          -

          Manual testing

          Make a list of basic tests to make sure it works

          Test NumActionExpected Result
          001Browse to the index page while not logged in and +

          Manual testing

          Make a list of basic tests to make sure it works

          Test NumActionExpected Result
          001Browse to the index page while not logged in and while one or more notes exist.No edit or delete or add links should appear.
          002Browse to the index page while logged in. An Edit link should appear. Click on it. Fill out the form and click Submit.The text added in the form should be visible on the index page.
          API-001Invoke mfp::note::create with a specific word as the title.Proc should return an object id.
          API-002Given an object id from API-001, invoke mfp::note::get.Proc should return the specific word in the title.
          API-003Given the object id from API-001, invoke mfp::note::delete.Proc should return 0 for success.

          Other things to test: try to delete someone else's note. Try to delete your own note. Edit your own note. - Search for a note.

          Write automated tests

          by Simon Carstensen and Joel Aufrecht

          + Search for a note.

          Write automated tests

          by Simon Carstensen and Joel Aufrecht

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

          +

          It seems to me that a lot of people have been asking for some guidelines on how to write automated tests. I've done several tests by now and have found the process to be extremely easy and useful. It's a joy to work with automated testing once you get the hang of it.

          Create the directory that will contain the test script and edit the script file. The directory location and file name are standards which are recognized by the automated testing package:

          [$OPENACS_SERVICE_NAME www]$ mkdir /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/tcl/test
           [$OPENACS_SERVICE_NAME www]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/tcl/test
          @@ -68,7 +68,7 @@
           goes inside -test_code {}.  We want to implement test case API-001, "Given an object id from API-001, invoke mfp::note::get.  Proc should return the specific word in the title."

                 set name [ad_generate_random_string]
                 set new_id [mfp::note::add -title $name]
          -      aa_true "Note add succeeded" [exists_and_not_null new_id]

          To test our simple case, we must load the test file into the system (just as with the /tcl file in the basic tutorial, since the file didn't exist when the system started, the system doesn't know about it.) To make this file take effect, go to the APM and choose "Reload changed" for "MyFirstPackage". Since we'll be changing it frequently, select "watch this file" on the next page. This will cause the system to check this file every time any page is requested, which is bad for production systems but convenient for developing. We can also add some aa_register_case flags to make it easier to run the test. The -procs flag, which indicates which procs are tested by this test case, makes it easier to find procs in your package that aren't tested at all. The -cats flag, setting categories, makes it easier to control which tests to run. The smoke test setting means that this is a basic test case that can and should be run any time you are doing any test. (a definition of "smoke test")

          Once the file is loaded, go to ACS Automated Testing and click on myfirstpackage. You should see your test case. Run it and examine the results.

          TCLWebtest tests

          API testing can only test part of our package - it doesn't test the code in our adp/tcl pairs. For this, we can use TCLwebtest. TCLwebtest must be installed for this test to work. This provides a library of functions that make it easy to call a page through HTTP, examine the results, and drive forms. TCLwebtest's functions overlap slightly with acs-automated-testing; see the example provided for one approach on integrating them.

          Example

          Now we can add the rest of the API tests, including a test with deliberately bad data. The complete test looks like:

          ad_library {
          +      aa_true "Note add succeeded" [exists_and_not_null new_id]

          To test our simple case, we must load the test file into the system (just as with the /tcl file in the basic tutorial, since the file didn't exist when the system started, the system doesn't know about it.) To make this file take effect, go to the APM and choose "Reload changed" for "MyFirstPackage". Since we'll be changing it frequently, select "watch this file" on the next page. This will cause the system to check this file every time any page is requested, which is bad for production systems but convenient for developing. We can also add some aa_register_case flags to make it easier to run the test. The -procs flag, which indicates which procs are tested by this test case, makes it easier to find procs in your package that aren't tested at all. The -cats flag, setting categories, makes it easier to control which tests to run. The smoke test setting means that this is a basic test case that can and should be run any time you are doing any test. (a definition of "smoke test")

          Once the file is loaded, go to ACS Automated Testing and click on myfirstpackage. You should see your test case. Run it and examine the results.

          TCLWebtest tests

          API testing can only test part of our package - it doesn't test the code in our adp/tcl pairs. For this, we can use TCLwebtest. TCLwebtest must be installed for this test to work. This provides a library of functions that make it easy to call a page through HTTP, examine the results, and drive forms. TCLwebtest's functions overlap slightly with acs-automated-testing; see the example provided for one approach on integrating them.

          Example

          Now we can add the rest of the API tests, including a test with deliberately bad data. The complete test looks like:

          ad_library {
               Test cases for my first package.
           }
           
          @@ -214,4 +214,4 @@
                   }
               }
           
          -

          See also Section , “Automated Testing”.

          View comments on this page at openacs.org
          +

          See also Section , “Automated Testing”.

          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-distribute.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-distribute.html,v diff -u -N -r1.23 -r1.23.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-distribute.html 13 Sep 2009 23:54:41 -0000 1.23 +++ openacs-4/packages/acs-core-docs/www/tutorial-distribute.html 18 Jun 2010 21:29:36 -0000 1.23.2.1 @@ -1,11 +1,11 @@ -Prepare the package for distribution.

          Prepare the package for distribution.

          Browse to the package manager. Click on +Prepare the package for distribution.

          Prepare the package for distribution.

          Browse to the package manager. Click on tutorialapp.

          Click on Generate a distribution file for this package from the filesystem.

          Click on the file size (37.1KB) after the label Distribution File: and save the file to - /var/tmp.

          + /var/tmp.

          Package development guidelines

          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-etp-templates.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-etp-templates.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-etp-templates.html 13 Sep 2009 23:54:41 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/tutorial-etp-templates.html 18 Jun 2010 21:29:36 -0000 1.6.2.1 @@ -1,5 +1,5 @@ -OpenACS Edit This Page Templates

          OpenACS Edit This Page Templates

          by Nick Carroll

          +OpenACS Edit This Page Templates

          OpenACS Edit This Page Templates

          by Nick Carroll

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          Goals

          • Learn about the OpenACS templating system.

          • Learn about subsites and site-map administration.

          Introduction

          @@ -13,5 +13,5 @@ cvs -d:pserver:anonymous@openacs.org:/cvsroot co edit-this-page

        3. Go to the package manager at http://yoursite/acs-admin/apm. And install the new package: edit-this-page.

        4. Or use the "Add Application" form available on the Main site.

        5. Change ETP Application

          • Work out how to change the ETP application.

          • Investigate each of the available ETP templates:

            • Default

            • News

            • FAQ

          Exercise 4: Create a New ETP Template

          • Browse the files for each of the above ETP templates at:

            cd ~/openacs/packages/edit-this-page/templates
          • Use the article template as the basis of our new col2 template.

            cp article-content.adp col2-content.adp
                         cp article-content.tcl col2-content.tcl
                         cp article-index.adp col2-index.adp
            -            cp article-index.tcl col2-index.tcl
          • The template should provide us with the following ETP layout:

            Table 9.1. table showing ETP layout

            Header
            SidebarMain Content Pane
          • The "Main Content" pane should contain the editable content that ETP provides.

          • The "Header" should display the title of the page that you set in ETP.

          • The "Sidebar" should display the extlinks that you add as a content item in ETP.

          Exercise 5: Register the col2 Template with ETP

          • Need to register your template with ETP so that it appears in the drop-down menu that you would have seen in Exercise 3.

            cd ~/openacs/packages/edit-this-page/tcl
            +            cp article-index.tcl col2-index.tcl
          • The template should provide us with the following ETP layout:

            Table 10.1. table showing ETP layout

            Header
            SidebarMain Content Pane
          • The "Main Content" pane should contain the editable content that ETP provides.

          • The "Header" should display the title of the page that you set in ETP.

          • The "Sidebar" should display the extlinks that you add as a content item in ETP.

          Exercise 5: Register the col2 Template with ETP

          • Need to register your template with ETP so that it appears in the drop-down menu that you would have seen in Exercise 3.

            cd ~/openacs/packages/edit-this-page/tcl
                         emacs etp-custom-init.tcl
          • Use the function etp::define_application to register your template with ETP

            • Uncomment the "asc" definition

            • Set allow_extlinks to true, the rest should be false.

          • Restart your server for the changes to take effect.

          Exercise 6: Configure ETP to use the col2 Template

          • Configure your ETP instance at /lab4/index to use the col2 template.

          • Create external links to link to other mounted ETP instances.

          • Check that your external links show up in the sidebar when you view your ETP application using the col2 template.

          Who Wrote This and When

          This problem set was originally written by Nick Carroll in August 2004 for the University of Sydney Course EBUS5002.

          This material is copyright 2004 by Nick Carroll. It may be copied, reused, and modified, provided credit is given to the original author.

          ($Id$)
          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-future-topics.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-future-topics.html,v diff -u -N -r1.14 -r1.14.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-future-topics.html 13 Sep 2009 23:54:41 -0000 1.14 +++ openacs-4/packages/acs-core-docs/www/tutorial-future-topics.html 18 Jun 2010 21:29:36 -0000 1.14.2.1 @@ -1,7 +1,7 @@ -Future Topics

          Future Topics

          • How to enforce security so that users can't +Future Topics

            Future Topics

            • How to enforce security so that users can't change other users records

            • How to use the content management tables so that ... what?

            • How to change the default stylesheets for Form Builder HTML forms.

            • How to make your package searchable with OpenFTS/Oracle

            • How to prepare pagelets for inclusion in other pages

            • How and when to put procedures in a tcl procedure library

            • More on ad_form - data validation, other stuff. (plan to draw from Jon Griffin's doc)

            • partialquery in xql

            • How to use the html/text entry widget to get the - "does this look right" confirm page

            • APM package dependencies

            See also the OpenACS Programming FAQ

            View comments on this page at openacs.org
            + "does this look right" confirm page

          • APM package dependencies

          See also the OpenACS Programming FAQ

          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-hierarchical.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-hierarchical.html,v diff -u -N -r1.8 -r1.8.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-hierarchical.html 13 Sep 2009 23:54:41 -0000 1.8 +++ openacs-4/packages/acs-core-docs/www/tutorial-hierarchical.html 18 Jun 2010 21:29:36 -0000 1.8.2.1 @@ -1,5 +1,5 @@ -Hierarchical data

          Hierarchical data

          by Jade Rubick +Hierarchical data

          Hierarchical data

          by Jade Rubick with help from many people in the OpenACS community

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. Index: openacs-4/packages/acs-core-docs/www/tutorial-html-email.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-html-email.html,v diff -u -N -r1.8 -r1.8.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-html-email.html 13 Sep 2009 23:54:41 -0000 1.8 +++ openacs-4/packages/acs-core-docs/www/tutorial-html-email.html 18 Jun 2010 21:29:36 -0000 1.8.2.1 @@ -1,5 +1,5 @@ -Sending HTML email from your application

          Sending HTML email from your application

          by Jade Rubick

          +Sending HTML email from your application

          Sending HTML email from your application

          by Jade Rubick

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          Sending email is fairly simple using the acs-mail-lite Index: openacs-4/packages/acs-core-docs/www/tutorial-newpackage.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-newpackage.html,v diff -u -N -r1.39 -r1.39.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-newpackage.html 12 Jul 2009 01:08:29 -0000 1.39 +++ openacs-4/packages/acs-core-docs/www/tutorial-newpackage.html 18 Jun 2010 21:29:36 -0000 1.39.2.1 @@ -1,12 +1,12 @@ - -Creating an Application Package

          Creating an Application Package

          by Joel Aufrecht

          + +Creating an Application Package

          Creating an Application Package

          by Joel Aufrecht

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

          The intended page map

          Overview

          To start developing new code in OpenACS, we build a new package. A package +

          The intended page map

          Overview

          To start developing new code in OpenACS, we build a new package. A package is a a discrete collection of web pages, tcl code, and database tables and procedures. - A package with user interface is called an application; + A package with user interface is called an application; a package which provides functions to other packages and has no direct interface, a - service. A package can be installed, upgraded, and + service. A package can be installed, upgraded, and removed. It communicates with other packages through an API. This chapter walks you through the minimum steps to create a useful package, including writing documentation, setting up database tables and procedures, writing web pages, debugging, and automatic regression testing. @@ -18,55 +18,55 @@ right now. Code that is temporary hackage is clearly marked.

          In this tutorial, we will make an application package for displaying a list of text notes. -

          Before you begin

          You will need:

          • A computer with a working installation of - OpenACS. If you don't have this, see Chapter 2, Installation Overview. -

          • Example files, which are included in the -standard OpenACS 5.5.0 distribution. -

          Figure 9.1. Assumptions in this section

          Fully qualified domain name of your serveryourserver.test
          URL of your serverhttp://yourserver.test:8000
          Name of development account$OPENACS_SERVICE_NAME
          New Package keymyfirstpackage

          Use the APM to initialize a new package

          We use the ACS Package Manager (APM) to add, remove, and +

          Before you begin

          You will need:

          • A computer with a working installation of + OpenACS. If you don't have this, see Chapter 2, Installation Overview. +

          • Example files, which are included in the +standard OpenACS 5.6.0 distribution. +

          Figure 9.1. Assumptions in this section

          Fully qualified domain name of your serveryourserver.test
          URL of your serverhttp://yourserver.test:8000
          Name of development account$OPENACS_SERVICE_NAME
          New Package keymyfirstpackage

          Use the APM to initialize a new package

          We use the ACS Package Manager (APM) to add, remove, and upgrade packages. It handles package meta-data, such as lists of files that belong in the package. Each package is uniquely identified by a package key. To start developing a new package, use the APM to create an empty package with our new package key, myfirstpackage. This will create the initial directories, meta-information files, and database - entries for a new package. (More info on APM) -

          1. Browse to - http://yourserver:8000/acs-admin/apm. -

          2. Click Create a New Package.

            Fill in the fields listed below. Ignore the rest (and leave the check boxes alone). + entries for a new package. (More info on APM) +

            1. Browse to + http://yourserver:8000/acs-admin/apm. +

            2. Click Create a New Package.

              Fill in the fields listed below. Ignore the rest (and leave the check boxes alone). (Some will change automatically. Don't mess with those.) -

              • - Package Key: - myfirstpackage

              • - Package Name: - My First Package -

              • - Package Plural: - My First Package

              • - Package Type: - Application -

              • - Initial Version: - 0.1d -

              • Summary: - This is my first package. +

                • + Package Key: + myfirstpackage

                • + Package Name: + My First Package +

                • + Package Plural: + My First Package

                • + Package Type: + Application +

                • + Initial Version: + 0.1d +

                • Summary: + This is my first package.

                At the bottom, click - Create Package. + Create Package.

            This creates a package rooted at - /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage. - This is the "home directory" of our new package, and all - files in the package will be within this directory. More on the structure of - packages).

          Add an Application Instance to the Server

          In order to see your work in progress, you must create a + /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage. + This is the "home directory" of our new package, and all + files in the package will be within this directory. More on the structure of + packages).

          Add an Application Instance to the Server

          In order to see your work in progress, you must create a map between the URL space of incoming requests and the package application instance. You do this by adding the application in the main site administration). This creates a link between the incoming URL requests and an - instance of the application. (More on applications and nodes)

          You can have instances of a package on one site, each with a + instance of the application. (More on applications and nodes)

          You can have instances of a package on one site, each with a different URL and different permissions, all sharing the same code and tables. This requires that a package be developed package-aware. You'll see how to do that - in this tutorial.

          1. Browse to -http://yourserver.test:8000/admin/applications/application-add/.

          2. Choose "My First Package" from the list and click OK (the other fields are optional).

          By mounting the package, we've caused all requests to - http://yourserver.test:8000/myfirstpackage - to be satisfied from the files at /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/www.

          Quick start

          The remainder of the tutorial walks you through each file one at a time as you create the package. You can skip all this, and get a working package, by doing the following:

          cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/files/tutorial
          +      in this tutorial.

          1. Browse to +http://yourserver.test:8000/admin/applications/application-add/.

          2. Choose "My First Package" from the list and click OK (the other fields are optional).

          By mounting the package, we've caused all requests to + http://yourserver.test:8000/myfirstpackage + to be satisfied from the files at /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/www.

          Quick start

          The remainder of the tutorial walks you through each file one at a time as you create the package. You can skip all this, and get a working package, by doing the following:

          cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/files/tutorial
           psql $OPENACS_SERVICE_NAME -f myfirstpackage-create.sql
           cp note-edit.* note-delete.tcl index.* ../../../../myfirstpackage/www/
           mkdir ../../../../myfirstpackage/lib
          Index: openacs-4/packages/acs-core-docs/www/tutorial-notifications.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-notifications.html,v
          diff -u -N -r1.13 -r1.13.2.1
          --- openacs-4/packages/acs-core-docs/www/tutorial-notifications.html	13 Sep 2009 23:54:41 -0000	1.13
          +++ openacs-4/packages/acs-core-docs/www/tutorial-notifications.html	18 Jun 2010 21:29:36 -0000	1.13.2.1
          @@ -1,5 +1,5 @@
           
          -Notifications

          Notifications

          by David Bell and Simon Carstensen

          +Notifications

          Notifications

          by David Bell and Simon Carstensen

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          The notifications package allows you to send notifications through any Index: openacs-4/packages/acs-core-docs/www/tutorial-pages.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-pages.html,v diff -u -N -r1.40 -r1.40.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-pages.html 13 Sep 2009 23:54:41 -0000 1.40 +++ openacs-4/packages/acs-core-docs/www/tutorial-pages.html 18 Jun 2010 21:29:36 -0000 1.40.2.1 @@ -1,9 +1,9 @@ -Creating Web Pages

          Creating Web Pages

          by Joel Aufrecht

          +Creating Web Pages

          Creating Web Pages

          by Joel Aufrecht

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff. -

          Install some API

          As a workaround for missing content-repository functionality, copy a provided file into the directory for tcl files:

          -    cp /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/files/tutorial/note-procs.tcl /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/tcl/

          To make this file take effect, go to the APM and choose "Reload changed" for "MyFirstPackage".

          Page Map

          Our package will have two visible pages. The first shows a list of all objects; the second shows a single object in view or edit mode, and can also be used to add an object. The index page will display the list, but since we might reuse the list later, we'll put it in a seperate file and include it on the index page.

          Figure 8.4. Page Map

          Page Map

          Build the "Index" page

          Each user-visible page in your package has, typically, +

          Install some API

          As a workaround for missing content-repository functionality, copy a provided file into the directory for tcl files:

          +    cp /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/acs-core-docs/www/files/tutorial/note-procs.tcl /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/tcl/

          To make this file take effect, go to the APM and choose "Reload changed" for "MyFirstPackage".

          Page Map

          Our package will have two visible pages. The first shows a list of all objects; the second shows a single object in view or edit mode, and can also be used to add an object. The index page will display the list, but since we might reuse the list later, we'll put it in a seperate file and include it on the index page.

          Figure 9.5. Page Map

          Page Map

          Build the "Index" page

          Each user-visible page in your package has, typically, three parts. The tcl file holds the procedural logic for the page, including TCL and database-independent SQL code, and does things like Index: openacs-4/packages/acs-core-docs/www/tutorial-parameters.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-parameters.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-parameters.html 13 Sep 2009 23:54:41 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/tutorial-parameters.html 18 Jun 2010 21:29:36 -0000 1.6.2.1 @@ -1,5 +1,5 @@ -Adding in parameters for your package

          Adding in parameters for your package

          Each instance of a package can have paramaters associated +Adding in parameters for your package

          Adding in parameters for your package

          Each instance of a package can have paramaters associated with it. These are like preferences, and they can be set by the administrator for each application to change the behavior of your application.

          To add parameters for your package, go to the Automatic Index: openacs-4/packages/acs-core-docs/www/tutorial-schedule-procs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-schedule-procs.html,v diff -u -N -r1.7 -r1.7.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-schedule-procs.html 13 Sep 2009 23:54:41 -0000 1.7 +++ openacs-4/packages/acs-core-docs/www/tutorial-schedule-procs.html 18 Jun 2010 21:29:36 -0000 1.7.2.1 @@ -1,5 +1,5 @@ -Scheduled Procedures

          Scheduled Procedures

          Put this proc in a file /packages/myfirstpackage/tcl/scheduled-init.tcl. Files in /tcl with the -init.tcl ending are sourced on server startup. This one executes my_proc every 60 seconds:

          ad_schedule_proc 60 myfirstpackage::my_proc
          +Scheduled Procedures

          Scheduled Procedures

          Put this proc in a file /packages/myfirstpackage/tcl/scheduled-init.tcl. Files in /tcl with the -init.tcl ending are sourced on server startup. This one executes my_proc every 60 seconds:

          ad_schedule_proc 60 myfirstpackage::my_proc
           

          This executes once a day, at midnight:

          ad_schedule_proc \
               -schedule_proc ns_schedule_daily \
               [list 0 0] \
          Index: openacs-4/packages/acs-core-docs/www/tutorial-second-database.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-second-database.html,v
          diff -u -N -r1.7 -r1.7.2.1
          --- openacs-4/packages/acs-core-docs/www/tutorial-second-database.html	13 Sep 2009 23:54:41 -0000	1.7
          +++ openacs-4/packages/acs-core-docs/www/tutorial-second-database.html	18 Jun 2010 21:29:36 -0000	1.7.2.1
          @@ -1,5 +1,5 @@
           
          -Connect to a second database

          Connect to a second database

          It is possible to use the OpenACS TCL database API with +Connect to a second database

          Connect to a second database

          It is possible to use the OpenACS TCL database API with other databases. In this example, the OpenACS site uses a PostGre database, and accesses another PostGre database called legacy.

          1. Modify config.tcl to accomodate the legacy database, and to Index: openacs-4/packages/acs-core-docs/www/tutorial-specs.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-specs.html,v diff -u -N -r1.11 -r1.11.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-specs.html 13 Sep 2009 23:54:41 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/tutorial-specs.html 18 Jun 2010 21:29:36 -0000 1.11.2.1 @@ -1,5 +1,5 @@ -Write the Requirements and Design Specs

            Write the Requirements and Design Specs

            Before you get started you should make yourself familiar with +Write the Requirements and Design Specs

            Write the Requirements and Design Specs

            Before you get started you should make yourself familiar with the tags that are used to write your documentation. For tips on editing SGML files in emacs, see Section , “OpenACS Documentation Guide”.

            It's time to document. For the tutorial we'll use pre-written documentation. When creating a package @@ -50,4 +50,4 @@ Writing bi01.html for bibliography Writing index.html for book [$OPENACS_SERVICE_NAME xml]$

          Verify that the documentation was generated and reflects - your changes by browsing to http://yoursite:8000/myfirstpackage/doc

          View comments on this page at openacs.org
          + your changes by browsing to http://yoursite:8000/myfirstpackage/doc

          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/tutorial-upgrade-scripts.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-upgrade-scripts.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-upgrade-scripts.html 13 Sep 2009 23:54:41 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/tutorial-upgrade-scripts.html 18 Jun 2010 21:29:36 -0000 1.6.2.1 @@ -1,5 +1,5 @@ -Writing upgrade scripts

          Writing upgrade scripts

          by Jade Rubick

          +Writing upgrade scripts

          Writing upgrade scripts

          by Jade Rubick

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          If your package changes its data model, you have to write an Index: openacs-4/packages/acs-core-docs/www/tutorial-upgrades.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-upgrades.html,v diff -u -N -r1.6 -r1.6.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-upgrades.html 13 Sep 2009 23:54:41 -0000 1.6 +++ openacs-4/packages/acs-core-docs/www/tutorial-upgrades.html 18 Jun 2010 21:29:36 -0000 1.6.2.1 @@ -1,5 +1,5 @@ -Distributing upgrades of your package

          Distributing upgrades of your package

          by Jade Rubick

          +Distributing upgrades of your package

          Distributing upgrades of your package

          by Jade Rubick

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          The OpenACS Package Repository builds a list of packages Index: openacs-4/packages/acs-core-docs/www/tutorial-vuh.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-vuh.html,v diff -u -N -r1.15 -r1.15.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial-vuh.html 13 Sep 2009 23:54:41 -0000 1.15 +++ openacs-4/packages/acs-core-docs/www/tutorial-vuh.html 18 Jun 2010 21:29:36 -0000 1.15.2.1 @@ -1,5 +1,5 @@ -Using .vuh files for pretty urls

          Using .vuh files for pretty urls

          .Vuh files are special cases of .tcl files, used for rewriting incoming urls. We can use a vuh file to prettify the uri for our notes. Instead of note-edit?item_id=495, we can use note/495. To do this, we will need a new .vuh file for redirection and we will need to change the referring links in note-list. First, add the vuh:

          [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/www
          +Using .vuh files for pretty urls

          Using .vuh files for pretty urls

          .Vuh files are special cases of .tcl files, used for rewriting incoming urls. We can use a vuh file to prettify the uri for our notes. Instead of note-edit?item_id=495, we can use note/495. To do this, we will need a new .vuh file for redirection and we will need to change the referring links in note-list. First, add the vuh:

          [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/packages/myfirstpackage/www
           [$OPENACS_SERVICE_NAME www]$ emacs note.vuh
           

          Paste this into the file:

          # Transform requests of type: a/b
           # into this internal request: A?c=b
          Index: openacs-4/packages/acs-core-docs/www/tutorial-wysiwyg-editor.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-wysiwyg-editor.html,v
          diff -u -N -r1.6 -r1.6.2.1
          --- openacs-4/packages/acs-core-docs/www/tutorial-wysiwyg-editor.html	13 Sep 2009 23:54:41 -0000	1.6
          +++ openacs-4/packages/acs-core-docs/www/tutorial-wysiwyg-editor.html	18 Jun 2010 21:29:36 -0000	1.6.2.1
          @@ -1,5 +1,5 @@
           
          -Enabling WYSIWYG

          Enabling WYSIWYG

          by Nima Mazloumi

          +Enabling WYSIWYG

          Enabling WYSIWYG

          by Nima Mazloumi

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          Most of the forms in OpenACS are created using the form builder, see Section , “Using Form Builder: building html forms dynamically”. For detailed information on the Index: openacs-4/packages/acs-core-docs/www/tutorial.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial.html,v diff -u -N -r1.21 -r1.21.2.1 --- openacs-4/packages/acs-core-docs/www/tutorial.html 13 Sep 2009 23:54:41 -0000 1.21 +++ openacs-4/packages/acs-core-docs/www/tutorial.html 18 Jun 2010 21:29:36 -0000 1.21.2.1 @@ -1,2 +1,2 @@ -Chapter 8. Development Tutorial

          Chapter 8. Development Tutorial

          Section missing
          View comments on this page at openacs.org
          +Chapter 9. Development Tutorial
          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/update-repository.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/update-repository.html,v diff -u -N -r1.14 -r1.14.2.1 --- openacs-4/packages/acs-core-docs/www/update-repository.html 13 Sep 2009 23:54:41 -0000 1.14 +++ openacs-4/packages/acs-core-docs/www/update-repository.html 18 Jun 2010 21:29:36 -0000 1.14.2.1 @@ -1,5 +1,5 @@ -How to Update the OpenACS.org repository

          How to Update the OpenACS.org repository

          1. +How to Update the OpenACS.org repository

            How to Update the OpenACS.org repository

            1. Setup a local OpenACS server running 5.0 or better.

            2. Edit packages/acs-admin/www/apm/build-repository.tcl and adjust the Configuration Settings.

            3. Index: openacs-4/packages/acs-core-docs/www/update-translations.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/update-translations.html,v diff -u -N -r1.13 -r1.13.2.1 --- openacs-4/packages/acs-core-docs/www/update-translations.html 13 Sep 2009 23:54:41 -0000 1.13 +++ openacs-4/packages/acs-core-docs/www/update-translations.html 18 Jun 2010 21:29:36 -0000 1.13.2.1 @@ -1,5 +1,5 @@ -How to Update the translations

              How to Update the translations

              1. Identify any new locales that have been created. +How to Update the translations

                How to Update the translations

                1. Identify any new locales that have been created. For each new locale, check the parameters, especially that the locale is in the format [two-letter code for language, lower-case]_[TWO-LETTER CODE FOR COUNTRY, Index: openacs-4/packages/acs-core-docs/www/upgrade-4.5-to-4.6.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/upgrade-4.5-to-4.6.html,v diff -u -N -r1.23 -r1.23.2.1 --- openacs-4/packages/acs-core-docs/www/upgrade-4.5-to-4.6.html 13 Sep 2009 23:54:41 -0000 1.23 +++ openacs-4/packages/acs-core-docs/www/upgrade-4.5-to-4.6.html 18 Jun 2010 21:29:36 -0000 1.23.2.1 @@ -1,6 +1,6 @@ -Upgrading 4.5 or higher to 4.6.3

                  Upgrading 4.5 or higher to 4.6.3

                  The required platform for OpenACS 4.6 is the same as - 4.5, with the exception of OpenFTS. OpenACS 4.6 and later require OpenFTS 0.3.2 for full text search on PostGreSQL. If you have OpenFTS 0.2, you'll need to upgrade.

                  If upgrading from 4.4, you need to manually run acs-kernel/sql/postgres/upgrade-4.4-4.5.sql. See Bug #632

                  1. Make a Backup. Back up the database and file system (see ???).

                  2. OPTIONAL: Upgrade OpenFTS. Section , “Upgrading OpenFTS from 0.2 to 0.3.2”

                  3. +Upgrading 4.5 or higher to 4.6.3

                    Upgrading 4.5 or higher to 4.6.3

                    The required platform for OpenACS 4.6 is the same as + 4.5, with the exception of OpenFTS. OpenACS 4.6 and later require OpenFTS 0.3.2 for full text search on PostGreSQL. If you have OpenFTS 0.2, you'll need to upgrade.

                    If upgrading from 4.4, you need to manually run acs-kernel/sql/postgres/upgrade-4.4-4.5.sql. See Bug #632

                    1. Make a Backup. Back up the database and file system (see Section , “Manual backup and recovery”).

                    2. OPTIONAL: Upgrade OpenFTS. Section , “Upgrading OpenFTS from 0.2 to 0.3.2”

                    3. Stop the server

                      [root root]# svc -d /service/$OPENACS_SERVICE_NAME
                    4. Upgrade the file system. Section , “Upgrading the OpenACS files”

                    5. Start the server @@ -9,4 +9,4 @@ upgrade, plus any new packages you want. It's safest to upgrade the kernel by itself, and then come back and upgrade the rest of the - desired packages in a second pass.

                    6. On the next screen, click Install Packages

                    7. When prompted, restart the server:

                      [root root]# restart-aolserver $OPENACS_SERVICE_NAME
                    8. Wait a minute, then browse to the package manager, http://yourserver/acs-admin/apm.

                    9. Check that the kernel upgrade worked by clicking All and making sure that acs-kernel version is 5.5.0.

                  4. Rollback. If anything goes wrong, roll back to the backup snapshot.

                  View comments on this page at openacs.org
                  + desired packages in a second pass.

                2. On the next screen, click Install Packages

                3. When prompted, restart the server:

                  [root root]# restart-aolserver $OPENACS_SERVICE_NAME
                4. Wait a minute, then browse to the package manager, http://yourserver/acs-admin/apm.

                5. Check that the kernel upgrade worked by clicking All and making sure that acs-kernel version is 5.6.0.

              2. Rollback. If anything goes wrong, roll back to the backup snapshot.

              View comments on this page at openacs.org
              Index: openacs-4/packages/acs-core-docs/www/upgrade-4.6.3-to-5.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/upgrade-4.6.3-to-5.html,v diff -u -N -r1.13 -r1.13.2.1 --- openacs-4/packages/acs-core-docs/www/upgrade-4.6.3-to-5.html 13 Sep 2009 23:54:41 -0000 1.13 +++ openacs-4/packages/acs-core-docs/www/upgrade-4.6.3-to-5.html 18 Jun 2010 21:29:36 -0000 1.13.2.1 @@ -4,7 +4,7 @@ how to upgrade an Oracle installation from OpenACS 4.6.3 to 5 .

            4. PostGreSQL. You must use PostGreSQL 7.3.x or newer to upgrade OpenACS beyond 4.6.3. See Upgrade PostGreSQL to 7.3; Table 2.2 -

              1. Back up the database and file system.

              2. Upgrade the file system for packages/acs-kernel. Section , “Upgrading the OpenACS files”

              3. Upgrade the kernel manually. (There is a script to do most of the rest: /contrib/misc/upgrade_4.6_to_5.0.sh on HEAD). You'll still have to do a lot of stuff manually, but automated trial and error is much more fun.)

                [root root]# su - $OPENACS_SERVICE_NAME
                +            

                1. Back up the database and file system.

                2. Upgrade the file system for packages/acs-kernel. Section , “Upgrading the OpenACS files”

                3. Upgrade the kernel manually. (There is a script to do most of the rest: /contrib/misc/upgrade_4.6_to_5.0.sh on HEAD). You'll still have to do a lot of stuff manually, but automated trial and error is much more fun.)

                  [root root]# su - $OPENACS_SERVICE_NAME
                   [$OPENACS_SERVICE_NAME aolserver]$ cd /var/lib/aolserver/ $OPENACS_SERVICE_NAME/packages/acs-kernel/sql/postgresql/upgrade

                  Manually execute each of the upgrade scripts in sequence, either from within psql or from the command line with commands such as psql -f upgrade-4.6.3-4.6.4.sql $OPENACS_SERVICE_NAME. Run the scripts in this order (order is tentative, not verified):

                  psql -f upgrade-4.6.3-4.6.4.sql $OPENACS_SERVICE_NAME
                  Index: openacs-4/packages/acs-core-docs/www/upgrade-openacs-files.html
                  ===================================================================
                  RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/upgrade-openacs-files.html,v
                  diff -u -N -r1.23 -r1.23.2.1
                  --- openacs-4/packages/acs-core-docs/www/upgrade-openacs-files.html	13 Sep 2009 23:54:41 -0000	1.23
                  +++ openacs-4/packages/acs-core-docs/www/upgrade-openacs-files.html	18 Jun 2010 21:29:36 -0000	1.23.2.1
                  @@ -1,5 +1,5 @@
                   
                  -Upgrading the OpenACS files

                  Upgrading the OpenACS files

                  Chosing a Method to Upgrade your Files

                  OpenACS is distributed in many different ways: +Upgrading the OpenACS files

                  Upgrading the OpenACS files

                  Chosing a Method to Upgrade your Files

                  OpenACS is distributed in many different ways:

                  • as a collection of files

                  • as one big tarball

                  • via CVS

                  • via automatic download from within the APM (package manager)

                  Upgrades work by first changing the file system (via any @@ -11,7 +11,7 @@ describes whether or not you need to be upgrading using this page or not: Section , “Upgrading an OpenACS 5.0.0 or greater installation” -

                  Methods of upgrading OpenACS files

                  • Upgrading files for a site which is not in a CVS repository. Unpack the tarball into a new directory and copy its +

                  Methods of upgrading OpenACS files

                  • Upgrading files for a site which is not in a CVS repository. Unpack the tarball into a new directory and copy its contents on top of your working directory. Or just 'install software', select remote repository, and upgrade your files from there.

                    [root root]# su - $OPENACS_SERVICE_NAME
                    @@ -32,7 +32,7 @@
                             with the latest OpenACS version, without overriding your own
                             local customizations. 

                    This diagram explains the basic idea. However, the labels are incorrect. Step 1(a) has been removed, and Step - 1(b) should be labelled Step 1.

                    Figure 5.2. Upgrading a local CVS repository

                    Upgrading a local CVS repository
                    • Step 0: Set up a working CVS checkout. To get your OpenACS code into your local CVS + 1(b) should be labelled Step 1.

                      Figure 5.2. Upgrading a local CVS repository

                      Upgrading a local CVS repository
                      • Step 0: Set up a working CVS checkout. To get your OpenACS code into your local CVS repository, you will set up a working CVS checkout of OpenACS. When you want to update your site, you'll update the working CVS checkout, import those changes @@ -97,7 +97,7 @@

                        1. [$OPENACS_SERVICE_NAME ~]$ cd /var/lib/aolserver/$OPENACS_SERVICE_NAME
                           [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$ cvs up -Pd
                           (CVS feedback)
                          -[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$

                      Upgrading a Production Site Safely

                      If you are upgrading a production OpenACS site which is on a private CVS tree, this process lets you do the upgrade without risking extended downtime or an unusable site:

                      1. Declare a freeze on new cvs updates - ie, you cannot run cvs update +[$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]$

              Upgrading a Production Site Safely

              If you are upgrading a production OpenACS site which is on a private CVS tree, this process lets you do the upgrade without risking extended downtime or an unusable site:

              1. Declare a freeze on new cvs updates - ie, you cannot run cvs update on the production site

              2. Make a manual backup of the production site in addition to the automated backups

              3. Import the new code (for example, OpenACS 5.0.4, openacs-5-0-compat versions of Index: openacs-4/packages/acs-core-docs/www/upgrade-overview.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/upgrade-overview.html,v diff -u -N -r1.23 -r1.23.2.1 --- openacs-4/packages/acs-core-docs/www/upgrade-overview.html 13 Sep 2009 23:54:41 -0000 1.23 +++ openacs-4/packages/acs-core-docs/www/upgrade-overview.html 18 Jun 2010 21:29:36 -0000 1.23.2.1 @@ -4,4 +4,4 @@ or better, you should always be able to upgrade all of your core packages automatically. If you haven't changed anything, no manual intervention should be required. If you are running - OpenACS prior to 4.5, upgrading will require manual effort.

                If all of these conditions are true:

                • Your OpenACS Core is 5.0.0 or later

                • You do not keep your OpenACS site in a local CVS repository

                • You do not have any custom code

                then you can upgrade automatically using the automated installer in the OpenACS Package Manager (APM), and you can probably skip the rest of this chapter. To upgrade directly from the OpenACS repository using the APM:

                1. Browse to the Installer.

                2. Click install or upgrade under "Install from OpenACS Repository" and select the packages to install or upgrade.

                3. The APM will download the requested packages from OpenACS.org, install the files on your hard drive, run any appropriate database upgrade scripts, and prompt you to restart the server. After restarting the server again, the upgrade is complete.

                Figure 5.1. Upgrading with the APM

                Upgrading with the APM

                It's always a good idea to precede an upgrade attempt with a snapshot backup.

                Table 5.1. Assumptions in this section

                name of OpenACS user$OPENACS_SERVICE_NAME
                OpenACS server name$OPENACS_SERVICE_NAME
                Root of OpenACS file tree/var/lib/aolserver/$OPENACS_SERVICE_NAME
                Database backup directory/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup
              View comments on this page at openacs.org
              + OpenACS prior to 4.5, upgrading will require manual effort.

              If all of these conditions are true:

              • Your OpenACS Core is 5.0.0 or later

              • You do not keep your OpenACS site in a local CVS repository

              • You do not have any custom code

              then you can upgrade automatically using the automated installer in the OpenACS Package Manager (APM), and you can probably skip the rest of this chapter. To upgrade directly from the OpenACS repository using the APM:

              1. Browse to the Installer.

              2. Click install or upgrade under "Install from OpenACS Repository" and select the packages to install or upgrade.

              3. The APM will download the requested packages from OpenACS.org, install the files on your hard drive, run any appropriate database upgrade scripts, and prompt you to restart the server. After restarting the server again, the upgrade is complete.

              Figure 5.1. Upgrading with the APM

              Upgrading with the APM

              It's always a good idea to precede an upgrade attempt with a snapshot backup.

              Table 5.1. Assumptions in this section

              name of OpenACS user$OPENACS_SERVICE_NAME
              OpenACS server name$OPENACS_SERVICE_NAME
              Root of OpenACS file tree/var/lib/aolserver/$OPENACS_SERVICE_NAME
              Database backup directory/var/lib/aolserver/$OPENACS_SERVICE_NAME/database-backup
              View comments on this page at openacs.org
              Index: openacs-4/packages/acs-core-docs/www/upgrade-supporting.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/upgrade-supporting.html,v diff -u -N -r1.16 -r1.16.2.1 --- openacs-4/packages/acs-core-docs/www/upgrade-supporting.html 13 Sep 2009 23:54:41 -0000 1.16 +++ openacs-4/packages/acs-core-docs/www/upgrade-supporting.html 18 Jun 2010 21:29:36 -0000 1.16.2.1 @@ -43,7 +43,7 @@ are not, and so they don't match. Also some functions use casting commands that no longer work in 7.3 and these functions must be recreated.

              - To upgrade an OpenACS site from PostGreSQL 7.2 to 7.3, first upgrade the kernel to 4.6.3. Then, dump the database, run the upgrade script /var/lib/aolserver/$OPENACS_SERVICE_NAME/bin/pg_7.2to7.3_upgrade_helper.pl on the dump file, and reply the dump. See Forum OpenACS Q&A: PG 7.2->7.3 upgrade gotcha?. Example:

              1. Back up the database as per ???.

              2. Run the upgrade script on the backup file.

                [root root]# su - $OPENACS_SERVICE_NAME
                +      To upgrade an OpenACS site from PostGreSQL 7.2 to 7.3, first upgrade the kernel to 4.6.3.  Then, dump the database, run the upgrade script /var/lib/aolserver/$OPENACS_SERVICE_NAME/bin/pg_7.2to7.3_upgrade_helper.pl on the dump file, and reply the dump.  See Forum OpenACS Q&A: PG 7.2->7.3 upgrade gotcha?.  Example:

                1. Back up the database as per PostgreSQL.

                2. Run the upgrade script on the backup file.

                  [root root]# su - $OPENACS_SERVICE_NAME
                             [$OPENACS_SERVICE_NAME $OPENACS_SERVICE_NAME]# cd /var/lib/aolserver/$OPENACS_SERVICE_NAME/bin
                             [$OPENACS_SERVICE_NAME bin]$ ./pg_7.2to7.3_upgrade_helper.pl \
                             ../database-backup/nightly.dmp \
                  @@ -76,4 +76,4 @@
                             postgres73 user's home directory.

                3. Change the path in $OPENACS_SERVICE_NAME's .bashrc or .bash_profile (or both) files to reflect the new postgres73 - user directory. Also add in the PGPORT.

                4. Restore the database from dump as per the recovery instructions.

            View comments on this page at openacs.org
            + user directory. Also add in the PGPORT.

          2. Restore the database from dump as per the recovery instructions.

          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/variables.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/variables.html,v diff -u -N -r1.26 -r1.26.2.1 --- openacs-4/packages/acs-core-docs/www/variables.html 13 Sep 2009 23:54:41 -0000 1.26 +++ openacs-4/packages/acs-core-docs/www/variables.html 18 Jun 2010 21:29:36 -0000 1.26.2.1 @@ -1,10 +1,10 @@ -Variables

          Variables

          Date and Time Variables

          ($Id$)

          By joel@aufrecht.org

          +Variables

          Variables

          Date and Time Variables

          ($Id$)

          By joel@aufrecht.org

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          Starting with OpenACS 5.0 and the introduction of acs-lang, we recommend retrieving date/time information from the database in - ANSI format and then using lc_time_fmt to format it for display.

          Example 11.1. Getting datetime from the database ANSI-style

          db_multirow -extend { mydate_pretty } {
          +    ANSI format and then using lc_time_fmt to format it for display.

          Example 12.1. Getting datetime from the database ANSI-style

          db_multirow -extend { mydate_pretty } {
               select to_char(mydate, 'YYYY-MM-DD HH24:MI:SS') as mydate_ansi,
                     ...
               ...
          Index: openacs-4/packages/acs-core-docs/www/win2k-installation.html
          ===================================================================
          RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/win2k-installation.html,v
          diff -u -N -r1.45 -r1.45.2.1
          --- openacs-4/packages/acs-core-docs/www/win2k-installation.html	13 Sep 2009 23:54:41 -0000	1.45
          +++ openacs-4/packages/acs-core-docs/www/win2k-installation.html	18 Jun 2010 21:29:36 -0000	1.45.2.1
          @@ -1,12 +1,12 @@
           
          -OpenACS Installation Guide for Windows2000

          OpenACS Installation Guide for Windows2000

          by Matthew Burke and Curtis Galloway

          +OpenACS Installation Guide for Windows2000

          OpenACS Installation Guide for Windows2000

          by Matthew Burke and Curtis Galloway

          OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

          NOTE: These instructions were valid for ACS v4, but have not been tested with OpenACS and the ArsDigita binary distributions are no longer available. Currently - (10/2003), the best option to get OpenACS 5.5.0 running on Windows + (10/2003), the best option to get OpenACS 5.6.0 running on Windows is to use VMware and John Sequeira's Oasis VM distribution @@ -250,4 +250,4 @@

          In the services control panel you should see two services: AOLserver-lintcollectors and AOLserver-iguanasdirect. -

          ($Id$)
          View comments on this page at openacs.org
          +

          ($Id$)
          View comments on this page at openacs.org
          Index: openacs-4/packages/acs-core-docs/www/xml/variables.ent =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/xml/variables.ent,v diff -u -N -r1.19 -r1.19.2.1 --- openacs-4/packages/acs-core-docs/www/xml/variables.ent 12 Jul 2009 01:08:30 -0000 1.19 +++ openacs-4/packages/acs-core-docs/www/xml/variables.ent 18 Jun 2010 21:29:36 -0000 1.19.2.1 @@ -1,7 +1,7 @@ - - - + + + - - + + Index: openacs-4/packages/acs-core-docs/www/xml/for-everyone/release-notes.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/xml/for-everyone/release-notes.xml,v diff -u -N -r1.27 -r1.27.2.1 --- openacs-4/packages/acs-core-docs/www/xml/for-everyone/release-notes.xml 12 Jul 2009 01:08:30 -0000 1.27 +++ openacs-4/packages/acs-core-docs/www/xml/for-everyone/release-notes.xml 18 Jun 2010 21:29:36 -0000 1.27.2.1 @@ -37,6 +37,52 @@ linkend="changelog-latest">) since the last release and in the entire &majorversion;.&minorversion; release sequence . + + Release 5.6.0 + + + + Added new package dependency type, "embeds". This is a variant of the + "extends" package dependency type added in OpenACS 5.5.0. It allows one + to write embeddable packages, with scripts made visible in client packages + using URLs which include the embedded package's package key. An example + embeddable package might be a rewritten "attachments" package. The current + implementation requires a global instance be mounted, and client packages + generate urls to that global instance. Among other things, this leads to + the user navigating to the top-level subsite, losing any subsite theming + that might be associated with a community. Using "embeds", a rewritten + package would run in the client package's context, maintaining theming and + automatically associating attachments with the client package. + + + Added global package parameters - parameters can now have scope "local" or "global", + with "local" being the default.. + + + Fixes for ns_proxy handling + + + Significant speedup for large sites + + + Optional support for selenium remote control (acs-automated-tests) + + + New administration UI to manage mime types and extension map + + + Added acs-mail-lite package params for rollout support + + + Support for 3-chars language codes in acs-lang + + + Added OOXML mime types in acs-content-repository + + + + + Release 5.5.0