Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

jozef (8299)

  (email not shown publicly)

Journal of jozef (8299)

Thursday August 19, 2010
10:09 AM

Bundles Packages Builds Releases Tests

When I showed Benjamin (a college of mine) my TPF 2010Q3 grant proposal, we slipped to a discussion about deploying Perl software. Nice (and recent) list of different approaches can be found To sum it up => TIMTOWTDI. Which is good, but none of those is perfect. The Perl+CPAN world is way too complex.

During out discussion with Benjamin I proposed an idea of shipping the application altogether with the OS. Insane? The base Debian system is ~190MB, all the rest is needed for the application. Then deployment will be a matter of running this system on a virtual machine, somewhere in the cloud or in a simple chroot. (btw any Linux distribution can have any other Linux distribution working in a chroot) The files will never clash, all the "machines" would be dedicated. No fear of putting files where they belong to.


Monday August 02, 2010
09:07 AM

XML + XPath + GUI = Xacobeo

Xacobeo a Perl GUI to visualize XML and perform XPath queries just entered Debian unstable -

Wednesday July 28, 2010
12:00 PM

You just upload your application, ...

It is amazing what happened to the Python thanks to just one company. The killer feature of that company is that they can handle and manage millions of servers and even give them for a public usage => "..., there are no servers to maintain: You just upload your application, and it's ready to serve your users.". I would like this to be true one day for Perl too!

I really do. In coming months (years?) I'll try to plug together « MiniCPANInject + SmokeTesting + ContinuousIntegration + Virtualization + Debian + Monitoring » to create an architecture for Debian-Perl hosting. Actually who cares about OS used, when the uploaded code just works, right?... A hosting that is aware that one server is not enough for everyone and will offer an architecture for development, user-acceptance, staging and production environments to start with a project from $day == 1.


Tuesday June 22, 2010
12:22 PM

sub r {return if !$_[0]; r($_[0]-1); } leaktrace{ r(1);};

Today @$work we discovered that even dummy recursive calling of a function is leaking memory. Here is the one-liner 10000x calling it self and returning:

perl -MEnglish -MGTop -le 'my $g=GTop->new();$m=$g->proc_mem($PID);print $m->size; sub r { return if not $_[0]; r($_[0]-1); } r(100000); $m=$g->proc_mem($PID); print $m->size;'

The output is:


Before the recursion 7MB allocated. After the recursion (that finished) 34MB...

Here is what Test::LeakTrace say about it:

$ perl -MTest::LeakTrace -le 'sub r { return if not $_[0]; r($_[0]-1); } leaktrace{ r(1); };'
leaked ARRAY(0x9b7e8e8) from -e line 1.
leaked SCALAR(0x9b98cb8) from -e line 1.
leaked ARRAY(0x9c311f8) from -e line 1.
leaked SCALAR(0x9c311e8) from -e line 1.

Are we doing anything wrong? Is it ok? How to release the memory?

Saturday June 19, 2010
09:29 AM

UNIX / in Strawberry %INC

That was a surprise for me to see / in MSWin32 paths. Dump of %INC:

$VAR1 = {
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         'warnings/' => 'C:/strawberry/perl/lib/warnings/',
         'File/Spec/' => 'C:/strawberry/perl/lib/File/Spec/',
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         'File/' => 'C:/strawberry/perl/lib/File/',
         '' => 'C:/strawberry/perl/lib/',
         '' => 'C:/strawberry/perl/lib/',
         'File/Spec/' => 'C:/strawberry/perl/lib/File/Spec/',
         'Data/' => 'C:/strawberry/perl/lib/Data/',
         'App/' => 'lib/App/'

Thursday May 06, 2010
01:55 AM

Learning from

Joel shows that StackOverflow is (||was?) running on 2 servers (+1 backup) using C# and SQL Server. Impressive :-) seek to 24:56 to see the full performance+tech table.

There is also a Perl+Perl6 mentioned in this talk, seek to 38:00 to hear the #1 thing you should never do...


Sunday April 25, 2010
12:40 PM


is just a base module responsible for loading extension (Data::Keys::E::*) during the object build time. It just makes sure one of the extensions supplied get() and set() method. The rest is up to the extensions.

get() should be called with one argument a $key and return value for it. set() should be called with $key and $value arguments returning modified (if it was) $key.

So far I've created this extensions:

How I want to use it now? Value::InfDef to help reading folders full of JSON files. Key::Auto to store data as Git does - based on the hash of data. Key::Adapt to easily access Debian distribution files in the pool folder or CPAN distributions files based on the AUTHORID/DISTRIBUTION in CPAN mirror folder structure.

For now there is just folder storage as I want to use it for some tasks, but it should be quite easy to create any key/value storage extension.


Friday March 26, 2010
04:44 AM

dh-make-perl --locate Foo::Bar

I didn't know about this easy way to locate Perl modules in Debian packages.

$ dh-make-perl --locate Foo::Bar
Using cached Contents from Fri Mar 26 10:25:51 2010
Foo::Bar is not found in any Debian package

$ dh-make-perl --locate Moose::Meta::Class
Using cached Contents from Fri Mar 26 10:25:51 2010
Moose::Meta::Class is in libmoose-perl package

$ dh-make-perl --locate Test::More
Using cached Contents from Fri Mar 26 10:25:51 2010
Test::More is in Perl core (package perl) since 5.6.2

So there is a ready made solution how to locate Perl modules in Debian packages. The '--locate' option is in Squeeze (testing) version of dh-make-perl or in the source repositiory.

Thursday March 11, 2010
05:35 AM

How to get a CPAN module into Debian

05:01 AM

Perl 5.12 for Squeeze?

"The squeeze freeze is also just around the corner AFAIK so I don't think there's much chance of 5.12 making it in. If somebody wants to step up and push for it, they should definitely talk to the release team first."