[sf-perl] Mouse, again?

Joseph Brenner doom at kzsu.stanford.edu
Fri Mar 2 11:50:13 PST 2012

Jonathan Swartz <swartz at pobox.com> wrote:

> Joseph: As far as Mouse, I tried to use it for CHI at one point, then backed out. The problem is that it sort of looks lke Moose, but will break in all kinds of funny ways when you try to use advanced features. It especially breaks down when trying to use MooseX extensions.

Yeah, that's a problem I kind-of expected.

> Its only advantage is faster start-up time. If you're writing a command-line script that has to be executed all the time, that might be important. If you're writing anything that's going to run persistently, like web code, then not so important.

Right.  I should explain that at present the reason I'm considering
using it is that I've noticed that it's already installed where I work
(as is "Class::Accessors", oddly enough), and I will probably start
playing with Mouse just because it's there and I don't have to jump
through any political hoops to get something else.  I'm also happy not
to write my own base class (doable, but it feels very stupid).

To speculate on why Mouse is installed and not Moose: I would guess
that the dev team was interested in trying something new, but was
worried about the heavy-weight reputation of Moose.  The concern is
probably not start-up time (this is a mod_perl shop) but memory usage
on the high-traffic web servers...

(There are a bunch of things that could be improved about the
architecture of this place, notably the fact that there's essentially
a single tree of live code, so even though I'm doing intranet/database
crunching work that doesn't touch the front end, I have to live with
code development processes that are paranoid about taking down a web
site and losing a hundred thousand an hour until it's back up.)

More information about the SanFrancisco-pm mailing list