The whole company “Agile”?

January 4th, 2010

Last month while I was discussing with my friend Siraj we started to ask ourselves why the Agile “philosophy” doesn’t get popular in the whole company. What I mean is that nowadays it’s kind of easy to find the software/product development department of companies using Agile methodologies, but what else is missing or needed to the Human Resources, Marketing, Finance, Administration, Sales and every other departments join this movement?

When you start with Agile development, not only the software development process changes but many other things related to how your company works. For instance, it’s very difficult to think about an Agile team that will succeed with “command-and-control” management. The teams are self-managed, which implies a different style of management. Instead of bosses that keep asking for things done, we have servant leaders which provide all possible resources so that their teams can work and make decisions. The base of the pyramid begins to make decisions and not the top anymore, because they have the best work knowledge and therefore are the most suitable to do it. In some extreme cases in modern companies like Semco, the very employees are the ones who hire their managers.

That is, when we talk about agile methods, even though we are referring to the Agile software development methods, there are a lot of other concepts and philosophies that we are implicitly talking about (because they are very closely related).

I have an example to better explain where I want to go with this. I once worked for a company of reasonable size that, like many others of this size, had a traditional Human Resources department. One day I had a problem and needed urgent assistance from the HR staff. When I talked to them, two bad things happened. First, they treated me badly and like if they were doing a favor to me. Second, they said that my request would be met only in a few days because they had many important things to do first. What was happening was that my daughter was very sick, I had a problem with my health insurance and they were not willing to approve my daughter’s appointment with a doctor. A HR team with the “agile culture” would know in first place that since I am their main “user”, I deserve attention, respect and my problems are their problems. The emergencies of their users should be more important than any paperwork they have to do. And second, even though their backlog was abnormally large, a case with such severity should certainty jump the queue.

So when I say that other departments of companies could be “agile”, I am not suggesting that they work with Agile software development – which would make no sense – but that they use the same concepts of leadership, self-organizing teams working in a participatory environment, based on trust and cooperation, making a better effort to understand who are their “users” and what are their needs, create visions for their products and departments (that would help them make better decisions) and so on.

Getting this HR department above to speak up as an example, wouldn’t it be perfectly acceptable for them to do a personas exercise to discover what is the profile and the characteristics of their users? Wouldn’t it be great if they did chartering sessions, discussed their values, made retrospectives to discover how to improve their process and so on? Imagine how transparent and organized would be if the HR team had a big Kanban board in their room showing the activities, progress and their bottlenecks?

I think that this may not happen because much of the material and examples available on these subjects nowadays are formatted for people related to software development. Yes, there are books such as those of Ricardo Semler who are categorized in bookstores as “Business”, but I don’t see much business people really interested in these subjects. Why is that?

It’s time to finish with this “fork” between companies’ agile communities and the other departments. In Agile adoptions we frequently see after some time two totally different companies working within one. We must bring people from other areas and other hierarchical levels to the conferences and our world and show them these ideas. I will love the day that it will be possible to go to an Agile Conference and talk not only to software people but also HR managers, VPs of Marketing and other guys who are not in the development department; or else when we can find in user group meetings not only the “agilists” but also managers, human resources analysts, accountants and so on.

And now, where do we start?

Dev in Rio 2009, a great software development conference in Rio de Janeiro!

December 4th, 2009

Even though it was conceived, planned and executed in a little bit more than 20 days, Dev in Rio 2009 was awesome, a huge success! We had around 400 people at the SulAmerica Conventions Center in my home town Rio de Janeiro talking about software development, programming at the Coding Dojo and having a lot of fun in a whole day of presentations that ended in the biggest #Horaextra ever. “Hora extra” (which means “Overtime”) is the name of our weekly meeting where the nerds hang out together to drink and have a nice chat about geek stuff.

Dev Rio in 2009 started at the scheduled time when me and my friend Henrique Bastos (the creators of the conference) opened the event with a quick presentation and thanking our sponsors, supporters, communities and friends who helped us a lot more than you can imagine.

Dev in Rio 2009 - Abertura
* Henrique Bastos and me at the Dev in Rio opening.

To begin the day, we started the two tracks of Dev in Rio 2009. At the main auditorium we had the scheduled lectures while in the foyer we had the Coding Dojo.

Coding Dojo is a programming arena that was organized by the Dojo Rio folks in partnership with Dojo@SP. The idea is to work on simple and novelty problems, using programming techniques like Test-Driven Development and SOLID principles. This was definitely the best surprise we had in the day – the Dojo went much better than we could ever imagine (except that the Java Dojo wasn’t much popular, I have to admit).

Dev in Rio 2009 - Coding Dojo
* Coding Dojo at Dev in Rio: 3 meters of code on the wall!

Dev in Rio 2009 - Coding Dojo
* People participating at Dev in Rio’s Coding Dojo.

The first talk of the day was given by Ryan Ozymek, that entered the stage with his famous penguin to talk about his experience with open source software and the Joomla! community. He detailed how a big software development community works and gave his entrepreneur vision about how to use open source software to leverage businesses.

