Dialogue based dictatorship

February 19, 2012 by Geir Berset in process, software, software design, teamwork No Comments » ()

We’re planning some major improvements to how our products are used. It so happened that one project triggered the other, and we’re left with about 6-9 projects (depending on how you group them) that needs to be coordinated in order to achieve the aims.

Coordination takes time from developers, so we have to find an effective solution. This is a short story on how we have proceded this far.

One person is in charge of overall coordination of all projects. This person is the program director (which happens to be me). My initial job was to write about the common motivation for all projects, and a little more specifically about each project. Just a few short sentences.

The next step was to appoint project leads for planning each project that had dependencies. Our principles for project leaders are simple.

We trust you. Go ahead, be a dictator, make decisions.

So, you start out with trust. Trust is good. We are a competent set of grown-ups. To keep this trust during the project, and to avoid any doubts and second guessing at the end of planning, we encourage the following process.

  • Listen to opinions. All perspectives are valuable. (Customers and co-workers alike) This means that you have to seek these opinions out early in the process, before establishing assumptions and making decisions.
  • Disregard opinions if you have to. If there is a very specific opinion that you’ll like to disregard, document the opinion and the reason why you disregard it.
  • Inform, but don’t stop and wait. No approvals needed, we trust you, remember?

Consider the figure below.

Think of each colored circle as an opinion. It’s a good quality that there are difference of opinions due to differing perspectives. (Completely overlapping circles signals group think, be alarmed, be very alarmed.) The area where all opinions overlap are the design by committee area. This is the crappy solution where no-one disagrees, but no-one is happy. Have no doubt about it, design by committee is what democracy looks like. It is safe and, it is steady, and slow, and populistic. It’s good for society, but bad for risky innovation. Democracy is modus operandi for many companies, and they’re usually stuck.

Then, there’s the workshop

Interrelated topics requires a lot of back-and-forth coordination, and a workshop is a great arena for resolving these issues, as well as exploring more opinions.

We’ve recently gathered at a workshop, and each project has presented their current planning status, and then proceeded to address open questions and dependencies. This requires a bit of going back and forth between topics, but at the end of the workshop (we spent 2 days), there has been so much information and clarification back and forth, that the project leads are able to go back to the drawing board, and make wise and informed dictatoral decisions for the final stages of the design and planning.

We expect the dictatorship part to work, as it relies on trust, and is time-boxed. You’re not a dictator for life, just per project. If you get corrupted by power, and ultimately lose the trust of your peers, you will not be able to lead future projects with any efficacy.

We expect some controversial areas in the final designs.

The figure below might represent the different forms of decision making:

We’re not done with these designs quite, yet. So let’s wait and see how this goes before we congratulate ourselves too much.

(And if you’re left thinking that the process described above is what good leadership is all about: listening, careful intellectual consideration, but also being able to make the best informed decision regardless of some unresolved controversies, then you’re right. Easier said then done, though.)


Thoughts on Program Managers

December 9, 2011 by Geir Berset in process, teamwork No Comments » ()

A good program manager (PM) is imperative for making really good software products.

In Toyota, they have this role of Chief Engineer. For those who don’t know, Toyota has been the fastest growing car company most of the time since the 1950′s, and apart from having technical excellence in their product, they credit a lot of this to the role of the Chief Engineers. The Chief Engineer is a guy that would embed himself with potential customers of the new design. If he were to design a car for carpenters, he’d put on his carpenter pants and get all carpenty. Usually he’d discover a lot of design details needed a carpenter. Stuff like double (or triple, or quadruple) coffee holders, a flat dash-board for throwing documents on and to write upon, doors that swing up really wide, to expose the sound system speakers to the outside workers, and so forth. Basically a lot of stuff an office rat, or a technical engineer wouldn’t dream of.

This approach, combined with the excellent technical quality and their unprecedented production effectiveness, created a lot of success for Toyota.

We’ve chosen the little more cheesy title “Program manager” for our Chief Engineers. We like cheesy, because it’s so cheesy. (Actually, people don’t like it).

With 7 people and 3 products, (Aptoma anno 2010) everybody is a PM. And everybody is a developer. And everybody is a janitor. And so on. The lines between developers, visionaries and managers are as blurry as they should and have to be. Everybody is taking turns doing anything, and this is part of the fun of being in a small company. Great stuff.

It doesn’t scale.

We’re now 13 people in Aptoma, 10 of which are developers (and we’re looking for more talent). With more customers and products, development and maintenance gets increasingly complex, both in coding and in managing. And so we need more focus time on development and on program management as two different, but mutually dependent, exercises.

