Slides of my presentation at the Research track of the 34th International Conference on Software Maintenance and Evolution (ICSME 2018).
The full paper is available here: http://www.ivanomalavolta.com/files/papers/ICSME_2018.pdf
4. VRIJE
UNIVERSITEIT
AMSTERDAM
Goal and research questions
4
To empirically characterize how maintainability issues of
Android apps evolve
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
5. VRIJE
UNIVERSITEIT
AMSTERDAM
Building the dataset
5
Union
App published in
Google Play?
9,400
Remove
duplicates
Has
manifest?
Has proper Android
source code?
Active
GitHub repo?
Remove
impurities
Enough commits
frequency?
8,049 6,619
6,454
4,756
2,238
1,410
GitHub repos
(434)
Commits metadata
(106,689)
Collect commits
metadata
• Kotlin code
• Missing Java code
• Android libraries
• #commits >= 6
• lifespan >= 8 weeks
• changed dates
• forks
• not analyzable
• Keep weeks with
at least 1 commit
• #weeks >= 8
7. VRIJE
UNIVERSITEIT
AMSTERDAM
Extracted maintainability issues
Software Analysis Toolkit
Developed by SIG
7
SAT tool
Maintainability issue Description
Unit size Methods exceeding 30 lines of code
Unit complexity Methods whose McCabe Cyclomatic Complexity exceeds 10
Unit interfacing Methods having more than 4 formal parameters
Module coupling Classes exceeding 20 incoming dependencies
Duplication Code clones of at least 6 lines of code
Maintainability The total count of the previous issue types
1. Fully automatic
2. No need to build the apps
3. Close contact with SAT developers
4. Its supported metrics are correlated with the
speed at which issues are solved by developers[1]
Why SAT
[1] Bijlsma, D., Ferreira, M. A., Luijten, B., & Visser, J. (2012). Faster issue resolution with
higher technical quality of software. Software quality journal, 20(2), 265-285.
8. VRIJE
UNIVERSITEIT
AMSTERDAM
Most recurrent maintainability issues (RQ1)
8
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
020406080100
MT US UC UI MC DP
Type of maintainability issue
Density
M
aintainability
(TO
TAL)
Unit size
Unit com
plexity
Unit interfacing
M
odule
coupling
Code
duplication
Density
of issues
#issues at commit c
NKLOC of the app after c
Average of 18 issues every 1k
LOCs
DUPLICATION and UNIT SIZE
are the most recurring issues
in Android apps
Is DUPLICATION really
an issue in Android?
9. VRIJE
UNIVERSITEIT
AMSTERDAM
How do maintainability issues evolve? (RQ2)
9
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
Does the density of maintainability issues actually change over time?
Weekly snapshots
1 time series for each pair <app, issue type>
Check stationarity
NON-stationarity for
93% of the apps
Android developers’ activities can impact the
maintainability of their apps over time
Weeks
Density
10. VRIJE
UNIVERSITEIT
AMSTERDAM
Evolution trends identification (RQ2)
10
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
Time series
Seasonal
Trend
Remainder
1,230 distinct trends
Open card
sorting
Taxonomy of 12
evolution trends
sampling
ADCPU−16Emu (I)
AttysScope (SI)
SGit (IP)
AndroidBootcampProject (PI)
BitcoinChecker (D)
Ursmu (SD)
BirdWalk (DP)
MLManager (PD)
CineTime (H)
RadyoMenemenPro (V)
PixelDungRemix (A)
android−simple−gameapi (C)
Increase
Stable
increase
Increasing
plateau
Plateau
increasing
Decrease
Stable
decrease
Decreasing
plateau
Plateau
decreasing
Hill
Valley
Anomalous
Constant
Growth ReductionMixed Constant
Weeks
Density
Weeks
11. VRIJE
UNIVERSITEIT
AMSTERDAM
The taxonomy of evolution trends (RQ2)
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
ADCPU−16Emu (I)
AttysScope (SI)
SGit (IP)
AndroidBootcampProject (PI)
BitcoinChecker (D)
Ursmu (SD)
BirdWalk (DP)
MLManager (PD)
CineTime (H)
RadyoMenemenPro (V)
PixelDungRemix (A)
android−simple−gameapi (C)
Increase
Stable
increase
Increasing
plateau
Plateau
increasing
Decrease
Stable
decrease
Decreasing
plateau
Plateau
decreasing
Hill
Valley
Anomalous
Constant
Growth MixedReduction Constant
12. VRIJE
UNIVERSITEIT
AMSTERDAM
Evolution trends by maintainability issue type
(RQ2)
12
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
DP
MC
UI
UC
US
MT
I SI IP PI D SD DP PD H V A C
10
20
30
40
Maintainability
Unit size
Unit complexity
Unit interfacing
Module coupling
Code duplication
Growth Reduction Mixed Constant
Increasing
plateau
Hill
Mainly a growth in time
• with recurrent plateau
Counts
Increase
Stable
increase
Plateau
increasing
Decreasing
plateau
Decrease
Stable
decrease
Plateau
decreasing
Valley
M
ix
Constant
Are developers resolving unit
interfacing and duplication issues?
SGit (IP)
CineTime (H)
13. VRIJE
UNIVERSITEIT
AMSTERDAM
Developers’ activities (RQ3)
13
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
0
10
20
30
40
Weeks
Maintainability(MT)Maintainabilityissuesdensity
Weeks
Maintainability hotspots
14. VRIJE
UNIVERSITEIT
AMSTERDAM
Developers’ activities (RQ3)
14
Which are the most recurrent types of maintainability issues in Android apps?
How does the density of Android maintainability issues evolve over time?
What are the development activities in which maintainability hotspots occur?
RQ1
RQ2
RQ3
0
10
20
30
40
Weeks
Maintainability(MT)
0
10
20
30
40
Weeks
Maintainability(MT)
App time series
Identify
hotspots
0
10
20
30
40
Weeks
Maintainability(MT)
Hotspots do not occur often in the app lifetime
(max: 8), average of ~1 hotspot per app
Content
analysis
sessions
Taxonomy of Android
developers activities [1]
Hotspots occur independently of the type of
developer’s activities
2,112 commits
sampling
[1] Pascarella, Geiger, Palomba, Di Nucci, Malavolta, Bacchelli.
Self-Reported Activities of Android Developers. MOBILESoft 2018
3,374
Counts
15. VRIJE
UNIVERSITEIT
AMSTERDAM
Conclusions
VRIJE
UNIVERSITEIT
AMSTERDAM
3
Why apps maintainability is important
High expectations
Continous feedback
Frequent updates
Continuous maintenance
VRIJE
UNIVERSITEIT
AMSTERDAM
Most recurrent maintainability issues (RQ1)
8
020406080100
MT US UC UI MC DP
Type of maintainability issue
Density
M
aintainability
(TO
TAL)
Unit size
Unit com
plexity
Unit interfacing
M
odule
coupling
Code
duplication
Density
of issues
#issues at commit c
NKLOC of the app after c
Average of 18 issues every 1k
LOCs
DUPLICATION and UNIT SIZE
are the most recurring issues
in Android apps
Is DUPLICATION really
an issue in Android?
VRIJE
UNIVERSITEIT
AMSTERDAM
Evolution trends by maintainability issue type
(RQ2)
12
DP
MC
UI
UC
US
MT
I SI IP PI D SD DP PD H V A C
10
20
30
40
Maintainability
Unit size
Unit complexity
Unit interfacing
Module coupling
Code duplication
Growth Reduction Mixed Constant
Increasing
plateau
Hill
Mainly a growth in time
• with recurrent plateau
Are developers resolving unit
interfacing and duplication issues?
Maintainability issues
rarely decrease!
VRIJE
UNIVERSITEIT
AMSTERDAM
Developers’ activities (RQ3)
14
0
10
20
30
40
Weeks
Maintainability(MT)
0
10
20
30
40
Weeks
Maintainability(MT)
App time series
Identify
hotspots
0
10
20
30
40
Weeks
Maintainability(MT)
Hotspots do not occur often in the app lifetime
(max: 8), average of >1 hotspot per app
Content
analysis
sessions
Taxonomy of Android
developers activities [1]
Hotspots occur independently of the type of
developer’s activities
2,112 commits
sampling
[1] Pascarella, Geiger, Palomba, Di Nucci, Malavolta, Bacchelli.
Self-Reported Activities of Android Developers. MOBILESoft 2018
Replication package
https://github.com/S2-group/ICSME2018ReplicationPackage
17. VRIJE
UNIVERSITEIT
AMSTERDAM
Demographics
17
10 20 50 100 200 500 1000 2000
Number of commits per app
1 2 5 10 20 50 100 200
Number of commits per snapshot
1 2 5 10 20 50 100
Number of unique contributors per app
10 20 50 100 200
Number of snapshots per app
2008 2009 2011 2012 2013 2014 2015 2016
Development start date per app
19. VRIJE
UNIVERSITEIT
AMSTERDAM
SAT processing time and resources
19
Average execution time = 8.73s per snapshot
Total processing time = ~12 days
LOCs processed = ~800 million
Checked-out resources = ~7 terabytes