Lecture 8: DSP - Florida State University

Download Report

Transcript Lecture 8: DSP - Florida State University

SEA Side

Software Engineering Annotations Annotation 1: Extreme Programming Professor Sara Stoecklin Director of Software Engineering- Panama City [email protected]

[email protected]

850-522-2091 850-522-2023 Ex 182 Florida State University Computer Science

SEA Side – Extreme Programming 1

Extreme Programming

Definition:

An agile (lightweight) team process to create software rapidly that is extremely reliable, efficient, and well-factored. - (marketing)

A deliberate and disciplined approach to software development that emphasizes team work to improve the process through utilization of refactoring, patterns, and good testing.

SEA Side – Extreme Programming 2

Extreme Programming (XP)

History:

Many of the practices were created and tested as part of the Chrysler C3 project, which was a very successful software development project for a payroll system.

About six years old and has proved to be a cost effective process for development of software.

SEA Side – Extreme Programming 3

Why Not XP

• • •

Lightweight – does not scale

Meant for small projects 2-15 people, 1 to 2 years. Most are less than 6 people and less than one year projects. Not academically Proven

Statistics and successes are not tested by an independent group. Lot of hype. Easy systems

Anyone can develop a small system what about a 5 year system with 300 database tables, 500 screens, 4000 reports and 1500 transactions. What about an operating system such as MVS or Windows XP?

SEA Side – Extreme Programming 4

Why XP

Promotes Good Software Engineering Principles

Patterns, refactoring, cohesion, coupling, encapsulation, polymorphism, and inheritance.

Allows the personal software process to mature

Allows a finely tuned software development process to emerge within an organization.

Promotes Good Testing Principles

Defines a method for testing, promotes testing as completely, encourages good unit testing.

SEA Side – Extreme Programming 5

What are the XP Practices

There are 12 simple practices which rely on the synergy between them. These practices support each other by covering the weakness of one with the strength of others

Five are basic XP principles

Seven are process techniques

SEA Side – Extreme Programming 6

Twelve XP Practices

Five Basic XP Principles

Small Releases

40-hour work week

On-site customer

Collective Ownership

Coding Standards

SEA Side – Extreme Programming 7

Twelve XP Practices

Five Basic XP Principles

Small Releases

»

Everything released to the customer should be as small as possible

»

Put simple system to work as quickly as possible

»

Release new versions on a very short development cycle

»

Helps to reduce schedule slips since short release cycles limit scope for each release

»

Release planning meeting discover these small units of functional behavior.

SEA Side – Extreme Programming 8

Twelve XP Practices

Five Basic XP Principles

40-hour work week

»

Never work overtime, go home at 5:00, have a nice week-end

»

Rested programmers have more courage and make fewer mistakes

»

Rested staff keeps them happy causing more chance of having stable teams.

»

Rested staff more able to handle intense inter personal interaction of the team

»

Use the release planning meeting to plan the 40 hour week releases

SEA Side – Extreme Programming 9

Twelve XP Practices

Five Basic XP Principles

On-site customer

» »

A real customer is available on site.

Answers questions, resolve disputes, set small scale priorities, and provide test .

»

Customer participates in release planning meetings to define the small incremental RELEASES.

» »

Customer participates in writing USER STORIES Customer participates in testing RELEASES with the USER STORIES

SEA Side – Extreme Programming 10

Twelve XP Practices

Five Basic XP Principles

Collective Ownership

»

Anyone can change the code and anyone who sees an opportunity to add value to any portion of the code is required to do it at any time.

» » » »

Everyone improves product Fix bugs – define tests to test bugs Refactor Mercilessly Create unit test for each unit developed

»

Frequent integration of new code

SEA Side – Extreme Programming 11

Twelve XP Practices

Five Basic XP Principles

Coding Standards

»

Everybody defines the class naming standards, variable naming standards, class names, variable names.

»

Standards are set or evolve for the team.

SEA Side – Extreme Programming 12

Twelve XP Practices

Seven Process Techniques

The Planning Game

Metaphor

Simple Design

Pair Programming

Refactoring

Continuous Integration

Testing

SEA Side – Extreme Programming 13

Twelve XP Practices

Seven Process Techniques

The Planning Game

»

Customer and Developer participate in writing USER STORIES (other names - lightweight use cases, process narratives, scenarios). CRC cards helpful.

»

Each story transforms into one or more releases on a release plan.

»

Customer and Developer write, estimate stories, schedule by priority or risk with the team owning the schedule.

»

If the project velocity gets too high then we limit the scope of this release. If the load factor of a story gets to high then we split the story.

»

Customer writes the acceptance test cases for these USER STORIES

SEA Side – Extreme Programming 14

Twelve XP Practices

Seven Process Techniques

Metaphor

»

Start development with just a metaphor not a detailed architectural plan

»

Be consistant with names, find common ground, find common domain patterns, solutions

»

Uniformity simplifies coding.

SEA Side – Extreme Programming 15

Twelve XP Practices

Seven Process Techniques

Simple Design

»

The right design for the system at any moment is the one that had not duplication, runs all the tests, does everything needed, upholds constraints.

» »

Start with small simple designs A simple design takes less time to finish than a complex one.

» » » »

Never add functinality before it is scheduled.

Simple designs are easier to maintain.