We now have established formal program management for two of our products (front-page editing, and article- production and layout) and one for our elastic cloud services (streaming, hosting and video transcoding for the media industry).

What Does a Program Manager do?

In short, there are five main responsibilities to the PM.

  1. Serve as the customer advocate
  2. Write functional specs
  3. Keep track of progress
  4. Hold team reflections.
  5. Maintain road-map.
  6. Remove obstacles for the team.

How?

Seems so simple from the list above, but there is a lot to this role.

1. Serve as the customer advocate. In order to serve as the customer advocate, you need a lot of information about what to advocate. You need to talk to users, you need to empathically understand them, and you need to dear to expose yourself to irritated users having problems. And you get to talk to those that are really, really happy and has had the time to reflect and envision new stuff. We aim to do this a lot for the same reasons that the Chief Engineer do in Toyota. This can be done by checking in at the customer, and saying “what’s up!”. Sounds easy, but the tricky part of this is that if you have a crappy product, they’ll only tell you about how crappy your product is. So get your bug-list to zero first. As such, the PM has to coordinate input from various sources, and streamline this information to use it to advocate the customer needs to the rest of the dev-team.

2. … and that’s where the functional spec comes in. Based on the deep understanding of customer needs, the feedback from support, from developers, from just about anyone with a stake in your product, the PM will propose changes, often through a written functional spec. The functional spec will describe an idea for improvement or extension to the product. If the functional spec contains wire-frames (in HTML, or just drawings) it can even be tested on potential users for early feedback.

3/4. Keep track on progress, and hold reflections. Once you say GO to a great development team, they will go into ‘get-shit-done-mode’, and won’t stand for any interruptions. That’s why the PM is keeping noise away from the team by being the customer proxy, gathering input, writing the next functional spec in parallel. And if anyone is to know anything about what is going on, someone must have the job of saying “Hey! How are things going?” and “Hey! Do you have what you need?”. Developers in ‘get-shit-done-mode’, will first bite your hand off, but everybody appreciates to pause and reflect from time to time, and to be able to report achievements.

5. Maintain roadmap. This is the wet dream for every bureaucrat. The internal road-map needs to contain information about technical challenges, resource availability, timing, deadlines, suggested and affirmed projects and so forth. Someone needs to coordinate all this. Presto!, the PM is there to help.

So how did anyone in Aptoma find the time for all of this when we didn’t have formal PMs? They didn’t. But these things just kind of works, to a point, when the company is small. We’ve exceeded this limit now, and this, our first small step towards dev-teams’ separation of concern is here.

6. Remove obstacles. The PM will, by nature of the role, gain overview of the work flow, and during reflections get insight into obstacles that are holding the team back. This can be recurring problems, communication challenges, and so forth. The PM will work to remove such obstacles, to make work flow smoothly.

Possible challenges

Boring maturity. We have to fine-tune this role for it not to become a boring formal meeting process. And we need to acknowledge that we’re not Toyota. Yet. We’re still a very small company, and a lot of people do a lot of different stuff. A job description any cleaner than your average pile of laundry still does not exist at 13 employees.

Conflict of interest. There’s been internal developer outcry for PMs for the last few months. And as expectations are high, it might be natural to think of a PM as a silver bullet “Ah, nice, here comes someone to do all stuff that is boring to me, so I can do only the fun parts. Woho!”. Chances are, however, that some work is fun for both PMs and developers. As such, fun vs. boring is not a well defined separation of concern. For separation of roles to work, one has to consider intellectually (what works, and what does not), as opposed to just consider emotionally what belongs where. The goal is better software and services for our customers, we must keep in mind.

Loss of agility. If the PM (the bureaucrat that he is) goes all-in on on functional specs, and basically tries to solve the entire problem of creating new functionality/products there, this might lead to over-planning causing unnecessary delays and loss of agility, innovation and flexibility. Knowing programmers quite well, I’m quite sure he’ll get a friendly (or even hostile) kick in the butt if this occurs.

Expected Benefits

  1. More time for developers to focus on development.
  2. Deeper empathical understanding of our customers needs.
  3. Better and more holistic planning; one guy gets access to all the input and sees the whole picture.
  4. Better coordination to strategy; PMs will report to the director, which makes it easier to provide feedback on direction, and to fine tune strategy.

What We Aim to Preserve

  1. The autonomy of teams; As the director gets higher quality reports, and as planning gets well managed, it might be tempting for top management to mingle more and leave less decisions to the team. This can be harmful.
  2. Developer ownership of ideas; The point of program management is not to shield the dev-team completely from information and customer concerns, but to structure and wisely involve at the right time. It’s a balancing act.
  3. A peer team-structure; PMs don’t need ties. They’re embedded in the team. Authority comes from professional and personal qualities, not from formalities.

