- Publicity: Public Only All
acs-content-repository-procs.tcl
tcl/acs-content-repository-procs.tcl patch a patch to the cr for handling the deleting revision's files when the revision has been deleted from the database Walter McGinnis (wtem@olywa.net), 2001-09-23 based on original photo-album package code by Tom Baginski JCD 2002-12-96 This should be fixed since on oracle anyway, being in a transaction does not mean that you get read level consistency across queries. End result is that someone can do an insert into the delete list and the delete_files query will whack it and the file will then never be deleted. Oops.
- Location:
- packages/acs-content-repository/tcl/acs-content-repository-procs.tcl
Procedures in this file
- acs_cr_scheduled_release_exec (private)
- cr_check_orphaned_files (private, deprecated)
- cr_cleanup_orphaned_files (private)
- cr_delete_scheduled_files (private)
- cr_scan_mime_types (private)
Detailed information
acs_cr_scheduled_release_exec (private)
acs_cr_scheduled_release_exec
This was handled by oracle, but since other dbs, such as PostgreSQL don't support job submission, the job scheduling has been moved to aolserver. (OpenACS - DanW)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
cr_check_orphaned_files (private, deprecated)
cr_check_orphaned_files [ -delete ] [ -mtime mtime ]
Deprecated. Invoking this procedure generates a warning.
Check for orphaned files in the content repository directory, and delete such files if required. Orphaned files might be created, when files are added to the content repository, but the transaction is being aborted. This function is intended to be used for one-time maintenance operations. Starting with 5.8.1, OpenACS contains support for handling orphaned files much more efficiently via a transaction log that is checked via cr_cleanup_orphaned_files in cr_delete_scheduled_files.
- Switches:
- -delete (optional, boolean)
- delete the orphaned files
- -mtime (optional)
- same semantics as mtime in the file command
- Author:
- gustaf.neumann@wu-wien.ac.at
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
cr_cleanup_orphaned_files (private)
cr_cleanup_orphaned_files
Helper proc to cleanup orphaned files in the content repository. Orphaned files can be created during aborted transactions involving the files being added to the content repository.
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
cr_delete_scheduled_files (private)
cr_delete_scheduled_files
Tries to delete all the files in cr_files_to_delete. Makes sure file isn't being used by another revision prior to deleting it. Should be scheduled daily. This proc is extremely simple, and does not have any concurrency checks to make sure another version of the proc is running/deleting a file. Will add some concurrency checks to a future revision. Right now go with short and sweet, count on scheduling to prevent conflicts
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
cr_scan_mime_types (private)
cr_scan_mime_types
Scan AOLserver mime types and insert them into cr_mime_types
- Author:
- ben@openforce
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.