@vandys @randomgeek @codinghorror As a #Perl hacker I will never besmirch #CGI as a standard or for light-use web scripts, but a lot of sins were committed with the two.

These days the done thing is to use #PSGI and a framework like #Mojolicious or #Dancer2 in a persistent app server. You don’t have to write nearly as much code, either. https://plackperl.org

The #Plack middleware can even run your code as a CGI or #FastCGI script if you reallly want.

PSGI/Plack - Perl Superglue for Web Frameworks and Web Servers

On this day in 2008, the #Apache Software Foundation released mod_perl 2.0.4, compatible with the December 2007 release of #Perl v5.10: https://lists.apache.org/thread/shyvjnl3dww17pdv24147vbnnwpcb64b

#ModPerl embeds a #Perl runtime in the Apache #httpd web server, hooking it into all stages of the request and response process as well as configuration file logic. Before the advent of #PSGI and #Plack in the 2010s, it was the recommended platform for persistent Perl web applications without the overhead of legacy #CGI.

#WebDev #ASF

@js @berkes @simon #CGI for #Perl #WebDev hasn't been a best practice since the release of the #PSGI spec and #Plack middleware in 2009. There are several very good frameworks that build on PSGI, described here for folks coming from CGI: https://metacpan.org/pod/CGI::Alternatives

The CGI module itself was removed from the core Perl distribution with v5.20 in 2014 https://perldoc.perl.org/perl5200delta#CGI-and-its-associated-CGI::-packages

For anything but the simplest single-user apps, you are permitted to point and laugh at anyone that still uses CGI.

CGI::Alternatives - Documentation for alternative solutions to CGI.pm - metacpan.org

Documentation for alternative solutions to CGI.pm

Yay! PR for a thing I got to #opensource for work is merged!
https://github.com/plack/Plack/pull/610 #perl #plack
Add support for the psgix.cleanup extension by afresh1 · Pull Request #610 · plack/Plack

Having cleanup support in the FCGI Handler will be beneficial to us as it allows post-processing of tasks after the request has been served to the client and we would like to do our request logging...

Was asked about a problem with #mod_perl and decided it was easier to switch to #plack https://gist.github.com/afresh1/bc9318482a9fdba74b99823b4c120be3 #perl #blogsum
blogsum as a Plack app - https://github.com/obfuscurity/blogsum - https://metacpan.org/pod/Plack - Patches needed due to CGI::Compile: https://metacpan.org/pod/CGI::Compile#CAVEATS

blogsum as a Plack app - https://github.com/obfuscurity/blogsum - https://metacpan.org/pod/Plack - Patches needed due to CGI::Compile: https://metacpan.org/pod/CGI::Compile#CAVEATS