PS! I say “he” not because we don’t think women can be great developers or PMs, but because this is a note about us. All PMs and developers are still men in this hot dog shop. Don’t let that scare you from contacting us, if you’re a woman.


Company self-examination

February 19, 2011 by Geir Berset in process, teamwork 2 Comments » ()

This week we gathered the entire company (first time, ever) for a couple of strategy sessions. We ended up doing a lot of reflective exercises, talking a lot about how we work. Below are the results.

Identifying our own weaknesses

Reflections were very open hearted, which made it a very useful exercise.

Not enough “slack” in the system

This surfaced as a root cause for many of the negative caracteristics we were able to find about ourselves. We’re always pressured for progress on all fronts, by customers, by our own ambitions and by the need for more revenue to keep going. And even though this tension between where we are and where we’d like to be drives us forward at breakneck speeds, it does have some negative side-effects.

a) “Sharpening the saw” Not enough time is spend educating ourselves.
b) Sharing: It feels like disturbing each other when we need to get help or want to share.
c) At times, lack of slack limits our capacity to jump straight onto new important challenges.

Solutions to this problem are many. In many ways it’s a management problem. But solutions rarly have only one single solution. As the management problem might have schrunk in the past years, the culture for pushing the limits of the machinery is there still.

We need to

  • Take the time needed to sharpen the saw. You don’t get more time, you take it.
  • Drop projects that are not core business.
  • Be clear on when we are available, and when we’re not.
  • Insist stronger to hand over projects to customers’ internal development teams.
  • Hire more people.

And please note that the problem is one of ambition, not of sloppiness — we’re not working hard due to excessive amounts of bugs. We’re out there pushing forward.

Not enough sharing between projects

Lack of sharing is not always a problem. (Creating shared dependencies between products can be very limiting to innovation. Google’s Eric Scmhidt knows this, as he recently was quoted “I learned a long time ago, don’t try to force technology to be merged.” And thus independency is a strength, too) However, there are ways to increase sharing and still keep the benefit higher than the cost.

We’re always on the lookout for ways to share code and technology without creating limiting dependencies. We’ve had several unsuccesful attempts at this in the past, but we’re getting better. We’re a bit concerned that we’ve been scared by our earlier failures, but we’ve now made a concious decision to keep up the dialogue of a possible “loosely coupled” sharing architecture.

We have a lot to benefit from more knowledge sharing, though. Learning more about “who knows what about what” we believe will enable us to improve our ability to pull knowledge when needed. Combined with fixing the “lack of slack”-problem above, we hope that this will trigger many an interesting conversation in the time to come.

We’re forcing ourselves to share more information such as “I’m going to be working on caching technologies for the next two weeks. Let me know if you have anything to share.” and then to be sharing the results findings in each projects regularly (i.e. every two months in an interactive whiteboard-session)

Our web-site stinks

Being quite proud of our individual and collective capabilities, we like to think of ourselves as a Ferrari-engine inside a Volkswagen. Thus it’s time to do something serious about the way we present ourselves. That does not mean that you’ll be seeing us coding in suits any time soon, but we’ll definitely have to do something about our web-site. We’re currently on the lookout for graphical designers that can understand our business and help with design and profiling. Let us know if you have any tips. Pimp my http://aptoma.com. We need it.

Other caracteristics

As you can see we’re more interested in what we can improve, than what we’re good at already, and we do think we’re a bit hard on ourselves. Some caracteristics have negative side-effects, and some have positive, but most have both positive and negative aspects. Below are some caracteristics with good side-effects, with a few ones with negative side-effects thrown in for good measure.

  • We’re sometimes a bit hard on ourselves.
  • We’re very agile – Customers not accustomed to our style sometimes find that this makes us seem unpredictable — we’re not commiting for distant detailed roadmaps, as we’re adapting to the ever changing future as it unfolds. We see this as a strenght, and customers tend to do so, too, when they’ve seen us in action for a while.
  • We like doing everything ourselves – You don’t have to look further than our web-site to understand that this is not always good. We learn a lot from coding our own sites, frameworks and tools, but sometimes the time has come to admit that we have learned enough and should move on to build on other’s work.
  • We’re very focussed – Focussing means saying no to something. Customers don’t always love this. But we didn’t forget or ignore you, we just focussed on something more important for the time being. It’s our job to care for customer needs in the long-haul, also. When we get to your problem, it will also get our undivided attention.
  • We don’t communicate enough internally.
  • We think that exposing ourselves to customer feedback is a strenght, but sometimes it becomes too much and it ends up limiting our work.
  • We’re very clear on what we value in our software: maintainability, usability/productivity and performance.
  • We’re good at creating cheap proof of concepts before we solidify into production code, but sometimes we move on too fast which creates a bit more technical debt than necessary. But we’re very concious about our technical debt, and we have a track record for paying it down before it is too late.

