Archive for Agile

Rolling out an agile development process

I have been asked to help in introduction of a development process for the team working on a greenfield project. The team consist of dozen or so developers with a given task to replace an old legacy system with something which will perform better, will be more flexible and easier to maintain. The existing process that is based on individuals being assigned to never-ending stream of tasks (mostly maintenance, bugfixes and improvements) might work, in my opinion, when system is not in active development stage, therefore not ideal for the greenfield project when there is much bigger density of innovation and collaboration required to succeed.

Interesting task I have to say. I think I will approach this by addressing both project management and engineering requirements by setting up an iterative process based on bits and pieces from Scrum and XP. It shouldn’t be a surprise to anyone involved in the past in Web21C Experiment. The Scrum process will kick off with pretty standard set of features hence I will not bother you with details.

What I want to achieve in field of team organisation is to:

  • grow a successful team that delivers business value (doh!) as soon as possible (doh!)
  • improve internal and external communication and information flow
  • share common understanding of the domain and the system
  • learn how to cope with inevitable change
  • activate developers to be more encouraged to introduce new ideas and solutions
  • put the team in position to be more in the partner relationship with business
  • improve motivation and satisfaction from work
  • encourage being passionate about technology and sharing that passion

In the same time in field of engineering practices I’ll stand my ground on:

  • automation, automation, automation
  • continuous integration
  • code coverage
  • automated integration tests
  • patterns
  • non mandated on-request pairing (you wonder what it is?)
  • lightweight solutions
  • shared code-ownership

There is an interesting lean Kanban process on horizon which looks as a good match for the environment however I will not be pushing for this initially. As the process should evolve over time there is always time to navigate original agile scrum process towards something which can be maybe a better choice. Only time will prove.

Comments, advice?

Popularity: 2% [?]

Comments

Agile planning for less geeky people

I’ve been performing a small experiment lately and wanted to share some results.

My girlfriend is pursuing chartered accountant qualification. In order to qualify as an ACCA member, one has to complete 14 exams. The length of time it takes to qualify depends on the student as the course is designed to be flexible. Each year there are two examination session and one can sit up to four papers per session. With just couple of exams, it makes substantial amount to read, digest, revise, rehearse, to be able to pass. But in the same time it is pretty predictable. If you put this much of effort you can expect particular result. So, the problem can be defined as:

with a limited time on hands, how to score >= 51% for each of the exams one attempts to pass.

I could see her struggle. She knew what she has to do but she didn’t know if with current time constraints it is durable. She didn’t know if she will be able to prepare well enough for all the papers, or maybe drop an exam to give more time to other exams. What was needed is a simple plan with estimation put in realistic time frame. I decided to step in and help organize it using agile planning tool which I’ve been using for last two years: ScrumWorks. I’m trying to be quite serious here but I can see glimpses of smile appearing on faces of many people reading it now. I understand and it would be quite amusing for me as well. But hey, there is no such thing which we can’t do to entertain other people!

We started our planning with creating user stories. It would map directly to modules in each paper. The size of each user story would be the same to start with. Then each user story would be tasked out: each module requires particular amount of time allocated to reading, making exercises, revising. On the top of that there was time allocated to mock exams and wide spectrum revising. Each of the tasks can be quite well estimated. What’s unusual here is that all the user stories were tasked out up front and not on weekly iteration planning. In this case it was possible and needed as the deadline is fixed and domain well understood. After this agile planning exercise we ended up with very clear backlog. We knew what it takes to pass exam. The second part of this was allocating user stories with tasks to particular weekly iterations. It was easy enough just to divide workload in equal batches and reserve some time in last two weeks for this known-unknowns which always appear before release.

It’s her fifth iteration now. Except the initial introduction of the process I haven’t been interfering much. Each Sunday she was re-planning to accommodate real velocity, adding, removing or changing tasks, re-prioritizing. I have to say that she loves Scrumworks! It is a very simple tool which just does the job. Especially drag-and-drop re-planning and burn down charts she found very handy and useful.

So, what has changed since introducing this process? First advantage is improved visibility of progress which in very honest and direct way shows if one is doomed or not. It helps to make difficult decisions. With weekly iterations it helps to maintain a high average focus and saves a lot of stress being generated by not knowing if we are behind or ahead with preparations. I recon I will have to wait till exams to see how well the geeky project management can help “an average Joe”.

Popularity: 33% [?]

Comments (1)

Thoughts on dispersed agile teams

