fastcgi perl (reload)

Discussion in 'Install/Configuration' started by henpa, Nov 9, 2006.

  1. henpa

    henpa New Member

    Hi,

    I have lsws set for running my fastcgi perl script. But I am developing the script and testing at the web at the same time. But the changes I make at the script does not appear on the web page, since lsws/fastcgi does not have a new copy of the updated script.

    When I used to develop using modperl, it had some kind of verification to check if the script changed, and if it did, it would reload automatically in memory.

    Can this be done using lsws and fcgi?

    Thanks!
  2. mistwang

    mistwang LiteSpeed Staff

    Running perl CGI inside mod_perl is completely different to running perl FCGI. What you want is possible, but as I know, no other web server can do that right now, including Apache, if you use FCGI.

    We have a perl runner FCGI script, lsws/fcgi-bin/lsperld.fpl, which is similar to Apache's mod_perl, and it does the reload automatically. I personally prefer perl FCGI over the perl runner or mod_perl running plain CGI script for the sake of better performance though.
  3. henpa

    henpa New Member

    By the way, will there ever be a LSAPI designed for Perl? And would it perform any better then the default FastCGI one?

    Thanks!
  4. mistwang

    mistwang LiteSpeed Staff

    There might be. We are busy with other work, have no time for this yet. :)

    It should be faster than the FastCGI one, I believe. If you are good at C coding, you can even make one yourself, should be pretty easy as LSAPI is similar to FCGI's interface. Just use the FCGI.pm as prototype.
  5. henpa

    henpa New Member

    Thanks for the (very) fast reply!

    As for the script reload, I created a new "CGI" context pointing to the same script. It will load each time, but for this very early development period, this will do.

    Thanks once again.
  6. mistwang

    mistwang LiteSpeed Staff

    Yeah, that's a smart solution. :)

Share This Page