During these strategy sessions we also spent a great deal of time talking about the future of large scale new media publishing, and our role in it. We’re very grateful and excited about our increasing opportunity to play an important role in the way ahead for innovative new media publishers.

And, oh, there’s one solution to all the problems here that we have yet to discuss. We could hire you and put your great skills to good use. Join us in our relentless quest for personal and collective productivity.


3 More Industry Problems

October 31, 2010 by Geir Berset in process, teamwork 5 Comments » ()

Today I read an excellent and, as always, emotional journal paper by Tom Gilb — the measure guy of software — entitled “What’s Wrong with Requirements Specifications? An Analysis of the Fundamental Failings of Conventional Thinking about Software Requirements, and Some Suggestions for Getting it Right“. (Download PDF)

It got me thinking (once again) about all that is wrong with the software industry. I now have even more to report. Everywhere I look, I see a mess. It is important to acknowledge that the industry is in its infancy. Acknowledging this, you can confidently and profitably dedicate a lot of time to work on the system, not just in the system. Because the system is broken by default, and will remain so for many decades to come, I believe.

3 Industry Problems

1. Requirements are not well defined. The main problem, as I see it, is that we’re mixing means and ends, as Gilb puts it. We’re talking too much about what we want, and not so much the background for that wish, which is what we should be specifying. If we know why you want something (i.e. business strategy, broken into objectives), we can use our experience to devise better solutions. Gilb proceeds to explain how to quantify and measure requirements. He’s right to say that we should, but he’s just way ahead of us, and we need to fix the way we specify requirements before we can start measuring anything. His point remains valid.

2. Factory organization – Separated and specialized functional units passing work between them in a large, efficient factory organization is doomed to fail (planning & specification, design, coding, QA, bugfixing). Such disregard for tacit knowledge and basic motivational psychology should not exist. Economies of scale in development (and services) is a myth. This has been tested and has failed horribly (think waterfall). It still happens all the time, and in many industries, not just the software industry. Probably also where you are right now. The closest metaphor I can think of is a kindergarden separated into “baby-feeders”, “diaper changers” and “comforters” etc. Think holistically — the real value delivered in in a kindergarden are not merely the practical operations. By contrast it is the safety and relationship developed with a few adults that the child will value.

3. Budgeting – Budgeting is usually a waterfall process in disguise. Budgeting was a tool developed for manufacturing, and should have remained so. But, to a carpenter, every problem looks like a nail, and so budgets are for manufacturing, service organizations and even product development companies. We’re not in manufacturing. Don’t adapt their tools. And, yes, this includes the Toyota Production System. Watch out, they’ll make you decide in your budgets what to do for the next year, and hold you to your promises. They’ll even scientifically measure this. Budgets forces you to spend the best part of each autumn guessing and assuming while you really should be out there gaining knowledge about emergent challenges, and adapting to them. Time is scarce — don’t waste it budgeting.

What does the Industry Think are the Solutions?

  1. Start XP/Scrum/Lean-teams
  2. Start XP/Scrum/Lean-teams
  3. Start XP/Scrum/Lean-teams

John Seddon says it well when he states that everything needs to be projects and tools for us westeners. “Toolheads”, he calls us. I believe he’s got a point. Even Lean, originally The Toyota System, has been subsumed into tools and projects. Every organization has got a lean manager, or a lean team these days — fixing problems functional department by functional department (oh, the irony) by introducing some tools and running some projects, and then moving on. An A3-reporting there, a daily scrum here, a pull system there, 80% code coverage over there, and so it goes. Basically they are piling new tools and projects onto a broken framework, instead of building the capacity to change the system from the inside by getting managers out there, getting knowledge, working on the system. Get away from budgets, spreadsheets, resource plans and other guesswork – get knowledge and let’s use it to improve the way we work.

The current industry solutions only have us doing the wrong thing better. There’s nothing more wasteful than doing well what should not be done at all.

What are the Real Solutions?

We need to acknowledge that the way work is organized is broken and start addressing it from the core. What makes this challenging, is that the entire organization needs to be in on this, not just the lean tools team or the new empowered Scrum team. These teams are usually not empowered to change the system. Start by getting that power. Talk to your management. Talk to your CEO. Be patient. Discuss. Elaborate. Start small, but do it every day.

