SlideShare a Scribd company logo
1 of 21
Download to read offline
Using Source Code Metrics to Predict Change-
Prone Java Interfaces
Daniele Romano and Martin Pinzger
 Williamsburg, ICSM 2011
29 Sept 2011




         Delft
         University of
         Technology

         Challenge the future
Contributions
•  Correlation source code metrics vs #changes in interfaces:
   •  C&K metrics
   •  complexity and usage metrics
   •  interface usage cohesion metric
•  Predictive power of source code metrics for interfaces:
   •  prediction models
•  10 open source projects
   •  8 Eclipse projects
   •  Hibernate 2 and Hibernate 3

                                                             2
Motivations
•  Changes in interfaces are not desirable
   •  changes can have stronger impact
   •  interfaces define contracts
   •  existing object oriented metrics not sound for interfaces


 •  Related work about metrics as quality predictors
     •  no differences among the kind of class




                                                           3
Hypotheses

•  H1
   • InterfaceUsageCohesion (IUC) has a stronger
   correlation with number of Source Code Changes
   (#SCC) of interfaces than the C&K metrics
•  H2
   • IUC can improve the performance of prediction models
   to classify Java interfaces into change- and not-
   change-prone



                                                      4
The Approach

                      source code
                       repository




          metrics                   Changes
        computation                 Retrieval




Spearman rank         Correlation
                                       Metrics train models
  correlation         Prediction
                        analysis    Changes classify interfaces
                        analysis
      H1                                        H2

                                                        5
Metrics Computation

                     Evolizer Model
source code            Importer
 repository

                                      Famix
                                      Model
                      Computation
 Metrics
 Values               Understand




                                         6
Changes Computation

                                   Evolizer
      source code               Version Control
       repository                 Connector        Revisions
                                                     Info
                                                       &
                                                  Subsequent
                         Changes Computation         files
Fine-Grained
                            Evolizer Change
Source Code                     Distiller
  Changes
   (SCC)                    AST Comparison




                                                      7
Why SCC?
•  Filtering out useless changes due to modification of:
   •  licenses
   •  comments
•  More precise measurement




#Revision=1      #LineModified=1       #SCC=2

                                                           8
C&K Correlation for Interfaces
     Project            CB0            NOC        RFC         DIT     LCOM       WMC
Hibernate3           0.535**     0.029         0.592**     0.058     0.103     0.657**
Hibernate2           0.373**     0.065         0.325**     -0.01     0.006     0.522**
ecl.debug.core       0.484**     0.105         0.486**     0.232*    0.337     0.597**
ecl.debug.ui         0.216*      0.033         0.152       0.324**   0.214*    0.131
ecl.jface            0.239*      0.012         0.174**     0.103     0.320**   0.137
ecl.jdt.debug        0.512**     0.256**       0.349**     -0.049    0.238**   0.489**
ecl.team.core        0.367*      0.102         0.497**     0.243     0.400     0.451**
ecl.team.cvs.core    0.688**     -0.013        0.738**     0.618**   0.610**   0.744**
ecl.team.ui          0.301*      -0.003        0.299*      -0.103*   0.395**   0.299*
update.core          0.499**     -0.007        0.381**     0.146     0.482**   0.729**
     Median          0.428       0.031         0.365       0.124     0.328     0.505

            *= significant at α=0.05    **= significant at α=0.01

                                                                                   9
Weighted Methods per Class (WMC)


   •  ci cyclomatic complexity of the ith method
   •  n number of methods in a class



                                   Number of Methods




                                                   10
Interface Segregation Principle
  ISP
       defined by Robert C. Martin
       cope with fat interfaces


  Fat   interface
       interfaces that serve different clients
       each kind of client uses a different set of methods
       the interface should be split in more interface, each one
        designed to serve a specific client




                                                                    11
Interface Segregation Principle (I)




 Different clients do not share any methods

ClusterClients(i): counts the number of clients
that do not share any method of the interface i


                                                  12
Interface Usage Cohesion




 Different clients share a method




                                    13
Other metrics for interfaces…

•  Number Of Methods (NOM)
•  Number Of Arguments (NOA)
•  Arguments Per Procedure (APP)
•  Number of Clients (Cli)
•  Number of Invocations (Inv)
•  Number of Implementing Classes (Impl)




                                           14
Correlation for Interfaces
     Project            Inv            Cli     NOM          Clust      IUC
Hibernate3           0.544**    0.433**      0.657**     0.302**     -0.601**
Hibernate2           0.165      0.104        0.522**     0.016       -0.373**
ecl.debug.core       0.317**    0.327**      0.597**     0.273**     -0.682**
ecl.debug.ui         0.497**    0.498**      0.131       0.418**     -0.508**
ecl.jface            0.205      0.099        0.137       0.106**     -0.363**
ecl.jdt.debug        0.495**    0.471        0.489**     0.474**     -0.605**
ecl.team.core        0.261      0.278        0.451**     0.328*      -0.475**
ecl.team.cvs.core    0.557**    0.608** 0.744**          0.369       -0.819**
ecl.team.ui          0.290      0.270        0.299       0.056       -0.618**
update.core          0.677**    0.656** 0.729**          0.606**     -0.656**
     Median          0.317      0.327        0.505       0.328       -0.605

            *= significant at α=0.05     **= significant at α=0.01

                                                                                15
Prediction Analysis
•  Three Machine Learning Algorithms
    •  upport Vector Machine
     S
    •  aïve Bayes Network
     N

    •  eural Nets
     N

•  Interfaces classification:




•  Training using 10 fold cross-validation
    •  {CBO, RFC, LCOM, WMC} = CK
    •  {CBO, RFC, LCOM, WMC, IUC} = IUC
                                             16
Prediction – AUC values
                       NBayes             LibSVN                NN
      Project        CK     IUC      CK        IUC         CK        IUC
ecl.team.cvs.core   0.55    0.75    0.692    0.811   0.8         0.8
ecl.debug.core      0.75    0.79    0.806    0.828   0.85        0.875
ecl.debug.ui        0.66    0.72    0.71     0.742   0.748       0.766
Hibernate2          0.745   0.807   0.735    0.708   0.702       0.747
Hibernate3          0.835   0.862   0.64     0.856   0.874       0.843
ecl.jdt.debug       0.79    0.738   0.741    0.82    0.77        0.762
ecl.jface           0.639   0.734   0.607    0.778   0.553       0.542
ecl.team.core       0.708   0.792   0.617    0.608   0.725       0.85
ecl.team.ui         0.88     0.8    0.74     0.884   0.65        0.75
update.core         0.782   0.811   0.794    0.817   0.675       0.744
      Median        0.747   0.791   0.722    0.814   0.736       0.764


                                                                        17
Results
•  H1 ACCEPTED
   • IUC has a stronger correlation with #SCC of interfaces
   than the C&K metrics
   •  UIC shows the best correlation

•  H2 PARTIALLY ACCEPTED
   • IUC can improve the performance of prediction models
   to classify Java interfaces into change- and not-
   change-prone
   •  Despite the improvements Wilcoxon test showed a
   significant difference only for the LibSVM

                                                        18
Implications
• Researchers
  •  taking in account the nature of the measured entities


• Quality Engineers
  •  enlarge metrics suites


• Developers and Architects
  •  Measure the ISP violation



                                                        19
Future Work

• Metrics measurement overtime

• Further validation

• Are the shared methods the problem?

• Component Based System and Service Oriented System




                                                20
21

More Related Content

Viewers also liked

Reliability and Quality - Predicting post-release defects using pre-release f...
Reliability and Quality - Predicting post-release defects using pre-release f...Reliability and Quality - Predicting post-release defects using pre-release f...
Reliability and Quality - Predicting post-release defects using pre-release f...ICSM 2011
 
Richard Kemmerer Keynote icsm11
Richard Kemmerer Keynote icsm11Richard Kemmerer Keynote icsm11
Richard Kemmerer Keynote icsm11ICSM 2011
 
Lionel Briand ICSM 2011 Keynote
Lionel Briand ICSM 2011 KeynoteLionel Briand ICSM 2011 Keynote
Lionel Briand ICSM 2011 KeynoteICSM 2011
 
Metrics - You can't control the unfamiliar
Metrics - You can't control the unfamiliarMetrics - You can't control the unfamiliar
Metrics - You can't control the unfamiliarICSM 2011
 
Industry - The Evolution of Information Systems. A Case Study on Document Man...
Industry - The Evolution of Information Systems. A Case Study on Document Man...Industry - The Evolution of Information Systems. A Case Study on Document Man...
Industry - The Evolution of Information Systems. A Case Study on Document Man...ICSM 2011
 
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...ICSM 2011
 
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...ICSM 2011
 
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...ICSM 2011
 
Industry - Testing & Quality Assurance in Data Migration Projects
Industry - Testing & Quality Assurance in Data Migration Projects Industry - Testing & Quality Assurance in Data Migration Projects
Industry - Testing & Quality Assurance in Data Migration Projects ICSM 2011
 
Natural Language Analysis - Mining Java Class Naming Conventions
Natural Language Analysis - Mining Java Class Naming ConventionsNatural Language Analysis - Mining Java Class Naming Conventions
Natural Language Analysis - Mining Java Class Naming ConventionsICSM 2011
 
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...ICSM 2011
 
ERA - Tracking Technical Debt
ERA - Tracking Technical DebtERA - Tracking Technical Debt
ERA - Tracking Technical DebtICSM 2011
 
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...ICSM 2011
 
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...ICSM 2011
 
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...ICSM 2011
 
Components - Graph Based Detection of Library API Limitations
Components - Graph Based Detection of Library API LimitationsComponents - Graph Based Detection of Library API Limitations
Components - Graph Based Detection of Library API LimitationsICSM 2011
 
ERA - Clustering and Recommending Collections of Code Relevant to Task
ERA - Clustering and Recommending Collections of Code Relevant to TaskERA - Clustering and Recommending Collections of Code Relevant to Task
ERA - Clustering and Recommending Collections of Code Relevant to TaskICSM 2011
 
Impact analysis - A Seismology-inspired Approach to Study Change Propagation
Impact analysis - A Seismology-inspired Approach to Study Change PropagationImpact analysis - A Seismology-inspired Approach to Study Change Propagation
Impact analysis - A Seismology-inspired Approach to Study Change PropagationICSM 2011
 
ERA - A Comparison of Stemmers on Source Code Identifiers for Software Search
ERA - A Comparison of Stemmers on Source Code Identifiers for Software SearchERA - A Comparison of Stemmers on Source Code Identifiers for Software Search
ERA - A Comparison of Stemmers on Source Code Identifiers for Software SearchICSM 2011
 
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...ICSM 2011
 

Viewers also liked (20)

Reliability and Quality - Predicting post-release defects using pre-release f...
Reliability and Quality - Predicting post-release defects using pre-release f...Reliability and Quality - Predicting post-release defects using pre-release f...
Reliability and Quality - Predicting post-release defects using pre-release f...
 
Richard Kemmerer Keynote icsm11
Richard Kemmerer Keynote icsm11Richard Kemmerer Keynote icsm11
Richard Kemmerer Keynote icsm11
 
Lionel Briand ICSM 2011 Keynote
Lionel Briand ICSM 2011 KeynoteLionel Briand ICSM 2011 Keynote
Lionel Briand ICSM 2011 Keynote
 
Metrics - You can't control the unfamiliar
Metrics - You can't control the unfamiliarMetrics - You can't control the unfamiliar
Metrics - You can't control the unfamiliar
 
Industry - The Evolution of Information Systems. A Case Study on Document Man...
Industry - The Evolution of Information Systems. A Case Study on Document Man...Industry - The Evolution of Information Systems. A Case Study on Document Man...
Industry - The Evolution of Information Systems. A Case Study on Document Man...
 
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...
Impact Analysis - ImpactScale: Quantifying Change Impact to Predict Faults in...
 
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...
Components - Crossing the Boundaries while Analyzing Heterogeneous Component-...
 
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...
ERA Poster - Measuring Disruption from Software Evolution Activities Using Gr...
 
Industry - Testing & Quality Assurance in Data Migration Projects
Industry - Testing & Quality Assurance in Data Migration Projects Industry - Testing & Quality Assurance in Data Migration Projects
Industry - Testing & Quality Assurance in Data Migration Projects
 
Natural Language Analysis - Mining Java Class Naming Conventions
Natural Language Analysis - Mining Java Class Naming ConventionsNatural Language Analysis - Mining Java Class Naming Conventions
Natural Language Analysis - Mining Java Class Naming Conventions
 
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...
ERA - Measuring Disruption from Software Evolution Activities Using Graph-Bas...
 
ERA - Tracking Technical Debt
ERA - Tracking Technical DebtERA - Tracking Technical Debt
ERA - Tracking Technical Debt
 
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...
Tutorial 2 - Practical Combinatorial (t-way) Methods for Detecting Complex Fa...
 
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...
Natural Language Analysis - Expanding Identifiers to Normalize Source Code Vo...
 
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...
Industry - Precise Detection of Un-Initialized Variables in Large, Real-life ...
 
Components - Graph Based Detection of Library API Limitations
Components - Graph Based Detection of Library API LimitationsComponents - Graph Based Detection of Library API Limitations
Components - Graph Based Detection of Library API Limitations
 
ERA - Clustering and Recommending Collections of Code Relevant to Task
ERA - Clustering and Recommending Collections of Code Relevant to TaskERA - Clustering and Recommending Collections of Code Relevant to Task
ERA - Clustering and Recommending Collections of Code Relevant to Task
 
Impact analysis - A Seismology-inspired Approach to Study Change Propagation
Impact analysis - A Seismology-inspired Approach to Study Change PropagationImpact analysis - A Seismology-inspired Approach to Study Change Propagation
Impact analysis - A Seismology-inspired Approach to Study Change Propagation
 
ERA - A Comparison of Stemmers on Source Code Identifiers for Software Search
ERA - A Comparison of Stemmers on Source Code Identifiers for Software SearchERA - A Comparison of Stemmers on Source Code Identifiers for Software Search
ERA - A Comparison of Stemmers on Source Code Identifiers for Software Search
 
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...
Postdoc symposium - A Logic Meta-Programming Foundation for Example-Driven Pa...
 

Similar to Metrics - Using Source Code Metrics to Predict Change-Prone Java Interfaces

A tale of bug prediction in software development
A tale of bug prediction in software developmentA tale of bug prediction in software development
A tale of bug prediction in software developmentMartin Pinzger
 
IncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudIncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudGábor Szárnyas
 
Expanding your impact with programmability in the data center
Expanding your impact with programmability in the data centerExpanding your impact with programmability in the data center
Expanding your impact with programmability in the data centerCisco Canada
 
A Unique Test Bench for Various System-on-a-Chip
A Unique Test Bench for Various System-on-a-Chip A Unique Test Bench for Various System-on-a-Chip
A Unique Test Bench for Various System-on-a-Chip IJECEIAES
 
MySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudMySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudVitor Oliveira
 
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)Robb Boyd
 
