Module 3
Module 3
Chapter 3
Agile Development
Therefore, an agile process must be flexible and adaptable. Also holds the below
features:
An agile software process must adapt incrementally.
Customer feedback is essential for making appropriate adjustments.
Operational prototypes or parts of the system are effective catalysts for
gathering customer feedback.
An incremental development strategy should be implemented.
Software increments (working prototypes or segments of the operational
system) must be delivered in short time frames.
Delivering increments quickly helps keep pace with changes and
unpredictability.
This iterative approach allows customers to regularly evaluate the software
increment.
Customers can provide crucial feedback to the development team.
Customer feedback influences process adaptations.
1. Our highest priority is to satisfy the customer through early and continuous
delivery of valuable software.
2. Welcome changing requirements, even late in development. Agile processes
harness change for the customer’s competitive advantage.
3. Deliver working software frequently, from a couple of weeks to a couple of
months, with a preference to the shorter timescale.
4. Business people and developers must work together daily throughout the
project.
5. Build projects around motivated individuals. Give them the environment and
support they need, and trust them to get the job done.
6. The most efficient and effective method of conveying information to and
within a development team is face-to-face conversation.
7. Working software is the primary measure of progress.
8. Agile processes promote sustainable development. The sponsors, developers,
and users should be able to maintain a constant pace indefinitely.
9. Continuous attention to technical excellence and good design enhances
agility.
10. Simplicity—the art of maximizing the amount of work not done—is essential.
11. The best architectures, requirements, and designs emerge from self–
organizing teams.
12. At regular intervals, the team reflects on how to become more effective,
then tunes and adjusts its behavior accordingly.
Key traits that must exist among the people on an effective software team
6. Mutual trust and respect: A cohesive team demonstrates the essential trust
and respect that make them "so tightly bonded that their collective strength
surpasses the individual contributions."
7. Self-organization: In agile development, self-organization entails three
aspects: (1) the agile team organizes itself to accomplish the tasks at hand, (2) it
structures the process to suit its specific environment, and (3) it schedules work
to optimize software delivery. Beyond technical advantages, self-organization
significantly enhances collaboration and boosts team morale.
3.4.1 XP Values
Kent Beck outlines a core set of five values that underpin all activities within
Extreme Programming (XP): communication, simplicity, feedback, courage, and
respect. Each of these values serves as a guiding principle for specific XP
practices and tasks.
Planning
The planning activity, also known as the planning game in Extreme Programming
(XP), initiates with a crucial phase of listening. This involves gathering
requirements, enabling technical members of the XP team to grasp the business
context of the software and understand the necessary outputs, major features,
and functionalities. Through this listening phase, a set of "stories" (also referred
to as user stories), which describe the required outputs, features, and
functionalities of the software, are created by the customer and written on
index cards.
Each story is assigned a value or priority by the customer based on its
business significance. Subsequently, members of the XP team assess each
story and assign a development cost, typically measured in weeks.
If a story is estimated to require more than three weeks, the customer is
encouraged to split it into smaller stories, and the value and cost assignment
process is repeated. Importantly, new stories can be introduced at any point
in the planning process.
Customers and developers collaborate closely to determine how to group
these stories into the next software release or increment to be developed by
the XP team.
Once a foundational commitment is made for a release, which includes
agreements on the stories to be included, the delivery date, and other
project details, the XP team prioritizes and orders the stories in one of three
ways: (1) all stories are implemented concurrently within a few weeks, (2)
stories with the highest business value are prioritized and scheduled first, or
(3) stories perceived to carry the highest risk are prioritized and addressed
first.
Following the delivery of the initial project release or software increment,
the XP team calculates the project velocity. Project velocity, simply put,
quantifies the number of customer stories successfully implemented during
the initial release. This metric serves two main purposes: (1) it aids in
estimating delivery dates and schedules for subsequent releases and (2) it
helps identify if there has been an over-commitment across all stories
throughout the entire development project. If an over-commitment is
detected, adjustments are made to the content of future releases or to the
final delivery dates.
Design
Coding
After completing the development of stories and initial design work, the
team focuses on creating a set of unit tests for each story planned for the
current software release (increment). These tests ensure that each story's
requirements are properly exercised and validated.
Following the creation of unit tests, developers concentrate on implementing
only what is necessary to pass these tests, adhering to the KIS (keep it simple)
principle. Once the code is written, it is immediately subjected to unit testing,
providing instant feedback to developers.
During the coding phase, a prominent practice in XP is pair programming,
where two developers collaborate at a single workstation to write code for a
story. This approach facilitates real-time problem-solving and quality
assurance, as the code is continuously reviewed as it is being written.
Pair programming also helps maintain focus on the task at hand, with each
person taking on complementary roles—for instance, one may handle coding
specifics while the other ensures adherence to XP's coding standards or
verifies that the code satisfies the established unit tests.
As pair programmers complete their work, the code they produce is
integrated with that of others. Integration can occur daily by a dedicated
integration team or be managed directly by the pair programmers
themselves. This practice of continuous integration minimizes compatibility
issues and interfaces problems.
Testing
In XP, a fundamental practice is to create unit tests before starting coding. These
tests should be developed using an automated framework, allowing them to be
executed easily and repeatedly. This approach supports a regression and
integration testing strategy whenever code is modified, aligning with XP's
philosophy of frequent refactoring. Organizing individual unit tests into a
"universal testing suite" [Wel99] enables daily integration and validation testing
of the system. This continuous testing strategy provides ongoing feedback on
progress and helps detect issues early.
According to Wells [Wel99], addressing small issues every few hours is more
efficient than dealing with major problems right before a deadline.
XP acceptance tests, also known as customer tests, are defined by the customer
and focus on validating overall system features and functionalities that are
visible and reviewable by the customer. These tests are derived from user
stories implemented in each software release.
3.4.3 Industrial XP
Joshua Kerievsky characterizes Industrial Extreme Programming (IXP) as a
natural progression of XP, enriched with XP's core values of simplicity, customer
focus, and test-driven development. However, IXP diverges from traditional XP
by placing greater emphasis on management involvement, enhancing customer
participation, and refining technical methodologies. It introduces six additional
practices tailored to ensure the effective implementation of XP in substantial
projects within larger organizations.
Project chartering: The IXP team evaluates the project to ascertain if there is a
valid business justification and whether the project aligns with the
organization's overarching goals and objectives. Chartering also analyses the
project's context to understand its relationship with existing systems or
processes, whether it complements, extends, or replaces them.
Scrum
Scrum, an agile software development method originated by Jeff Sutherland and
his team in the early 1990s, aligns with the principles of the agile manifesto. It
guides development activities through a framework that encompasses
requirements, analysis, design, evolution, and delivery. Work tasks within each
of these activities are structured into time-bound iterations called sprints. The
Scrum team adapts and refines tasks in real-time to address current project
challenges. The overall flow of the Scrum process is depicted in the
accompanying diagram.
Scrum prioritizes a collection of software process patterns that have
demonstrated effectiveness in projects characterized by tight deadlines,
evolving requirements, and critical business demands.
Each of these patterns outlines a series of development actions:
Backlog - refers to a prioritized list of project requirements or features that
deliver business value to the customer. Items can be added to the backlog
continuously. The product manager evaluates the backlog and adjusts priorities
as necessary.
Sprints - are comprised of work units necessary to fulfil a requirement outlined
in the backlog, all within a fixed time-box (usually around 30 days). No changes,
such as introducing new backlog items, are permitted during the sprint. This
approach enables team members to operate within a short-term, yet stable,
environment.
Scrum meetings, also known as daily stand-ups, are brief gatherings held daily
by the Scrum team, typically lasting around 15 minutes. During these meetings,
each team member answers three key questions:
What have you accomplished since the last team meeting?
What obstacles or challenges are you currently facing?
What do you aim to achieve by the next team meeting?
These questions ensure team members stay informed, address any issues
promptly, and maintain alignment on project progress.
A Scrum master, serving as the team leader, facilitates the meeting and
evaluates responses from each team member. The Scrum meeting aids in early
detection of potential issues and promotes knowledge sharing among team
members.
Demos - involve presenting the software increment to the customer, allowing
them to evaluate the implemented functionality. It's important to highlight that
the demo may not include all planned features but focuses on delivering
functionalities within the established time-box.
Crystal
Alistair Cockburn and Jim Highsmith created the Crystal family of agile
methods.
The emphasis is on "manoeuvrability" in software development.
("maneuverability" refers to the ability to swiftly adapt and respond to changes, challenges, and
opportunities throughout the development process. It involves being flexible, agile, and responsive
to evolving requirements, market conditions, and technological advancements.)
Cockburn describes it as a resource-limited, cooperative game centered
on invention and communication.
The primary goal is to deliver useful, working software, with a secondary
goal of preparing for subsequent iterations.
The Crystal family offers a range of agile processes tailored for different
project types.
MRS. DEEKSHA DEPARTMENT OF CS&E
SE&PM (21CS61) Lecture Notes 17
Agile teams can select the Crystal method that best fits their project and
environment.
AM aligns with the values outlined in the Agile Manifesto. It emphasizes the
importance of making decisions courageously, even if it means rejecting a design
and refactoring it. Additionally, the philosophy acknowledges that technologists
may not have all the answers, encouraging respect and collaboration with
business experts and other stakeholders.
Chapter 4
PRINCIPLES THAT GUIDE THE PRACTICE
topics require discussion (see Principle 2) and that “moving on” is sometimes
the best way to achieve communication agility.
Principle 10. Negotiation is not a contest or a game.
It works best when both parties win. There are many instances in which you and
other stakeholders must negotiate functions and features, priorities, and
delivery dates. If the team has collaborated well, all parties have a common goal.
Still, negotiation will demand compromise from all parties.
Principle 10. Track the plan frequently and make adjustments as required.
Software projects fall behind schedule one day at a time. Therefore, it makes
sense to track progress on a daily basis, looking for problem areas and situations
in which scheduled work does not conform to actual work conducted. When
slippage is encountered, the plan is adjusted accordingly.
Principle 1. The primary goal of the software team is to build software, not
create models.
Agility means getting software to the customer in the fastest possible time.
Models that make this happen are worth creating, but models that slow the
process down or provide little new insight should be avoided.
Principle 2. Travel light—don’t create more models than you need. Every model
that is created must be kept up-to-date as changes occur. More importantly,
every new model takes time that might otherwise be spent on construction
(coding and testing). Therefore, create only those models that make it easier
and faster to construct the software.
Principle 3. Strive to produce the simplest model that will describe the
problem or the software.
Don’t overbuild the software. By keeping models simple, the resultant software
will also be simple. The result is software that is easier to integrate, easier to
test, and easier to maintain (to change). In addition, simple models are easier
for members of the software team to understand and critique, resulting in an
ongoing form of feedback that optimizes the end result.
Principle 4. Build models in a way that makes them amenable to change.
Assume that your models will change, but in making this assumption don’t get
sloppy. For example, since requirements will change, there is a tendency to give
requirements models short shrift. Why? Because you know that they’ll change
anyway. The problem with this attitude is that without a reasonably complete
requirements model, you’ll create a design (design model) that will invariably
miss important functions and features.
Principle 5. Be able to state an explicit purpose for each model that is created.
Every time you create a model, ask yourself why you’re doing so. If you can’t
provide solid justification for the existence of the model, don’t spend time on it.
Principle 6. Adapt the models you develop to the system at hand.
It may be necessary to adapt model notation or rules to the application; for
example, a video game application might require a different modelling
technique than real-time, embedded software that controls an automobile
engine.
Principle 7. Try to build useful models, but forget about building perfect
models. When building requirements and design models, a software engineer
reaches a point of diminishing returns. That is, the effort required to make the
model absolutely complete and internally consistent is not worth the benefits of
these properties. Am I suggesting that modelling should be sloppy or low
quality? The answer is “no.” But modelling should be conducted with an eye to
the next software engineering steps. Iterating endlessly to make a model
“perfect” does not serve the need for agility.
Principle 8. Don’t become dogmatic about the syntax of the model.
If it communicates content successfully, representation is secondary although
everyone on a software team should try to use consistent notation during
modelling, the most important characteristic of the model is to communicate
information that enables the next software engineering task. If a model does
this successfully, incorrect syntax can be forgiven.
Principle 9. If your instincts tell you a model isn’t right even though it seems
okay on paper, you probably have reason to be concerned. If you are an
experienced software engineer, trust your instincts.
Software work teaches many lessons—some of them on a subconscious level. If
something tells you that a design model is doomed to fail (even though you can’t
prove it explicitly), you have reason to spend additional time examining the
model or developing a different one.
Principle 10. Get feedback as soon as you can.
Every model should be reviewed by members of the software team. The intent
of these reviews is to provide feedback that can be used to correct modelling
mistakes, change misinterpretations, and add features or functions that were
inadvertently omitted.
Construction Principles
The construction activity encompasses a set of coding and testing tasks that lead
to operational software that is ready for delivery to the customer or end user.
Coding may be
(1) The direct creation of programming language source code (e.g., Java),
(2) The automatic generation of source code using an Intermediate design like
representation of the component to be built.
The initial focus of testing is at the component level, often called unit testing.
Other levels of testing include
i) Integration testing (conducted as the system is constructed).
ii) Validation testing that assesses whether requirements have been met for the
complete system (or software increment)
(iii) Acceptance testing that is conducted by the customer in an effort to exercise
all required features and functions.
The following set of fundamental principles and concepts are applicable to
coding and testing:
Coding Principles: The principles that guide the coding task are closely aligned
with programming style, programming languages, and programming methods.
However, there are a number of fundamental principles that can be stated:
Preparation principles: Before you write one line of code, be sure you
• Understand of the problem you’re trying to solve.
• Understand basic design principles and concepts.
• Pick a programming language that meets the needs of the software to be built
and the environment in which it will operate.
• Select a programming environment that provides tools that will make your
work easier.
• Create a set of unit tests that will be applied once the component you code is
completed.
Validation Principles: After you’ve completed your first coding pass, be sure you
• Conduct a code walkthrough when appropriate.
• Perform unit tests and correct errors you’ve uncovered.
• Refactor the code
Testing Principles: Glen Myers states a number of rules that can serve well as
testing objectives:
• Testing is a process of executing a program with the intent of finding an error.
• A good test case is one that has a high probability of finding an as-yet
undiscovered error.
• A successful test is one that uncovers an as-yet-undiscovered error.
Davis suggests a set of testing principles that have been adapted for use.
Principle 2. Tests should be planned long before testing begins. Test planning
can begin as soon as the requirements model is complete. Detailed definition of
test cases can begin as soon as the design model has been solidified. Therefore,
all tests can be planned and designed before any code has been generated.
Principle 3. The Pareto principle applies to software testing. In this context the
Pareto principle implies that 80 percent of all errors uncovered during testing
will likely be traceable to 20 percent of all program components. The problem,
of course, is to isolate these suspect components and to thoroughly test them.
Principle 4. Testing should begin “in the small” and progress toward testing “in
the large.” The first tests planned and executed generally focus on individual
components. As testing progresses, focus shifts in an attempt to find errors in
integrated clusters of components and ultimately in the entire system.
Deployment Principles
Principle 5. Buggy software should be fixed first, delivered later. Under time
pressure, some software organizations deliver low-quality increments with a
warning to the customer those bugs “will be fixed in the next release.” This is a
mistake. There’s a saying in the software business: “Customers will forget you
delivered a high-quality product a few days late, but they will never forget the
problems that a low-quality product caused them. The software reminds them
every day.”