You need to design your organization towards challenges (think in terms of what you are solving for your customers, and design against that), rather than just defaulting to functional departments with their meaningless budgets and policies.

This means organizing in cross-functional teams empowered to change the way work is done, with management as a support function embedded into the work. Everyone’s goal becomes to establish good flow in how we solve real problems for real customers in the most effective way possible.

This is when magic starts to happen, and the fun kicks in. Solving a real problem for a real customer, and actually being there to witness it, is motivating and stimulating. Communicating directly and related to real challenges, not just via plans, sprint-/project backlogs, meetings, reports, Gantt charts and budgets.

Freed from this burden we can spend time improving the way we work, just a little, but every single day. It’s really quite simple. It’s fun. It’s motivating. And not the least, it is very, very profitable. And it is sustainable. It scales.

No more factories with human cogs, no more economies of scale. We all want to be a linchpin. We need economies of flow.

Anyway, this is how we’re designing our organization, and it seems to work very well. Come to us and take part of this journey. We’re hiring in Oslo and Gothenburg. (Follow the author @geirber or the company @aptoma on twitter, or through RSS)

References

  1. Why Do We Believe in Economy of Scale? Article on Bryce Harrison inc.
  2. Linchpin – Book by Seth Godin, inspired by the same factory problem
  3. 3 Major Problems with the Software Industry (Select *)
  4. The surprising truth about what motivates us (YouTube)
  5. What’s Wrong with Requirements Specifications (PDF)
  6. Cultural Change is Free (John Seddon on Vimeo video)
  7. Systems Thinking (Dry, but good, Wikipedia stuff)
  8. Rethinking Lean service (Entertaining Podcast)
  9. Economies of scale – It’s a myth (Entertaining Podcast)

Work For Us

August 18, 2010 by Geir Berset in Uncategorized No Comments » ()

We are very proud to announce that @rudolfrck will be joining us as of 1st of October 2010.

And, we are still hiring in Gothenburg and Oslo.

We are looking for talented and hard-working developers with the desire to be a part of what we are trying to create. We develop software products for the new media, and we deliver services related to those products. All of which we are doing in order to help our customers tell their rich stories and to be profitable.

Our primary focus is usability and performance. We rely heavily on free and open source software (FOSS).

Read more about the career opportunities at our web-pages.

Please drop me a mail at geir@aptoma.com if you have any questions for me before deciding whether to apply for the position.


Limit Work to Capacity

April 22, 2010 by Geir Berset in Monday School, process, teamwork No Comments » ()

Hard work does not pay off. At least not if your ultimate goal is to improve at what you do. And not if what you do is quality product development.

In that case you need to build in slack for learning into the system. You want everyone to have time for sharing, improving and learning continuously, and you want to be able to come home from work with energy to pursue your goals for personal skill development even further.

It’s great fun to be good at what you choose to spend your life doing.

Since the primary raw materials in software product development are skills and intellect, rapid learning is the prime goal and the capital for product development. Fail to invest in raw materials for your business, and you’ll soon run out of stock. Don’t allow for time to learn, rather, require it.

Running a system at 100% yields all sorts of problems.

Symptoms include

  • You stop talking to each other. “Sorry, can’t help, have to go do this thing that is  really urgent”
  • You start building technical debt. “If I just skip to write that test (it’s really hard to write), then I can save 2 hours today to get to the next thing I have to do.”
  • Shallow bug-fixing. “Need to fix this bug real fast, in order to get the other 4 bugs done, too! No time for digging further” Root cause analysis and regression testing get skimped on.
  • Useful, although sometimes inconclusive and somewhat directionless, discussions plainly stops happening.
  • Stress activates your lizard brain, which numbs the rational being. You are in survival mode.
  • Work gets less inspiring and fun, which slows things down. Inspiration is high-octane fuel.
  • People get exhausted, and energy-level is low during, and after work hours. You need to “relax” on Facebook at work and in front of the TV at home, instead of doing inspirational learning.

(Picture from Wikimedia commons)

If you have trouble grasping the concept, picture a congested highway. If you remove a small percentage of the cars, you get a magnitude of improvement in throughput and speed. This is a fact.

Did you ever try to squeeze a washing machine 100% full? No clothes get cleaned. Remove 10 or 20% of the clothes, and you have a winner.

Don’t maximize utilization.
Build in time for learning, improving and sharing.

