Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
Here's the deal: JSP pages get compiled into servlets, and have performance equivalent to servlets. They are faster than CGI, but so is molasses. They are NOT faster than mod_perl, and similar options like FastCGI. (Don't believe what the Resin guys say: their benchmark used slow perl code because they didn't know much about performance under mod_perl.) If you're using a database, the quality of the database drivers will have a large effect on the speed of your application. Last time I benchmarked it, DBD::Oracle seemed to be a little faster than Oracle's JDBC stuff, but not much and they may have improved it since then.

With the speed issue gone, you have two things to consider. The first is what it's like to use JSP. In my opinion, it's not so good. JSP uses embedded Java code, which is actually much worse than embedded Perl code because of all the casting and the difficulty of treating Java types generically. I think you'd be much better off with a good templating tool for Java, like FreeMarker, WebMacro, or Velocity. You can read more about why this might be a better choice in "The Problems with JSP". If you want to use a Perl tool that is similar to JSP in terms of embedding code in pages, you can read about the best perl options here.

The other thing you should consider is the experience that your team has. If you are mostly more experienced at Perl than Java, you will definitely write a better site quicker by using Perl. I personally find Perl to be more productive, but someone who had written as much Java as I've written Perl might disagree.

If you do decide to use JSP, do yourself a favor and at least get a decent tag library like the one that the Struts project provides. It basically turns JSP into a templating tool, which is a bit silly since the other templating tools are probably simpler and faster, but it does let you use something decent and put "JSP" on your resume.

In reply to Re: CGI (Perl) vs JSP by perrin
in thread CGI (Perl) vs JSP by Nomis52

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?

What's my password?
Create A New User
Domain Nodelet?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (2)
As of 2023-06-06 05:44 GMT
Find Nodes?
    Voting Booth?
    How often do you go to conferences?

    Results (26 votes). Check out past polls.