1. Euphoria for cgi -- issues
- Posted by Andy Serpa <renegade at earthling.net> Sep 17, 2002
- 415 views
Figured out how to get do cgi scripts with Euphoria on my web server (shared host). It occured to me, however, that unlike PHP and other cgi languages, there are no configuration variables to set that protect me from doing something stupid. Although Rob has pointed out that you don't necessarily need permission to run Euphoria on a web server (to get it technically working I mean), I believe with most (shared) hosts it is not actually officially "allowed" even if it does happen to work. (Most hosts specify PHP & Perl only or something -- no C programs, etc.) Therefore, I have no desire to bring it up to my host if I decide to run a Euphoria script. Anyway, without shell access to my host, is there a way to kill a Euphoria process if it were to get stuck in a loop or something like that? (With PHP there is usually a max execution time of 30 seconds for any script, and then it is killed automatically.) Or must I just make sure I do all my debugging on my home machine (difficult of because of different OS, scripts grabbing web pages, etc.) to avoid potential trouble? Also, does anyone have any idea how the overhead of Euphoria compares to PHP or Perl running on Linux? (PHP is known as very resource-friendly, while Perl is known to hog them a bit -- where does Euphoria fall in? I assume on the hog side because PHP gets its advantage from being a built-in Apache module, whereas Perl has to create extra processes. I think.)
2. Re: Euphoria for cgi -- issues
- Posted by Robert Craig <rds at RapidEuphoria.com> Sep 17, 2002
- 396 views
Andy Serpa writes: > Anyway, without shell access to my host, is there a way to kill a > Euphoria process if it were to get stuck in a loop or something like > that? (With PHP there is usually a max execution time of 30 seconds for > any script, and then it is killed automatically.) My host has resource limits on the amount of memory, and the amount of CPU time that a process is allowed. A run-away process will be killed pretty quickly, regardless of what language it is written in. > Also, does anyone have any idea how the overhead of > Euphoria compares to PHP or Perl running on Linux? I'm not sure, but I think Euphoria starts up quite quickly, and the interpreter is much smaller than the others. Euphoria is also 30x faster than Perl on many tasks. Another issue is database access. Opening/closing a Euphoria EDS database just involves opening/closing one file. I imagine a fancy commercial database would have a lot more overhead than that. > Most hosts specify PHP & Perl only or something -- > no C programs, etc. That's not what I found when I shopped around for ListFilter.com. Most places, even very cheap ($5/month) places allow C. Sometimes they only list Perl, etc. as options, because they know most people are looking for that. C is not a good idea for most CGI scripts, because speed is usually not a big issue. Regards, Rob Craig Rapid Deployment Software http://www.RapidEuphoria.com