If you, as we have been, find yourself in this mess. There are several ways to get out of it.

  1. Say no. If you never say no, you don’t have a strategy — say no to the least important stuff. Saying no is hard, scary and extremely useful.
  2. If you work for a consultancy firm, give up. Incentives for maximizing utilization is too high in consultancy companies, as they get paid for “productive hours” only. Quit your job, and go to work in a product development company, or a skilled in-house team. Anything but most consultancy firms, they will cannibalize you.
  3. Scale up capacity to meet demand. What can I say, we are hiring.

Quantified

This is no science, but if I would be forced to put some numbers on this, I’d say that:

  • Build in approximately 20% learning/sharing time during normal work hours. Yes, that’s one whole day a week. We use it for our monday school, impulsive discussions, reading, friday meeting (our arena for general discussions on processes) and blogging, to mention some activities.
  • If you want, you can probably “work” 60 hours a week or more without any danger of burning out, but only as long as that time is spent balanced and having fun, learning and improving/being productive — and only if personal situation allows for it without sacrificing time spent on other important values, like your kids.
  • Don’t build overtime into your standard operating procedures. Required overtime doing “productive” work should be the rare exception, not the default.

Find a sustainable pace where you are balancing learning, improving, being productive and all of the time having fun. That’s an important ingredient in the recipe for success.

By the way, did I mention that we’re hiring or that we’re hiring?


Automated Unit Testing for JavaScript

March 3, 2010 by Patrik Henningsson in Monday School 3 Comments » ()

In our work towards Continuous Deployment and an improved approach to JavaScript we are missing one very important thing – automated unit testing for JavaScript. Currently we have have some tests written in TestCase that will run in the browser. But we need away to automate this without the need of a browser so we have started to look at some alternatives.

The solution we’re currently playing around with is Rhino + Env.js + QUnit.

Rhino is a JavaScript implementation written in Java and you can run it in a terminal, which harmonize with our aim for automation.

Env.js is a DOM implementation written entirely in JavaScript and will simulate the basic functions of a browser.

QUnit is simply the framework for the unit tests.

So far it looks very promising and it looks like we can do much of our testing in this environment. We will post more of our discoveries here later when we have done more testing, so stay tuned or follow me on twitter (@pahen).


A first look at JavaScript Frameworks

February 22, 2010 by Michael Plikk in Monday School 5 Comments » ()

In our discussion today about Javascript frameworks we finally came to a conclusion, of sort, regarding when to use frameworks.

In back office applications we can use whatever framework we want. It is used by a small number of people and we have total control over possible dependencies and namespace collisions, so we do not have to worry about breaking other people’s stuff.

When we create code that is going to be included on another web page it is a completely different story. In those cases our goal will be to create code that does not require a framework, so we avoid polluting the requiring site with our dependencies. It might not always be possible to achieve this, but it is a noble goal at least.

We have been using Prototype for most of our work so far. On smaller projects we have started to dabble a bit in JQuery and YUI. The next time we do any major JavaScript development we will explore the options they give us.

The major reasons for moving away from Prototype is the huge size of the library, and numerous changes it makes to basic JavaScript objects. A lot of the changes are good and make for easier code development, but they don’t really feel like proper JavaScript. Instead they rely too much on magical functions and the forced object oriented coding style that Prototype enforces.

We also find that Prototype (and Scriptaculous) are lacking in regards to their option for “plugins”, like calendar- or graph-plugins. Either Scriptaculous have a solution built in, or there are very few good alternatives. Both JQuery and YUI seem to have better communities surrounding them that develop better, and more, plugins that might suit our needs.

The little experience we have with JQuery so far indicates that it is very DOM-centred. This is both a boon and a bane; we loose some of the power we might have gotten used to in Prototype, but it might help us creating purer JavaScript for code in the areas that do not touch on the DOM. This is a goal we have since we want to make all of our JavaScript code testable, and it is much easier to test code that only manipulate data and do not touch the DOM.

Another option in regards to plugins that we are going to look into is ExtJS. The GUI elements that they offer seem to be very powerful, and using pre-built items would save us a lot of time. The pitfall that we saw was that overuse of the items they supply might make the application look too much like a desktop application. Since we are developing for the web we should be careful to not draw too much inspiration from the desktop, they are different media and require different solutions.


No Scrum, No More

February 11, 2010 by Geir Berset in process, teamwork 23 Comments » ()

After listening to Olve Maudal at the Lean Meetup in Oslo yesterday, and after reading some of his tweets today (@olvemaudal) I realized that we never informed our readers that we are not doing Scrum anymore. I don’t think we have for 9 months or more. We were quite elaborate, if not evangelical, about our experiments with it here on this blog, so I figured it’s over due to let you know.

It’s official: We’re not doing Scrum anymore.

I will take the time to elaborate on why, and I’ll reflect on what we’ve learned from our experiences.

