CGI Services Architecture
Recent Pages

Environment Variables
Handling Concurrency
Template Processing
RDF Responses
RDF Messaging
URL Rewriting
File Uploads
Sample Authenticated Se ...
HTTP Cookies
Client Authentication

Links on Twitter
CSA Home
Table of Contents



User ID

Campaigns petition banner

AWK Functions

This is the list of the AWK functions that are currently provided by the relevant CSA libraries. As it was the case with Rc Functions, describing all of them in this document will be a major task. In the meantime please refer directly to the comments in the associated library files.


AWK function overrides

Similarly to what happens with Rc Functions, it is possible to provide local copies also of any AWK functions, as well as providing new application-level functions that are not present in the main library. This needs special provisions on the part of CSA, as AWK does not allow functions to be re-defined. Local copies of functions except _userproc() (see Input Hook and Output Hook) must be written to $CSA_ROOT/lib/include/. For instance, a local copy of $CSA_INSTALL/lib/include/_xmldecode.awk will have to be written to $CSA_ROOT/lib/include/_xmldecode.awk. Whenever the local repository is changed, either to add new function files or to change existing ones, the function cache must be re-built. The cache is located in $TMPDIR/fncache.awk, and it must be manually removed to force a re-build the next time a CSA program is run.

Whenever you upgrade to a new CSA version you must make sure that the $TMPDIR/fncache.awk file of every CSA application is re-built with the updated functions. This can be done by setting CSA_AWK_NEWCACHE=1 in the main CSA script (CGI front-end). Do not forget to unset it again (or set it to 0)after all caches have been re-built, or your CSA applications will execute slower.

Local function libraries, other than overrides, can also be provided by writingthem to $CSA_ROOT/lib/ and passing them as arguments to the csaAwk() rc function from within application-level programs.

CSA AWK global variables

This is the complete list of global CSA names that are defined in the relevant AWK library functions. Please refer to the associated files for more info on them.


Trackbacks (0) | New trackback | Print

This Web Site is Copyright © 2007,2008,2009,2010 Carlo Strozzi, Some Rights Reserved
site map | recent changes | disclaimer