Introduction to Agile Development and Scrum
It has these modules…
It has these modules…
What is Agile?
Agile is an iterative approach to project management that helps teams be responsive and deliver value to their customers faster
Agile defining characteristics:
Agile emphasizes:
Agile Manifesto:
We have come to value:
Individuals and interactions over processes and tools.
Working software over comprehensive documentation.
Customer collaboration over contract negotiation.
Responding to change over following a plan.
That is, while there is value in the items on the right, we value the items on the left more.
Agile Software development:
Key takeaway:
Build what is needed, not what was planned.
Problems with waterfall approach:
Extreme Programming values:
What is Kanban?
Kanban | ‘kanban | noun
(also Kanban system) a Japanese manufacturing system in which the supply of components is regulated through the use of an instruction card sent along the production line.
Origin
1970s: Japanese, Literally mean ‘billboard, sign’
Core principles of Kanban:
Agile and Scrum:
Scrum:
Is a management framework for incremental product development
Prescribes small, cross-functional, self-organizing teams
Provides a structure of roles, meeting, rules, and artifacts
Uses fixed-length iterations called sprints
Has a goal to build a potentially shippable product increment with every iteration
Easy to Understand – Difficult to master
Sprint:
A sprint is one iteration through the design, code, test, and deploy cycle
Every sprint should have a goal
2 weeks in duration
Steps in the Scrum process:
Agile development is iterative:
Scrum roles:
Scrum Artifacts:
Product backlog
Sprint backlog
Done increment
Scrum events:
Sprint planning meeting
Daily Scrum meeting (a.k.a. daily stand-up)
Sprint
Sprint review
Sprint retrospective
Benefits of Scrum:
Higher productivity
Better product quality
Reduced time to market
Increased stakeholders satisfaction
Better team dynamics
Happier employees
Scrum vs. Kanban:
Organize for success:
Proper organization is critical to success
Existing teams may need to be reorganized
Conway’s Law:
“Any organization that designs a system (defined broadly) will produce a design whose structure is a copy of the organization’s communication structure.”
— Melvin Conway, Datamation, 1968
Examples of Conway’s Law:
If you ask an organization with four teams to write a compiler … you will get a 4-pass compiler!
How teams should be aligned?
Teams are loosely coupled, tightly aligned
Each team has its own mission aligned with the business (like a “mini startup”)
Teams have end-to-end responsibility for what they build
The long-term mission is usually around a single business domain
Autonomy is important:
It’s motivating – and motivated people build better stuff
It’s fast – decisions happen locally in the team
It minimizes handoffs and waiting, so teams don’t get bogged down
The Agile dilemma!
The entire organization must be Agile:
Agile + DevOps = Alignment
The biggest pitfall for companies is that, they think they’re agile, but actually they’re just doing an iterative work.
Agile is not…
Deadlines:
“I love deadlines… I like the whooshing sound they make as they fly by”. – Douglas Adams
How do you avoid this?
Plan iteratively:
Don’t decide everything at the point when you know the least
Plan for what you know
Adjust as you know more
Your estimates will be more accurate
Formulas for failure:
Product Manager vs. Product Owner:
Project Manager vs. Scrum Master:
Development Team vs. Scrum Team:
“Until and unless business leaders accept the idea that they are no longer managing projects with fixed functions, timeframes, and costs, as they did with waterfall, they will struggle to use agile as it was designed to be used.”
— Bob Kantor, Founder Kantor Consulting Group, Inc.
The roles have changed:
Agile planning tools:
Tools will not make you Agile
Tools can support your Agile process
Many Agile planning tools
ZenHub is one of them
ZenHub:
Plug-in to GitHub
Provides a kanban board and project management reporting
Customizable and integrated with GitHub
Why use ZenHub?
Helps you manage where you are in a project based on GitHub Issues
Provides an easy way to let management know how you are doing
Maintains up-to-date status due to integration with GitHub
Allows developers to only use one tool – GitHub
What is Kanban Board?
Real World Example:
Default ZenHub pipelines:
What is a user story?
A user story represents a small piece of business value that a team can deliver in an iteration.
Story contents:
Stories should contain:
A brief description of the need and business value
Any assumptions or details
The definition of “done”
Story description:
User stories document a persona requesting a function to achieve a goal:
As a <some role>
I need <some function>
So that <some benefit>
Assumptions and details:
It’s important to document what you know;
List any assumptions
Document any details that may help the developer
Acceptance criteria:
It is critical to document the definition of “done”
I like to use the Gherkin syntax
Given <some precondition>
When <some event happens>
Then <some outcome>
Sample Story:
Bill Wake’s INVEST:
Independent
Negotiable
Valuable
Estimable
Small
Testable
Epic:
A big idea
A user story that is bigger than a single sprint
A user story that is too big to estimate on its own
When to use an epic?
When a story is too large in scope it is considered an epic
Backlog items tend to start as epics when they are lower priority and less defined
For sprint planning, epics should be broken down into smaller stories
What are story points?
Story point;
What does a story point measure?
Relative T-Shirt sizes
Story points acknowledge that humans are bad at estimating time-to-completion
Instead, story points use relative T-Shirt sizes (S, M, L, XL)
Most tools use Fibonacci numbers (1, 2, 3, 5, 8, 13, 21)
Agree on what “medium” means:
Since story points are relative, it’s important to agree on what “medium” is
Then, evaluate from there
Is it the same, larger, or smaller than medium
Story size:
A story should be small enough to be coded and tested within a single sprint iteration – ideally, just a few days
Large stories should be broken down into smaller ones
Story point antipattern
Equating a story point to wall-clock time
Humans are bad at estimating wall-clock time
Don’t do it!
Steps in the Scrum process:
Product Backlog:
ZenHub Kanban board:
Creating new stories
Story Template:
As a <some role>
I need <some function>
So that <some benefit>
Need a service for counting things:
As a User
I need a service that has a counter
So that I can keep track of how many times something was done
Creating the next story:
Must allow multiple counters:
As a User
I need to have multiple counters
So that I can keep track of several counts at once
Creating the next story:
Persist counters across restarts:
As a Service Provider
I need the service to persist the last known count
So that users don’t lose track of their counts after the service is restarted
Creating the last story:
Counters can be reset:
As a System Administrator
I need the ability to reset the counter
So that I can redo counting from the start
Stories in the backlog:
Prioritize the product backlog:
Backlog refinement:
Keep the product backlog ranked by priority so that the important stories are always on the top
Break large stories down into smaller ones
Make sure that stories near the top of the backlog are groomed and complete
Backlog refinement meeting:
Who should attend?
Product owner
Scrum master
Development team (optional)
Lead developer/architect
What is the goal?
Groom the backlog by ranking the stories in order of importance
Make sure the story contains enough information for a developer to start working on it
Backlog refinement workflow:
New issue triage:
Start with new issue triage
Goal: At the end of backlog refinement, the New Issues column is empty
Take stories from new issues and…
Move them into the product backlog if they will be worked on soon
Move them into the icebox if they are a good idea but not now
Reject them if they are not where you want to go
Backlog refinement workflow:
As a <some role>
I need <some function>
So that <some benefit>
Assumptions and Details:
<anything you already know>
Acceptance Criteria:
Given <some precondition>
When <some event>
Then <some measurable outcome>
Need a service that has a counter:
Must Persist counter across restarts:
Deploy service to the cloud:
Ability to reset the counter:
Label:
Labels in GitHub
Need a service that has a counter:
Must persist counter across restarts:
Deploy service to the cloud:
Ability to reset the counter:
Technical debt is anything you need to do that doesn’t involve creating a new feature
Technical debt builds up when you take shortcuts, but may also occur naturally
Examples of technical debt:
Code refactoring
Setup and maintenance of environments
Changing technology like databases
Updating vulnerable libraries
Who should attend?
Product owner
Scrum master
Development team
Sprint planning goals:
Each sprint should have a clearly defined business goal
The product owner describes the goal and product backlog items supporting it
It’s important for the whole team to understand why they are building the increment
Mechanics of sprint planning
The development team;
Takes stories from the top of the product backlog and assigns them to the sprint backlog
Assigns story points and labels
Ensures each story contains enough information for a developer to start working on it
Stops adding stories when the team’s velocity is reached
Team velocity:
The number of story points a team can complete in a single sprint
This will change over time as the team gets better at estimating and better at executing
The velocity is unique to the team because the story point assignment is unique to the team
Create a sprint milestone:
Create a sprint milestone to start the sprint
The milestone title should be short
The description should document the milestone goal
The duration should be 2 weeks
Create a milestone:
Steps in the Scrum Process:
The Sprint:
A sprint is one iteration through the design, code, test, deploy cycle
It is usually 2 weeks in duration
Every sprint should have a goal
Daily Execution:
Take the next highest priority item from the sprint backlog
Assign it to yourself
Move it in process
Occurs every day at the same time and place
Sometimes called the “daily Scrum”
Each team member briefly reports on their work
Called a “stand-up” during the meeting to keep it short
Timeboxed to 15 mins
Not a project status meeting – all status should be tabled for later discussion
Daily stand-up meeting:
Who should attend?
Scrum master
Development team
Product owner (optional)
Daily stand-up question:
Each team member answers three questions:
Impediments and blockers:
Impediments identified by the team should be unblocked by the scrum master
Developers that are blocked should work on the next story
Tabled topics:
Topics raised during the daily stand-up should be held until the meeting has ended
Anyone interested in those topics can stay to discuss
Milestones and burndowns:
Milestones can be created for anything in your project
Burndown charts can be used to measure your progress against a milestone
Burndown chart:
The measurement of story points completed vs. story points remaining for a sprint
Over time the story points remaining should go down, hence the name: burndown
Burndown chart examples:
Live demonstration of implemented stories
Product owner determines if stories are done based on acceptance criteria
Done stories are closed
Sprint Review meeting:
Who should attend?
Product owner
Scrum master
Development team
Stakeholders
Customers (Optional)
Sprint review:
Feedback gets converted into new product backlog stories
This is where iterative development allows the creation of products that couldn’t have been specified up-front in a plan-driven approach
Rejected Stories:
What about stories that are not considered done?
Add a label to indicate this and close them
Write a new story with new acceptance criteria
This will keep the velocity more accurate
A meeting to reflect on the sprint
Measures the health of the process
The development team must feel comfortable to speak freely
Who attend the meeting:
Scrum master
Development team
A time for reflection:
Three questions are answered:
The goal is improvement:
This is critical for maintaining a healthy team
The scrum master must ensure that changes are made as a result of the feedback
The goal is to improve for the next sprint
Measurements and metrics:
You can’t improve what you can’t measure
High performing teams use metrics to continually improve
They take baselines and set goals and measure against them
Beware of vanity metrics
Look for the actionable metrics
Baselines and Goals:
Baseline:
It currently requires 5 size team members, 10 hours to deploy a new release of your product
This costs you $X for every release
Goals:
Reduce deployment time from 10 hours to 2 hours
Increase percentage of defects detected in testing from 25% to 50%
Top 4 actionable metrics:
How quickly can you recover from failure?
Example metrics:
End of sprint activities:
Move stories from done to closed
Close the current milestone
Create a new sprint milestone
Adjust unfinished work
Handling untouched stories:
Stories not worked on can be moved to the top of the product backlog
Resist the urge to move them to the next sprint
Remember to unassign them from the sprint milestone
Handling unfinished stories:
Don’t move unfinished stories into the next sprint!
Give the developers credit for the work they did
This will keep your velocity more accurate
Adjust the description and story points of the unfinished story, label it unfinished, and move it to done
Write a new story for the remaining work
Assign remaining story points and move it to the next sprint
Ready for the next sprint:
All stories assigned to the current sprint are closed
All unfinished stories are reassigned
The sprint milestone is closed
A new sprint milestone is created
Agile Anti-Patterns:
No real product owner/Multiple product owners
Teams are too large
Teams are not dedicated
Teams are too geographically distributed
Teams are siloed
Teams are not self-managing
YOU WILL FAIL!
…and you should not wonder why.