Subclassing Perl Interfaces

Gerry Gleason, who has done a ton of work for PurpleWiki recently, and I have had an ongoing discussion about when to use base classes in Perl. The reason the question comes up at all is that Perl base classes do not behave the way base classes do in “real” object-oriented languages. Because Perl does very little in the way of type-checking, defining interfaces as Perl base classes doesn’t give you the same benefits as it would in other languages.    (4PS)

Nevertheless, when you have multiple classes with the same interface, I think it’s good practice to define the interface in a base class, if only for the discipline of doing so. When we were designing a new pluggable back-end architecture for PurpleWiki, Gerry and I first discussed the API using the Wiki, then Gerry went off and implemented three different backends simultaneously. Today, I created a base class for those backends, and in the process of subclassing them, I discovered a bunch of inconsistencies and subtle bugs in the implementation. The point is not that Gerry is a sloppy programmer. Anyone would have made the same mistakes in the process of implementing a new architecture quickly, especially doing (and learning from) multiple implementations simultaneously. The point is that the process of creating a base class forced us to rigorously examine the interfaces of each implementation. Even though Perl doesn’t do as much as it could with base classes, the processing of implementing base classes and subclassing them forces us to do our own checking, which results in better code.    (4PT)

Perl doesn’t leave you totally helpless when it comes to base classes, although again, you have to do extra work to get the behavior you want. For example, you can “assure” that methods are overloaded by defining methods that croak in the base class. If these methods are not overloaded, then they will croak when they are called.    (4PU)

Connectivity Parties, For-Benefit Organizations, and Post-Modernism

I spent some time today with Gerry Gleason, who was in town for the weekend. I was telling him about a Coding Sprint Blue Oxen was planning, and he asked what those were. When I explained them to him, he said, “Oh, we used to do those for NFS. We called them Connectivity Parties.” Back then, folks would gather together at conferences, set up a bunch of hardware, and code away. Yet another demonstration of the timeliness of good patterns, regardless of what they’re called. Of course, the ubiquity of high-speed wireless and four-pound laptops make it much easier these days.    (4PK)

Gerry had two other language-related insights. We spoke about the problem of non-profits getting caught up with the language of business, and thus losing sight of the importance of things like volunteerism, caring, and so forth. I pointed out that the term, “non-profit,” immediately frames these organizations in the language of business. Gerry told me that he had had this conversation with Phil Cubeta in the past, and that they had come up with the term, “for-benefit.” I like it. Even though Blue Oxen Associates is an LLC (a legal for-profit), I think I’ll start referring to it as “for-benefit,” because that captures the essence of what we’re trying to accomplish.    (4PL)

On a more scholarly note, Gerry is reading Ken Wilber‘s Integral Psychology, which has a chapter on modernism and post-modernism. Wilber says that out of modernism emerged three distinct disciplines — art, religion, and science — and that science (and by proxy, rationality) eventually trumped the other two. Postmodernism disputes the distinctions between those three fields. However, many people — both critical theorists and scientists — misinterpret postmodernism as a rejection of science. I don’t think science and postmodernism are orthogonal. You can be a good scientist and reject the notion of universal objectivity. The problem is with framing. “Postmodernism” is framed as a reaction to “modernism,” which is historically accurate, but which undermines the essence of its underlying values. I recognize, without irony, that this is a postmodernist interpretation of why postmodernism is misinterpreted. I’ll shut up now.    (4PM)

TARDIS, Collective Memory, and Meetings

Gerry Gleason taught me a new word today: TARDIS, which stands for Time And Relative Dimensions In Space. It was used in Doctor Who for time and space travel. It looks like a phone booth on the outside, but it’s got infinite space on the inside. It sounded to me like infinite closet space, a place where you might store all of your belongings and never look at them again.    (2G6)

My hard disk sometimes feels like a TARDIS, the Internet even moreso. In order to have Collective Memory, we need to have better indexing of this infinite closet space. And search engines are not the end all and be all of information organization. We need to constantly refactor and distill information, a manual process that helps learning and also helps us find things later.    (2G7)