Refactor out complexity Do spike solutions (risk first)

SEA Side – Extreme Programming 16

Twelve XP Practices Seven Process Techniques

Pair Programming

»

Master feedback loop to ensure that the XP programming practices stay in place.

»

Reduces overall project risk.

»

Two people working side by side to produce quality code – one thinks, one drives.

SEA Side – Extreme Programming 17

Twelve XP Practices

Seven Process Techniques

Pair Programming

»

Thinker

• • • • • • •

Is this approach going to work What are some test cases to test this code Is there some way to simplify the code Is there some pattern we should be using Is there duplicated code Is there some refactoring technique to use Is there some other solution

»

Driver

• •

Keys in solutions Aids thinker

SEA Side – Extreme Programming 18

Twelve XP Practices

Seven Process Techniques

Pair Programming

»

Does not cost twice as much.

• • • •

Aids in jelling programming assignment Encourages testing Encourages thinking Encourages not leaving bad code

» »

Pair new programmer with old-timer.

Rules:

• • • • •

can’t go off and do things separately Both must be able to see the monitor Take turns driving No lone rangers Trust your partner

SEA Side – Extreme Programming 19

Twelve XP Practices

Seven Process Techniques

Refactoring

»

Remove duplication

»

Improve communications

»

Add flexibility

»

Simplify

»

Refactor for patterns (design, application, analysis)

»

Refactor for good design

»

Keep code clean

SEA Side – Extreme Programming 20

Twelve XP Practices

Seven Process Techniques

Continuous Integration

»

Build, integrate and test daily according to the iteration planning and release scheduling

• • •

Load current release Load changes Run tests

»

Take iteration deadlines seriously

»

Measure progress with standup meetings

SEA Side – Extreme Programming 21

Twelve XP Practices

Seven Process Techniques

Testing

»

Types

• •

Functional testing – black box Unit tests – programmer written with method by method

• • • •

Acceptance tests - customer written for stories Parallel tests – test to assure system works as old system Stress test – simulate worst case load Monkey test – test behavior of nonsensical input

SEA Side – Extreme Programming 22

Twelve XP Practices

Seven Process Techniques

Testing

»

Unit tests

• •

Cornerstone of XP – code it first Need a unit test framework

http: www.XProgramming.com

• • • • •

Harder it is to write the test- more you need it Enables collective code ownership Junit testing becoming standard Enables refactoring and frequent integration Safety net of regression and validation tests

SEA Side – Extreme Programming 23

Twelve XP Practices

Seven Process Techniques

Testing

»

Unit tests

• •

Rhythm for unit testing Loop iteratively

Write a little code

Write the code for testing this code

Test written code with code for testing

Correct code or test for code

SEA Side – Extreme Programming 24

Twelve XP Practices

Seven Process Techniques

Testing

»

Acceptance Tests

• • • • •

Created from user stories Black box system tests Used in regression tests Should be automated so they can be ran often Improve the quality of the system

SEA Side – Extreme Programming 25

Defines user requirements

The XP Process

Build User Stories

requirements new velocity metaphor

Define Architectural Spikes Conduct Release Planning

estimating release plan

Controls Scope Build Iteration

bugs next iteration

Conduct Acceptance Testing

release

Improves Quality SEA Side – Extreme Programming 26

Getting Started

How do I start using XP

A new project

– – – – –

Collect user stories Conduct spike solutions Schedule release planning meeting Plan iterations Start iterative development

– –

Try automated unit tests Try automated acceptance testing

SEA Side – Extreme Programming 27

Web-Sites

• • • • •

http://www.extremeprogramming.org

http://www.junit.org

http://www.instantiations.com/jfactor/ http://c2.com/cgi/wiki?ExtremeProgrammingRoadma

p http://www.xpuniverse.com/home

SEA Side – Extreme Programming 28

Summary

• • • •

Remember – XP is lightweight – does not scale

Meant for small projects 2-15 people, 1 to 2 years. Most are less than 6 people and less than one year projects. Promotes Good Software Engineering Principles

Patterns, refactoring, cohesion, coupling, encapsulation, polymorphism, and inheritance. Allows the personal software process to mature

Allows a finely tuned software development process to emerge within an organization. Promotes Good Testing Principles

Defines a method for testing, promotes testing as completely, encourages good unit testing.

SEA Side – Extreme Programming 29

Computing Degrees at FSU-Panama City

Information System Degrees Scientific Degrees

Management Information Systems (BS) . Advisor Jeanne Dexter – [email protected]

    Systems Analysis IT Management Computer Consulting Application Programming

Computer Science (MS, Web-BS)

    

. Advisor Sara Stoecklin [email protected]

Operating Systems Systems Programming Applications Programming Database Administration Systems Administration

Information Studies (Web – BS,MS) Computer Engineering (BS, Web-MS)

     

. Advisor Alan Stromberg [email protected]

. Advisor Kamran Imen [email protected]

Web Development

Embedded Systems Network Management

Image Processing Information Systems

Electronics and Electromagnetics Management of Information Services

 

Signals and Systems Communications Social Informatics

Microprocessors Information and Communication Technologies

SEA Side – Extreme Programming 

Computer Architecture

30

. Degree Programs http://www.pc.fsu.edu/degreeplansheets/default.asp