Why are we not scrumming?

The shortlist:

  1. Iterations were too long – It would sometimes feel like a waterfall in miniature. Reality for most development teams is that circumstances change constantly, and developing the capacity to adapt to these changes are more important than planning iterations carefully, which is just a form of guesswork.
  2. Too much overhead – Sprint planning felt a bit forced. We had to decide what to do for days or weeks to come, and ended up with requirements churn. Beyond a certain point during planning, we went into congestion, and stopped caring about the details.
  3. Our sprints are too diverse – Sprint goals ended up  so diverse sometimes that we ended up more often than not with the sprint goal of “Finish all tasks” which was a quite uninspiring goal. (We tried very hard to create good sprint goals)
  4. Demos not often enough – We need to show off the feature we just made right now, not in 14 or 30 days at the demo. That is way to late for us. Demoing should be an integral part of each feature or improvement you make. You need to be close to, and intimate, with real users. If we had investors or any other formal committee of sponsors that needed to approve everything we did, we would see the use of such “demo roundups” at regular intervals.
  5. Too long release cycles – The scrum process batches a lot of changes, improvements, bugfixes and new features into periodical releases. We are working on continuous deployment with a steady stream of product improvements, which allows for more predictable releases and better fail-tolerance.
  6. “Scrum is just the easy parts of XP”  – It’s a quote from Kent Beck, although he does not like to be quoted on that one. This is why most are doing Scrum in combination with XP of course. I think you in many cases are better off with XP without Scrum, but that’s another story. We’re not doing XP in its purest form, either. Even though XP has much stricter coding practices, XP also has its limitations. The lean startup movement (which Kent Beck himself seems to be quite interested in) complements the weaker parts of XP — the customer feedback part, especially in the initial phases of product development.

You might see a pattern here: We’re still doing most, or all, scrum practices, just more often and in smaller chunks. This brings us closer to Lean.

What did we learn from it?

You should have a Product Backlog, and it should be a very simple sortable list. The emphasis should be on keeping it short, however. A long list of features becomes an administrative overhead. We found ourselves sifting through much of the same tasks from sprint planning to sprint planning. Too much got captured in the sprint backlog. We are still using product backlogs actively.

You should hold sprint planning meetings. The problem with the scrum-format of it is that it has more emphasis on creating a plan up front (i.e. the waterfall comparison), than it has on the planning itself. If planning is a monthly activity (or bi-weekly, or whatever your sprint length is in scrum), you end up reading your plan more than you spend time planning. We find that planning is at its best a continuous, on demand, activity. Do more of it, often, but in smaller chunks, and keep less of it lying around. I will have to agree with the Dwight on this one : Plans are nothing; planning is everything.

Daily scrums solves a non-existing problem – I’m sure that it is not hard to find team that would benefit from daily scrums. If you are such a team, chances are you are not communicating enough. We find that by hanging out on the project IRC-channel doing continuous micro-coordination and sharing information, and by hooking up on Skype to discuss challenges and problems on-screen as they arise we have nothing left to coordinate or discuss on the daily scrums. Everyone is in the loop on what is happening.

Retrospects are pure beauty. Again, the problem with scrum for us is not that it is has bad practices (it has the best of practices, actually). The problem is that it is performed to seldom to have the desired effect. Retrospect is not an activity, it is a mindset, and has to permeate everything you do, and should be done on a continuous basis. Ask these questions about every little project, task and experiment you run. What went well? What could be better? What will I focus on improving? It’s key to learning, and learning is essential.

Under what circumstances would we consider scrum?

If we ever find ourselves in a multi-team environment with quite large teams (5-10 per team), with sponsors that needed formal updates and demos, we would be sure to consider both scrums and scrum of scrums.

So, was all our Scrumming just a waste of time?

No way. It was a learning experience.

Never forget this: There is no silver bullet. You should try different stuff, be critical and analytical in the process, ask why to just about everything, and you will learn a lot. Shed each practice that fails to materialize into concrete value for your development process. In the end, no process formalities will save you, your diverse experience will.

What will we do differently?

We will continue to draw inspiration from Scrum, Lean, XP, Lean Startup, Customer Development, Continuous Deployment, etc. But instead of changing ourselves to fit the process (as was much the case with our scrum-efforts), we will look at the core of their ideas, extract their essence and see how they could apply to our existing and intuitive way of doing things;

If being a keen student of processes and development theory has taught us only one thing, it is that we should trust our gut feeling, our sense of what is purposeful and what is common sense, and that most of our current practices are worth keeping, and improving.