I came across a paper from Microsoft on distributed agile development and wanted to share some thoughts from my experience on that topic. It’s not a matter of choice, that’s matter of reality that software teams are more and more often distributed where the scale of distribution may run from:

  • homeworkers based in the same city,
  • to people based in the same country in different offices/cities
  • followed by team members located in the different countries
  • then continents and
  • time zones.

Luckily we haven’t left this planet yet!

It is nothing unusual to have a team working together day by day dispersed between two, three or four timezones (I’m lucky now with three timezones but with majority of people in the same room). Searching for the new highly skilled professionals, acquisitions in new global markets or outsourcing to cheaper regions could be some of the reasons for increasing distribution.

The physical distance and time difference is not helping to create a funcional agile team. It is actually very far from ideal situation where people sit in the same room, with whiteboard handy and plenty of formal and informal communication going on, following all practices. Broken communication and being unable to apply original agile/xp practices are first problems which come to my mind. It is rather intuitive that dispersed teams will never be as good as team working under the same roof. Or maybe, as I think the last thought goes a bit too far and takes away any hope, the amount of work and skills required to create successful distributed team is bigger for at least an order of magnitude. And again, as always in agile, it is up to each and everyone in the team to make it work.

To fix the broken communication we should actually simply collocate as often as possible with emphasis on planning and release time. It is almost unavoidable. But it is also investment which will pay off when team members will have to work on distance together. People who actually know each other will later on communicate much better. To enable this communication we have to provide right tools: unlimited voice communication with conferencing capabilities, IM clients, tools for remote desktop sharing, access to the same network resources, webcams, hand free headsets. One should also learn how to be open and approachable, that’s a key factor! Pairing is for many people difficult even in the same room and becomes even more difficult on distance, but still possible and beneficial. It’s simply much harder and takes longer to learn how to do it comfortably. Couple of pieces of advice: don’t break something what works by constantly reorganizing teams, don’t loose some people by letting them drift away forgotten. As I already mentioned not all xp/agile practices can be used in original form like pair programming. How you are going to use for instance index cards stuck to a wall with dispersed team? It might not work. But there is always some answer. Maybe a given practice can be slightly modified to fulfill its role, or maybe it can be replaced with some other practice (see paper from Thoughtworks on Subclassing XP) which might work better. To figure out what works and what doesn’t frequent retrospectives with all members is a must. As I said: it is all about communication!

Popularity: 24% [?]

Comments (1)

Developing in branches, releasing from trunk

BranchesMe and my new team preparing now to starting a new greenfield project in month or so. Starting something new is very exciting itself and lets us put new processes in place. But how to decide about the processes? Simply by collaborating, discussing and exchanging ideas and previous experience. In this post I will focus on the development/release process and choices we are facing at the moment.

Just to give some perspective… In the past when working on the BT SDK with Web21c team I was using ScrumWorks for managing user stories or, as some other people would call it, features, improvements or bugfixes and mapping those to particular releases. The public releases were very infrequent and scheduled every 3 months. Emergency releases with bug fixes could happen more often. Of course as for an agile team internal releases occurred more often, usually every 2 weeks ended with an acceptance session with a product owner. The Subversion has been used as the source repository, with all active development happening usually in parallel in the trunk. Some time before release the code was frozen in a branch by copying an active trunk and only bug fixes were applied to the release branch, subsequently merged back to the trunk. I could call this process “Develop in trunk, release from a branch”.

At my current project we use only JIRA for managing bugs/features/improvements and matching it to particular releases and the releases will occur much more often (every week or two) with possible multiple emergency releases in meantime. Source is kept in Subversion as well. The team is not calling itself “agile” however I think it has to be very agile to cope with the schedule and a right process should be established to support it. It could look like:

Development time

1. In JIRA we create a bunch of tickets for new features, bug fixes or improvements. A developer is assigned (hey, who likes that phrase?) a task to work on.
2. Before starting work a new branch is created from trunk with the JIRA number as a name
3. Work on that task commences and all changes are committed to the new branch. If there are several dependant tickets then JIRA should have a parent ticket created and all dependant tickets assigned as children. It resembles higher level user story with tasks from Scrum.

Build/Release time

1. In JIRA a release or version will be set up and given a name (i.e. 1.0.1). This will contain a list of tickets that are to be used for this release
2. A new branch will be created in SVN from trunk, matching the name of the JIRA release.
3. The branches that match the JIRA tickets for this release are merged into the new release branch.
4. A continuous integration build is pointed to the newly created release branch.
5. The build should pass unit tests, integration tests, automated acceptance tests, is then deployed to UAT environment for final user acceptance tests.
6. When ready for release, a tag is created from the branch matching the JIRA release name. The software is deployed to production.
7. The code from the tag is now merged back to trunk

