Stories
Slash Boxes
Comments
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 ]

rcaputo (9040)

rcaputo
  (email not shown publicly)
http://poe.perl.org/
+ -

  Comment: Re:You know you're not wanted in #perl. (Score 1) on 2010.08.11 21:36

by rcaputo on 2010.08.11 21:36 (#72301)
Attached to: Matt Trout, aka mst, is insane

Indeed. Most people have reasons for the things they do.

Read More 17 comments
Comments: 17
+ -

  Comment: Re:You know you're not wanted in #perl. (Score 1) on 2010.08.11 13:18

by rcaputo on 2010.08.11 13:18 (#72291)
Attached to: Matt Trout, aka mst, is insane
He's an active participant in #perl and a channel op. These things happened while you were busy falling out of touch with the Perl IRC community.
Read More 17 comments
Comments: 17
+ -

  Comment: Matt Trout, aka mst, is insane (Score 1) on 2010.08.11 12:16

by rcaputo on 2010.08.11 12:16 (#72284)
Attached to: Matt Trout, aka mst, is insane
If we start with the premise that Matt's insane, then he doesn't actually need a reason. Craaaaazy people do craaaaazy things. Like sell appliances at deeeeep discounts.
Read More 17 comments
Comments: 17
+ -

  Comment: only inasmuch as There's Only One Way To Do It (Score 1) on 2010.08.06 22:21

by rcaputo on 2010.08.06 22:21 (#72264)
Attached to: My reply to Removing database abstraction

"Inside every large program, there is a small program trying to get out." --Tony Hoare

Abstractions incur overhead, yep. Fortunately, POE's higher-level abstractions (wheels, components) are entirely optional. The low-level abstract event loop primitives are still there: select_read(), alarm(), sig(), etc. There's a smaller POE inside. It's already out, but it's been a bit neglected.

History has a bigger role to play than abstractions in the obstruction of change. A long-established, stable module like POE has reduced mobility because lots of people actually use it. A newbie module like Reflex can reinvent itself every few weeks, and nobody is going to mind. The depth of the abstraction stack has nothing to do with it. Although POE+Reflex's is shorter and (I hope) a bit more efficient as a result.

If anything, the depth of the abstraction stack allows more rapid change to occur. There's wiggle room in each level of abstraction, and if I'm allowed to consider modules to be abstractions, then delegating development (via CPAN, for example) accelerates change. But I digress on a technicality. :)

I think it's a mistake to talk about POE's "programming style" as if that's a particular thing. The Perl I'm using has a motto: There Is More Than One Way To Do It. That applies to using POE. For example, you may prefer condvars or promises to callbacks. POE can do that. And if you prefer to write classes that provide callbacks or can be used as promises, then POE can do that via Reflex.

Yeah, the flexibility comes at a cost, but, as you say, all things do. I think the benefits are worth it, but of course I'm always looking for a better cost/benefit ratio. All reasonable suggestions considered.

Read More 5 comments
Comments: 5
+ -

  Comment: Re:you accidentally opted out of rt.cpan.org notic (Score 1) on 2010.04.28 16:51

by rcaputo on 2010.04.28 16:51 (#71933)
Attached to: Nerd communication

Well, that sucks. Maybe the default was different in my day.

I guess we'll have to leave it at this, since neither of us seems to be talking to someone who can do anything about it.

Read More 6 comments
Comments: 6
+ -

  Journal: Reflex Progress on 2010.04.16 1:04

Journal by rcaputo on 2010.04.16 1:04
User Journal

I've been making good progress on Reflex lately. I have to: I've applied to talk about it at YAPC::NA, so I need something to talk about! The code has been moving too fast for CPAN right now, but you can follow along at Reflex's repository on github. Here's a summary of the latest changes:

Read More 0 comments

+ -

  Comment: you accidentally opted out of rt.cpan.org notices (Score 1) on 2010.04.09 19:17

by rcaputo on 2010.04.09 19:17 (#71880)
Attached to: Nerd communication

Check your CPAN contact address, which should be redirecting to your current e-mail address. rt.cpan.org is consistently contacting me via my @cpan.org address. Maybe I opted in for that? I don't recall... I set it up over a decade ago.

Also check https://rt.cpan.org/Prefs/Other.html to see whether your e-mail delivery is not "Suspended". If it is, I can only guess that it was auto-suspended because your @cpan.org address was bouncing.

If it's still not working: "Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com." That request is right there under the Search field on most (all?) rt.cpan.org pages.

Or not. Maybe someone from Best Practical will stumble across your blog and help out.

Read More 6 comments
Comments: 6
+ -

  Comment: snerp vortex isn't just for git (Score 1) on 2010.04.01 12:35

by rcaputo on 2010.04.01 12:35 (#71811)
Attached to: svn to mercurial?

I can't answer your question directly, but I know that my Snerp Vortex is designed to support more than just git.

Someone with Mercurial chops could write SVN::Dump::Replayer::Mercural, and then snerp would support --replayer=mercurial

Read More 4 comments
Comments: 4
+ -

  Comment: I/O dispatch is about 130% faster, since you ask. (Score 1) on 2009.10.15 12:05

by rcaputo on 2009.10.15 12:05 (#70900)
Attached to: POE 1.280 is Faster

Sorry, no fancy graphs.

I wrote a deliberately simple program to count select_read() events per second. I ran it five times for each version of POE, averaged the results, and calculated the improvement using (new_rate/old_rate-1). Standard deviation for the sample sets were about 1%, if that matters.

#!/usr/bin/env perl

use warnings;
use strict;

use POE;

my $limit = 10_000;
my @start_times;
my @end_times;
my $count = 0;

my $filehandle;

POE::Session->create(
  inline_states => {
    _start => sub {
      open $filehandle, "<", "/dev/zero" or die $!;
      $_[KERNEL]->select_read($filehandle, "count");
      @start_times = times();
    },
    count  => sub {
      if ($count < $limit) {
        $count++;
        return;
      }

      @end_times = times();
      for (0..$#end_times) {
        $end_times[$_] -= $start_times[$_];
      }

      $_[KERNEL]->select_read($filehandle, undef);
    },
  },
);

POE::Kernel->run();

print join("\t", "POE", "BENCH", "COUNT", "RATE"), "\n";
print join(
  "\t",
  $POE::VERSION,
  "io/cpusec",
  $limit,
  sprintf("%.2f", $limit / ($end_times[0] + $end_times[1])),
), "\n";

I don't have a methodology to test the mark-and-sweep garbage collection in isolation. Got any ideas?

Read More 2 comments
Comments: 2
+ -

  Journal: POE 1.280 is Faster on 2009.10.14 0:19

Journal by rcaputo on 2009.10.14 0:19
User Journal

POE 1.280 has just been released, but it may take up to a day before your favorite CPAN mirror catches wind of it. You'll also need the latest POE::Test::Loops, version 1.030.

Those following along may notice that the version numbers jumped a little. That's because POE has undergone a couple optimizations that alter its behavior a little.

I/O Dispatch is Faster

Read More 2 comments
Comments: 2
+ -

  Journal: Upcoming POE Changes on 2009.10.09 12:40

Journal by rcaputo on 2009.10.09 12:40
User Journal

Those of you who use POE for serious things should be aware of a couple changes introduced after 1.269.

Read More 1 comments
Comments: 1
+ -

  Journal: POE Supports Other Event Loops, Really on 2009.09.11 0:57

Journal by rcaputo on 2009.09.11 0:57
User Journal

Lately I've been hearing, repeatedly and loudly, that POE doesn't work with other event loops. I wrote the first bridge between POE and another event loop in May of 2000, so this is rather shocking news to me. I've had to rerun "make test" just to be sure I wasn't dreaming! :)

Read More 1 comments
Comments: 1
+ -

  Journal: Help me rename Lexical::Persistence on 2009.09.06 1:51

Journal by rcaputo on 2009.09.06 1:51
User Journal

"Persistence" implies that data will be saved and loaded from disk, to a database, or some other persistent storage. That's not what the module does, so I think it needs a new name.

Lexical::Persistence objects are closures that make the values of lexical variables stick (or persist) in everything they call. In the following example, the Lexical::Persistence object makes sure that getter()'s version of $x contains the value stored by setter().

Read More 2 comments
Comments: 2
+ -

  Journal: Trying Out this Git Thing on 2009.08.08 16:38

Journal by rcaputo on 2009.08.08 16:38
User Journal
Distributing Development

Distributed version control is great. It'll bring on the patches, establish world peace, and get you laid. It adds extra steps to your workflow, but they make everything easier. Don't ask me how. Even if I understood that trick, the Magician's Code wouldn't let me explain it to you.

Read More 1 comments
Comments: 1
+ -

  Journal: POE Changes Coming Soon on 2009.07.23 23:30

Journal by rcaputo on 2009.07.23 23:30
User Journal

POE::Test::Loops 1.020 will be released tonight. This is a suite of reusable tests for developers who want to add external event loop support to POE. Version 1.020 acquires more signal handler tests from POE. Existing POE::Loop authors should try the new tests at their earliest convenience. Those who need the code right away can track the repository:

Read More 0 comments