Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 167751
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T12:19:51+00:00 2026-05-11T12:19:51+00:00

We have an existing Perl application that supports mod_perl . However, our new host

  • 0

We have an existing Perl application that supports mod_perl. However, our new host (Dreamhost) does not suppport mod_perl, only FastCGI; thus necessitating the port.

The existing code does not use any Apache specific stuff and is just normal Perl code written in way that’s acceptable to mod_perl.

Reading the documentation and online tutorials, it appears that adding FastCGI support involves wrapping existing code inside a specific kind of loop. Below are the most commonly given skeleton code:

A. Using FCGI

use FCGI; while (FCGI::accept >= 0) {     #Run existing code. } 

B. Using CGI::Fast

use CGI::Fast while (my $cgi = CGI::Fast->new())  {      #Run existing code. } 

Sub-Questions:

  1. Are methods A and B equivalent ways to add FastCGI support?
  2. If A and B are different, what then are the pros and cons of using one over the other?
  3. Are there any best practices or gotchas one should know about when porting from mod_perl to FastCGI?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T12:19:52+00:00Added an answer on May 11, 2026 at 12:19 pm

    Generically speaking, a FastCGI application is very similar to CGI. The major difference is that you can take advantage of the fact that your process is able to be persistent. You can leverage that to gain speed advantages in your application—for example, you can cache database data in your running process. Essentially, you’re changing your application into its own application server, running behind a FastCGI gateway provided by the Web server.

    The idea is to figure out how to make your application’s means of processing applicable to a FastCGI gateway. Do you use any mod-perl specific functionality? If so, move away from that. If not, then just start working on talking via FastCGI. You’ve an advantage in that there are FastCGI interfaces available for Perl. I assume that you’re using some sort of a version control system, so just make a branch that is for porting to FastCGI. Then, just start thinking about POST and PUT as reading from standard input and your application’s responses as writing to standard output.

    You may want to also just read through a library that implements a FastCGI interface for an application. You can find some of those at fastcgi.com. That might help for you to understand what your application is going to be doing differently in relation to what it is doing currently.

    Good luck!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 274k
  • Answers 274k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Several ways: Use window.location to fire a GET request. Caveat… May 13, 2026 at 2:25 pm
  • Editorial Team
    Editorial Team added an answer It depends on what version of dev studio. In VS6… May 13, 2026 at 2:25 pm
  • Editorial Team
    Editorial Team added an answer You can download a zip file like any files with… May 13, 2026 at 2:25 pm

Related Questions

When I speak of scripting languages I am speaking of languages like Python, Perl,
I've been benchmarking the performance of a framework I'm writing in Perl and I'm
We need to read and count different types of messages/run some statistics on a
I'm looking for suggestions on new development system from some programmers that have more

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.