It is clearly “Develop in branches, release from trunk”. Sounds weird at the beginning. Have to admit that I didn’t use exactly this process before but my first impression is that it is really structured methodology which:

  • gives superb view what actually is currently deployed (via mapping tickets to releases in JIRA)
  • allows adding/removing changes easily – we can always take a previous tagged version and apply selected modification by merging
  • supports external auditing

In the same time my gut feel tells me that:

  • merging before release might be a nightmare (volunteers for a release manager?)
  • the process seems to be too regulated, “boxed”, “walled”

It will very much depend on the release schedule and how often the changes will be released which means how often the trunk will be up to date with the latest code. Let’s assume we have biweekly releases. It will mean that at the average a developer will be working with a one week old code. With an application in a maintenance mode with occasional bug fixes which doesn’t change dramatically it would be acceptable but taking as example a new project with many contributors, dependencies between components and a lot of expected changes in design and implementation I think that might be problematic.

It really doesn’t encourage refactoring neither. Just imaging what would happen if two branches taken from the same version of TRUNK were exposed to wider and more intensive refactoring? And for me refactoring is a necessary factor which means continuous and gradual code quality improvement leading to system quality improvement. I know, we should do everything right first time. Why I didn’t think about this before?

Other downside which I can see is that we might completely lose transparency and visibility what is happening with the code. People will commit to “own” branches without a continuous integration. I have to say that I like to monitor changes to current source code via email from continuous integration with last check-in comments. It gives me a way of quickly assessing if the ongoing development is related to my current task, I can merge incoming changes one by one with my changes which means that I don’t do something which someone already has done or something which doesn’t make sense any more.

So, I have mixed feelings. The biggest advantage of the process I can see is easy adding/withdrawing pieces of functionality at short notice. And it (at least in theory, not mentioning the merging hell) fulfils the role very well. The process actually resembles the way how open source communities work. Each contributor branches from trunk and does development on his/her own without breaking anyone else code. When feature is ready then it is (after code review) merged back to trunk or release branch.

It appears that the problem here is caused by subversion not being the best at the merging job. So as we can see a good tool for merging is essential here to make the life easier. It looks like open source guys moved towards GIT and BAZAAR now with GIT getting a lot of traction as it has support for SVN as well.

The process described is not final and would look into refining it to better support given development/release practises. If you have suggestions, comments or you have been using similar process please free to contribute and share.

Popularity: 43% [?]

Comments (8)

Selenium and the Permission denied to get property Location.href problem

SeleniumI came across a strange behaviour of Selenium and wanted to share my pain with someone really. But first couple of words of introduction. I use Selenium in my current webapp project which I am working on. The application uses quite a lot of javascript (Dojo framework mostly) which can be tested using D.O.H. framework but the Selenium is giving us the final sanity checks, acts as integration test framework and may be used by product owner in an agile environment to drive acceptance on user stories via automated acceptance tests.

Selenium is an excellent package. I really love it. Just to mention integration with various browsers, Selenium IDE, support for integration with build (Selenese ant task) and really easy way of creating and storing the tests as HTML. It is a framework which cannot be ignored by anyone working on webinterfaces.

There is previously mentioned selenese ant task which helps with integration of the Selenium tests and an ant build. You can grab the jar from the Selenium RC distribution.

However as most of the things around us it is not a perfect software. Anyone had the famous “Permission denied to get property Location.href”? Cross domain scripting issues?
In my case I figure out two reasons for above problem and I wanted to share it:

Problem 1:

Let’s look at the following selenium command:

  • open
  • http://host/some/url

Looks good, doesn’t it? So it might work, but it can as well break on another box with the “Permission denied to get property” and some other scary warnings. The solution in this case was simply to remove the host definition from url leaving just:

  • open
  • /some/url

Problem 2:

One of the pages I was testing had redirection in case of the authorization violation. So esentially after single HTTP request the browser was receiving single response with redirection and then performed another request to the URL defined in the redirection. Selenium couldn’t handle that correctly. But again, it wasn’t deterministic, it could work on one box but fail on another. Timing issues etc. Hate that. Neither of the combinations worked in consistent way: openAndWait, open + pause.

The solution in this case required change in the webapp to remove usage of the redirection (which I believe was an ugly way of dealing with the problem anyway).

Hope it will help someone with similar issues. If you know another tricks or something to avoid when using Selenium please contact me or leave a comment here.

Popularity: 100% [?]

Comments (5)

Close
E-mail It