Click here to Skip to main content
15,393,377 members
Articles / Programming Languages / Java / Java SE
Posted 2 Jul 2008


1 bookmarked

Version Control Challenges in Agile Environments

2 Jul 2008CPOL6 min read
The Agile Manifesto states that individuals and interactions are more important than processes and tools. I pretty much agree with that. But the iterative nature of agile projects also raises some particular challenges to version control, which are just as important for small shops.

This article is in the Product Showcase section for our sponsors at CodeProject. These articles are intended to provide you with information on products and services that we consider useful and of value to developers.

Image 1


The Agile Manifesto promotes four basic values:

  • Individuals and interactions over processes and tools
  • Working software over comprehensive documentation
  • Customer collaboration over contract negotiation
  • Responding to change over following a plan

So, many companies stuck with overly rigid processes tried to implement more flexible approaches because they wanted to react better to changing customer needs. But how do you best realise this?

Key Success Factors

According to a survey by Dr. Dobb’s Journal, the majority of agile initiatives have been successful. In the same study, respondents were also asked for the critical success factors, resulting in the following top 3:

  • Iterative development
  • Regular delivery of working software
  • Configuration management

Quite clearly, proper software configuration management (or “version control”) is highly important to realise the two other success factors. To understand this importance, we have to look at the specific challenges that agile adoption creates regarding software configuration management. This article focuses in particular on the challenges when using iterative development. The challenges arising from the regular delivery of working software will be the topic of a next article.

Challenges When Practising Iterative Development

Developing in short iterations is mainly a reaction to the fact that many requirements are not fully understood at the beginning. Customers can decide better on what they want if they can see and test an intermediate product. To get this flexibility, business requests are typically broken down into smaller tasks, which should take 1-2 days to finish. These tasks are logged in a backlog and ranked according to their business value. This makes sure that the most important tasks are finished first.

This logic highlights some important facts:

  • Focus on tasks. Be able to identify, track and move tasks along the development lifecycle. Your configuration management should allow you to relate these tasks to your code changes and to merge them across branches. An example might be a bugfix that has to be merged from the development branch into one or more release branches.
  • Make sure that you can refactor your code. Business value (and not technical considerations) drives priorities. So, changes to your code base might become necessary as new features are added in later stages of the project.
  • Allow for multiple checkouts. Tasks prioritised by business value might imply working on the same files in parallel.
  • Be able to move unfinished tasks to a later iteration if necessary. An important rule to allow for short iterations is that deadlines are fixed. If there is a risk of delays, move features to later iterations instead.

How Does PureCM Solve These Challenges?

Focus on tasks. This means thinking in terms of issues such as bug fix or a new feature instead of individual file changes. In PureCM, “Changesets” represent the set of file changes that are necessary to fulfil a certain task. Every action in PureCM is centred on these changesets: checking their history, rolling back an erroneous change, merging a task from one configuration to another. PureCM’s strengths when working with tasks is covered in more detail in my last article on The Code Project.

Make sure that you can refactor your code. PureCM supports file copy/move/rename while preserving the complete history, also across the whole branching hierarchy. Refactoring can be done wherever the developer wants to, e.g. using PureCM’s Eclipse or Visual Studio plug-in.

Allow for multiple checkouts. Multiple checkouts and writable workspaces are fully supported in PureCM. In this way, a file does not even need to be checked out to be edited. All current file statuses are tracked and shown live on the server to facilitate communication among developers.


Figure 1: Live file status tracking in the PureCM GUI

Use PureCM’s policy-based security to control whether you want to allow multiple checkouts or whether you want to lock files. These policies can be specified per file type, e.g. to allow multiple check-out for text files, but locking binary files.

Be able to move unfinished tasks to a later iteration if necessary. Basically, PureCM supports two approaches to solve this challenge: shelving when working with mainline development, as well as task branching.


Shelving is a way to checkpoint your code (changes) on the server without integrating them into the underlying codeline. Shelving is most useful when all (or many) developers work on the same codeline, which has the advantage of being a simple branching pattern. In this pattern, shelving allows one to move unfinished tasks from one iteration to another without causing rework.

Imagine that one of your developers is working on a feature. However, he is running late for the next iteration build. So instead of checking the code into the main codeline, the developer can shelve it on the server. Once the release has been built, his work can be easily integrated into the mainline and included in the next build.


Figure 2: Shelving dialogue in PureCM

PureCM provides full transparency about which tasks are shelved on a specific codeline. A development manager can see every shelveset in the branch it belongs to (called “stream” in PureCM). As branches and labels are technically the same in PureCM, a shelveset can easily be moved from one stream to another, e.g. after a new baseline has been created.


Figure 3: Shelved changesets for the 2007-4 development stream

Task Branching

Task branches are the best method to completely isolate a developer from his colleagues. In that way, an integration manager can pick the tasks he wants to integrate into a specific release, i.e. merging the task branches into the main codeline. The advantage of this approach is the maximum flexibility it provides, and the fact that work is based on a known stable version of the code. However, this comes at the cost of more complex merging, as the main codeline has usually evolved during work on the task branch, especially when the integration of a task is postponed.

Therefore PureCM facilitates working with task branches by using the powerful concept of streams. Streams are lightweight branches that inherit their code from their parent stream. Frequent branching required for branch-per-task patterns thus becomes very fast and efficient when using PureCM. Furthermore, PureCM allows for cherry picking of changesets AND automatic Quick merges. Cherry picking is useful to update a task branch with specific changes from the main codeline, while the Quick merge function accelerates integrating the task branch back into the main codeline once development has been finished.


Figure 4: Cherry picking changesets in PureCM


Software Configuration Management is a critical success factor to agile implementation. The new challenges arising from iterative development patterns have to be considered carefully to increase the chances of success. PureCM is an easy-to-use, yet powerful tool to solve these challenges.

Developers can focus on tasks instead of file changes, control at what time these tasks are integrated into the main codeline, and can refactor code in later iterations if needed. This increases their flexibility without piling supplementary work on their day-to-day development.


PureCM is a Software Configuration Management (SCM) solution that controls and tracks changes to digital assets. PureCM facilitates and speeds up development in team environments using the leading concept of stream-based branching and merging. Complete with integrated Issue Management functionality, PureCM can be tailored to any development and change management process. PureCM excels in task-oriented environments, where productivity and security is optimised using local workspaces combined with a client/server architecture.

Both the PureCM client and server are available across multiple platforms such as Windows, Linux, and Mac. Offering native integration with Visual Studio® and Eclipse, PureCM is easy to use and easy to deploy, and thus particularly well-suited for today’s dynamic environment.

Visit PureCM now!


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Kenji Sulzberger
United Kingdom United Kingdom
No Biography provided

Comments and Discussions

RantAdvert Pin
A Weatherill3-Jul-08 4:38
MemberA Weatherill3-Jul-08 4:38 
GeneralRe: Advert Pin
FZelle4-Jul-08 0:43
MemberFZelle4-Jul-08 0:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.