Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is...

21
Software Engineering Theory Software configuration management Lena Buffoni/ Kristian Sandahl Department of Computer and Information Science 2019-09-18

Transcript of Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is...

Page 1: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Software Engineering Theory

Software configuration management

Lena Buffoni/ Kristian SandahlDepartment of Computer and Information Science

2019-09-18

Page 2: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

2

Requirements

System Design(Architecture,

High-level Design)

Module Design(Program Design,Detailed Design)

Implementationof Units (classes, procedures,

functions)Unit testing

Module Testing(Integration testing of units)

System Testing(Integration testing of modules)

Acceptance Test(Release testing)

Validate Requirements, Verify Specification

Verify System Design

Verify Module Design

Verify Implementation

Project Management, Software Quality Assurance (SQA), Supporting Tools, Education

Maintenance

Page 3: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

What is configuration management?3

Configuration ItemIdentification Source code

modules Test scripts Design documents Build systems

SCM

Page 4: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

4

What is configuration management?

Baseline - a "snap-shot" of configuration items. Known to work together. Normally reviewed in some way. For example a release.

Change

How do we control changes?

File Av.03

File Cv.3.3

File Bv0.1 File A

v.03

File Av.03

File Bv0.1

File Bv0.11

File Cv.3.4

File Cv.3.3

Change

Page 5: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

5

What is configuration management?Configuration ItemIdentification

Source code modules Test scripts Design documents Build systems

Configuration control

Only authorized people may make changes

Larger changes -change requests

CHANGE REQUESTProject:__________Classification:_____Priority:__________Date: __________

Change Description:

Change Control Board (CCB) Make change decisions. Only large changes (e.g. new

major requirements)

SCM

Page 6: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

6

What is configuration management?Configuration ItemIdentification

Source code modules Test scripts Design documents Build systems

Configuration control

Larger changes -change requests

Status accounting

Document and report changes to those involved.

Auditing

Ensure that the items are complete and consistent.

Make sure that the configuration is tested and meets requirements.

SCM

Page 7: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

7

SCM toolsWorkflow systems Define processes for

change requests

Change report system Bug-tracking New features Change request(e.g free alternatives: Bugzilla,

Trac)

Tool examples: SVN, Git GitHub, GitLab Beanstalk

Change management

Revision control systems

Page 8: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

8

Revision control: Some terminology

create branch

trunkpull

push

make changes release

tag

History tree

Page 9: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Defining a common workflow

9

• A structured way of collaborating

• Different people/teams working on different parts of the system

Page 10: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

10

trunk

Anna’s repository

Viktor’s repository

clone

clone

push

push

pull

Page 11: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Pros/cons of centralized workflow

11

+ little setup

+ will work for small projects

- limited flexibility

- hard to maintain a continuously working product

Page 12: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

12

branch for feature 1

trunk

branch for feature 2

pull changes

merge

merge

Page 13: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Pros/cons of feature branches

13

+ easier conflict resolution

+ better control of what features to include when

+ possibility of using pull requests

- additional steps

- long living branches might be hard to merge

Page 14: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Push vs pull request

14

• Pull request: Submitting your code for consideration for inclusion in the main repository

+ an opportunity to review code and make changes

+ less risk of needing a rollback

- puts extra work on the repository owner

- can increase time before changes are integrated

Page 15: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

15

Gitflowhotfix branch

bug fixed

feature branches

trunk

release candidate

development branch

stable version 1.2

stable version 1.3

Page 16: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

16

Things can get complicated

Non-linear vs linear history

Page 17: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Pros/cons of git workflow

17

+ always stable code in the master

+ can work on release and future features simultaneously

+ fix issues without disrupting workflow

- not good for supporting multiple product versions

- history can get complicated

- many merging conflicts to resolve

Page 18: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

18

main repository

public copy

local copy

fork

pull request

pull & rebasepush

Page 19: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

Pros/cons decentralized workflow

19

+ no need to provide write access to main repository

+ good for large open-source projects

- more complicated to set up and maintain

Page 20: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

20

Make your own work-flow

tags

pullrequests

git hooks

versioning conventions

personal productivity

ease of management

ease of collaboration

cost of mistakes

branches, forks

companygoals/guidelines

Page 21: Software configuration managementTDDC88/theory/08SCM.pdfDesign documents Build systems SCM 4 What is configuration management? Baseline - a "snap-shot" of configuration items. Known

www.liu.se

www.liu.se

The end. Thank you! Questions?