Extreme Programming (XP) PDF
Document Details
Uploaded by Deleted User
Tags
Summary
This document presents an overview of Extreme Programming (XP), a software development methodology, covering its values, process, roles, practices, and artefacts. The content discusses communication, simplicity, feedback, courage and respect as core values in XP. The document details phases like Exploration, Planning, Iterations to Release, Productionizing, and Maintenance, and includes notable artifacts like user story cards and task lists. It focuses on specific aspects of XP development and its impact on software projects.
Full Transcript
CHAPTER 4 EXTREME PROGRAMMING (XP) COURSE NAME SOFTWARE ENGINEERING (UNDERGRADUATE) CSC 3114 (UNDERGRADUATE) Slide-2 EXTREME PROGRAMMING q Evolved from the problems caused by...
CHAPTER 4 EXTREME PROGRAMMING (XP) COURSE NAME SOFTWARE ENGINEERING (UNDERGRADUATE) CSC 3114 (UNDERGRADUATE) Slide-2 EXTREME PROGRAMMING q Evolved from the problems caused by the long development cycles of traditional development models (Beck 1999a). q First started as 'simply an opportunity to get the job done‘ (Haungs 2001) with practices that had been found effective in software development processes during the preceding decades (Beck 1999b) q Method is formed around common sense principles and simple to understand practices ¡ No process fits every project, rather, simple practices should be tailored to suit an individual project MMH Slide-3 XP VALUES q Communication: XP has a culture of oral communication and its practices are designed to encourage interaction. “Problems with projects can invariably be traced back to somebody not talking to somebody else about something important.” q Simplicity: Design the simplest product that meets the customer’s needs. An important aspect of the value is to only design and code what is in the current requirements rather than to anticipate and plan for unstated requirements. MMH Slide-4 XP VALUES q Feedback: The development team obtains feedback from the customers at the end of each iteration and external release. This feedback drives the next iteration. q Courage: Allow the team to have courage in its actions and decision making. For example, the development team might have the courage to resist pressure to make unrealistic commitments. q Respect: Team members need to care about each other and about the project. MMH Slide-5 XP PROCESS q The life cycle of XP consists of five phases: 1. Exploration 2. Planning 3. Iterations to Release 4. Productionizing 5. Maintenance and Death MMH Slide-6 XP PROCESS – EXPLORATION PHASE q The customers write out the story cards that they wish to be included in the first release q At the same time the project team familiarize themselves with the tools, technology and practices they will be using in the project q The exploration phase takes between a few weeks to a few months, depending largely on how familiar the technology is to the programmers MMH Slide-7 XP PROCESS – PLANNING PHASE § Users stories are written § Estimate the effort of working with the user stories § Priorities are given to the user stories to be implemented § Release planning creates the release schedule MMH Slide-8 XP PROCESS – ITERATIONS TO RELEASE PHASE q Includes several iterations of the systems before the first release q Each take one to four weeks to implement q The first iteration creates a system with the architecture of the whole system. This is achieved by selecting the stories that will enforce building the structure for the whole system q The customer decides the stories to be selected for each iteration q At the end of the last iteration the system is ready for production MMH Slide-9 XP PROCESS – PRODUCTIONIZING PHASE q Requires extra testing and checking of the performance of the system before the system can be released to the customer q New changes may still be found and the decision has to be made if they are included in the current release q The iterations may need to be quickened from three weeks to one week q The postponed ideas and suggestions are documented for later implementation MMH Slide- 10 XP PROCESS – MAINTENANCE PHASE q After the first release is productionized for customer use, the XP project must both keep the system in the production running while also producing new iterations q Requires an effort also for customer support tasks q Development velocity may decelerate after the system is in production q May require incorporating new people into the team and changing the team structure MMH Slide-11 XP PROCESS – DEATH PHASE q When the customer does no longer have any stories to be implemented q System satisfies customer needs also in other respects (e.g., concerning performance and reliability) q Necessary documentation of the system is finally written as no more changes to the architecture, design or code are made q Death may also occur if the system is not delivering the desired outcomes, or if it becomes too expensive for further development MMH Slide-12 XP - ROLES AND RESPONSIBILITY q Customer: writes the stories and functional tests, and decides when each requirement is satisfied. The customer sets the implementation priority for the requirements q Programmer: keeps the program code as simple and definite as possible q Tester: helps the customer write functional tests, also run functional tests regularly, broadcast test results and maintain testing tools MMH Slide-13 XP - ROLES AND RESPONSIBILITY q Tracker: gives feedback in XP. He traces the estimates made by the team (e.g. effort estimates) and gives feedback on how accurate they are in order to improve future estimations. He also traces the progress of each iteration and evaluates whether the goal is reachable within the given resource and time constraints or if any changes are needed in the process q Coach: Coach is the person responsible for the process as a whole. A sound understanding of XP is important in this role enabling the coach to guide the other team members in following the process q Consultant: Consultant is an external member possessing the specific technical knowledge needed q Manager (Big Boss): Manager makes the decisions MMH Slide-14 XP - PRACTICES q Interaction: Close interaction between the customer and the programmers. The programmers estimate the effort needed for the implementation of customer stories and the customer then decides about the scope and timing of releases. q Small/short releases: A simple system is "productionized“ rapidly – at least once in every 2 to 3 months. New versions are then released even daily, but at least monthly. q Metaphor: The system is defined by a metaphor/set of metaphors between the customer and the programmers. This "shared story" guides all development by describing how the system works. MMH Slide-15 XP - PRACTICES q Simple design: The emphasis is on designing the simplest possible solution that is implementable at the moment q Testing: Software development is test driven. Unit tests are implemented continuously q Refactoring: Restructuring the system by removing duplication, improving communication, simplifying and adding flexibility q Collective ownership: Anyone can change any part of the code at any time MMH Slide-16 XP - PRACTICES q Pair programming § Two people write the code at one computer § One programmer, the driver, has control of the keyboard/mouse and actively implements the program. The other programmer, the observer, continuously observes the work of the driver to identify tactical defects (syntactic, spelling, etc.) and also thinks strategically about the direction of the work. § Two programmers can brainstorm any challenging problem. Because they periodically switch roles. q Continuous integration: A new piece of code is integrated into the code-base as soon as it is ready. MMH Slide-17 XP - PRACTICES q 40-hour week: A maximum of 40-hour working week q On-site customer: Customer has to be present and available full-time for the team q Coding standards: Coding rules exist and are followed by the programmers (e.g. error message by exception handling). Communication through the code should be emphasized q Open workspace: A large room with small cubicle (compartment) is preferred q Just rules: Team has its own rules that are followed, but can also be changed at any time. The changes have to be agreed upon and their impact has to be assessed MMH Slide-18 XP - ARTEFACTS q User story cards § Paper index cards which contain brief requirement (features, non-functional) descriptions § Not a full requirement statement § Commitment for further conversation between the developer and the customer § During this conversation, the two parties will come to an oral understanding of what is needed for the requirement to be fulfilled § Customer priority and developer resource estimate are added to the card § The resource estimate for a user story must not exceed the iteration duration MMH Slide-19 XP - ARTEFACTS q Task list § A listing of the tasks (one-half to three days in duration) for the user stories that are to be completed for an iteration § Tasks represent concrete aspects of a user story § Programmers volunteer for tasks rather than are assigned to tasks q CRC (Class-Responsibility-Collaboration) cards (optional) § Paper index card on which one records the responsibilities and collaborators of classes which can serve as a basis for software design § The classes, responsibilities, and collaborators are identified during a design brainstorming/role-playing session involving multiple developers MMH Slide-20 XP - ARTEFACTS q Customer Acceptance Tests § Textual descriptions and automated test cases which are developed by the customer § The development team demonstrates the completion of a user story and the validation of customer requirements by passing these test cases. q Visible Wall Graphs ¡ To foster communication and accountability, progress graphs are usually posted in team work area. These progress graphs often involve how many stories are completed and/or how many acceptance test cases are passing. MMH Slide-21 XP - ARTEFACTS q Scope and use & Limitation § XP is aimed at small to medium-sized teams § Requires the development team to be located in one place. Scattering of programmers on two floors or even on one floor is intolerable for XP § Communication and coordination between project members should be enabled at all times § Require experienced team member through the project development time (XP is people based rather than plan based) MMH Slide-22 HOW XP SOLVES SOME SE PROBLEMS Problem Solution Slipped schedule Short development cycles Cost of changes Extensive, ongoing testing, system always running Defect rates Unit tests, customer tests Misunderstand the business Customer is a part of the team Business changes Changes are welcome Staff turnover (replacement) Intensive teamwork MMH Slide - 23 REFERENCES ¡ R.S. Pressman & Associates, Inc. (2010). Software Engineering: A Practitioner’s Approach. ¡ Kelly, J. C., Sherif, J. S., & Hops, J. (1992). An analysis of defect densities found during software inspections. Journal of Systems and Software, 17(2), 111-117. ¡ Bhandari, I., Halliday, M. J., Chaar, J., Chillarege, R., Jones, K., Atkinson, J. S., & Yonezawa, M. (1994). In-process improvement through defect data interpretation. IBM Systems Journal, 33(1), 182-214.