Home
News Forums Community Wiki Bugtracker Documentation Download
The Toolkit for Online Communities
12603 Community Members, 1 member online
Log In Register

Boost your application performance to serve large files!

OpenACS Home : xowiki : Boost your application performance to serve large files!
Previous Month May 2008 Next Month
Sun Mon Tue Wed Thu Fri Sat
27 28 29 30 1 2 3
4 5 6 (1) 7 (1) 8 9 (2) 10
(3) 11 (1) 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Popular tags

ad_form , ADP , ajax , aolserver , asynchronous , bgdelivery , bugtracker , COMET , cvs , debian, , emacs , FreeBSD , includelets , install, , installation , installers , javascript , linux , linux, , monitoring , nginx , osx , patches , performance , pg82 , pound , redhat, , selenium , ssl , stuff

No registered users in community xowiki
in last 30 minutes


Contributors

OpenACS.org

Gustaf: For handling the file-deliveries, i would recommend the background file delivery based on libthread, which does not block connection threads.

We use this in production since more than one year. For example today (no semester yet) we had so far 150.000 file deliveries.

The asynchrounous background delivery requires a small patch (2 changes, one is a backport from naviserver) and the tcl thread library (by zoran). The application code is in XOTcl is only a few lines of code and is included in xotcl-core (bgdelivery-procs.tcl).

One needs the following patch to


with this patch and xotcl-core, you can replace

ns_returnfile 200 $mime_type $filename
by
ad_returnfile_background 200 $mime_type $filename
e.g. in cr_write_content in acs-content-repository/tcl/revision-procs.tcl to activate it and to deliver files from the content-repository (file-store) in the background.

The connection thread is only used for permission management, localization of the file and writing the the reply header, the actual delivery of the file is performed via asychronous io without using up many resources. This can handle probably a couple of thousand concurrent file deliveries without running out of resources.

Check the files that has been served since the last reboot of your aolserver using this method from the developer support shell:

bgdelivery do set delivery_count


Original thread:
http://openacs.org/forums/message-view?message_id=482221



Categories: Subsystems Documentation (OpenACS.org)

Comments

    Add a comment