Performance Oriented Design
Performance Oriented DesignPerformance Oriented Design
Performance Oriented DesignRodrigo Campos
 
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Preeya Selvarajah
 
Ebs dba con4696_pdf_4696_0001
Ebs dba con4696_pdf_4696_0001Ebs dba con4696_pdf_4696_0001
Ebs dba con4696_pdf_4696_0001jucaab
 
ASP.NET MVC Performance
ASP.NET MVC PerformanceASP.NET MVC Performance
ASP.NET MVC Performancerudib
 
#SPFestSea Introduction to #Azure #Functions v2
#SPFestSea Introduction to #Azure #Functions v2#SPFestSea Introduction to #Azure #Functions v2
#SPFestSea Introduction to #Azure #Functions v2Vincent Biret
 
SERENE 2014 School: Daniel varro serene2014_school
SERENE 2014 School: Daniel varro serene2014_schoolSERENE 2014 School: Daniel varro serene2014_school
SERENE 2014 School: Daniel varro serene2014_schoolHenry Muccini
 
SERENE 2014 School: Incremental Model Queries over the Cloud
SERENE 2014 School: Incremental Model Queries over the CloudSERENE 2014 School: Incremental Model Queries over the Cloud
SERENE 2014 School: Incremental Model Queries over the CloudSERENEWorkshop
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandboxElaine Van Bergen
 
.NET Core Apps: Design & Development
.NET Core Apps: Design & Development.NET Core Apps: Design & Development
.NET Core Apps: Design & DevelopmentGlobalLogic Ukraine
 
170215 msa intro
170215 msa intro170215 msa intro
170215 msa introSonic leigh
 
Microsoft Cloud BI Update 2012 for SQL Saturday Philly
Microsoft Cloud BI Update 2012 for SQL Saturday PhillyMicrosoft Cloud BI Update 2012 for SQL Saturday Philly
Microsoft Cloud BI Update 2012 for SQL Saturday PhillyMark Kromer
 
Michael Ledford Fall 2014 Resume
Michael Ledford Fall 2014 ResumeMichael Ledford Fall 2014 Resume
Michael Ledford Fall 2014 ResumeMichael Ledford
 

Similar to Metrics - Using Source Code Metrics to Predict Change-Prone Java Interfaces (20)

Keynote HotSWUp 2012
Keynote HotSWUp 2012Keynote HotSWUp 2012
Keynote HotSWUp 2012
 
A tale of bug prediction in software development
A tale of bug prediction in software developmentA tale of bug prediction in software development
A tale of bug prediction in software development
 
IncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudIncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the Cloud
 
Expanding your impact with programmability in the data center
Expanding your impact with programmability in the data centerExpanding your impact with programmability in the data center
Expanding your impact with programmability in the data center
 
A Unique Test Bench for Various System-on-a-Chip
A Unique Test Bench for Various System-on-a-Chip A Unique Test Bench for Various System-on-a-Chip
A Unique Test Bench for Various System-on-a-Chip
 
MySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudMySQL Replication Performance in the Cloud
MySQL Replication Performance in the Cloud
 
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)
Simulating Networks Using Cisco Modeling Labs (TechWiseTV Workshop)
 
Performance Oriented Design
Performance Oriented DesignPerformance Oriented Design
Performance Oriented Design
 
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
 
Ebs dba con4696_pdf_4696_0001
Ebs dba con4696_pdf_4696_0001Ebs dba con4696_pdf_4696_0001
Ebs dba con4696_pdf_4696_0001
 
ASP.NET MVC Performance
ASP.NET MVC PerformanceASP.NET MVC Performance
ASP.NET MVC Performance
 
ASIC design verification
ASIC design verificationASIC design verification
ASIC design verification
 
#SPFestSea Introduction to #Azure #Functions v2
#SPFestSea Introduction to #Azure #Functions v2#SPFestSea Introduction to #Azure #Functions v2
#SPFestSea Introduction to #Azure #Functions v2
 
SERENE 2014 School: Daniel varro serene2014_school
SERENE 2014 School: Daniel varro serene2014_schoolSERENE 2014 School: Daniel varro serene2014_school
SERENE 2014 School: Daniel varro serene2014_school
 
SERENE 2014 School: Incremental Model Queries over the Cloud
SERENE 2014 School: Incremental Model Queries over the CloudSERENE 2014 School: Incremental Model Queries over the Cloud
SERENE 2014 School: Incremental Model Queries over the Cloud
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandbox
 
.NET Core Apps: Design & Development
.NET Core Apps: Design & Development.NET Core Apps: Design & Development
.NET Core Apps: Design & Development
 
170215 msa intro
170215 msa intro170215 msa intro
170215 msa intro
 
Microsoft Cloud BI Update 2012 for SQL Saturday Philly
Microsoft Cloud BI Update 2012 for SQL Saturday PhillyMicrosoft Cloud BI Update 2012 for SQL Saturday Philly
Microsoft Cloud BI Update 2012 for SQL Saturday Philly
 
Michael Ledford Fall 2014 Resume
Michael Ledford Fall 2014 ResumeMichael Ledford Fall 2014 Resume
Michael Ledford Fall 2014 Resume
 

Recently uploaded

Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 

Recently uploaded (20)

Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 

Metrics - Using Source Code Metrics to Predict Change-Prone Java Interfaces

  • 1. Using Source Code Metrics to Predict Change- Prone Java Interfaces Daniele Romano and Martin Pinzger Williamsburg, ICSM 2011 29 Sept 2011 Delft University of Technology Challenge the future
  • 2. Contributions •  Correlation source code metrics vs #changes in interfaces: •  C&K metrics •  complexity and usage metrics •  interface usage cohesion metric •  Predictive power of source code metrics for interfaces: •  prediction models •  10 open source projects •  8 Eclipse projects •  Hibernate 2 and Hibernate 3 2
  • 3. Motivations •  Changes in interfaces are not desirable •  changes can have stronger impact •  interfaces define contracts •  existing object oriented metrics not sound for interfaces •  Related work about metrics as quality predictors •  no differences among the kind of class 3
  • 4. Hypotheses •  H1 • InterfaceUsageCohesion (IUC) has a stronger correlation with number of Source Code Changes (#SCC) of interfaces than the C&K metrics •  H2 • IUC can improve the performance of prediction models to classify Java interfaces into change- and not- change-prone 4
  • 5. The Approach source code repository metrics Changes computation Retrieval Spearman rank Correlation Metrics train models correlation Prediction analysis Changes classify interfaces analysis H1 H2 5
  • 6. Metrics Computation Evolizer Model source code Importer repository Famix Model Computation Metrics Values Understand 6
  • 7. Changes Computation Evolizer source code Version Control repository Connector Revisions Info & Subsequent Changes Computation files Fine-Grained Evolizer Change Source Code Distiller Changes (SCC) AST Comparison 7
  • 8. Why SCC? •  Filtering out useless changes due to modification of: •  licenses •  comments •  More precise measurement #Revision=1 #LineModified=1 #SCC=2 8
  • 9. C&K Correlation for Interfaces Project CB0 NOC RFC DIT LCOM WMC Hibernate3 0.535** 0.029 0.592** 0.058 0.103 0.657** Hibernate2 0.373** 0.065 0.325** -0.01 0.006 0.522** ecl.debug.core 0.484** 0.105 0.486** 0.232* 0.337 0.597** ecl.debug.ui 0.216* 0.033 0.152 0.324** 0.214* 0.131 ecl.jface 0.239* 0.012 0.174** 0.103 0.320** 0.137 ecl.jdt.debug 0.512** 0.256** 0.349** -0.049 0.238** 0.489** ecl.team.core 0.367* 0.102 0.497** 0.243 0.400 0.451** ecl.team.cvs.core 0.688** -0.013 0.738** 0.618** 0.610** 0.744** ecl.team.ui 0.301* -0.003 0.299* -0.103* 0.395** 0.299* update.core 0.499** -0.007 0.381** 0.146 0.482** 0.729** Median 0.428 0.031 0.365 0.124 0.328 0.505 *= significant at α=0.05 **= significant at α=0.01 9
  • 10. Weighted Methods per Class (WMC) •  ci cyclomatic complexity of the ith method •  n number of methods in a class Number of Methods 10
  • 11. Interface Segregation Principle   ISP   defined by Robert C. Martin   cope with fat interfaces   Fat interface   interfaces that serve different clients   each kind of client uses a different set of methods   the interface should be split in more interface, each one designed to serve a specific client 11
  • 12. Interface Segregation Principle (I) Different clients do not share any methods ClusterClients(i): counts the number of clients that do not share any method of the interface i 12
  • 13. Interface Usage Cohesion Different clients share a method 13
  • 14. Other metrics for interfaces… •  Number Of Methods (NOM) •  Number Of Arguments (NOA) •  Arguments Per Procedure (APP) •  Number of Clients (Cli) •  Number of Invocations (Inv) •  Number of Implementing Classes (Impl) 14
  • 15. Correlation for Interfaces Project Inv Cli NOM Clust IUC Hibernate3 0.544** 0.433** 0.657** 0.302** -0.601** Hibernate2 0.165 0.104 0.522** 0.016 -0.373** ecl.debug.core 0.317** 0.327** 0.597** 0.273** -0.682** ecl.debug.ui 0.497** 0.498** 0.131 0.418** -0.508** ecl.jface 0.205 0.099 0.137 0.106** -0.363** ecl.jdt.debug 0.495** 0.471 0.489** 0.474** -0.605** ecl.team.core 0.261 0.278 0.451** 0.328* -0.475** ecl.team.cvs.core 0.557** 0.608** 0.744** 0.369 -0.819** ecl.team.ui 0.290 0.270 0.299 0.056 -0.618** update.core 0.677** 0.656** 0.729** 0.606** -0.656** Median 0.317 0.327 0.505 0.328 -0.605 *= significant at α=0.05 **= significant at α=0.01 15
  • 16. Prediction Analysis •  Three Machine Learning Algorithms •  upport Vector Machine S •  aïve Bayes Network N •  eural Nets N •  Interfaces classification: •  Training using 10 fold cross-validation •  {CBO, RFC, LCOM, WMC} = CK •  {CBO, RFC, LCOM, WMC, IUC} = IUC 16
  • 17. Prediction – AUC values NBayes LibSVN NN Project CK IUC CK IUC CK IUC ecl.team.cvs.core 0.55 0.75 0.692 0.811 0.8 0.8 ecl.debug.core 0.75 0.79 0.806 0.828 0.85 0.875 ecl.debug.ui 0.66 0.72 0.71 0.742 0.748 0.766 Hibernate2 0.745 0.807 0.735 0.708 0.702 0.747 Hibernate3 0.835 0.862 0.64 0.856 0.874 0.843 ecl.jdt.debug 0.79 0.738 0.741 0.82 0.77 0.762 ecl.jface 0.639 0.734 0.607 0.778 0.553 0.542 ecl.team.core 0.708 0.792 0.617 0.608 0.725 0.85 ecl.team.ui 0.88 0.8 0.74 0.884 0.65 0.75 update.core 0.782 0.811 0.794 0.817 0.675 0.744 Median 0.747 0.791 0.722 0.814 0.736 0.764 17
  • 18. Results •  H1 ACCEPTED • IUC has a stronger correlation with #SCC of interfaces than the C&K metrics •  UIC shows the best correlation •  H2 PARTIALLY ACCEPTED • IUC can improve the performance of prediction models to classify Java interfaces into change- and not- change-prone •  Despite the improvements Wilcoxon test showed a significant difference only for the LibSVM 18
  • 19. Implications • Researchers •  taking in account the nature of the measured entities • Quality Engineers •  enlarge metrics suites • Developers and Architects •  Measure the ISP violation 19
  • 20. Future Work • Metrics measurement overtime • Further validation • Are the shared methods the problem? • Component Based System and Service Oriented System 20
  • 21. 21