I advise you to try to improve the quality of how your team already, and intuitively go about doing the work. Do not change the way you work entirely in an attempt to magically achieve quality and speed. This way you can better preserve what you already got figured out, and at the same time be improving continuously.

In plain words, what are we doing now?

We still do a lot of the scrum practices. We just do them more often, and in smaller chunks. You might even say continuously, to some extent. We have learned to cherish planning over plans, and a retrospective mindset over bi-weekly formal retrospects. We write less plans, we take less notes. Communication flows more freely instead of formally in batches.

We get more done, and with increased quality, and we also have Scrum to thank for it, but definitely not only Scrum.

One of our biggest ongoing project nowadays is our establishment of Continuous Deployment practices, and all the discipline that goes with such a strategy. (It requires some coordination when you have servers deployed all over Europe, as we do) You will need to optimize the entire value stream to achieve this. We’ll keep you posted on how it evolves, and the benefits our customers and we reap from it.


JavaScript: Tools, Coding Standard and Guidelines

February 8, 2010 by Geir Berset in coding, Monday School 1 Comment » ()

We’re currently devoting an hour each Monday to collectively work our way through JavaScript. Our aim is to point to the key areas of interest and improvement, and to dig into each area one by one.

We are maintaining a TOC for our JS-discussions here.

Development Tools

Firebug is the most important development tool for us, without comparison. Everyone is familiar with this time-tested tool.

You will rarely need more than Firebug, although there are some valid alternatives now, in 2010. Chrome, Safari and Opera (Dragonfly) have all internal tools for debugging (and more). None of us have used those tools extensively, so we don’t know more than what we have heard from third parties, which is mostly positive. If you need to spot errors in IE, Microsoft Script Debugger is your best hope. IE8 ships with this integrated as default. No-one in our team reported ever making use of the Firebug Light for IE.

When it comes to JavaScript editors, we find that no text editor seems to differ significantly from the rest. Most editors provide color-formatting, some provide API-reference with autocompletion and some editors like vim and TextMate can be configured for auto-validation through JSLint.

Coding Standard

Our coding standard for JavaScript builds on our own internal PHP Coding standard as far as it fits, which in turn builds on the publicly available Zend Framework Coding standard.

We have boiled our standard down to this shortlist.

  • Follow the Zend Framework Coding standard
  • Use an underscore in front of private objects. (i.e. var _private = 0;) Private objects and methods can be defined as «trusted» with everything else foreign and error-prone. This can make your core more stable and rigid without having to overdo it with data-testing and integrity validation.

It is possible to achieve a private scope in JavaScript, but it comes at a cost in complexity, and we have decided against it. Our decision is based on experience and advice given in “Pro Javascript Design Patterns“.

/**
 * Rationale and short description of ClassName.
 */
var objectName = {
    myFunction: function(whatToDo)
    {
        if (typeof whatToDo === 'string' && whatTodo.length > 0) {
            objectName._doWhatYouGottaDo(whatToDo);
        }
    },
    _doWhatYouGottaDo: function(whatToDo) {
      // As this is a private function, I trust the type and data validity of the argument
      alert(whatToDo);
   }
};

The above is a minimal example, which in no way covers all the rules accurately.

Guidelines

Global scope. Put as little garbage as possible in the global scope. Use well-named objects as namespaces and if needed sub-namespaces. Know the results of using or skipping “var” when creating objects.

Use closures, with care! Closures are necessary in JavaScript, but as not all languages have them, they will to an inexperienced JS-programmer look too much like Magic(TM), which isn’t too good. Use good judgement when to use them, and  remember good inline commenting to make the magic more transparent.

Don’t use the “new” operator. When setting up prototype inheritance it has to be used, but there are no other cases where it should be used. In most cases it’s not only slow, but the alternatives are often easier to understand, require less code and are more powerfull. Because of this, we have decided to conform on code without new. As examples, new Array and new Object should be written as [] and {}.

Prototype inheritance contains power for object oriented code. We will return with more guidelines when our experience grow. We must admit not to have used this elaborately. A serious liability of PrototypeJS (the framework we used) is that it overrides prototype (the language feature) from JavaScript.

Few anonymous functions. As a rule of thumb, we say: name functions. This has to do with testability and readability of your code. The exception is if you need a “one-liner” to use just once, in which case anonymous functions are OK. You would normally not test these kind of functions.

Lint your code! Lint is a code quality tool, and it will hurt your feelings. But  that pain is just Douglas Crockford stabbing the parts of you responsible for writing bad JavaScript. You end up stronger in the end.

Recommended research material

JavaScript requires effort on your behalf. You need to do the homework if you want to be a powerful and successful JavaScript developer. For starters we recommend these resources: