In the Tension of Software Redundancy and Variability Sandro - - PowerPoint PPT Presentation

in the tension of software redundancy and variability
SMART_READER_LITE
LIVE PREVIEW

In the Tension of Software Redundancy and Variability Sandro - - PowerPoint PPT Presentation

Platzhalter fr Bild, Bild auf Titelfolie hinter das Logo einsetzen In the Tension of Software Redundancy and Variability Sandro Schulze (COW Veteran), TU Braunschweig, COW #29 Thanks to: David Wille, Snke Holthusen, Ina Schaefer (TU


slide-1
SLIDE 1

Platzhalter für Bild, Bild auf Titelfolie hinter das Logo einsetzen

In the Tension of Software Redundancy and Variability

Sandro Schulze (COW Veteran), TU Braunschweig, COW #29 Thanks to: David Wille, Sönke Holthusen, Ina Schaefer (TU Braunschweig), Olaf Lessenich, Sven Apel (University of Passau)

slide-2
SLIDE 2

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 2

What is this talk about?

“…some disciplines aim at introducing redundancy, others at exploiting it, and others still at avoiding it.” (from the COW #29 web page)

slide-3
SLIDE 3

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 3

Questions…to be answered Why does redundancy exists?

Any good reasons? On purpose?

Where does it come from?

Beyond plain copy&paste?

What does it tell us (under the hood)?

What is redundancy really used for…and why?

Does your mother know, you are here?

Does anybody know about all that redundancy?

slide-4
SLIDE 4

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 4

An Example of Software Evolution

http://www.levenez.com/unix/

slide-5
SLIDE 5

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 5

Clone-and-Own t0 t1 t2 t3

Versions evolve…. …and become variants

slide-6
SLIDE 6

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 6

Patterns of Redundancy Hardware Variation Platform Variation API/Library Protocols Algorithmic Idioms

WCRE 2006 ESE Journal 2008

slide-7
SLIDE 7

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 7

Patterns of Redundancy Replicate and Specialize Workarounds

Reliability, efficient evolution, knowledge Maintainability, bug propagation, (missing) back propagation

slide-8
SLIDE 8

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 8

10000

features

Redundancy introduces Variability

250+

distributions

http://www.distrowatch.com

slide-9
SLIDE 9

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 9

Unleashing Redundancy

  • How to add semantics to redundancy?
  • From where to obtain domain knowledge?

Provides Data Provides Information

How to get there?

slide-10
SLIDE 10

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 11

Forking & Evolution

System A System B changes changes

Which parts evolve together/independent across systems?

slide-11
SLIDE 11

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 12

Analyzing Inter-System Clone Evolution

t1: t2: t3: t4: t5:

time Legend: clone connection clone fragment clone class system 1 system 2 t0 t∞

slide-12
SLIDE 12

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 13

Analyzing Inter-System Clone Evolution

vs.

simplicity precision Gives you a fast overview Gives you regions of interest NO information about features NO information for merging the code base of systems

slide-13
SLIDE 13

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 14

Semi-Structured Merge

Apel et al., ASE 2012

How much does this cost? How difficult is it to merge?

Structured Diff on abstract syntax trees (AST)

slide-14
SLIDE 14

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 15

Models are software….too

slide-15
SLIDE 15

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 16

Model-Based Development Process

1 Out1 Product 1 Gain 1 s Integrator 1 In3 2 In4 Z-1 Delay 1 s Integrator1 1 Out1 Product 1 Gain 1 s Integrator 1 In3 2 In4 Z-1 Delay 1 s Integrator1 1 Out1 1 In1 Product 2 In2 Z-1 Delay 1 s Integrator 1 s Integrator Limited Transport Delay

Variant 1 Variant 2

slide-16
SLIDE 16

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 17

The Model Zoo

c l

  • n

e

  • a

n d

  • w

n c l

  • n

e

  • a

n d

  • w

n c l

  • n

e

  • a

n d

  • w

n clone-and-own

slide-17
SLIDE 17

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 18

Towards A Family of Models

M

  • Difficult to maintain
  • Propagating changes à

à which models?

  • Replication usually not documented

Commonalities Differences

slide-18
SLIDE 18

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 19

Mining Model Variability

C C C C C C C C Intermediate Representation Analysis Import Family Model (annotated 150% model) Export EMFCompare

slide-19
SLIDE 19

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 20

Beyond Model Diff & Model Clone Detection

C1 I1 O1 C2 C3 I1 O1 C4 C1 I1 O1 C4 C1 I1 O1 C3 C4 C1 C4 I1 I1 I1 O1 O1 O1 C2

Differences and/or similarities detected by lots of existing tools Beyond that…. …we add semantics …put model elements in a family context

slide-20
SLIDE 20

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 21

Context & Interfaces

1 Out1 Product 1 Gain 1 s Integrator 1 In3 2 In4 Z-1 Delay 1 s Integrator1

Context à model components, connected to component of interest Interfaces à IN and OUT ports of component of interest

slide-21
SLIDE 21

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 22

Alternatives

Variant 1 C1 ⊕

Variant 1 C2 Merge 1+2 C2 C1

⊕ ➜

Variant 1 MV/VS C1 V1 V2 Variant 2 C2 Merge 1+2 C2 MV/VS C1 V1 V2

Different, mandatory components Variable sub- system and mandatory component

slide-22
SLIDE 22

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 23

Optional Components

Variant 1 C1 Variant 2 Merge 1+2 C1 ?

⊕ ➜ ⊕

Variant 2 C2 Variant 1 C1 ? Merge 1+2 C2 C1 ?

Optional and mandatory component An optional alternative ;-)

slide-23
SLIDE 23

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 24

Interface Variability

i0 i1 i2 j0 j1 i3 i4 i5 j2 j3 i6 j4

Compare trees for…

Components Connectors

Wille et al., MAPLE 2013

slide-24
SLIDE 24

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 25

Putting the Pieces Together

M

Redundancy Family Model

slide-25
SLIDE 25

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 26

Summary

slide-26
SLIDE 26

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 28

Questions…partly answered Why does redundancy exists? Where does it come from? What does it tell us (under the hood)?

It’s much (all?) about variability!!!

Does your mother know, you are here?

At least, she does not know the whole truth!!! But there’s more… …compositional testing and verification …propagating patches/changes …modular reasoning

slide-27
SLIDE 27

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 29

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 6

Clone-and-Own t0 t1 t2 t3

Versions evolve…. …and become variants

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 9

10000

features

Redundancy introduces Variability

250+

distributions

http://www.distrowatch.com!

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 13

Analyzing Inter-System Clone Evolution

t1: t2: t3: t4: t5:

time Legend: clone connection clone fragment clone class system 1 system 2 t0 t∞

Sandro Schulze | Redundancy vs. Variability | COW #29 | Slide 19

Towards A Family of Models

M
  • Difficult to maintain
  • Propagating changes ! which

models?

  • Replication usually not documented

Commonalities Differences