tuning github for spl development branching models and operations for product engineers oscar díaz...

57
Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group San Sebastian, Spain Leticia Montalvillo University of the Basque Country ONEKIN Research Group San Sebastian, Spain SPLC’15 Nashville 2015, TN

Upload: hannah-blankenship

Post on 04-Jan-2016

214 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Tuning Github for SPL development

Branching models and operations for product engineers

Oscar DíazUniversity of the Basque Country

ONEKIN Research GroupSan Sebastian, Spain

Leticia MontalvilloUniversity of the Basque Country

ONEKIN Research GroupSan Sebastian, Spain

SPLC’15 Nashville 2015, TN

Page 2: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 2

SPL SettingEvolving SPLsFeature-Oriented SPLs

Page 3: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 3

SPL Scope of reuse

Deestral&Bosch2005: Product Derivation in Software Product Families: A Case Study

Page 4: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 4

Domain engineering development

Feature-Oriented SPLsFeature implementation =

Page 5: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 5

Application engineering development

1. Get initial feature configuration

2. Customization

3. Assemble

Customized core asset

Brand newasset

Page 6: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 6

It looks like two kinds of repositories exist

1 Core_Asset_Repository + N Product_Repository

Page 7: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 7

Where do we keep the assets?

VCSs

Page 8: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 8

Github highlights

More than 10 million of users

More than 24 million of repositories

Web-based Git Repository hosting service

Popular for collaborative development

"GitHub Press Info". github.com. Github. Retrieved 2015-07-23

Page 9: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 9

?A Look into a Github Repository

Repository Owner

Repository Name

User logged

Default branch

Source Code

Page 10: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 10

?A look into a Forked Repository

Cloned Source Code

All branches & commits

A link to the “original” repository

My account

Page 11: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 11

How do both repositories look like on Github?

Page 12: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 12

How does a core asset repository look like in Github?

Domain developer

Features implementation

Core asset repository name

Page 13: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 13

How does a Product Repository look like in Github?

Application developer Product repository name

Product assets

Page 14: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 14

The problemThe sync Challenge

Page 15: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 15

?Now, let’s have a show of hands …

Page 16: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 16

Should a product repository be obtained after a core asset repository?

Page 17: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 17

Should reusable core asset updates be propagated to existing products?

Page 18: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 18

Should product specific customizations be upgraded as core assets?

Page 19: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 19

If you answered “Yes” to any ….There is a sync challenge

Page 20: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 20

The problem: The Sync Challenge

The sync challenge implies to:

1. Create product repositories from core asset repositories along a feature configuration

2. Update product assets with newer versions available at core asset repository

3. Feedback product customizations from product repository to core asset repository

Page 21: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 21

Does Github support the sync challenge?

Fork & pull Request operate at high granularity. We want them at feature level

Fork Granularity: at repository level (branches and commit history) What if we only want a subset of the features?

Pull Requests Granularity: at branch level ( branches hold a project’s

snapshot) What if we only want the changes related to a given feature to

be propagated? What happens if my product is not reusing that feature?

Page 22: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 22

How can we tune Github to support engineers on the sync challenge?

Page 23: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 23

The solutionGitLine: a Firefox plug-in that extends Github functionality

Page 24: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 24

Github operations for the sync challenge3 OPERATIONS FOR PRODUCT ENGINEERS

1. Create product repositories from Core Asset repositories along a core asset configuration

PRODUCT FORK

2. Update product assets with newer versions from core asset repository

UPDATE PROPAGATION

3. Feedback product specific assets from product repositories to core asset repository

FEEDBACK PROPAGATION

Page 25: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 25

Product Fork operation

Product Fork ( User_Account X Core_Asset_Repository X Configuration_of_core_assets ) :: Product_Repository

Page 26: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 26

Product Fork: Accesing the Core Asset Repository

Page 27: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 27

Product Fork: Getting the feature configuration

Product Fork Update Propagation Feedback Propagation