With this in mind, here are some guidelines for high-performance meetings:    (2G8)

  • Always scribe in real-time on a Shared Display. After-the-fact minutes are better than nothing, but they’re not better than real-time distillations. It helps focus conversation, and it gives you an artifact to which you can refer later. These days, when I attend gatherings where no one is at the whiteboard, I start to squirm.    (2G9)
  • There needs to be a medium for building on relationships you make at a meeting. This could be as involved as a mailing list, and it could be as loose as an attendee list with contact information.    (2GA)

ChiliPLoP, Day 3

Last Thursday, my workshop met for a second day. Having agreed on a working definition for collaboration (see Collab:Collaboration), we started working on the Pattern Language. As was the case the previous day, I knew exactly what I wanted to accomplish, and I made that clear when we got started. What differed this day, however, was that Linda Rising, Ofra Homsky, and Joe Yoder — our three experienced Pattern Language authors — led the way in terms of process.    (1CT)

We began by laying out the index cards we had collected the previous day onto a table. The goal was to see what patterns we had and what seemed to be missing. The definition that we had collectively agreed on the day before helped us tremendously with this process. For example, because collaboration — as we defined it — required bounded goals, that meant there were patterns related to the start and end of the collaborative process. There were also patterns related to interaction (meetings for example) and knowledge exchange (Shared Display).    (1CU)

Mapping out our cards also helped us identify gateways to other Pattern Languages, such as Linda and Mary Lynn Manns‘s patterns for introducing new ideas into organizations, Ofra’s patterns for leadership, Jim Coplien and Neil Harrison‘s organizational patterns, and GivingSpace‘s patterns of uplift.    (1CV)

Lots of brainstorming and storytelling happened throughout. My favorite was a story that Joe Yoder told about a factory where he had previously worked, which literally left its financial books open on the factory floor. Anyone who worked at the company could examine the books and suggest improvements. The open books were a form of Think Out Loud that showed that the company treated its operations as a collaborative process involving all of its employees, regardless of position. Tremendously empowering stuff.    (1CW)

Linda, Ofra, and Joe constantly stressed the importance of iteration and cautioned Josh Rai and me about getting too caught up with formality too early in the process. Ever fearful of being berated by Ralph Johnson or Jim Coplien, I would periodically complain, “That name isn’t a noun phrase!” Fortunately, the rest of the group kept me on track. We had plenty of time to weed out and refine our patterns after the brainstorming process.    (1CX)

We ended our brainstorming at lunch, at which point we had 36 cards. After lunch, we picked two patterns — Collab:StoneSoup and Collab:KickOff — and Linda led us through a group pattern writing exercise. (I’ll say more about these two patterns when I describe Day 4.) She gave us a letter-sized piece of paper for each component of the Coplien Form (name, problem, context, forces, solution, rationale, resulting context, known uses, and related patterns). Each of us took one piece of paper, wrote down our ideas, then exchanged it with someone else for another piece of paper. The cycle continued until we all had our say to our satisfaction. Afterwards, we discussed what we had written.    (1CY)

This was the first time Linda had tried this particular exercise, and I think it worked very well. It was particularly good at helping us reach Shared Understanding. We all had slightly different views of both patterns. Actually going through the group writing process helped make these differences explicit, at which point we were able to talk through our differences.    (1CZ)

Because Josh and I were the pattern-writing newbies in the group, we each collected the sheets for one of the patterns and promised to combine, edit, and rewrite them into a readable draft. I chose Collab:StoneSoup; Josh took Collab:KickOff. The plan for Day 4 (which was only a half day) was to workshop our results.    (1D0)

I ended the day with a brief overview of how blogs and Wikis integrated with Backlinks could be used to tie stories with corresponding patterns.    (1D1)

Chili Beer    (1D2)

Since that night was our last in Carefree, I decided to organize a margarita BOF. Earlier, somebody had told us about the Satisfied Frog, a legendary Mexican restaurant and bar that had “a thousand different kinds of margaritas.” This was the obvious place to hold our BOF, so Josh, Jerry Michalski, Gerry Gleason, and I trekked on over.    (1D3)

As with most legends, the facts had been slightly exaggerated. The Satisfied Frog only served one kind of margarita, although in fairness, it did give us the option of frozen versus on-the-rocks and with or without salt.    (1D4)

The restaurant did, however, brew its own special beer — chili beer — which was bottled with a serrano chili pepper. It had a nice kick to it, but it wasn’t overpowering. I recommend it to those with a a penchant for adventure and a bit of a heat tolerance.    (1D5)