• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Keeping up with Perl: Development, Upgrade and Deployment Options for Perl 5.12
 

Keeping up with Perl: Development, Upgrade and Deployment Options for Perl 5.12

on

  • 3,401 views

With the growth in dynamic languages, Perl still rules the roost as “the duct tape of the Internet.” Now that Perl 5.12 and Perl Dev Kit 9 are available, are you ready to make the move? In this ...

With the growth in dynamic languages, Perl still rules the roost as “the duct tape of the Internet.” Now that Perl 5.12 and Perl Dev Kit 9 are available, are you ready to make the move? In this webinar for Perl developers and system administrators, join Jan Dubois, senior Perl developer at ActiveState, and Troy Topnik, technical writer at ActiveState to learn:

* What’s new in Perl 5.12
* What to do with legacy code
* Assess if you need to upgrade
* How to deploy quickly and efficiently
* How to use CPAN and Perl Package Manger (PPM) for managing 3rd party modules
* Deployment choices including web, system, desktop and utility applications

Statistics

Views

Total Views
3,401
Views on SlideShare
3,123
Embed Views
278

Actions

Likes
1
Downloads
21
Comments
0

13 Embeds 278

http://www.activestate.com 94
http://allframeworks.ru 93
http://andrey.opeykin.ru 40
http://xomiak.blogspot.com 23
http://www.allframeworks.ru 9
http://stage.activestate.com 6
http://sayperl.org 3
http://sayperl.org 3
https://www.activestate.com 2
http://xomiak.blogspot.de 2
http://www.sayperl.org 1
http://xss.yandex.net 1
http://xomiak.blogspot.ru 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Keeping up with Perl: Development, Upgrade and Deployment Options for Perl 5.12 Keeping up with Perl: Development, Upgrade and Deployment Options for Perl 5.12 Presentation Transcript

    • Keeping up with Perl: Development, Upgrade and Deployment Options for Perl 5.12
    • Poll
    • Agenda
      • Perl, ActivePerl, and ActiveState
      • Resilience and continued growth of Perl
      • What's new in Perl 5.12
      • Updating legacy code
      • Distributing and deploying applications
    • Perl
      • Created by Larry Wall in 1987
        • Perl 2 1988
        • Perl 3 1989
        • Perl 4 1991
      • Perl 5 released in 1995
        • language syntax stabilizes
        • all the major parts are there
        • first “extensible” version (use Some::Module)
      • Continued incremental improvements through the 5.x series
      • Perl 6 – beyond the scope of this presentation
        • is essentially a new language
        • not ready yet, though Rakudo Star is getting closer
    • ActivePerl
      • the first distribution of Perl for Windows
      • ActiveState hired by Microsoft to improve Perl performance and features for Windows
      • Gurusamy Sarathy (gsar), the Perl “Pumpking”
      • enhancements for ActivePerl submitted upstream to core Perl
      • ActivePerl helps popularize Perl: 2 million downloads per year
      • added some useful things:
        • PPM (Perl Package Manager)
        • PerlScript and Perl for ISAPI extensions
      • CPAN is a 'one stop shop' for user-created modules
        • standard toolchin for building, testing, and installing modules
        • searchable
        • standardized documentation format
        • bug tracking
        • HUGE: 18,000 modules
      • PPM is ActivePerl's client for installing these modules
        • command line and GUI interface
        • pre-compiled packages for specific platforms and Perl versions
        • dependencies handled automatically
        • provides most modules on CPAN (around 13,000)
      & PPM
    • The Resilience of Perl
      • “ the duct tape of the internet” (but much more)
      • unfashionable != unpopular|obsolete
      • key modules provide functionality outside the core
        • object oriented programming via Moose
        • web frameworks: Catalyst, HTML::Mason et al.
      • mature language – changes are more incremental
        • threading / fork() emulation in Perl 5.6
        • Unicode support in Perl 5.8
    • Poll
    • Perl Releases
      • Perl releases used to be feature-based until 5.10
      • significant features in Perl 5.10:
        • given/when statement, smartmatch operator ~~
        • defined-or operator //
        • recursive regexp patterns
        • named regexp capture groups
      • Perl 5.12 and forward are time-based
        • no feature milestones to define the release
        • only features ready by release-time will be included
    • What's new in Perl 5.12
      • lots of bug fixes not available elsewhere
        • maintenance releases will only fix regressions, critical bugs (crashes) and security vulnerabilities
      • deprecation warnings enabled by default
      • various "little" features
    • package NAME VERSION
      • This statement is parsed exactly the same way as
      • “ use PACKAGE VERSION ”. For example:
      • package Foo::Bar 1.23;
      • ... sets the module version right in the "package" statement at compile time, without having to assign to $VERSION at run-time
    • The “Yada Yada” operator
        • For example
        • if ($condition) { ... }
        • ...is the same as:
        • if ($condition) { die "unimplemented" }
        • marks unimplemented, placeholder code
        • pseudo-code becomes compile-able, tests pass
    • Implicit strictures
      • An explicit request to require Perl 5.12 or later will automatically turn on "use strict"
      • For example:
      • use 5.12.0;
      • implies:
      • use strict;
      • use feature ":5.12";
    • ...and more...
      • Unicode improvements
        • now supports all Unicode properties
        • use feature "Unicode_strings";
      • Y2038 compliance even on 32-bit systems
      • new pragmata
        • autodie
        • overloading
      • N regex escape: opposite of
      • pluggable keywords
      • qr// overloading
    • Updating legacy code
      • Blog comment spotted in the wild:
        • “ There’s a lot of legacy Perl out there, and the host organisations are naturally afraid to touch it. So if there was a guide to “De-legacy your Perl” or “Bring your legacy Perl into the light” it may be highly valued. That’s not the same as writing good Perl: it’s about understanding and incrementally saving code that’s already there. That book has not yet been written.”
              • Nik Silver
      • There's no book, but there are tools and documentation...
    • Try running it!
        • Run the old code with with a newer interpreter – it may just work.
        • The interpreter will warn about deprecated code
        • incremental approach: 5.6 to 5.8 to 5.10 to 5.12
          • use warnings;
          • less likely to “break” existing code
          • setting up each environment takes time and effort
          • tempting to stay with a “less obsolete” version
        • “ bite the bullet” approach: upgrading directly to 5.12
          • address all the incompatibilities at once
          • opportunity to use new language features
          • great excuse to write automated tests!
            • write tests for the old version first, then run them against 5.12
    • Poll
    • Consult perldelta
      • each perl release has a list of differences and incompatibilities with the previous version
        • http://perldoc.perl.org/index-history.html
        • also in the ActivePerl documentation
      • pay particular attention to the Incompatible Changes section
      • don't skip a version, the perldeltas are not cumulative (e.g. going from 5.8 to 5.12, check the 5.10 delta and all point releases)
        • you can skip development releases (5.7, 5.9, 5.11, etc.)
    • Check all modules
      • binary modules are NOT compatible between major Perl versions (e.g. 5.8 to 5.10)
      • update to the latest modules (unless that proves too hard)
      • using PPM helps – installing vs. building plus installing saves time
      • Check the module's Changes file and documentation
    • Use Perl::Critic
      • Perl::Critic – a tool for examining your source code
        • uses Conway's “Perl Best Practices”
        • points out bad or deprecated code and suggests alternatives
      • PDK has a helpful GUI interface
    • ... or don't upgrade
      • choosing not to upgrade is viable if:
        • your code is not business or mission-critical (i.e. nobody would care if it broke), or
        • you have commercial support for the older Perl version
      • ActivePerl Business Edition provides access to older builds of ActivePerl
      • ActivePerl Enterprise Edition can provide access and support for specific versions and platform builds
    • Deploying / Distributing
      • Deploying or distributing code written in an interpreted language is different from deploying compiled binaries.
      • Traditionally, the target system requires:
        • the source code of the application
        • an interpreter compatible with the code
        • all required modules/libraries
      • Depending on the type of application, there are a few different approaches...
    • User/Customer supplies interpreter
      • Linux, Mac OS X, and most UNIX-like operating systems have their own Perl interpreters, but:
        • may be the wrong version for your code
        • some required binary modules may not be available (as packages)
      • ActivePerl Community Edition is available for free, but:
        • additional hassle for the customer
        • Windows, Mac OS X, and Linux only
        • latest releases of 5.12, 5.10, and 5.8 only
        • support is from the Perl comunity, not a vendor
      • ActivePerl Business Edition
    • Packaging the application
      • PDK deployment tools (PerlApp, PerlSvc, PerlCtrl et al.) package your perl code with:
        • an embedded perl interpreter
        • all required modules / libraries
      • suitable for desktop applications and system services
      • to the end user, it's just a native executable
        • no additional prerequisite software needed
        • no additional cost or hassle for the end user
      • end users cannot easily modify the application
    • In-House Perl vs. ActivePerl OEM
      • For enterprise-level or otherwise large scale “systems” software, distributing a real Perl interpreter may be preferable to packaging
          • integrators or customers may need access to the code (making changes on the fly)
          • may have a suite of related applications which use the same environment / modules
          • performance advantages
      • A “Roll your own” Perl distribution:
          • lots of maintenance overhead in addition to your own code
          • harder to keep up-to-date
      • ActivePerl OEM: lets you distribute ActivePerl with your own software
          • QA and support
          • indemnification
    • Poll
      • Founded 1997
      • 2 million developers, 97% of Fortune 1000 rely on ActiveState
      • Development, management, distribution solutions for dynamic languages
      • Core languages: Perl, Python, Tcl
      • Other: PHP, Ruby, Javascript
      ActiveState
    • ActiveState solutions
      • Get Perl Dev Kit 9 – on sale until Aug. 15 th
        • 1-user: $245 (save $50)
        • 5-pack: $995 (save $185)
        • Upgrade from $95 (save ($50)
      • Get ActivePerl 5.12 Business Edition :
        • Use code APBE200 to get $250 off until Aug. 30th
      • Speak to a representative about ActivePerl 5.12 Enterprise or OEM: 1-866-510-2914
      • business-solutions@activestate.com
      • www.activestate.com