ebook img

The art of agile development PDF

403 Pages·2.241 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview The art of agile development

The Art of Agile Development James Shore and Shane Warden Beijing • Cambridge • Farnham • Köln • Paris • Sebastopol • Taipei • Tokyo The Art of Agile Development by James Shore and Shane Warden Copyright © 2008 O’Reilly Media, Inc., Inc. All rights reserved. Printed in the United States of America. Published by O’Reilly Media, Inc., 1005 Gravenstein Highway North, Sebastopol, CA 95472 O’Reilly books may be purchased for educational, business, or sales promotional use. Online editions are also available for most titles (http://safari.oreilly.com). For more information, contact our corporate/ institutional sales department: (800) 998-9938 or [email protected]. Editor: Mary O’Brien Indexer: Joe Wizda Copy Editor: Sarah Schneider Cover Designer: Karen Montgomery Production Editor: Sarah Schneider Interior Designer: David Futato Proofreader: Sada Preisch Illustrator: Robert Romano Printing History: October 2007: First Edition. The O’Reilly logo is a registered trademark of O’Reilly Media, Inc. The Theory in Practice series designations, The Art of Agile Development, and related trade dress are trademarks of O’Reilly Media, Inc. While every precaution has been taken in the preparation of this book, the publisher and authors assume no responsibility for errors or omissions, or for damages resulting from the use of the information contained herein. TM This book uses RepKover™, a durable and flexible lay-flat binding. ISBN-10: 0-596-52767-5 ISBN-13: 978-0-596-52767-9 [C] Table of Contents Preface ................................................................ xiii Part I. Getting Started 1. Why Agile? .......................................................... 3 Understanding Success 4 Beyond Deadlines 4 The Importance of Organizational Success 5 Enter Agility 6 2. How to Be Agile ..................................................... 9 Agile Methods 9 Don’t Make Your Own Method 10 The Road to Mastery 11 Find a Mentor 12 3. Understanding XP ................................................. 15 The XP Lifecycle 18 The XP Team 27 XP Concepts 39 4. Adopting XP ....................................................... 43 Is XP Right for Us? 43 Go! 51 Assess Your Agility 62 Part II. Practicing XP 5. Thinking ........................................................... 69 Pair Programming 71 Energized Work 79 Informative Workspace 83 IX Root-Cause Analysis 88 Retrospectives 91 6. Collaborating ...................................................... 99 Trust 102 Sit Together 112 Real Customer Involvement 120 Ubiquitous Language 124 Stand-Up Meetings 129 Coding Standards 133 Iteration Demo 138 Reporting 144 7. Releasing ........................................................ 153 “Done Done” 156 No Bugs 160 Version Control 169 Ten-Minute Build 177 Continuous Integration 183 Collective Code Ownership 191 Documentation 195 8. Planning .......................................................... 199 Vision 201 Release Planning 206 The Planning Game 219 Risk Management 224 Iteration Planning 233 Slack 246 Stories 253 Estimating 260 9. Developing ....................................................... 271 Incremental Requirements 273 Customer Tests 278 Test-Driven Development 285 Refactoring 303 Simple Design 314 Incremental Design and Architecture 321 Spike Solutions 331 Performance Optimization 335 Exploratory Testing 341 X TABLE OF CONTENTS Part III. Mastering Agility 10. Values and Principles ............................................. 353 Commonalities 353 About Values, Principles, and Practices 354 Further Reading 354 11. Improve the Process .............................................. 357 Understand Your Project 357 Tune and Adapt 358 Break the Rules 359 12. Rely on People ................................................... 361 Build Effective Relationships 361 Let the Right People Do the Right Things 363 Build the Process for the People 364 13. Eliminate Waste .................................................. 367 Work in Small, Reversible Steps 367 Fail Fast 369 Maximize Work Not Done 370 Pursue Throughput 371 14. Deliver Value ..................................................... 375 Exploit Your Agility 375 Only Releasable Code Has Value 376 Deliver Business Results 378 Deliver Frequently 379 15. Seek Technical Excellence ........................................ 381 Software Doesn’t Exist 381 Design Is for Understanding 382 Design Trade-offs 383 Quality with a Name 383 Great Design 383 Universal Design Principles 384 Principles in Practice 387 Pursue Mastery 388 References ........................................................... 391 Index ................................................................. 397 TABLE OF CONTENTS XI PART I Getting Started CHAPTER 1 Why Agile? Agile development is popular. All the cool kids are doing it: Google, Yahoo, Symantec, Microsoft, and the list goes on.* I know of one company that has already changed its name to Agili-something in order to ride the bandwagon. (They called me in to pitch their “agile process,” which, upon further inspection, was nothing more than outsourced offshore development, done in a different country than usual.) I fully expect the big consulting companies to start offering Certified Agile Processes and Certified Agile Consultants—for astronomical fees, of course—any day now. Please don’t get sucked into that mess. In 1986, [Brooks] famously predicted that there were no silver bullets: that by 1996, no single technology or management technique would offer a tenfold increase in productivity, reliability, or simplicity. None did. Agile development isn’t a silver bullet, either. In fact, I don’t recommend adopting agile development solely to increase productivity. Its benefits— even the ability to release software more frequently—come from working differently, not from working faster. Although anecdotal evidence indicates that agile teams have above-average productivity,† that shouldn’t be your primary motivation. Your team will need time to learn agile development. While they learn—and it will take a quarter or two—they’ll go slower, not faster. In addition, emphasizing productivity might encourage your team to take shortcuts and to be less rigorous in their work, which could actually harm productivity. Agile development may be the cool thing to do right now, but that’s no reason to use it. When you consider using agile development, only one question matters. Will agile development help us be more successful? * Source: various experience reports at the Extreme Programming and Agile conferences. †See, for example, [Van Schooenderwoert], [Mah], and [Anderson 2006]. 3 When you can answer that question, you’ll know whether agile development is right for you. Understanding Success The traditional idea of success is delivery on time, on budget, and according to specification. [Standish] provides some classic definitions: Successful Despite their popularity, there’s “Completed on time, on budget, with all features and something wrong with these functions as originally specified.” definitions. Challenged “Completed and operational but over budget, over the time estimate, [with] fewer features and functions than originally specified.” Impaired “Cancelled at some point during the development cycle.” Despite their popularity, there’s something wrong with these definitions. A project can be successful even if it never makes a dime. It can be challenged even if it delivers millions of dollars in revenue. CIO Magazine commented on this oddity: Projects that were found to meet all of the traditional criteria for success—time, budget and specifications—may still be failures in the end because they fail to appeal to the intended users or because they ultimately fail to add much value to the business. ... Similarly, projects considered failures according to traditional IT metrics may wind up being successes because despite cost, time or specification problems, the system is loved by its target audience or provides unexpected value. For example, at a financial services company, a new system... was six months late and cost more than twice the original estimate (final cost was $5.7 million). But the project ultimately created a more adaptive organization (after 13 months) and was judged to be a great success—the company had a $33 million reduction in write-off accounts, and the reduced time-to-value and increased capacity resulted in a 50 percent increase in the number of concurrent collection strategy tests in production.* Beyond Deadlines There has to be more to success than meeting deadlines... but what? When I was a kid, I was happy just to play around. I loved the challenge of programming. When I got a program to work, it was a major victory. Back then, even a program that didn’t work was a success of some sort, as long as I had fun writing it. My definition of success centered on personal rewards. As I gained experience, my software became more complicated and I often lost track of how it worked. I had to abandon some programs before they were finished. I began to believe that maintainability was the key to success—an idea that was confirmed as I entered the workforce and began working with teams of other programmers. I prided myself on producing elegant, maintainable code. Success meant technical excellence. * R. Ryan Nelson, “Applied Insight—Tracks in the Snow,” CIO Magazine, http://www.cio.com/archive/090106/applied.html. 4 CHAPTER 1: WHY AGILE? Organizational success Technical Personal success success Figure 1-1. Types of success Despite good code, some projects flopped. Even impeccably executed projects could elicit yawns from users. I came to realize that my project teams were part of a larger ecosystem involving dozens, hundreds, or even thousands of people. My projects needed to satisfy those people ... particularly the ones signing my paycheck. In fact, for the people funding the work, the value of the software had to exceed its cost. Success meant delivering value to the organization. These definitions aren’t incompatible. All three types of success are important (see Figure 1-1). Without personal success, you’ll have trouble motivating yourself and employees. Without technical success, your source code will eventually collapse under its own weight. Without organizational success, your team may find that they’re no longer wanted in the company. The Importance of Organizational Success Organizational success is often neglected by software teams in favor of the more easily achieved technical and personal successes. Rest assured, however, that even if you’re not taking responsibility for organizational success, the broader organization is judging your team at this level. Senior management and executives aren’t likely to care if your software is elegant, maintainable, or even beloved by its users; they care about results. That’s their return on investment in your project. If you don’t achieve this sort of success, they’ll take steps to ensure that you do. Unfortunately, senior managers don’t usually have the time or perspective to apply a nuanced solution to each project. They wield swords, not scalpels. They rightly expect their project teams to take care of fine details. When managers are unhappy with your team’s results, the swords come out. Costs are the most obvious target. There are two easy ways to cut them: set aggressive deadlines to reduce development time, or ship the work to a country with a lower cost of labor. Or both. These are clumsy techniques. Aggressive deadlines end up increasing schedules rather than reducing them [McConnell 1996] (p. 220), and offshoring has hidden costs [Overby]. Do aggressive deadlines and the threat of offshoring sound familiar? If so, it’s time for your team to take back responsibility for its success: not just for personal or technical success, but for organizational success as well. THE IMPORTANCE OF ORGANIZATIONAL SUCCESS 5 WHAT DO ORGANIZATIONS VALUE? Although some projects’ value comes directly from sales, there’s more to organizational value than revenue. Projects provide value in many ways, and you can’t always measure that value in dollars and cents. Aside from revenue and cost savings, sources of value include:* • Competitive differentiation • Brand projection • Enhanced customer loyalty • Satisfying regulatory requirements • Original research • Strategic information Enter Agility Will agile development help you be more successful? It might. Agile development focuses on achieving personal, technical, and organizational successes. If you’re having trouble with any of these areas, agile development might help. Organizational Success Agile methods achieve organizational successes by focusing on delivering value and decreasing costs. This directly translates to increased return on investment. Agile methods also set expectations early in the project, so if your project won’t be an organizational success, you’ll find out early enough to cancel it before your organization has spent much money. Specifically, agile teams increase value by including business experts and by focusing development efforts on the core value that the project provides for the organization. Agile projects release their most valuable features first and release new versions frequently, which dramatically increases value. When business needs change or when new information is discovered, agile teams change direction to match. In fact, an experienced agile team will actually seek out unexpected opportunities to improve its plans. Agile teams decrease costs as well. They do this partly by technical excellence; the best agile projects generate only a few bugs per month. They also eliminate waste by cancelling bad projects early and replacing expensive development practices with simpler ones. Agile teams communicate quickly and accurately, and they make progress even when key individuals are unavailable. They regularly review their process and continually improve their code, making the software easier to maintain and enhance over time. * Based partly on [Denne & Cleland-Huang]. 6 CHAPTER 1: WHY AGILE?

See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.