– 04 – 2015-05-04 – main –
Softwaretechnik / Software-Engineering
Lecture 04: More Process Modelling & Software Metrics
2015-05-04
- Prof. Dr. Andreas Podelski, Dr. Bernd Westphal
Albert-Ludwigs-Universit¨ at Freiburg, Germany
Lecture 04: More Process Modelling & Software Metrics - - PowerPoint PPT Presentation
Softwaretechnik / Software-Engineering Lecture 04: More Process Modelling & Software Metrics 2015-05-04 Prof. Dr. Andreas Podelski, Dr. Bernd Westphal 04 2015-05-04 main Albert-Ludwigs-Universit at Freiburg, Germany
– 04 – 2015-05-04 – main –
Albert-Ludwigs-Universit¨ at Freiburg, Germany
– 04 – 2015-05-04 – Sprelim –
2/91 Last Lecture:
This Lecture:
what is the consequence? what is tailoring in the context of “V-Modell XT”?
– 04 – 2015-05-04 – main –
3/91
– 04 – 2015-05-04 – Sevoinciter –
4/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
yes to some amount to a low amount
– 04 – 2015-05-04 – Sevoinciter –
4/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
yes to some amount to a low amount
evolutionary software development — an approach which includes evolutions
changed requirements are considered by developing the software in sequential steps
Ludewig & Lichter (2013), flw. (Z¨ ullighoven, 2005)
– 04 – 2015-05-04 – Sevoinciter –
4/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
yes to some amount to a low amount
evolutionary software development — an approach which includes evolutions
changed requirements are considered by developing the software in sequential steps
Ludewig & Lichter (2013), flw. (Z¨ ullighoven, 2005)
iterative software development — software is developed in multiple iterative
steps, all of them planned and controlled. Goal: each iterative step, beginning with the second, corrects and improves the existing system based on defects detected during usage. Each iterative steps includes the characteristic activities analyse, design, code, test.
Ludewig & Lichter (2013)
– 04 – 2015-05-04 – Sevoinciter –
5/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
incremental software development — The total extension of a system under
development remains open; it is realised in stages of expansion. The first stage is the core system. Each stage of expansion extends the existing system and is subject to a separate project. Providing a new stage of expansion typically includes (as with iterative development) an improvement of the old components.
Ludewig & Lichter (2013)
– 04 – 2015-05-04 – Sevoinciter –
5/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
incremental software development — The total extension of a system under
development remains open; it is realised in stages of expansion. The first stage is the core system. Each stage of expansion extends the existing system and is subject to a separate project. Providing a new stage of expansion typically includes (as with iterative development) an improvement of the old components.
Ludewig & Lichter (2013)
– 04 – 2015-05-04 – Sevoinciter –
5/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
incremental software development — The total extension of a system under
development remains open; it is realised in stages of expansion. The first stage is the core system. Each stage of expansion extends the existing system and is subject to a separate project. Providing a new stage of expansion typically includes (as with iterative development) an improvement of the old components.
Ludewig & Lichter (2013)
incremental development — A software development technique in which requirements definition, design, implementation, and testing occur in an overlapping, iterative (rather than sequential) manner, resulting in incremental completion of the overall software product. IEEE 610.12 (1990)
– 04 – 2015-05-04 – Sevoinciter –
5/91
Analysis of Requirements Use on Target System Defined Steps Preliminary Results Used Complete Plan
Rapid Prototyping Evolutionary Development Iterative Development Incremental Development
. . .
incremental software development — The total extension of a system under
development remains open; it is realised in stages of expansion. The first stage is the core system. Each stage of expansion extends the existing system and is subject to a separate project. Providing a new stage of expansion typically includes (as with iterative development) an improvement of the old components.
Ludewig & Lichter (2013)
incremental development — A software development technique in which requirements definition, design, implementation, and testing occur in an overlapping, iterative (rather than sequential) manner, resulting in incremental completion of the overall software product. IEEE 610.12 (1990)
Examples: operating system releases, short time-to-market (→ continuous integration).
– 04 – 2015-05-04 – main –
6/91
– 04 – 2015-05-04 – Sspiral –
7/91 risk — a problem, which did not occur yet, but on occurrence threatens important project goals or results. Whether it will occur, cannot be surely predicted.
Ludewig & Lichter (2013)
riskvalue = p · K
p: probability of problem occurrence, K: cost in case of problem occurrence.
– 04 – 2015-05-04 – Sspiral –
7/91 risk — a problem, which did not occur yet, but on occurrence threatens important project goals or results. Whether it will occur, cannot be surely predicted.
Ludewig & Lichter (2013)
riskvalue = p · K
p: probability of problem occurrence, K: cost in case of problem occurrence.
105 106 107 108 cost in case
/ e 0.01 0.1 1 10 100 500 incidence prob- ability p / 10−3
acceptable risks inacceptable risks extreme risks
– 04 – 2015-05-04 – Sspiral –
7/91 risk — a problem, which did not occur yet, but on occurrence threatens important project goals or results. Whether it will occur, cannot be surely predicted.
Ludewig & Lichter (2013)
riskvalue = p · K
p: probability of problem occurrence, K: cost in case of problem occurrence.
105 106 107 108 cost in case
/ e 0.01 0.1 1 10 100 500 incidence prob- ability p / 10−3
acceptable risks inacceptable risks extreme risks
10−9 or ‘Extremely Improbable”’ (AC 25.1309-1).
– 04 – 2015-05-04 – Sspiral –
8/91
Barry W. Boehm
Repeat until end of project (successful completion or failure):
(i) determine the set R of risks threatening the project; if R = ∅, the project is successfully completed (ii) assign each risk r ∈ R a risk value v(r) (iii) for the risk r0 with the highest risk value, r0 = max{v(r) | r ∈ R}, find a way to eliminate this risk, and go this way; if there is no way to eliminate the risk, stop with project failure
– 04 – 2015-05-04 – Sspiral –
8/91
Barry W. Boehm
Repeat until end of project (successful completion or failure):
(i) determine the set R of risks threatening the project; if R = ∅, the project is successfully completed (ii) assign each risk r ∈ R a risk value v(r) (iii) for the risk r0 with the highest risk value, r0 = max{v(r) | r ∈ R}, find a way to eliminate this risk, and go this way; if there is no way to eliminate the risk, stop with project failure
Advantages:
– 04 – 2015-05-04 – Sspiral –
8/91
Barry W. Boehm
Repeat until end of project (successful completion or failure):
(i) determine the set R of risks threatening the project; if R = ∅, the project is successfully completed (ii) assign each risk r ∈ R a risk value v(r) (iii) for the risk r0 with the highest risk value, r0 = max{v(r) | r ∈ R}, find a way to eliminate this risk, and go this way; if there is no way to eliminate the risk, stop with project failure
Advantages:
Note: risk can by anything; e.g. open technical questions (→ prototype?), but also lead developer leaving the company (→ invest in documentation), changed market situation (→ adapt appropriate features), . . .
– 04 – 2015-05-04 – Sspiral –
9/91
– 04 – 2015-05-04 – Sspiral –
9/91
A concrete process using the Spiral Model could look as follows:
t (cost, project progress) t0 t1 t2 t3
– 04 – 2015-05-04 – Sspiral –
9/91
A concrete process using the Spiral Model could look as follows:
t (cost, project progress) t0 t1 t2 t3
– 04 – 2015-05-04 – main –
10/91
– 04 – 2015-05-04 – Sprocesses –
11/91
A process model may describe:
dependencies (the procedure model);
Process models typically come with their own terminology (to maximise confusion?), e.g. what we call artefact is called product in V-Model terminology.
– 04 – 2015-05-04 – Sprocesses –
11/91
A process model may describe:
dependencies (the procedure model);
Process models typically come with their own terminology (to maximise confusion?), e.g. what we call artefact is called product in V-Model terminology. Process models are legion; we will take a closer look onto:
– 04 – 2015-05-04 – Sprocesses –
12/91
to tag theirs “light” and all others “heavy”.
are useful and necessary for your project;
necessary nor useful for your project.
process models to a “weight class”.
– 04 – 2015-05-04 – Sprocesses –
13/91
– 04 – 2015-05-04 – Sprocesses –
14/91
partial payment when reaching milestones.
companies.
– 04 – 2015-05-04 – main –
15/91
– 04 – 2015-05-04 – Svxt –
16/91
– 04 – 2015-05-04 – Svxt –
17/91
we discuss the (German) “V-Modell”.
for Defence Technology and Procurement (‘Bundesministerium f¨ ur Verteidigung’), released 1998
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
(create call for bids, choose developer, accept product)
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
(create call for bids, choose developer, accept product)
(create offer, develop system, hand over system to customer)
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
(create call for bids, choose developer, accept product)
(create offer, develop system, hand over system to customer)
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
(create call for bids, choose developer, accept product)
(create offer, develop system, hand over system to customer)
– 04 – 2015-05-04 – Svxt –
18/91
project role
customer ‘Auftraggeber’ developer ‘Auftragnehmer’ customer/developer ‘Auftragg.’/‘Auftragn.’ customer/developer ‘Auftragg.’/‘Auftragn.’
project type
system development project (AG) system development project (AN) system development project (AG/AN) introduction and maintenance of specific process model
project subject
HW system SW system HW-SW system/embedded System integration introduction and maintenance of specific process model
V-Modell XT offers support for four different project types:
(create call for bids, choose developer, accept product)
(create offer, develop system, hand over system to customer)
– 04 – 2015-05-04 – Svxt –
19/91
V-Modell XT explanation role role (‘Rolle’) activity activity (‘Aktivit¨ at’)
parts of activities artefact product (‘Produkt’)
(‘Thema’) parts of products
a set of related products and activities phase project segment (?) (‘Projektabschnitt’)
– 04 – 2015-05-04 – Svxt –
20/91
– 04 – 2015-05-04 – Svxt –
21/91
%''".'
– 04 – 2015-05-04 – Svxt –
22/91
– 04 – 2015-05-04 – Svxt –
23/91
– 04 – 2015-05-04 – Svxt –
24/91
Project Roles:
Organisation Roles:
– 04 – 2015-05-04 – Svxt –
24/91
Project Roles:
¨ Anderungssteuerungsgruppe (Change Control Board), ¨ Anderungsverantwortlicher, Anforderungsanalytiker (AG), Anforderungsanalytiker (AN), Anwender, Assessor, Ausschreibungsverantwortlicher, Datenschutzverantwortlicher, Ergonomieverantwortlicher, Funktionssicherheitsverantwortlicher, HW-Architekt, HW-Entwickler, Informationssicherheitsverantwortlicher, KM-Administrator, KM-Verantwortlicher, Lenkungsausschuss, Logistikentwickler, Logistikverantwortlicher, Projektkaufmann, Projektleiter, Projektmanager, Prozessingenieur, Pr¨
QS-Verantwortlicher, SW-Architekt, SW-Entwickler, Systemarchitekt, Systemintegrator, Technischer Autor, Trainer
Organisation Roles:
Akquisiteur, Datenschutzbeauftragter (Organisation), Eink¨ aufer, IT-Sicherheitsbeauftragter (Organisation), Qualit¨ atsmanager
– 04 – 2015-05-04 – Svxt –
25/91
5L
– 04 – 2015-05-04 – Svxt –
25/91
5L
– 04 – 2015-05-04 – Svxt –
26/91
– 04 – 2015-05-04 – Svxt –
26/91
– 04 – 2015-05-04 – Svxt –
27/91
i.e. created always and exactly once (e.g. project plan)
– 04 – 2015-05-04 – Svxt –
28/91 SW-Development (‘SW-Entwicklung’)
– 04 – 2015-05-04 – Svxt –
28/91 SW-Development (‘SW-Entwicklung’)
coding . . .
programmer
– 04 – 2015-05-04 – Svxt –
29/91
Recall the idea of the “V shape”:
requirements fixed requirements fixed acceptance acceptance system specified system specified system delivered system delivered architecture designed architecture designed system integrated system integrated modules designed modules designed system realised system realised verification & validation
– 04 – 2015-05-04 – Svxt –
29/91
Recall the idea of the “V shape”:
requirements fixed requirements fixed acceptance acceptance system specified system specified system delivered system delivered architecture designed architecture designed system integrated system integrated modules designed modules designed system realised system realised verification & validation
V-Modell XT mainly supports three strategies to develop a system, i.e. principal sequences between decision points:
– 04 – 2015-05-04 – Svxt –
30/91
requirements fixed requirements fixed acceptance acceptance system specified system specified system delivered system delivered architecture designed architecture designed system integrated system integrated modules designed modules designed system realised system realised verification & validation
incremental component based prototypical
– 04 – 2015-05-04 – Svxt –
31/91
Advantages:
thus they may receive increased attention of management and developers
Disadvantages:
Needs to prove in practice, in particular in small/medium sized enterprises (SME).
– 04 – 2015-05-04 – main –
32/91
– 04 – 2015-05-04 – Srup –
33/91
– 04 – 2015-05-04 – main –
34/91
– 04 – 2015-05-04 – Sagile –
35/91 “Agile denoting ‘the quality of being agile; readiness for motion; nimbleness, activity, dexterity in motion’ software development methods are attempting to
with faster and nimbler software development processes. This is especially the case with the rapidly growing and volatile Internet software industry as well as for the emerging mobile application environment.” (Abrahamsson et al., 2002)
– 04 – 2015-05-04 – Sagile –
35/91 “Agile denoting ‘the quality of being agile; readiness for motion; nimbleness, activity, dexterity in motion’ software development methods are attempting to
with faster and nimbler software development processes. This is especially the case with the rapidly growing and volatile Internet software industry as well as for the emerging mobile application environment.” (Abrahamsson et al., 2002)
The Agile Manifesto (2001): We are uncovering better ways of developing software by doing it and helping others do it. Through this work we have come to value: Individuals and interactions over processes and tools Working software
Customer collaboration
Responding to change
that is, while there is value in the items on the right, we value the items on the left more.
– 04 – 2015-05-04 – Sagile –
36/91
valuable software.
change for the customers competitive advantage.
a preference to the shorter timescale.
– 04 – 2015-05-04 – Sagile –
36/91
valuable software.
change for the customers competitive advantage.
a preference to the shorter timescale.
they need, and trust them to get the job done.
development team is face-to-face conversation.
– 04 – 2015-05-04 – Sagile –
36/91
valuable software.
change for the customers competitive advantage.
a preference to the shorter timescale.
they need, and trust them to get the job done.
development team is face-to-face conversation.
should be able to maintain a constant pace indefinitely.
– 04 – 2015-05-04 – Sagile –
36/91
valuable software.
change for the customers competitive advantage.
a preference to the shorter timescale.
they need, and trust them to get the job done.
development team is face-to-face conversation.
should be able to maintain a constant pace indefinitely.
adjusts its behavior accordingly.
– 04 – 2015-05-04 – Sagile –
37/91
restrictions),
recommend or request customer’s presence in the project,
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Sagile –
38/91
– 04 – 2015-05-04 – Sagile –
39/91
XP values:
XP practices:
(including customer)
(→ Delphi method)
the code
– 04 – 2015-05-04 – Sagile –
39/91
XP values:
XP practices:
(including customer)
(→ Delphi method)
the code
. . . ✘ coding . . . tests for . . .
programmer programmer
– 04 – 2015-05-04 – Sagile –
40/91
– 04 – 2015-05-04 – Sagile –
41/91
in contrast to XP no techniques proposed/required
– 04 – 2015-05-04 – Sagile –
41/91
in contrast to XP no techniques proposed/required Three roles:
– 04 – 2015-05-04 – Sagile –
41/91
in contrast to XP no techniques proposed/required Three roles:
customer,
in the product backlog,
requirement(s) to realise in next sprint,
daily scrum,
sprints
– 04 – 2015-05-04 – Sagile –
41/91
in contrast to XP no techniques proposed/required Three roles:
customer,
in the product backlog,
requirement(s) to realise in next sprint,
daily scrum,
sprints
developing autonomously,
many requirements to realise in next sprint,
self-organised, team decides who does what when,
support communication and cooperation, e.g. by spatial locality
– 04 – 2015-05-04 – Sagile –
41/91
in contrast to XP no techniques proposed/required Three roles:
customer,
in the product backlog,
requirement(s) to realise in next sprint,
daily scrum,
sprints
developing autonomously,
many requirements to realise in next sprint,
self-organised, team decides who does what when,
support communication and cooperation, e.g. by spatial locality
right way,
process and rules,
not disturbed from
responsible for keeping product backlog up-to-date,
techniques and approaches
– 04 – 2015-05-04 – Sagile –
42/91
requirements,
backlog,
requirements in which sprint,
spring, taken from product backlog,
estimations)
backlog,
remove tasks from sprint backlog,
realised in last sprint,
sprint
– 04 – 2015-05-04 – Sagile –
43/91
Product Backlog sprint planning release planning Release Plan Release Burn. Sprint Backlog
sprint
realisation daily scrum Sprint Burndown review retrospective Sprint Report requirements workshop Product Increment
actions for improvement (if necessary)
– 04 – 2015-05-04 – Sagile –
44/91
members
intensive learning and experience necessary
– 04 – 2015-05-04 – main –
45/91
– 04 – 2015-05-04 – Smetricintro –
46/91
precisely describe and assess the products and the process of creation.
Note: all these key figures are models of products — they reduce everything but the aspect they are interested in.
– 04 – 2015-05-04 – main –
47/91
– 04 – 2015-05-04 – Sscales –
48/91
(i) nominal scale
(ii) ordinal scale
(iii) interval scale (with units)
(iv) rational scale (with units)
(v) absolute scale
– 04 – 2015-05-04 – Sscales –
49/91
m : A → M
(thus not natural).
– 04 – 2015-05-04 – Sscales –
50/91
m : A → M
distance or average
finishing number tells us who was, e.g. faster, than who; but nothing about how much faster 1st was than 2nd
– 04 – 2015-05-04 – Sscales –
51/91
m : A → M
two persons, born B1, B2, died D1, D2 (all dates beyond, say, 1900) — if ∆(B1, D1) = ∆(B2, D2), they reached the same age
– 04 – 2015-05-04 – Sscales –
52/91
m : A → M
– 04 – 2015-05-04 – Sscales –
53/91
m : A → M
absolute scale has been viewed as a rational scale, makes sense for certain purposes
– 04 – 2015-05-04 – Sscales –
54/91
– 04 – 2015-05-04 – Sscales –
55/91
M1 M2 M3 M4 M5 LOC 127 213 152 139 13297
– 04 – 2015-05-04 – Sscales –
55/91
M1 M2 M3 M4 M5 LOC 127 213 152 139 13297
(whiskers sometimes defined differently, with “outliers”):
100 % (maximum) 75 % (3rd quartile) 50 % (median) 25 % (1st quartile) 0 % (minimum)
– 04 – 2015-05-04 – Sscales –
55/91
M1 M2 M3 M4 M5 LOC 127 213 152 139 13297
(whiskers sometimes defined differently, with “outliers”):
100 % (maximum) 75 % (3rd quartile) 50 % (median) 25 % (1st quartile) 0 % (minimum)
40.000 30.000 20.000 10.000
median: 2,078 average: 7,033.027 LOC lecture’s *.tex files
– 04 – 2015-05-04 – main –
56/91
– 04 – 2015-05-04 – Smetrics –
57/91
metric — A quantitative measure of the degree to which a system, compo- nent, or process posesses a given attribute. See: quality metric.
IEEE 610.12 (1990)
– 04 – 2015-05-04 – Smetrics –
57/91
metric — A quantitative measure of the degree to which a system, compo- nent, or process posesses a given attribute. See: quality metric.
IEEE 610.12 (1990)
quality metric — (1) A quantitative measure of the degree to which an item possesses a given quality attribute. (2) A function whose inputs are software data and whose output is a single numerical value that can be interpreted as the degree to which the software possesses a given quality attribute.
IEEE 610.12 (1990)
– 04 – 2015-05-04 – Smetrics –
57/91
metric — A quantitative measure of the degree to which a system, compo- nent, or process posesses a given attribute. See: quality metric.
IEEE 610.12 (1990)
quality metric — (1) A quantitative measure of the degree to which an item possesses a given quality attribute. (2) A function whose inputs are software data and whose output is a single numerical value that can be interpreted as the degree to which the software possesses a given quality attribute.
IEEE 610.12 (1990)
– 04 – 2015-05-04 – Smetrics –
58/91
– 04 – 2015-05-04 – Smetrics –
59/91
Important motivations and goals for using software metrics:
– 04 – 2015-05-04 – Smetrics –
59/91
Important motivations and goals for using software metrics:
Metrics can be used:
N parameters”
– 04 – 2015-05-04 – Smetrics –
59/91
Important motivations and goals for using software metrics:
Metrics can be used:
N parameters”
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P.
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
but is expensive; irrelevant metrics are not economical (if not available for free)
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
but is expensive; irrelevant metrics are not economical (if not available for free)
– 04 – 2015-05-04 – Smetrics –
60/91
is called valuation yield (‘Bewertung’) of P. In order to be useful, a (software) metric should be:
the same valuation
but is expensive; irrelevant metrics are not economical (if not available for free)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated comparable reproducible available relevant economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable reproducible available relevant economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible available relevant economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available relevant economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available number of developers number of errors in the code (not only known ones) relevant economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available number of developers number of errors in the code (not only known ones) relevant expected development cost; number of errors number of subclasses (NOC) economical plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available number of developers number of errors in the code (not only known ones) relevant expected development cost; number of errors number of subclasses (NOC) economical number of discovered errors in code highly detailed timekeeping plausible robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available number of developers number of errors in the code (not only known ones) relevant expected development cost; number of errors number of subclasses (NOC) economical number of discovered errors in code highly detailed timekeeping plausible cost estimation following COCOMO (to a certain amount) cyclomatic complexity of a program with pointer
robust
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
61/91 characteristic
(‘Merkmal’)
positive example negative example differentiated program length in LOC CMM/CMMI level below 2 comparable cyclomatic complexity review (text) reproducible memory consumption grade assigned by inspector available number of developers number of errors in the code (not only known ones) relevant expected development cost; number of errors number of subclasses (NOC) economical number of discovered errors in code highly detailed timekeeping plausible cost estimation following COCOMO (to a certain amount) cyclomatic complexity of a program with pointer
robust grading by experts almost all pseudo-metrics
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrics –
62/91
– 04 – 2015-05-04 – Smetrics –
62/91
– 04 – 2015-05-04 – main –
63/91
– 04 – 2015-05-04 – Smetrickinds –
64/91
base measure — measure defined in terms of an attribute and the method for quantifying it.
ISO/IEC 15939 (2011)
values of base measures.
ISO/IEC 15939 (2011)
– 04 – 2015-05-04 – Smetrickinds –
65/91
subjective metric pseudo metric
Procedure Advantages Disadvan- tages Example, general Example in Software Engineering Usually used for (Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
65/91
subjective metric pseudo metric
Procedure measurement, counting, poss. normed Advantages exact, reproducible, can be obtained automatically Disadvan- tages not always relevant,
interpretation Example, general body height, air pressure Example in Software Engineering size in LOC or NCSI; number of (known) bugs Usually used for collection of simple base measures (Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
65/91
subjective metric pseudo metric
Procedure measurement, counting, poss. normed review by inspector, verbal or by given scale Advantages exact, reproducible, can be obtained automatically not subvertable, plausible results, applicable to complex characteristics Disadvan- tages not always relevant,
interpretation assessment costly, quality of results depends on inspector Example, general body height, air pressure health condition, weather condition (“bad weather”) Example in Software Engineering size in LOC or NCSI; number of (known) bugs usability; severeness
Usually used for collection of simple base measures quality assessment; error weighting (Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
65/91
subjective metric pseudo metric
Procedure measurement, counting, poss. normed review by inspector, verbal or by given scale computation (based on measurements or assessment) Advantages exact, reproducible, can be obtained automatically not subvertable, plausible results, applicable to complex characteristics yields relevant, directly usable statement on not directly visible characteristics Disadvan- tages not always relevant,
interpretation assessment costly, quality of results depends on inspector hard to comprehend, pseudo-objective Example, general body height, air pressure health condition, weather condition (“bad weather”) body mass index (BMI), weather forecast for the next day Example in Software Engineering size in LOC or NCSI; number of (known) bugs usability; severeness
productivity; cost estimation following COCOMO Usually used for collection of simple base measures quality assessment; error weighting predictions (cost estimation); overall assessments (Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
66/91 dimension name unit measurement procedure
size of group, department, etc. headcount – number of filled positions (rounded on 0.1); part-time positions rounded on 0.01 program size – LOCtot number of lines in total net program size – LOCne number of non-empty lines code size – LOCpars number of lines with not only comments and non-printable delivered program size – DLOCtot, DLOCne, DLOCpars like LOC, only code (as source or compiled) given to customer number of units unit-count – number of units, as defined for version control (Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
67/91 kind of assessment example problems countermeasures Statement “The specification is available.” Assessment “The module is coded in a clever way.” Grading “Readability is graded 4.0.”
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
67/91 kind of assessment example problems countermeasures Statement “The specification is available.” Terms are ambiguous, conclusions are hardly possible. Allow only certain statements, characterise them precisely. Assessment “The module is coded in a clever way.” Grading “Readability is graded 4.0.”
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
67/91 kind of assessment example problems countermeasures Statement “The specification is available.” Terms are ambiguous, conclusions are hardly possible. Allow only certain statements, characterise them precisely. Assessment “The module is coded in a clever way.” No basis for comparisons. Only offer particular outcomes, put them on an (at least
Grading “Readability is graded 4.0.”
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
67/91 kind of assessment example problems countermeasures Statement “The specification is available.” Terms are ambiguous, conclusions are hardly possible. Allow only certain statements, characterise them precisely. Assessment “The module is coded in a clever way.” No basis for comparisons. Only offer particular outcomes, put them on an (at least
Grading “Readability is graded 4.0.” Subjective, grading not reproducible. Define criteria for grades; give examples how to grade
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
68/91
Considering (all or some of)
(Ludewig and Lichter, 2013)
– 04 – 2015-05-04 – Smetrickinds –
69/91
– 04 – 2015-05-04 – main –
70/91
– 04 – 2015-05-04 – Spseudo –
71/91
Some of the most interesting aspects of software development projects are hard or impossible to measure directly, e.g.:
– 04 – 2015-05-04 – Spseudo –
71/91
Some of the most interesting aspects of software development projects are hard or impossible to measure directly, e.g.:
Due to high relevance, people want to measure despite the difficulty in measuring. Two main approaches:
d i ff e r e n t i a t e d c
p a r a b l e r e p r
u c i b l e a v a i l a b l e r e l e v a n t e c
i c a l p l a u s i b l e r
u s t Expert review, grading (✔) (✔) (✘) (✔) ✔! (✘) ✔ ✔ Pseudo-metrics, derived measures ✔ ✔ ✔ ✔ ✔! ✔ ✘ ✘
– 04 – 2015-05-04 – Spseudo –
72/91
Note: not every derived measure is a pseudo-metric:
→ we really measure average LOC per module.
→ we don’t really measure maintainability; average-LOC is only interpreted as maintainability. Not robust, easily subvertible (see exercises).
– 04 – 2015-05-04 – Spseudo –
72/91
Note: not every derived measure is a pseudo-metric:
→ we really measure average LOC per module.
→ we don’t really measure maintainability; average-LOC is only interpreted as maintainability. Not robust, easily subvertible (see exercises). Example: productivity (derived).
productivity (as defined above).
x := y + z;
instead of x := y + z; → 5-time productivity increase, real efficiency actually decreased.
– 04 – 2015-05-04 – Spseudo –
73/91
and false negatives between valuation yields and the property to be measured:
valuation yield low high quality high false positive × true positive × × × × × × × low true negative × × × × × false negative × × ×
LOC says “lines of code in this style” — this may be a useful measure.
– 04 – 2015-05-04 – Spseudo –
74/91
complexity — (1) The degree to which a system or component has a design
simplicity. (2) Pertaining to any of a set of structure-based metrics that measure the attribute in (1).
IEEE 610.12 (1990)
– 04 – 2015-05-04 – Spseudo –
74/91
complexity — (1) The degree to which a system or component has a design
simplicity. (2) Pertaining to any of a set of structure-based metrics that measure the attribute in (1).
IEEE 610.12 (1990)
comprising vertices V and edges E. The cyclomatic number of G is defined as v(G) = |E| − |V | + 1. Intuition: minimum number of edges to be removed to make G cycle free.
– 04 – 2015-05-04 – Spseudo –
75/91
Control Flow Graph of program P. Then the cyclomatic complexity of P is defined as v(P) = |E|−|V |+p where p is the number of entry or exit points.
– 04 – 2015-05-04 – Spseudo –
75/91
Control Flow Graph of program P. Then the cyclomatic complexity of P is defined as v(P) = |E|−|V |+p where p is the number of entry or exit points.
1
void i n s e r t i o n S o r t ( i nt [ ] a r r a y ) {
2
for ( i nt i = 2; i < a r r a y . length ; i++) {
3
tmp = a r r a y [ i ] ;
4
a r r a y [ 0 ] = tmp ;
5
i nt j = i ;
6
while ( j > 0 && tmp < a r r a y [ j −1]) {
7
a r r a y [ j ] = a r r a y [ j −1];
8
j −−;
9
}
10
a r r a y [ j ] = tmp ;
11
}
12
}
Number of edges: |E| = 11 Number of nodes: |V | = 6 + 2 + 2 = 10 External connections: p = 2 → v(P) = 11 − 10 + 2 = 3
1 2 3 4 5 8 7 6 10 Entry Exit
– 04 – 2015-05-04 – Spseudo –
75/91
Control Flow Graph of program P. Then the cyclomatic complexity of P is defined as v(P) = |E|−|V |+p where p is the number of entry or exit points.
decision points.
due to p > 0); easy to compute
programming language.
understand than sequencing.
either limit cyclomatic complexity to [agreed-upon limit] or provide written explanation of why limit exceeded.”
1 2 3 4 5 8 7 6 10 Entry Exit
– 04 – 2015-05-04 – Spseudo –
76/91
metric computation
weighted methods per class (WMC)
n
ci, n = number of methods, ci = complexity of method i depth of inheritance tree (DIT) graph distance in inheritance tree (multiple inheritance ?) number of children of a class (NOC) number of direct subclasses of the class coupling between object classes (CBO) CBO(C) = |Ko ∪ Ki|, Ko = set of classes used by C, Ki = set of classes using C response for a class (RFC) RFC = |M ∪
i Ri|, M set of methods of C,
Ri set of all methods calling method i lack of cohesion in methods (LCOM) max(|P| − |Q|, 0), P = methods using no common attribute, Q = methods using at least one common attribute
– 04 – 2015-05-04 – Spseudo –
76/91
metric computation
weighted methods per class (WMC)
n
ci, n = number of methods, ci = complexity of method i depth of inheritance tree (DIT) graph distance in inheritance tree (multiple inheritance ?) number of children of a class (NOC) number of direct subclasses of the class coupling between object classes (CBO) CBO(C) = |Ko ∪ Ki|, Ko = set of classes used by C, Ki = set of classes using C response for a class (RFC) RFC = |M ∪
i Ri|, M set of methods of C,
Ri set of all methods calling method i lack of cohesion in methods (LCOM) max(|P| − |Q|, 0), P = methods using no common attribute, Q = methods using at least one common attribute
. . . there seems to be angreement that it is far more important to focus on empirical validation (or refutation) of the proposed metrics than to propose new ones, . . . (Kan, 2003)
– 04 – 2015-05-04 – main –
77/91
“Tanker Summit Europe” von world24 in der Wikipedia auf Deutsch. Lizenziert unter CC BY-SA 3.0 ¨ uber Wikimedia Commons - http://commons.wikimedia.org/wiki/File:Tanker Summit Europe.JPG#/media/File:Tanker Summit Europe.JPG
– 04 – 2015-05-04 – Sgqm –
78/91
– 04 – 2015-05-04 – Sgqm –
79/91
The three steps of GQM: (i) Define the goals relevant for a project or an organisation. (ii) From each goal, derive questions which need to be answered to check whether the goal is reached. (iii) For each question, choose (or develop) metrics which contribute to finding answers. Note: we usually want to optimise wrt. goals, not wrt. metrics.
– 04 – 2015-05-04 – Sgqm –
79/91
The three steps of GQM: (i) Define the goals relevant for a project or an organisation. (ii) From each goal, derive questions which need to be answered to check whether the goal is reached. (iii) For each question, choose (or develop) metrics which contribute to finding answers. Note: we usually want to optimise wrt. goals, not wrt. metrics. Development of pseudo-metrics: (i) Identify aspect to be represented. (ii) Devise a model the aspect. (iii) Fix a scale for the metric. (iv) Develop a definition of the pseudo-metric, how to compute the metric. (v) Develop base measures for all parameters of the definition. (vi) Apply and improve the metric.
– 04 – 2015-05-04 – Sgqm –
80/91
It is often useful to collect some basic measures before they are actually required, in particular if collection is cheap:
is there a (pseudo-)metric which correlates with the problem?
– 04 – 2015-05-04 – Sgqm –
80/91
It is often useful to collect some basic measures before they are actually required, in particular if collection is cheap:
is there a (pseudo-)metric which correlates with the problem?
Measures derived from the above basic measures:
If in doubt, use the simpler measure.
– 04 – 2015-05-04 – Sgqm –
80/91
It is often useful to collect some basic measures before they are actually required, in particular if collection is cheap:
is there a (pseudo-)metric which correlates with the problem?
Measures derived from the above basic measures:
If in doubt, use the simpler measure.
LOC and changed lines over time (obtained by statsvn(1).
– 04 – 2015-05-04 – main –
81/91
– 04 – 2015-05-04 – Sprocmet –
82/91
– 04 – 2015-05-04 – Sprocmet –
82/91
process quality low high product quality high false positive × true positive × × × × × × × low true negative × × × × × false negative × × ×
– 04 – 2015-05-04 – Sprocmet –
82/91
process quality low high product quality high false positive × true positive × × × × × × × low true negative × × × × × false negative × × ×
– 04 – 2015-05-04 – Sprocmet –
83/91
&00,'(99
&00,3URGXFW7HDP
processes for developing better products and services
1RYHPEHU 7(&+1,&$/5(3257 &086(,75 (6&75
8QOLPLWHGGLVWULEXWLRQVXEMHFWWRWKHFRS\ULJKW
– 04 – 2015-05-04 – Sprocmet –
84/91
constellations: CMMI-DEV (development), CMMI-ACQ (acquisition), CMMI-SRV (service)
– 04 – 2015-05-04 – Sprocmet –
84/91
constellations: CMMI-DEV (development), CMMI-ACQ (acquisition), CMMI-SRV (service)
improvement,
– 04 – 2015-05-04 – Sprocmet –
84/91
constellations: CMMI-DEV (development), CMMI-ACQ (acquisition), CMMI-SRV (service)
improvement,
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
monitoring and control (PMC), measurement and analysis (MA), Process and Product Quality Assurance (PPQA), configuration management (CM), supplier agreement management (SAM)
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
is defined, documented, and used; tailoring for projects.
integration (PI), verification (VER), validation (VAL), organisational process focus (OPF), organisational process definition (OPD), organisational training (OT), integrated project management (IPM), risk management (RSKM), decision analysis and resolution (DAR)
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
and take countermeasures.
management (QPM)
– 04 – 2015-05-04 – Sprocmet –
85/91 level level name process areas 1 initial
managed REQM, PP, PMC, MA, PPQA, CM, SAM 3 defined + RD, TS, PI, VER, VAL, OPF, OPD, OT, IPM, RSKM, DAR 4 quantitatively managed + OPP, QPM 5
+ OID, CAR
future; process organisation/techniques change accordingly
resolution (CAR)
– 04 – 2015-05-04 – Sprocmet –
86/91
– 04 – 2015-05-04 – Sprocmet –
86/91
their generic practices are reached. Example: GG.2 (for level 2) includes
– 04 – 2015-05-04 – Sprocmet –
86/91
their generic practices are reached. Example: GG.2 (for level 2) includes
Example: RD (requirements development) includes
particular for area RD SG 1 and SG 2.
– 04 – 2015-05-04 – Sprocmet –
87/91 % of organisations
10.17% 0.91% 32.15% 46.87% 2.00% 7.90% 7.18% 0.95% 25.99% 59.74% 1.42% 4.73% 5.75% 0.36% 23.13% 64.66% 1.51% 4.60% 4.21% 0.22% 22.86% 63.72% 2.76% 6.24% 1.69% 1.33% 20.63% 67.13% 2.14% 7.07% 1.53% 1.39% 17.88% 70.63% 1.46% 7.10% 1.22% 1.03% 15.91% 71.78% 2.69% 7.38% 0.67% 1.34% 16.44% 67.79% 4.70% 9.06% Not Given Initial Managed Defined Quantitatively Managed Optimizing 2007 (1101 Appraisals) 2008 (1058 Appraisals) 2009 (1392 Appraisals) 2010 (1378 Appraisals) 2011 (1357 Appraisals) 2012 (1437 Appraisals) 2013 (1559 Appraisals) 2014 (298 Appraisals)
CMMI level
Statistics on achieved CMMI maturity levels (Source: SEI, Jan. 1, 2007 – Mar. 31, 2014)
– 04 – 2015-05-04 – Sprocmet –
88/91
how — there are examples, but no particular techniques or approaches
selection of sub-contractors (a certificate at least proves that they think about their process)
product quality
– 04 – 2015-05-04 – Sprocmet –
88/91
how — there are examples, but no particular techniques or approaches
selection of sub-contractors (a certificate at least proves that they think about their process)
product quality
for all kinds of software,
processes may require new (expensive) appraisal, in this sense CMMI may hinder innovation,
already in level N − 1?”
– 04 – 2015-05-04 – Sprocmet –
89/91
CMMI 1
aerospace, etc.)
– 04 – 2015-05-04 – main –
90/91
– 04 – 2015-05-04 – main –
91/91
Abrahamsson, P., Salo, O., Ronkainen, J., and Warsta, J. (2002). Agile software development methods. review and analysis. Technical Report 478. Basili, V. R. and Weiss, D. M. (1984). A methodology for collecting valid software engineering data. IEEE Transactions of Software Engineering, 10(6):728–738. Beck, K. (1999). Extreme Programming Explained – Embrace Change. Addison-Wesley. Boehm, B. W. (1988). A spiral model of software development and enhancement. IEEE Computer, 21(5):61–72. Chidamber, S. R. and Kemerer, C. F. (1994). A metrics suite for object oriented design. IEEE Transactions on Software Engineering, 20(6):476–493. H¨
uller, M. (2006). SPICE in der Praxis: Interpretationshilfe f¨ ur Anwender und Assessoren. dpunkt.verlag. IEEE (1990). IEEE Standard Glossary of Software Engineering Terminology. Std 610.12-1990. ISO/IEC (2011). Information technology Software engineering Software measurement process. 15939:2011. Kan, S. H. (2003). Metrics and models in Software Quality Engineering. Addison-Wesley, 2nd edition. Ludewig, J. and Lichter, H. (2013). Software Engineering. dpunkt.verlag, 3. edition. Schwaber, K. (1995). SCRUM development process. In Sutherland, J. et al., editors, Business Object Design and Implementation, OOPSLA’95 Workshop Proceedings. Springer-Verlag. Team, C. P. (2010). Cmmi for development, version 1.3. Technical Report ESC-TR-2010-033, CMU/SEI. V-Modell XT (2006). V-Modell XT. Version 1.4. Z¨ ullighoven, H. (2005). Object-Oriented Construction Handbook - Developing Application-Oriented Software with the Tools and Materials