After that, Guilherme Silveira and Nico Steppat talked about a very controversial theme: Is Java dead? They addressed the fact that there are many things beyond the language in the Java universe and that despite the language is “expiring” the JVM can still be very useful.

After lunch, Fabio Akita gave no respite for anyone who was sleepy and did an excellent presentation on the Ruby on Rails ecosystem, with excellent videos, screen casts and quite information beyond the code. He doesn’t know but he took away the breath of the simultaneous translation girls!

Continuing, the (almost carioca) Jacob Kaplan-Moss made his presentation on Django, that he calls “the web framework for perfectionists with deadlines”, developed in Python. He spoke about the concepts and values that guided the development of the project and showed a bit of code to give the audience an idea of how to use the basics of Django.

The last presentation of the day was given by Jeff Patton, that talked about product development with Agile methods. Using as a narrative the story of a project carried out in conjunction with Obie Fernandez, several common problems in software development (and their solutions) have been addressed.

In the end, our great friend Vinicius Manhães Teles led an interesting conversation between speakers, communities and the audience. We had the impression that if we didn’t control the time, the conversation would have taken hours and hours because there were a lot of interesting subjects and questions. The audience took a great deal and we had interesting topics like entrepreneurship and controversial as the stupid regulation law of the systems analyst profession proposed by the Brazilian government (in Portuguese only).

Dev in Rio 2009 - Discussion
* Discussion led by Vinicius Teles. And before anybody asks, no, that one on the picture is not Adam Savage from MythBusters, it’s Jeff Patton.

While all these things were happening, me, Henrique, Gustavo Guanabara and Flavia Freire (Arteccom’s journalist) spent the day recording a huge podcast of the event, interviewing staff and filming the scenes. We have talked with the speakers, sponsors and attendees about all the subjects addressed on the talks! Watch the “making of” of some Podcasts with Ryan Ozimek, with Guilherme and Paulo Silveira and with Fabio Akita and Marcos Tapajós.

Dev in Rio 2009 - Podcast recording
* Guanabara recording the Podcast with Fabio Akita and Marcos Tapajós (and a neat detail: Guilherme Silveira and Paulo Silveira doing Pair Programming just behind them).

Since the event was realized on a monday, we ended the conference inviting everybody (with the “Estamos todos bêbados” song from Matanza in the background and choreography by Sylvestre Mergulhão and Henrique Andrade) for an epic edition of #Horaextra (that means “Overtime”, our weekly social meeting) at Lapa 40º. The entrance was free to everybody that had the Dev in Rio 2009 badge and that was how we realized the biggest and best #Horaextra ever:


* Watch more Dev in Rio 2009 videos.

I’m sure that this simple blog post cannot tell even 0,001% of what Dev in Rio 2009 was and how happy I am for being able to make it. I’d like to thank again the fundamental support from the folks of Globo.com that was the main responsible for making it happen, our sponsors Caelum, Locaweb and D-Click and everybody else that have supported us some way: Associação PythonBrasil, Fábrica Livre, Myfreecomm, OpenSourceMatters, Arteccom, DojoRio, Dojo@SP, #Horaextra, PythOnRio, RioJUG, RubyInside Brasil, Guanabara.info and everybody that attended to Dev in Rio 2009. Without your support nothing would’ve been possible!

Dev in Rio 2009 - Everybody in the end
* Participants of Dev in Rio’s round table.

If you didn’t go to Dev in Rio, I have two things to tell you: (1) you did lose one of the best conferences in Rio ever but (2) we’re going to make the presentation videos available very soon to alleviate your pain. :)

See you in 2010!

The fun theory

October 10th, 2009

Something that I always believed: fun can obviously change behaviour for the better.

That applies to our work activities and environments too. Just answer these simple questions and you will see why I think so:

  • Wouldn’t you feel better working at a company where you could have lots of fun while working?
  • Don’t you prefer to work with cool and funny people?
  • Don’t you feel more productive when you do something you enjoy?

If you are not doing those things already, start the change!

Congratulations Volkswagen for the initiative and thanks Glaucia Peres and Marcos Pereira for the link!

A story of failure with Scrum

May 25th, 2009

Mental note: I promisse to post more often on this blog. :)

While I don’t do it, see what happens when you use Scrum but you’re not really Agile:

Then see what happens when you don’t write unit tests and don’t do Test-Driven Development:

Why I don’t write code comments

April 5th, 2009

These days I was configuring some personal projects on ohloh and one thing called my attention. Ohloh showed the message “very few source code comments” in all my projects.

This is no surprise to me. I really don’t like to write source code comments. Why? Because if my code isn’t clear and easy enough for one to read and easily understand, I need to refactor. Many times I ask friends to take a look at code snippets and check if they understand. When they don’t, the method is usually too big or the variable/method names are not clear enough, and then I refactor to make it better to understand.

One example that I love (and use in many presentations) is the code to send e-mails using Java Mail API. The code would be something like this (from Java World tutorial):

