of 27 /27
Software Engineering Principles Principles form the basis of methods, Principles form the basis of methods, techniques, methodologies and tools techniques, methodologies and tools Seven important principles that may be Seven important principles that may be used in all phases of software development used in all phases of software development Apply to the software product as well as Apply to the software product as well as the development process the development process 1

Software Engineering Principles Principles form the basis of methods, techniques, methodologies and tools Principles form the basis of methods, techniques,

Embed Size (px)

Citation preview

Software Engineering Principles

Principles form the basis of methods, techniques, Principles form the basis of methods, techniques, methodologies and toolsmethodologies and tools

Seven important principles that may be used in Seven important principles that may be used in all phases of software developmentall phases of software development

Apply to the software product as well as the Apply to the software product as well as the development processdevelopment process

1

Key principlesKey principles

Rigor and formalityRigor and formality Separation of concernsSeparation of concerns ModularityModularity AbstractionAbstraction Anticipation of changeAnticipation of change GeneralityGenerality IncrementallyIncrementally

2

Rigor and formalityRigor and formality

Software engineering is a creative design Software engineering is a creative design activity, BUT It must be practiced systematicallyactivity, BUT It must be practiced systematically

Rigor is a necessary complement to creativity Rigor is a necessary complement to creativity that increases our confidence in our that increases our confidence in our developmentsdevelopments

Formality is rigor at the highest degreeFormality is rigor at the highest degree

3

Examples: Rigor and formalityExamples: Rigor and formality

Product:Product: – – Formal-Mathematical analysis of program Formal-Mathematical analysis of program

correctnesscorrectness – – Rigorous-Systematic test data derivation Rigorous-Systematic test data derivation • • Process:Process: – – Rigorous- detailed documentation of each Rigorous- detailed documentation of each

development step in waterfall modeldevelopment step in waterfall model – – Formal- automated transformational process to Formal- automated transformational process to

derive program from formal specificationsderive program from formal specifications

4

Separation of concerns

To dominate complexity, separate the issues to To dominate complexity, separate the issues to concentrate on one at a timeconcentrate on one at a time

– – "Divide & conquer""Divide & conquer" Supports parallelization of efforts and separation Supports parallelization of efforts and separation

of responsibilitiesof responsibilities

5

Examples:Examples:

Process: Go through phases one after the other Process: Go through phases one after the other as in waterfall Modelas in waterfall Model

––Do separation of concerns by separating Do separation of concerns by separating activities with respect to timeactivities with respect to time

– – Product: Keep different types of product Product: Keep different types of product requirements separaterequirements separate

––Functionality discussed separately from the Functionality discussed separately from the performance constraintsperformance constraints

6

ModularityModularity

A complex system may be divided into simpler A complex system may be divided into simpler pieces called modulespieces called modules

• • A system that is composed of modules is called A system that is composed of modules is called modularmodular

• • Supports application of separation of concernsSupports application of separation of concerns – – when dealing with a module we can ignore when dealing with a module we can ignore

details of other modulesdetails of other modules

7

Modularity: Cohesion and Modularity: Cohesion and couplingcoupling Each module should be highly cohesiveEach module should be highly cohesive – – module understandable as a meaningful unitmodule understandable as a meaningful unit – – Components of a module are closely related to Components of a module are closely related to one anotherone another • • Modules should exhibit low couplingModules should exhibit low coupling – – modules have low interactions with othersmodules have low interactions with others – – understandable separatelyunderstandable separately

8

An ExampleAn Example

9

Abstraction

Identify the important aspects of a phenomenon Identify the important aspects of a phenomenon and ignore its detailsand ignore its details

– – Special case of separation of concernsSpecial case of separation of concerns – – The type of abstraction to apply depends on The type of abstraction to apply depends on

