Slashdot Mirror


mod_perl 2.0.0 Released

JamesD_UK writes "mod_perl 2.0.0 has been officially released into CPAN. Enhancements over mod_perl 1 include threads support and a perl interface to the Apache Portable Runtime. More details on the release can be found on CPAN."

31 of 165 comments (clear)

  1. Re:Slashdot Offshoring Myths by bigman2003 · · Score: 2, Insightful

    Overall a post with so much truth that it hurts. But, I disagree on one statement you made:

    if someone with no education can do your job cheaper, you don't deserve your job

    Not every job needs to be one that requires education. Many people do great work, without education- they jut have the skill and drive to do a better job than others.

    I recently went from being a non-degreed schmuck, to one with a degree. This didn't make my work any better.

    --
    No reason to lie.
  2. dumb arse by alfiejohn · · Score: 3, Interesting

    did you happen to look up at ANY slashdot URL:

    /./comments.pl

    hrmm... this kind of looks like a perl cgi, most likely living in mod_perl!

    get a clue dumb arse.
    int 20h;

  3. Funny... by Metteyya · · Score: 3, Interesting

    Almost all of the comments criticizing Perl have been modded "Troll". Slashdot authors getting touchy?

    1. Re:Funny... by imsabbel · · Score: 2, Funny

      i guess the mods have just proven your point....

      --
      HI O WISE PRINCE. WHT TOOK U SO DAM LONG?
    2. Re:Funny... by moof1138 · · Score: 3, Informative

      Here is the list of the top level comments prior to yours that were modded down:
      1) Never used it. What's the big deal?
      2) FP
      3) dead language.
      4) offshoring myths
      5) if the server is running it the slashdot effect will kill it.
      6) Is there anyone left who hasn't switched to Ruby or Python?
      7) Who still uses Perl for web stuff?

      All were either totally OT, or obvious language-war trolls, save #1 which was wasn't a critical post.

      AFAICT it looks like the moderation system is working quite well.

      --

      Hyperbole is the worst thing ever.
  4. Perl a dead language? by Anonymous Coward · · Score: 5, Interesting

    I do not understand how anyone can suggest that PERL is a dead language. It is still one of the most powerful text processing languages out there, with the extensibility that allows it to do everything from performing network activities to CGI. Although CGI is in its decline, it is still used plenty.

    Theres that and the fact that PERL is just a really fun language, very easy, and extremely free-flowing, which I personally think is a good thing.

    1. Re:Perl a dead language? by suso · · Score: 2, Insightful

      Just like a natural language. A language is only dead when its no longer developed or used natively. A computer language should fit a simular definition. Thus, I would say it will be a LONG time before Perl fits that definition.

    2. Re:Perl a dead language? by Fnord · · Score: 2, Informative

      For most of those cases, app servers have completely replaced CGI. The problem with CGI is lack of persistence, and process startup costs. These days, any decent web app is written with some persistent layer that interacts directly with the web server, and loads code snipets of its own language, starts objects, calls callback routines or something similar to handle requests. mod_perl, J2EE/JSP, PHP, Zope, and Ruby on Rails are all examples of this.

  5. Re:Perl still used? by Living+WTF · · Score: 5, Informative

    > Who still uses Perl for web stuff?

    What do you think that ".pl" in most slashdot URLs stands for? PHP Light? Phyton Lowspeed? Perhaps Lisp?

    --
    I don't suffer from insanity, I enjoy every minute of it.
  6. mod_parrot by hey · · Score: 4, Interesting

    Bah, mod_parrot is where its at.
    http://www.smashing.org/mod_parrot/
    I program my web application in Parrot.

  7. Re:Perl still used? by xmodem_and_rommon · · Score: 2

    since when where perl and .net the only systems on the planet?

    There are plenty of perfectly good up-to-date ways to do things, such as with python or PHP. Both of which are at least a capable as .net, but have the added bonus of no platform lock in (PHP and python work equally well on Linux, FreeBSD and Windows servers)

  8. threads support by Anonymous Coward · · Score: 2, Interesting

    Out of curiosity, is this still the same threading model that's existed in Perl for some time? Or is it revamped? Because if it hasn't been updated, well, it's pretty much useless. I've done threading in perl, and every time you spawn a thread, a whole new interpreter is spawned. On top of this, there are many limitations on sharing data between threads (you can't share objects, for one thing).

    It might as well be called forking, to be honest, because it doesn't really qualify as threading.

  9. General note: what is it? by Anonymous Coward · · Score: 5, Informative

    For people who are wondering what mod_perl is exactly: it's a way of integrating perl into Apache's webserver. I think the main advantage is that you don't have the overhead of firing up perl for each cgi-type request. The main gotchas, for the developers point of view, involve a little perl enviornment staying alive, when a perl script starts, runs, and stops, it cleans up after itself, but when it 'stays alive' inside apache, you have to make sure it's not accumulating too much memory cruft, that you're closing handles, etc etc.

    This is what I know mostly by reputation, rather than direct experience, experts please feel free to correct me

    --

    #perl -e '$??s:;s:s;;$?::s;;=]=>%-{-|}&|`{;; y; -/:-@[-`{-};`-{/" -;;s;;$_;see'

    1. Re:General note: what is it? by ydnar · · Score: 5, Informative

      The main advantage is not the faster CGI execution environment.

      mod_perl lets you create Apache modules in Perl, that handle every stage of a request (or anything else), and are full peers of Apache modules written in C.

      ModPerl::Registry[Prefork] is just a bonus. The more interesting m_p modules are authn/authz/dispatch modules that can replace cumbersome C equivalents.

      y

  10. API space rename hurt by henry.thorpe · · Score: 3, Interesting
    I'd been happily using mod_perl2 since 1.99r12 or so. Then, right before the release of 2.0, between 2.0r3 and 2.0r5, the namespace changed http://perl.apache.org/docs/2.0/rename.html. I realize that there are good reasons for doing this (http://marc.theaimsgroup.com/?t=111135037100002&r =1&w=2), but it was still pretty painful if you hadn't had some prior warning. In particular, the FreeBSD ports tree is still feeling some pain. Guess I just got lazy with all the dependencies handled in the ports tree.

    But, now we have to flash-cut our production systems, unless someone knows how to changes things to work under both namespaces...

  11. Re:Perl still used? by _defiant_ · · Score: 5, Informative

    Who still uses Perl for web stuff?

    Ohh, I don't know... how about Amazon and Salon? Kuro5hin and all the other Scoop based sites like DailyKos and MyDD. And now that I think about it, MovableType, TypePad, and LiveJournal are all writen in Perl.

  12. CGI by Reality+Master+101 · · Score: 4, Informative
    Everyone bitchin' that "CGI is dead" should broaden their horizons a bit. CGI may be stupid and dead, but Perl is used in a lot of different ways. It's still one the best languages for getting good work done.

    For example, Mason is a pretty good tool for doing Perl-based web components.

    So bitch about CGI if you wish, but that's not what Perl is for.

    --
    Sometimes it's best to just let stupid people be stupid.
  13. Is an elephant bigger or a girafe taller? by systems · · Score: 5, Insightful

    It's not that Perl is good or bad by itself, the question is more like, you still that Perl is still good/better in comparision to Ruby, Tcl, Python, Haskell, OCaml, Mozart/Oz and others more.

    I do realize, that sometimes comparing two languages is more like asking, is an elephant bigger or a girafe taller?

    But honestly, if you are still to start learning would you still have picked Perl.

    I picked Tcl and I have my reasons. (Tcl/Tk, Sqlite, event driven programming and OpenAcs). And my second choice would be ruby, I strongly like the OOP paradigm and as far as I know Ruby got better support for this paradigm, I'll probably learn ruby next, I believe one should learn a new language every now and then (it's a common advice, I didn't come up with it).

    Supporting old system is good enough reason to learn Perl, but beside taking advantage of availbe libraries (and this is a HUGE good reason) I dont see any other reason to get excited over Perl.

  14. Re:Perl a dead language? NOT by fanatic · · Score: 4, Interesting

    I work doing router and server admin.

    The shortest path between "need" and "have" is usually a perl script. CPAN alone puts perl above anything else I know of.

    --
    "that's not encryption - it's a new perl script that I'm working on..." - from some Matrix parody
  15. Obligatory Futurama Quote by Anonymous Coward · · Score: 2, Funny

    Does anyone actually still use Perl? Isn't that a dead language kinda like Cobol?

    Obligatory Futurama Quote:

    Farnsworth: And this is my universal translator. Unfortunately so far it only translates into an incomprehensible dead language.

    Cubert: Hello.

    Universal Translator: Bonjour!

    Farnsworth: Crazy gibberish!

    (Source: A Clone Of My Own)

  16. Re:Perl still used? by ajs · · Score: 2, Informative

    "Yeah, but is it mod_perl or cgi? If you're using fastcgi, is there still a big performance gain by switching to mod_perl?"

    If you're still thinking in terms of CGI, then it's close to a wash.

    However, mod_perl isn't about CGI. mod_perl is about exposing the Apache API to you. Want to build a caching system that doesn't require a single line of code to be executed for 90% of incoming requests? You can do that with mod_perl. Want to proxy some requests based on the protocol version the browser uses? mod_perl can do that long before you get to the point of even trying to find a cgi program on disk.

    mod_perl lets you do far more than any lightly coupled tool can, and thus it is the building block upon which you build a real CMS (like bricolage) or other high-level Web tool (like TTK, which is what Slashdot uses).

  17. What defines dying? by malverian · · Score: 5, Interesting

    Perl still has a very active community with some very incredible and dedicated hackers. The main thing that keeps me coming back to Perl for personal projects is the fact that it's such a FUN language to program in. I can think of many benefits to using Python and PHP in a work environment, but no matter how long I work with other languages, I always come running back to Perl when I'm in the mood for some highly caffeinated drinks and a late night of hacking. Say what you will about Python or PHP, but you probably can't say either is fun or enlightening to use. I've found that Larry Wall is a very unique individual, and a lot of that is pervayed through the style of his programming language. In Perl I can say (figuratively).. "Go fetch the paper!" or "Can you get the paper?" and both of them work. While that might be a readability nightmare, it lets you be very creative with your code. And to some people, being creative is a nice release after the regimented, controlled environment we deal with in the workplace.

    --
    You're just mad because the voices in your head talk to me.
  18. Re:Perl still used? by abulafia · · Score: 4, Informative

    Amazon.com - E-commerce pioneer seeking to offer the world's largest selection of products online. for details.

    AvantGo - Mobile applications for handheld devices.

    DynDNS.org - One of the world's largest providers of free and premium Dynamic DNS services.

    Findory - Personalized news and blogs aggregator. Findory learns what kind of content you like by the pages you read.

    Live365.com - The world's largest Internet radio website.

    Salon.com - Online magazine covering news, politics, technology, art, sex and health; winner of numerous web awards.

    Weta Digital - Weta Digital are well known as the special effects people behind the Lord of the Rings films. At his OSCON 2004 keynote, Milton Ngan of Weta Digital thanked some technologies, including Mason, which is used as part of their intranet.

    A

    AcuTrans.net - Home page for AcuTrans, a company providing an online content management system integrated with transcription services (built with Mason) for business, legal, medical, and self-insured companies.

    Adventist.org - The official web site of the Seventh-day Adventist Church.

    Alhazred - Progressive music project being produced with open source/free software

    Alzabo.org - Home page for Alzabo data modelling tool.

    American Lung Association of Washington - Assuring lung health for the people of Washington state through research, education, community service and advocacy.

    Apartments - Apartments for rent by RentersInc.com. Free apartment search engine and apartment guide.

    arabellan - Web presence of Ryan "Exide Arabellan" Zander, a graphical artist.

    astrojax.com - amazing fun and action game - community website with lots of features.

    Autismeinfocentrum.nl - Information- and documentationcentre about autism and related subjects in the Netherlands.

    AutoSupplyUK.com - Used Japanese import auto store.

    B BDO - Austrian tax consultancy

    Beotechnic - Company specializing in knowhow transfer

    Bikeworld.com - Online retailer, sporting a new 100% Mason-powered site that was developed entirely in-house.

    bizjournals.com - Publisher of 41 weekly business newspapers across the US.

    BlackSpider - Managed services provider focused exclusively on the provision of e-mail security solutions.

    Burma-Shave.org - All of the original Burma-Shave jingles, plus the Burma-Shave Daily mailing list.

    C

    cibera.de - cibera is an online library site which offers a central access point to interdisciplinary material concerning the Spanish- and Portuguese-speaking area as well as the Caribbean.

    Cars - iCarsInc.com Cars for sale. Buy and sell new and used cars online. Your next auto purchase starts right here. Find new, used, classics, sports cars, luxury cars, trucks, SUVï½s and even motorcycles for sale.

    --
    I forget what 8 was for.
  19. Some mod_perl info by programgeek · · Score: 5, Informative
    You people are saying alot of stuff without even bothering to google it.

    The following is taken from http://perl.apache.org/
    "mod_perl is more than CGI scripting on steroids. It is a whole new way to create dynamic content by utilizing the full power of the Apache web server to create stateful sessions, customized user authentication systems, smart proxies and much more. Yet, magically, your old CGI scripts will continue to work and work very fast indeed. With mod_perl you give up nothing and gain so much!"

    "mod_perl gives you a persistent Perl interpreter embedded in your web server. This lets you avoid the overhead of starting an external interpreter and avoids the penalty of Perl start-up time, giving you super-fast dynamic content.

    As you'd expect from the Perl community, there are hundreds of modules written for mod_perl, everything from persistent database connections, to templating sytems, to complete XML content delivery systems. Web sites like Slashdot and Wired Magazine use mod_perl."

    Yes, Slashdot does run on mod_perl.

    A friend of mine uses mod_perl and the performance increase he gets is insane.

    --
    Georgia
  20. Re:Perl still used? by Quattro+Vezina · · Score: 2, Funny

    Prolog?

    --
    I support the Center for Consumer Freedom
  21. Is it dying? It it the end of fun? by rduke15 · · Score: 4, Interesting
    it's such a FUN language to program in

    Exactly. But I guess that is what so many don't like. As Larry Wall said:
    "In trying to make programming predictable, computer scientists have mostly succeeded in making it boring"
    -- Larry Wall, interview in The Perl Journal, vol. 1 issue 1.

    I gess some prefer programming to be boring.

    I don't.
  22. Re:Python: Syntactically significant white-space by snorklewacker · · Score: 2, Interesting

    Bah. The whitespace thing is not all that bad unless you have funky editor requirements. Editing python in a textarea is hell. Do not attempt. Otherwise, it simply doesn't even bite me, and is only occasionally annoying.

    I think python's weird "half-closed" ranges, the fact that "print" is a hardwired built-in and not a first class function, its lack of real closures (they're still read-only), crippled lambda compared to sub and anonymous blocks (I'll give ruby the win there), surprising behavior like list and hash default function args always aliasing the same value ... those are all real and technical reasons to hate python.

    Of course I have a laundry list of hates for perl too, but anyone who uses a language long enough will garner such a list. Familiarity breeds contempt. And to be fair, python has lots of nice things. I thought list comprehensions were nice, but generator comprehensions are the bees knees.

    The whitespace thing just isn't an issue. You just can't do one-liners effectively, that's all.

    --
    I am no longer wasting my time with slashdot
  23. Re:mod_perl on Windows by jjn1056 · · Score: 2, Informative

    I build a REST interface for an audio generation system at "http://mp3.motorola.com.cn:8080/composer" which is mod_perl2 on windows server 2003 and perl 5.8.6. It just works, not trouble.

    --
    Peace, or Not?
  24. merits of perl, the future of parrot by gregorlowski · · Score: 3, Insightful

    Perl has a lot going for it. mod_perl and html::mason (used by /. and apache) together are a much more maintainable solution to large web apps than PHP, IMO. I had to maintain some really ugly old PHP code at my old job. Any language can get ugly if the coding style is ugly, but properly written html::mason does a lot more to separate Model, View, and Controller than any PHP solution I've seen.

    I did a lot of perl programming back in the day. Although I still like it a lot (I think the DBI is one of the best database libraries out there), I do find myself working more and more in both python and ruby for rapid development.

    If you love perl but sometimes get a headache from staring at long lines of code with lots of sigils, braces, and parentheses, take a look at ruby. From what I've seen of Perl6 so far, it will also clean up some syntax while retaining neat perlish tricks and adding a lot of advanced programming language features.

    I have high hopes for the parrot project too. Maybe one day we'll all be able to write parts of our apps in ruby, python, perl6, ponie, and integrate them together on a common VM platform. I think this would be an incredible step for open source software development! Still, I'm not going to hold my breath waiting for this... it looks like this scripting nirvana is still pretty far off.

  25. Re:Perl still used? by millette · · Score: 2, Informative

    See also embperl if all you want is to embed perl (duh) in html, as you might do with php. That being said, you should separate the code and the layout, blah blah blah.

  26. Powerful by sallgeud · · Score: 2, Informative

    At my previous job we used mod_perl (1 and 2[beta]). The excellent part about mod_perl is that it allows you to completely control Apache in every manner possible.

    There are excellent performance benefits in writing Apache handlers... and mod_perl simply allows them to be written in perl.

    The last application I developed handled multi-millions of records per day without flinching. There were dozens of users and several extremely complex equations and correlations done...

    In the end, it outperformed the other attempts made at doing the same thing... and it was simple to maintain.

    Since my departure (and that of the rest of the perl team)... the company decided to scrap perl and move completely to java (for unix systems). They're finding that getting rid of the several million lines of perl code and the hundred-or-so websites developed in mod_perl is likely to take them an eternity when rewriting in java.

    Though I now develop in ASP.NET (C#, etc)... I still fondly remember my days as a perl developer. Being able to crank out an application in little to no time was amazing... and with the power of CPAN it's hard to compare any other language.