Feature selection Configuration steps

Page 28: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 28

Behind the scenes …

… GitLine creates a new product repositoryinitialized only with the core assets of the selected features: deleting not wanted assets & branches & setting up the branching model for the user

Product Fork Update Propagation Feedback Propagation

Page 29: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 29

Product Fork: A new Product Repository

Product Fork Update Propagation Feedback Propagation

Page 30: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 30

Update Propagation Operation

Update Propagation ( User_Account X Core_Asset_Repository X Product_Repository):: Pull_Request

Page 31: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 31

Core Asset Repository has new updates

Product Fork

Update Propagation

Feedback Propagation

Page 32: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 32

Update Propagation: Enacting the operation

Page 33: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 33

Behind the scenes …

… GitLine is accessing the core asset repositoryand checks where there are newer feature versions that my product is reusing & brings them into a product’s repository dedicated branch

Product Fork

Update Propagation

Feedback Propagation

Page 34: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 34

Update Propagation pulling new versions of Core Assets

Page 35: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 35

Opening the update request: Diff view

Product Fork

Update Propagation

Feedback Propagation

Page 36: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 36

Feedback Propagation

Feedback Propagation ( User_Account X Product_Repository X customization_branch X Core_Asset_Repository ):: Pull_Request

Page 37: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 37

There is a new product specific asset

Product specific customizationWe want to feedback

Page 38: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 38

Selecting the product specific asset

Page 39: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 39

Behind the scenes …

… GitLine traverses the branch history to cherry-pick only the changes that occurred under that branch and propose them as feedback for a core asset repository feature.

Page 40: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 40

A new Feedback Pull Requestin the Core Asset Repository

Page 41: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 41

Opening the feedback request: Diff view

Product Fork Update Propagation

Feedback PropagationComparing PlayMovie Feature

Page 42: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 42

Almost reaching the end…

Page 43: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 43

What can you find in the paper?

Things I did not explained during the presentation:

A branching model for core asset repositories

A branching model for product repositories

The operational semantics for 3 sync repository operations

Page 44: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 44

A branching model for Core Asset Repository

4 main type of branches.Branch-per-purpose style

Page 45: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 45

What can you find in the paper?

Things I did not explained during the presentation:

A branching model for core asset repositories

A branching model for product repositories

The operational semantics for 3 sync repository operations

Page 46: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 46

A branching model for Product Repository

7 main type of branches.Branch-per-purpose style

Page 47: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 47

What can you find in the paper?

Things I did not explained during the presentation:

A branching model for core asset repositories

A branching model for product repositories

The operational semantics for 3 sync repository operations

Page 48: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 48

What can you find in the Web?

A realization of these operations as a Firefox plug-in: GitLine

GitLine is freely-available as a GitHub project

Page 49: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 49

https://github.com/letimome/GitLine

FORK & SEND PULL REQUEST

Page 50: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 50

http://letimome.github.io/GitLine

ASK FOR A LIVE DEMO!!

Page 51: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 51

Summary

ProblemSync DE & AE developments

ContributionBranching models for Core Asset & Product

RepositoryFormalization of three sync SPL operations

ValidationFeasibility: GitLine tool, Firefox plug-in for GitHub

Page 52: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 52

Limitations and future lines

Evaluation of the branching model & operations with practitioners

GitLine depends on Github

Provide GitLine with different composition mechanisms

Page 53: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

53Onekin Reserch Group

@

Contact us,[email protected]

Thanks for your attention!

Page 54: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Reserch Group 54

Extra to illustrate operations in action …

Page 55: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

55

Product Fork Operation

Onekin Research Group

Page 56: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 56

Update Propagation

Enact update propagation…

Diff=

Page 57: Tuning Github for SPL development Branching models and operations for product engineers Oscar Díaz University of the Basque Country ONEKIN Research Group

Onekin Research Group 57

Feedback Propagation

Onekin Research Group 57

Diff=

Enact Feedback…