purposepurpose • • Example: the user interface of a watch (its Example: the user interface of a watch (its

buttons) abstracts from the watch's internals for buttons) abstracts from the watch's internals for the purpose of setting time; other abstractions the purpose of setting time; other abstractions needed to support repairneeded to support repair

10

Anticipation of change

Ability to support software evolution requires Ability to support software evolution requires anticipating anticipating

potential future changespotential future changes ––It is the basis for software evolvabilityIt is the basis for software evolvability

11

Generality

While solving a problem, try to discover if it is an While solving a problem, try to discover if it is an instance of a more general problem whose instance of a more general problem whose solution can solution can

be reused in other cases be reused in other cases • • Sometimes a general problem is easier to solve Sometimes a general problem is easier to solve

than a special casethan a special case ––Carefully balance generality against Carefully balance generality against

performance and costperformance and cost

12

Incrementality

Process proceeds in a stepwise fashion Process proceeds in a stepwise fashion (increments)(increments)

• • Examples (process)Examples (process) – – deliver subsets of a system early to get early deliver subsets of a system early to get early

feedback from expected users, then add new feedback from expected users, then add new features incrementallyfeatures incrementally

– – deal first with functionality, then turn to deal first with functionality, then turn to performanceperformance

13

14

Process: A Generic Process: A Generic ViewView

15

A Layered A Layered TechnologyTechnology

Software Engineering

a “quality” focusa “quality” focus

process modelprocess model

methodsmethods

toolstools

16

A Process A Process FrameworkFramework

Process frameworkProcess frameworkFramework activitiesFramework activities

work taskswork taskswork productswork productsmilestones & deliverablesmilestones & deliverablesQA checkpointsQA checkpoints

Umbrella ActivitiesUmbrella Activities

17

Framework ActivitiesFramework Activities

CommunicationCommunication PlanningPlanning ModelingModeling

Analysis of requirementsAnalysis of requirements DesignDesign

ConstructionConstruction Code generationCode generation TestingTesting

DeploymentDeployment

18

Umbrella ActivitiesUmbrella Activities Software project managementSoftware project management Formal technical reviewsFormal technical reviews Software quality assuranceSoftware quality assurance Software configuration managementSoftware configuration management Work product preparation and Work product preparation and

productionproduction Reusability managementReusability management MeasurementMeasurement Risk managementRisk management

19

The Process Model:The Process Model:AdaptabilityAdaptability

the framework activities will the framework activities will alwaysalways be be applied on applied on everyevery project ... BUT project ... BUT

the tasks (and degree of rigor) for each the tasks (and degree of rigor) for each activity will vary based on:activity will vary based on: the type of project the type of project characteristics of the projectcharacteristics of the project common sense judgment; concurrence of the common sense judgment; concurrence of the

project teamproject team

20

The CMMIThe CMMI Capability Maturity Model Integration (CMMI) – Capability Maturity Model Integration (CMMI) –

developed by The Software Engineering Institute developed by The Software Engineering Institute (SEI)(SEI)

The CMMI defines each process area in terms of The CMMI defines each process area in terms of “specific goals” and the “specific practices” required “specific goals” and the “specific practices” required to achieve these goals.to achieve these goals.

Specific goalsSpecific goals establish the characteristics that establish the characteristics that must exist if the activities implied by a process area must exist if the activities implied by a process area are to be effective. are to be effective.

Specific practicesSpecific practices refine a goal into a set of process-refine a goal into a set of process-related activities.related activities.

21

The CMMIThe CMMI

Level 0: Incomplete - Level 0: Incomplete - Process goals not satisfiedProcess goals not satisfied Level 1: Performed - Level 1: Performed - Process goals satisfiedProcess goals satisfied Level 2: Managed - Level 2: Managed - Process areas conforms to Process areas conforms to

organizationally defined policy, resources are organizationally defined policy, resources are available, work tasks are monitoredavailable, work tasks are monitored

Level 3: Defined - Level 3: Defined - Tailored according to the Tailored according to the organization’s standard processesorganization’s standard processes

Level 4: Quantitatively managed - Level 4: Quantitatively managed - Quantitative Quantitative assessmentassessment

Level 5: Optimized - Level 5: Optimized - Processes are optimizedProcesses are optimized

22

Process PatternsProcess Patterns Process patterns define a set of activities, Process patterns define a set of activities,

actions, work tasks, work products and/or related actions, work tasks, work products and/or related behaviorsbehaviors

A template is used to define a patternA template is used to define a pattern Typical examples:Typical examples:

Customer communication (a process activity)Customer communication (a process activity) Analysis (an action)Analysis (an action) Requirements gathering (a process task)Requirements gathering (a process task) Reviewing a work product (a process task)Reviewing a work product (a process task) Design model (a work product)Design model (a work product)

23

Process AssessmentProcess Assessment

The process should be assessed to ensure that it The process should be assessed to ensure that it meets a set of basic process criteria that have meets a set of basic process criteria that have been shown to be essential for a successful been shown to be essential for a successful software engineeringsoftware engineering.

Many different assessment options are available: Many different assessment options are available: SCAMPISCAMPI CBA IPICBA IPI SPICESPICE ISO 9001:2000ISO 9001:2000

24

Assessment and ImprovementAssessment and Improvement

Software Process

Software Process Assessment

is examined by identifies capabilitiesand risk of

identifiesmodifications to

Software Process Improvement

Capability Determination

leads to leads to

motivates

25

Personal Software Process Personal Software Process (PSP)(PSP)

Recommends five framework activities:Recommends five framework activities: PlanningPlanning High-level designHigh-level design High-level design reviewHigh-level design review DevelopmentDevelopment PostmortemPostmortem

stresses the need for each software stresses the need for each software engineer to identify errors early and as engineer to identify errors early and as important, to understand the types of important, to understand the types of errorserrors

26

Team Software Process (TSP)Team Software Process (TSP)

Each project is “launched” using a “script” Each project is “launched” using a “script” that defines the tasks to be accomplishedthat defines the tasks to be accomplished

Teams are self-directedTeams are self-directed Measurement is encouragedMeasurement is encouraged Measures are analyzed with the intent of Measures are analyzed with the intent of

improving the team processimproving the team process

27

The Primary Goal of Any Software The Primary Goal of Any Software Process: Process: High QualityHigh Quality

Remember:Remember:

High quality = project timelinessHigh quality = project timeliness

Why?Why?

Less rework!Less rework!