// create some properties and get the default Session
Properties props = new Properties();
props.put("mail.smtp.host", _smtpHost);
Session session = Session.getDefaultInstance(props, null);
 
// create a message
Address replyToList[] = { new InternetAddress(replyTo) };
Message newMessage = new MimeMessage(session);
if (_fromName != null)
    newMessage.setFrom(new InternetAddress(from,
        _fromName + " on behalf of " + replyTo));
else
    newMessage.setFrom(new InternetAddress(from));
    newMessage.setReplyTo(replyToList);
    newMessage.setRecipients(Message.RecipientType.BCC, 
            _toList);
    newMessage.setSubject(subject);
    newMessage.setSentDate(sentDate);
 
// send newMessage
Transport transport = session.getTransport(SMTP_MAIL);
transport.connect(_smtpHost, _user, _password);
transport.sendMessage(newMessage, _toList);

I know that this is just an example but you know that it’s not difficult to find monsters like this one in production code.

This code is so difficult to read that the programmer had to say what he was doing, otherwise nobody would understand its purpose. There is a lot of infrastructure and business code together resulting on a huge abstraction leak.

Now take a look at the following code (from Fluent Mail API) and tell me how many seconds do you need to understand what the code does:

new EmailMessage()
    .from("demo@guilhermechapiewski.com")
    .to("destination@address.com")
    .withSubject("Fluent Mail API")
    .withBody("Demo message")
    .send();

This is an extreme example, of course. Maybe you will not write Fluent Interfaces for every little thing you need in your code, but if you add just a little bit of organization (using a better abstraction) it will already improve code readability:

class Email {
    public Email(String from, String to, ...) { ... }
    public void setFrom(String from) { ... }
    public void setTo(String to) { ... }
    public void send() {
        // put your complicated Java Mail code here
    }
}

Just by encapsulating the code in an abstraction that makes sense the WTF effect will be sensibly reduced. The programmers can now at least assume that the code sends e-mail messages since it’s included in a class called “Email”.

And that’s the point. When I create a culture of prohibiting myself from writing code comments, I’m obligating me to write easy, maintainable and understandable code.

That’s very extreme, I know, but the results of this approach are awesome.

Open source: “I don’t use open sorce software because I want support”

April 1st, 2009

“I don’t use open sorce software because I want support. I want to pay for it, so I can have support if I need.” That’s what a lot of people say about free and open source software. But today I came to a really interesting situation that it’s interesting to share.

We were configuring a continuous integration server at my team for a new project and we decided to use Integrity – that is a very simple yet powerful and beautiful tool. Our goal was really really simple: run tests, deploy the application and run more (acceptance) tests. Then we came to a situation where the tests were not running and the reason was somewhat bizarre. Integrity was opening a subshell to execute our build (and that’s very fair), but the problem is that Python’s sys.stdout was showing an Unicode error, because the test reports have a lot of accents. For some strange reason the very same code that was working in our shells was aborting with an Exception when executed in a subshell.

Given that complex situation, I decided to go to the website’s FAQ to see if somebody had this kind of problem before. I thought that maybe some configuration or environment variables setup could easily solve my problem. After some minutes of browsing I found instructions to configure Passenger user switching to overcome this problem, but I got no success.

Then, very frustrated, I decided to take a look in the documentation again and this time I saw a link to “support”, that pointed me to an IRC channel.

In five minutes I was talking to 2 commiters of the project and was having a high level discussion about the problem, the causes and the possible workarounds. The best part was that it took exactly 30 seconds for them to understand what I was talking about and they immediately started pointing me to solutions and asking me to try things… Thank to the guys’ tips (and Google) I could solve the problem in the end.

If you don’t like open source software because of the support, then I would like to ask you: in what reality do you live? Do you prefer to talk about “subshells” and “environment variables” with some call center attendant or do you want to talk to the people that can really help you solve your problem?

In other situation I was working at a company that used a VoIP telephony equipment that only worked on Windows. I wanted so much to use my preferred Linux distro, but that would mean that I couldn’t have a telephone. So, since we had a gold support plan (because we had a lot of PBXs with almost 200 branches), I decided to call the company and ask why they didn’t have a Linux version. I also tried to propose to or account manager: “we can implement that for you, just give us the Windows source code or protocol spec that we will implement everything for you and give you the source code and all the rights for free”. That was 6 years ago and they still don’t have a Linux version of the software….

Then I want to ask again: do you want to pray for your vendor to implement the solutions that are important to you or do you want to have the power to do it yourself when you need?

Think about these things. In the great majority of the times I asked for support in open source projects they were infinite times better than any paid support I’ve ever had!

Hello World!

March 31st, 2009

Although it’s a cliché, this is certainly the best title for a programmer’s first post! :)

After a long time of procrastination I’m finally starting my english blog! My intention is to continue the well succeeded work that I did in my portuguese blog, but this time opening the discussion and exposing my opinion to a bigger audience.

Hope that someone can find valuable information and insightful thoughts about software development, technology, agile methodologies and many other things that I will share here.

Hello world!