software version numbering - dsl of change
TRANSCRIPT
Software version numbering -DSL of
changeSergii Shmarkatiuk, 1st year PhD
student
x.x
x.KM.x
M.K
x
K
x.x.x
x.x.KN.x.x
N.M.K
x.M.x
x.M.KN.M.x N.x.K
2
Motivation
3
SCM practicesVersion control
Build & deployment
management
Continuous integration
Release management
Dependencies management
Merge management
Version numbering
4
Software development activities
Software testing
Software implementation
Project management
Process management
Software support &
maintenance
Version numbering
5
Version numbers are everywhere!
6
Versions of dependent modules
7
Why do we need version numbers?
• Label unique states of software applications for future reference• Introduce continuity for history of software changes• Track progress of software development• Establish dependencies between modules, libraries, applications, APIs, etc
8
Problem: version numbering is broken
• Ambiguous. Same version number often used to refer to different entities (e.g. builds and branches)• Unpredictable/inconsistent: 1.0 -> 1.1 -> 1.2 -> 2.0 -> 2.1 -> 3.1• Not formalized• Cannot be used to serve its purpose (reliable reference, continuity, tracking progress, establishing dependencies)
9
Problem: version numbering is brokenInconsistent version numbering practices:
•Undermine possibilities of development process automation
•Increase need of communication
•Become one of the causes of poor software quality
•Cause many problems related to software maintenance and support
10
Problem: version numbering is broken
11
Root cause of the problem Version numbering is falsely associated with sections numbering and plain tree
structure
12
Automatic document sections numbering1. Consistent
2. Incremental
3. Formalized
4. Automated
5. Is not ambiguous. Two different sections cannot have the same section number
6. Section numbers can be ordered: 1.2.1 < 1.2.2 < 1.2.3 2.1 < 2.2 < 2.3 1.1 < 4.2 < 5
7. Section numbers unambiguously indicate parent and child sections (subsets):
1.1.1 ⊂ 1.1 ⊂ 1 1.1.1 ⊂ 1 1.2.1 ⊂ 1.2 ⊂ 1 1.2.1 ⊂ 1 1.2.2 ⊂ 1.2 ⊂ 1 1.2.2 ⊂ 1 1.2.3 ⊂ 1.2 ⊂ 1 1.2.3 ⊂ 1
13
Automatic document sections numbering
Can be reused to number nodes of any tree
14
Automatic document sections numbering cannot be applied to software history
1.0.0 1.0.1 1.0.2
1.0
Δ1 Δ2 Δ3
1.0.0 ⊃ 1.0.1 ⊃ 1.0.2 ?
Δ1 Δ1 + Δ2 Δ1 + Δ2 + Δ3
15
1.0.0 1.0.1 1.0.2
1.0
Δ1 Δ2 Δ3
1.0.0 ⊅ 1.0.1 ⊅ 1.0.2 !
Δ1 Δ1 -Δ + Δ2
Δ1 -Δ + Δ2 -Δ + Δ3
-Δ -Δ
1.0.0 ⊅ 1.0!
Automatic document sections numbering cannot be applied to software history
16
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
?
1.2.1.1 1.2.1.2
17
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.2
1.2.1.1 1.2.1.2
18
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.3
1.2.1.1 1.2.1.2
19
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.1.1
1.2.1.1 1.2.1.2
20
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.1.2
1.2.1.1 1.2.1.2
21
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.4
1.2.1.1 1.2.1.2
22
It is possible to come up with two different entities with the same number:
Automatic document sections numbering cannot be applied to software history
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3
1.2.1.3
1.2.1.1 1.2.1.2
23
There are other problems …
1.0 1.1 1.2
1.0
24
There are other problems …
variation
variant
#1 #2 #3 #N…
version MaturityPlatformOSLocalizationBuild type…
25
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
26
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
Where is version?
27
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
Where is version?
28
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
Where is version?
29
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
Where is version?
30
There are other problems …
HTC_Touch_Diamond2_WM6.5_RUU_Topaz_S_HTC_RUS_2.16.411.2_Radio_Sign_Topaz_61.44tc.25.32_4.49.25.17_Ship.exe
Real world example:
Where is version?
31
32
33
34
Current version numbering practices
Marketing names: Leopard, Vista, Kepler
Dates: 98, 2000, 2013, 2015, 20140312
Revisions: 12345, 546894, 2131
Hashes: d5f954bef01d228b79ce35f2f1830aa7c7315d23
“Section numbering”: 1.0, 1.0.0, 5.1.6, 2.3.89.21
…
[http://en.wikipedia.org/wiki/Software_versioning]
OR something else…
35
Suggested solution1. Take “section numbering”
approach
2. Formalize it
3. Show that it is possible to perform basic operations using suggested formalization
4. Extend formalization to solve problems of software version numbering
5. Provide mapping from “old style” to “new style” approach
36
Elements of formal definition for
sections numbering
37
Google docs demo
38
Formalization of “sections numbering” approach
Nat o 0, 1, 2, …
_._ ⊆ Nat × Nat × … × Nato 0.1, 1.4, 45.23o 1.0.0, 45.2.0, 34.89.9o 3.5.20.11, 2.4.99.85.34.2
… Num = N1.N2. … .Nk
_<_ ⊆ Num × Numo 0 < 1, 2 < 9, 3 < 90o 1.1 < 1.2, 1.3 < 1.5, 4.1 < 6.8o 2.1.1 < 4.69.78.2 , 2 < 3.8.2.3
…
Section numbering
39
Formalization of “sections numbering” approach
next : Num -> Nat-> Numo next 1 {1} -> 2o next 1.0 1 -> 2.0o next 1.0 2 -> 1.1o next 3.4.5.6 3 -> 3.4.6.6
… NumTree : NumTree (Num NumTree) nTree = NumTree
nTree =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
Section numbering
40
Formalization of “sections numbering” approach
appendNext : NumTree -> Nat -> NumTree appendNext nTree 1 =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
o 2 appendNext nTree 2 =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
1.3
Section numbering
41
Formalization of “sections numbering” approach Section numbering
appendNext nTree 3 => o 1
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3 1.2.4
42
Elements of formal definition
for version numbering
43
Extension of “sections numbering” approach
Nat o 0, 1, 2, …
_._ ⊆ Nat × Nat × … × Nato 0.1, 1.4, 45.23o 1.0.0, 45.2.0, 34.89.9o 3.5.20.11, 2.4.99.85.34.2
… Num = N1.N2. … .Nk
_<_ ⊆ Num × Numo 0 < 1, 2 < 9, 3 < 90o 1.1 < 1.2, 1.3 < 1.5, 4.1 < 6.8o 2.1.1 < 4.69.78.2 , 2 < 3.8.2.3
…
Section numbering
Nat o 0, 1, 2, …
X : Set VC ::= Nat
| X _._ ⊆ VC × VC × … × VC
o 0.1, 1.4, 45.23o 1.0.0, 45.2.0, 34.89.9o 3.5.20.11, 2.4.99.85.34.2, o X , X.X , X.X.X , X.X.X.X , X. … .Xo X.1, X.2, X.3, X.4, … X.no X.X.2, X.5.X, 6.X.X, 6.5.X, X.23.10
Num = N1.N2. … .Nk
_<_ ⊆ Num × Numo 0 < 1, 2 < 9, 3 < 90o 1.1 < 1.2, 1.3 < 1.5, 4.1 < 6.8o 2.1.1 < 4.69.78.2 , 2 < 3.8.2.3o X.0 < X.1 o 1.X.14 < 1.X.25o 2.3.X < 3.8.Xo X < 0o 1.X.X < 1.0.X
Version numbering
44
Extension of “sections numbering” approach
next : Num -> Num -> Numo next 1 {1} -> 2o next 1.0 1 -> 2.0o next 1.0 2 -> 1.1o next 3.4.5.6 3 -> 3.4.6.6
… NumTree : NumTree (Num NumTree) nTree = NumTree
nTree =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
next : Num -> Numo next 1 -> 2o next 1.0 -> 1.1o next 3.4.5.6 -> 3.4.5.7o next 1.X -> 2.Xo next 3.X.X -> 4.X.Xo next X.6 -> X.7o next 1.0.X -> 1.1.Xo next 1.X.13 -> 1.X.14
… NumTree : NumTree (Num NumTree) nTree = NumTree nTree =>
o X.X.X 1.X.X
1.0.X 1.1.X
o 1.1.0o 1.1.1
1.2.Xo 1.2.0o 1.2.1o 1.2.2o 1.2.3
Section numbering Version numbering
45
Extension of “sections numbering” approach
appendNext : NumTree -> Nat -> NumTree appendNext vTree 1 =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
o 2 appendNext vTree 2 =>
o 1 1.1
1.1.1 1.2
1.2.1 1.2.2 1.2.3
1.3
Section numbering appendNext : NumTree -> Nat -> NumTree appendNext nTree 1 =>
o X.X.X 1.X.X
1.0.X 1.1.X
o 1.1.0o 1.1.1
1.2.Xo 1.2.0o 1.2.1o 1.2.2o 1.2.3
2.X.X appendNext nTree 2 =>
o X.X.X 1.X.X
1.0.X 1.1.X
o 1.1.0o 1.1.1
1.2.Xo 1.2.0o 1.2.1o 1.2.2o 1.2.3
1.3.X
Version numbering
46
Extension of “sections numbering” approach Section numbering
appendNext nTree 3 => o 1
1.1 1.1.1
1.2 1.2.1 1.2.2 1.2.3 1.2.4
appendNext nTree 3 => o X.X.X
1.X.X 1.0.X 1.1.X
o 1.1.0o 1.1.1
1.2.Xo 1.2.0o 1.2.1o 1.2.2o 1.2.3o 1.2.4
Version numbering
47
Extension of “sections numbering” approach
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 0.X , X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
Copy
Equivalence
48
Visual representation
of versions numbering
49
Extension of “sections numbering” approach: visual representation
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 0.X , X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
1 2 3 k…
X
50
Extension of “sections numbering” approach: visual representation
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
1 2 3 k…
X
X.X
/1.X
1.0 1.1 1.2
X.1 X.2 X.3 X.k…
1.k…
…/2.X /m.X
51
Extension of “sections numbering” approach: visual representation
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
1 2 3 k…
X
X.X
/1.X
1.0 1.1 1.2
X.1 X.2 X.3 X.k…
1.k…
…/2.X /m.X
52
Extension of “sections numbering” approach: visual representation
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
1 2 3 k…
X
X.X
/1.X
1.0 1.1 1.2
X.1 X.2 X.3 X.k…
1.k…
…/2.X /m.X
53
Extension of “sections numbering” approach: visual representation
Version numbering
_↓_o X ↓ 1, X ↓ 2, X ↓ 3, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
… _==_
o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
…
1 2 3 k…
X
X.X
/1.X
1.0 1.1 1.2
X.1 X.2 X.3 X.k…
1.k…
…/2.X /m.X
54
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
55
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
56
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
57
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
58
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
59
Extension of “sections numbering” approach: visual representation
1.x.x
1.0.x
x.x.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1 1.x.k
1.0.0 1.0.1 1.0.k…
…n.x.x
1.1.x
1.m.x
n.x.0 n.x.1 n.x.k…
…
…2.x.x
x.x.4 x.x.5 x.x.6 x.x.k…
1 2 k…
x
3 4 5 6
== == == == == == ==
_==_o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
60
Extension of “sections numbering” approach: visual representation
x.x.x
x.x.x
x.x.x
x.x.x
x.x.x
x.x.x…
x.x.x
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
x.x.x
x.x.x
x.x.x…
_==_o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
61
Extension of “sections numbering” approach: visual representation
x.x
x.x
x.x
x.x
x.x
x.x…
x.x
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
x.x
x.x
x.x…
_==_o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
62
Extension of “sections numbering” approach: visual representation
x
x
x
x
x
x…
x
_↓_o X ↓ 0, X ↓ 1, X ↓ 2, … X ↓ ko X.X ↓ X.1 , X.X ↓ X.2 , … , X.X ↓ X.ko X.X ↓ 1.X , X.X ↓ 2.X , … , X.X ↓ m.Xo 1.X ↓ 1.0 , 1.X ↓ 1.1 , 1.X ↓ 1.2 , … , 1.X ↓ 1.ko X.X.X ↓ 1.X.X , X.X.X ↓ 2.X.X, … , X.X.X ↓ n.X.Xo 1.X.X ↓ 1.0.X , 1.X.X ↓ 1.1.X, … , 1.X.X ↓ 1.m.Xo 1.X.X ↓ 1.X.0 , 1.X.X ↓ 1.X.1, … , 1.X.X ↓ 1.X.k o 1.0.X ↓ 1.0.0 , 1.0.X ↓ 1.0.1, … , 1.0.X ↓ 1.0.ko X.X.X ↓ X.X.X , X.X ↓ X.X , X ↓ X
…
x
x
x…
_==_o X.6.8 == 6.8o X.1 == 1o X.X.1 == 1o X.X.k == ko X.2.6 == 2.6o X.1.X == 1.Xo X.X.X = Xo X. … .X = X
63
Mapping of version numbers
Mapping from “old style” to “new style”
Approach: decomposition into branches and tags
65
Mapping from “old style” to “new style”
x.x.x
1.x.x
1.0.x
x.x.1 x.x.2 x.x.3
1.x.0 1.x.1
1.0.0 1.0.1
x.x.4 x.x.5 x.x.6
1.1 1.2 1.3 1.4 2.1 2.2
1.3.1.1
1.3.1.2
1.3.2.1
1.3.2.21.0.x
1.x.x
x.x.x
1.0.x1.x.xx.x.x
66
1.0.x
1.x.x
x.1.x x.2.xx.x.x
Mapping from “old style” to “new style”
1.0.x1.x.x
x.1.x x.2.xx.x.x
x.x.x
1.x.x
1.0.x
x.2.1 x.2.2x.1.1
1.0.0 1.0.1
x.1.2 x.1.3 x.1.4
2.1 2.21.1 1.2 1.3 1.4
1.3.2.1
1.3.2.2
x.1.x x.2.x
1.x.0 1.x.11.3.1.
11.3.1.
2
67
1.0.x
1.x.x
x.1.x x.2.xx.x.x
Mapping from “old style” to “new style”
1.0.x1.x.x
x.1.x x.2.xx.x.x
1.x.x
1.0.x
x.x.x
x.2.1 x.2.2x.1.1
1.x.0 1.x.1
1.0.0
x.1.2 x.1.3 x.1.4
2.1 2.21.1 1.2 1.3 1.4
1.3.1.1
1.3.2.1
1.3.1.2
x.1.x x.2.x
1.x.21.3.2.
2
69
1.0.x
1.1.x
2.x.xx.x.x
1.x.x
Mapping from “old style” to “new style”
1.0.x
1.1.x
x.x.x
2.x.1 2.x.21.x.1
1.0.0
1.x.2 1.x.3 1.x.4
2.1 2.21.1 1.2 1.3 1.4
1.3.1.1
1.x.x 2.x.x
1.0.11.3.1.
2
1.1.01.3.2.
1
1.1.11.3.2.
2
1.0.x1.1.x
2.x.xx.x.x
1.x.x
702.x.xx.x.x
1.x.x
1.1.x
1.0.x
Mapping from “old style” to “new style”
1.0.x1.1.x
2.x.xx.x.x
1.x.x
1.0.x
1.1.x
x.x.x
2.x.1 2.x.21.x.1
1.0.0
1.x.2 1.x.3 1.x.4
2.1 2.21.1 1.2 1.3 1.4
1.3.2.1
1.x.x 2.x.x
1.0.11.3.2.
2
1.1.01.3.1.
1
1.1.11.3.1.
2
71
Mapping from “old style” to “new style”
1.x.xx.x.x
1.1.x
1.0.x
1.0.x1.1.x
1.x.xx.x.x
1.0.x
1.1.x
x.x.x
2.x.1 2.x.21.x.1
1.0.0
1.x.2 1.x.3 1.x.42.1 2.21.1 1.2 1.3 1.4
1.3.2.1
2.x.x
1.x.x
1.0.11.3.2.
2
1.1.01.3.1.
1
1.1.11.3.1.
2
1.x.x
72x.x.xx.x.x
x.x.x
x.x.x
Mapping from “old style” to “new style”
x.x.xx.x.x
x.x.xx.x.x
x.x.x
x.x.x
x.x.x
x.x.8 x.x.10
x.x.1
x.x.7
x.x.2 x.x.3 x.x.5
2.1 2.2
1.1 1.2 1.3 1.4
1.3.2.1
x.x.x
x.x.91.3.2.
2
x.x.41.3.1.
1
x.x.61.3.1.
2
73x.xx.x
x.x
x.x
Mapping from “old style” to “new style”
x.xx.x
x.xx.x
x.x
x.x
x.x
x.8 x.10
x.1
x.7
x.2 x.3 x.5
2.1 2.2
1.1 1.2 1.3 1.4
1.3.2.1
x.x
x.91.3.2.
2
x.41.3.1.
1
x.61.3.1.
2
74xx
x
x
Revisions: 1, 2, 3, … , 2131, …
Mapping from “old style” to “new style”
xx
xx
x
x
x
8 10
1
7
2 3 5
2.1 2.2
1.1 1.2 1.3 1.4
1.3.2.1
x
91.3.2.
2
41.3.1.
1
61.3.1.
2
75
Semantics of version numbering
1.0.x1.x.x
x.1.x x.2.xx.x.x
1.0.x1.x.xx.x.x
1.0.x1.1.x
2.x.xx.x.x
1.x.x
1.0.x1.1.x
1.x.xx.x.x
xx
xx
There are many different ways to decompose the same history of versions.
Which one should we choose?
We need to learn about semantics of version numbering first…
76
Semantics of version
numbering
77
Semantics of “old” version numbering
[major].[minor].[build]
1.2.3
ITERATIONS
ARCHITECTURE
CONCEPTSPORTING
MARKETING
BUILDPATCH
http://semver.org/
78
Semantics of “new” version numbering
x.x.x
N.M.K
mutable
immutable
Creation of immutable
artifact
compatible
incompatible
Definition of compatibility
scope
all changes
Fixed set of
features
Feature freeze
79
Semantics of version numbers
x.x.x x.x.K
N.x.x
N.M.K
x.M.K
N.M.x
N.x.K
x.M.x
x.x.x
x.x.K
N.x.x
N.M.K
x.M.K
x.M.x
N.M.x
N.x.K
x.x.x
x.x.K
N.x.x
N.M.K
x.M.x
x.M.KN.M.x N.x.K
≃ ≃isomorphic
80
x.x.x x.x.K
N.x.x
N.M.K
x.M.K
N.M.x
N.x.K
x.M.x
x.x.x
x.x.K
N.x.x
N.M.K
x.M.K
x.M.x
N.M.x
N.x.K
Any changes
Features subset M
Universally compatible
Subset N of compatible features
Semantics of version numbers
Mutable(branch)
Immutable
(tag)
Universally compatible
Subset N of compatible features
81
x.x.x x.x.K
N.x.x
N.M.K
x.M.K
N.M.x
N.x.K
x.M.x
x.x.x
x.x.K
N.x.x
N.M.K
x.M.K
x.M.x
N.M.x
N.x.K
Any changes
Features subset M
Universally compatible
Subset N of compatible features
Semantics of version numbers
Mutable(branch)
Immutable
(tag)
Universally compatible
Subset N of compatible features
82
Mapping from “old style” to “new style”
1.0.x1.x.x
x.1.x x.2.xx.x.x
1.0.x1.x.xx.x.x
1.0.x1.1.x
2.x.xx.x.x
1.x.x
1.0.x1.1.x
1.x.xx.x.x
xx
xx
?
?
?
?
?
83
Mapping from “old style” to “new style”• Way of versions history decomposition depends
on WHY certain versions were created:• Purpose of tagging, branching, etc• Actual content of tag, branch, etc
• It is difficult to refactor existing history of versions because of insufficient information about purpose and content of certain artifacts.
• It is easier to follow rules of version numbering semantics at early stages of software projects.
• It is even more easy to follow rules if there is a special tool that helps with version numbering.
85
SCMFViz: version numbering tool
http://scmfviz.altern.kiev.ua/
86
Why new approach is
better
87
How does “new approach” solve problems?
1.2.1 < 1.2.2 < 1.2.32.1 < 2.2 < 2.31.1 < 4.2 < 5
x.x.1 < x.x.2 < x.x.3 < x.x.4 < x.x.5 < x.x.6
x.1.1 < x.1.2 < x.1.3 < x.1.4 < x.2.1 < x.2.2
1.x.1 < 1.x.2 < 1.x.3 < 1.x.4 < 2.x.1 < 2.x.2
1.x.0 < 1.x.1 < 1.x.2
1.0.0 < 1.0.1 < 1.1.0 < 1.1.1
It is possible to order version numbers (partially)
88
1.1.1 ⊂ 1.1 ⊂ 1
1.2.1 ⊂ 1.2 ⊂ 1
1.2.2 ⊂ 1.2 ⊂ 1
1.2.3 ⊂ 1.2 ⊂ 1
⊂ ↓->1.1.1 ⊂ 11.2.1 ⊂ 11.2.2 ⊂ 11.2.3 ⊂ 1
How does “new approach” solve problems?
Concept of subset ⊂ is not applicable to version numbers. “Copy” operation ↓ is used instead.
89
X.X.X ↓ 1.XX.X.X ↓ 2.X
…X.X.X ↓ M.X
X.X.X ↓ X.X.1 X.X.X ↓ X.X.2
…X.X.X ↓ X.X.K
X.X.X ↓ X.1X.X.X ↓ X.2
…X.X.X ↓ X.K
X.X.X ↓ 1X.X.X ↓ 2
…X.X.X ↓ 4
X.X.X ↓ 1.X.X
X.X.X ↓ 2.X.X
…X.X.X ↓ N.X.X
X.X.X ↓ X.1.XX.X.X ↓ X.2.X
…X.X.X ↓ X.M.X
N.X.X ↓ N.1.XN.X.X ↓ N.2.X
…N.X.X ↓ N.M.X
N.X.X ↓ N.X.1
N.X.X ↓ N.X.2
…N.X.X ↓ N.X.K
How does “new approach” solve problems?
⊂ ↓->
90
Hierarchy of version numbers
x.x
x.KM.x
M.K
x
K
x.x.x
x.x.KN.x.x
N.M.K
x.M.x
x.M.KN.M.x N.x.K
X.X.X ↓ X.M.XX.X.X ↓ N.X.XX.X.X ↓ X.X.KN.X.X ↓ N.M.XN.X.X ↓ N.X.KX.M.X ↓ X.M.KN.M.X ↓ N.M.K
X.X ↓ M.XX.X ↓ X.KM.X ↓ M.KM.X ↓ M.K
X ↓ K
It is possible to establish hierarchy of version numbers using copy operation:
91
Versions and Variations
92
Does version == variation ?
NO
93
Versions vs variations
Versions Variations
Provides Context (branches) and snapshots (tags)
Choice
Keeps track of Content Alternative implementations
Takes into account
Selected choices
Potential choicesVersion + choice configuration =
variant
Version numbering for variations
94
1.x.x
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
app
variations
1.x.1
Version numbering for variations
95
1.x.x
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
variations versions
1.x.1
Version numbering for variations
96
1.x.x
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app_1.x.6
app_1.x.6_debug
app_1.x.3_en
app_1.x.6_en_debug
app_1.x.0_x64
app_1.x.6_x64_debug
app_1.x.5_en_debug
app_1.x.6_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
variations versions variants
1.x.1
Version numbering for variations
97
1.x.x
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app_1.x.6
app_1.x.6_debug
app_1.x.3_en
app_1.x.6_en_debug
app_1.x.0_x64
app_1.x.6_x64_debug
app_1.x.5_en_debug
app_1.x.6_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
1.x.1
Version numbering for variations
98
1.x.x
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app_1.x.6
app_1.x.6_debug
app_1.x.3_en
app_1.x.6_en_debug
app_1.x.0_x64
app_1.x.6_x64_debug
app_1.x.5_en_debug
app_1.x.6_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
1.x.1
Version numbering for variations
99
1.x.x
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app_1.x.6
app_1.x.6_debug
app_1.x.3_en
app_1.x.6_en_debug
app_1.x.0_x64
app_1.x.6_x64_debug
app_1.x.5_en_debug
app_1.x.6_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
1.x.1
Version numbering for variations
100
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app
app_debug
app_en
app_en_debug
app_x64
app_x64_debug
app_en_debug
app_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
Keeping track only of latest version
1.x.1
Version numbering for variations
101
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app
app_debug
app_en
app_en_debug
app_x64
app_x64_debug
app_en_debug
app_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
1.x.3
1.x.5
Keeping track only of latest version
1.x.1
Version numbering for variations
102
1.x.0
x64 en debug
TRUE
TRUE
TRUE TRUE
TRUE
TRUE TRUE
TRUE TRUE
TRUE TRUE TRUE
1.x.0
app
app
app_debug
app_en
app_en_debug
app_x64
app_x64_debug
app_en_debug
app_x64_en_debug1.x.0
1.x.2
1.x.2
1.x.2
1.x.2
1.x.3
1.x.3
1.x.4
1.x.4
1.x.5
1.x.5
1.x.6
1.x.6
1.x.6
1.x.6
1.x.6
1.x.0
1.x.3
1.x.5
Keeping track only of latest version
103
Conclusion
104
Conclusion• Version != variation
• Versions and variations are complementary and always go side by side in software development
• Necessity of software configuration management practices arises because of high variability of software
• Both formalized version numbering and variations can help to understand nature of changes better
• If formalized, versions can provide context for variations and choices of alternative implementations
• Proper version numbering must be introduced into software projects as early as possible to avoid problems with version numbering.
• Formalized version numbering and variations are stepping stone for better software tools.