Perl, IIS 6.0 Win2K3 and CGI


G

g3000

Hello,
I have a question about CGI with IIS 6.0. Correct me if Im wrong
the CGI spec specifys what happens when a web server communicates with
a program on a web server.

It does not say HOW that should be done.
Well again correct me if Im wrong CGI means when a request comes in,
that request is passed to that CGI program ( Perl, PHP, JSP, etc ) and
that CGI program returns a page.

Now, my question is with Perl every time somebody makes a request for a
page it has to invoke PERL.EXE to satisfy the request? True or False.

So if I get 1000 requests for a CGI program they are 1000 individual
invocations of PERL.EXE to satisfy the request?

Now a CGI program that is "IN PROCESS" with the web server means that
it is always running and no 'invocation' of the program needs to happen
to satisfy the request.
Usually the request is passed off to a "process space" to be satified.

Im asking these questions because I want to know what I should wisely
do in IIS 6.0 to scale my web apps WITH using PERL. Should I use
another scripting language?

I DO NOT have the option to use Apache. But I will listen to posts as
to why that is smarter.
I have seen posts of FASTCGI but dont know what that is supposed to
have improved on versus regular CGI.

Thank you in advance for your time.
 
Ad

Advertisements

S

Sherm Pendley

g3000 said:
Well again correct me if Im wrong CGI means when a request comes in,
that request is passed to that CGI program ( Perl, PHP, JSP, etc ) and
that CGI program returns a page.

Not all of those are necessarily CGI programs. Perl and PHP can be either
CGI or in-process modules. I don't know about JSP.
Now, my question is with Perl every time somebody makes a request for a
page it has to invoke PERL.EXE to satisfy the request? True or False.

If it's a Perl CGI, yes.
So if I get 1000 requests for a CGI program they are 1000 individual
invocations of PERL.EXE to satisfy the request?

Assuming that the CGI in question is written in Perl, then yes.
Now a CGI program that is "IN PROCESS" with the web server

.... is not a CGI. The CGI spec defines the communication that takes place
between the web server and a child process. If there's no child process,
it's not CGI.

Keep in mind that using CGI.pm in a Perl script doesn't always mean it's
running as a CGI. CGI.pm can be used from a command line with no server
at all, for debugging, and it can also be used in in-process scripts under
mod_perl.
Im asking these questions because I want to know what I should wisely
do in IIS 6.0 to scale my web apps WITH using PERL.

Should I use another scripting language?

That's impossible to say without knowing exactly what it is you need to do.

In general terms, you should learn as many languages as you can; that will
leave you better equipped to choose which language is best suited for any
given task.
I DO NOT have the option to use Apache. But I will listen to posts as
to why that is smarter.

IIS' many problems are well known and widely discussed. Do we *really*
need to re-hash all that?
I have seen posts of FASTCGI but dont know what that is supposed to
have improved on versus regular CGI.

It's sort of a hybrid approach. Like CGI, it's an external process. But
unlike CGI, the external process is long-lived. That is, it doesn't need
to be started from scratch for each request.

sherm--
 
G

g3000

Thanks Tim for your answers. I REALLY would like to use apache instead.
But its not my call.

The college kids that ive been tasked to baby sit ( which is the reason
im asking these questions ) said before I came on board they wanted to
use Apache and they were told no.

So maybe I might pursue that again. I think it was the client request
though.

I will definitely go to ActiveState. Ive used it before scripting doing
database stuff ( Im a Oracle DBA ). Guess I should learn more. DBAs are
being asked to administer web servers more now days.

I also thought about ASP. But Im always iffy on the Microsoft only
stuff. But I guess since the majority of our work will be on Msft
servers , might as well. I was also thinking about ASP.net and C#.
 
G

g3000

Thanks Sherm,
I appreciate the reply and the knowledge.

I dont want to get into an IIS vs Apache battle. Those discussions are
so imature. Although I will admint **SOMETIMES** there are myths that
are elimanated in those discussions.

As I stated in my other reply I would rather use Apache and mod_perl. I
like Perl. Just wanted to know that the college kids im baby sitting
are using the language wisely.

I was even thinking there maybe a web framework for Perl. But have not
found one yet. Im thinking management, perfomance, scalability, and the
ease of adding more functionality.
They are thinking " this will be really cool to do this". They have not
gotten the reality that this is not high school and we have REAL
clients to satisfy.

Hopefully I can get back to doing Oracle and somebody else can babysit
them. I just hate for them to fast talk when I ask questions and I know
they are given me "programmer lies".

Thanks again Sherm. Im gonna make sure they get the ActiveState ISAPI
extension.
 
S

Sherm Pendley

g3000 said:
I was even thinking there maybe a web framework for Perl. But have not
found one yet.

Ummm... How hard have you looked? When I google for "web framework perl",
the first hit is to Catalyst, a framework I've not used but about which
I've heard a lot of positive comments.

sherm--
 
Ad

Advertisements

G

g3000

thanks Tim for your reply,

My statement was a poor choice of words.
What I should have said was that my conclusion was if ActiveState says
that PerlEx is faster then PerlIS and PerlEx is discontinued what does
that mean for PerlIS?
Is PerlIS is something I would want to use?

Seems you are saying yes, it is something I want to use, in reference
to my original question and statements.
My thinking was that PerlIS was either not going to be supported or is
not a "capable" solution.
From what Ive researched so far with IIS I either use what you use (
PerlScript/ASP ) or I use PerlIS.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top