Outline. Research Definition. Motivation. Foundation of Reverse Engineering. Dynamic Analysis and Design Pattern Detection in Java Programs

Similar documents
Task scenarios Outline. Scenarios in Knowledge Extraction. Proposed Framework for Scenario to Design Diagram Transformation

Service Oriented Enterprise Architecture and Service Oriented Enterprise

A SOFTWARE MODEL FOR THE MULTILAYER PERCEPTRON

Goals of the Lecture UML Implementation Diagrams

Τεχνολογία Λογισμικού

Keywords Software Architecture, Object-oriented metrics, Reliability, Reusability, Coupling evaluator, Cohesion, efficiency

On Modeling Software Architecture Recovery as Graph Matching

On Modeling Software Architecture Recovery as Graph Matching

The identification of key quality characteristics based on FAHP

COP4020 Programming Languages. Compilers and Interpreters Prof. Robert van Engelen

GE FUNDAMENTALS OF COMPUTING AND PROGRAMMING UNIT III

Goals of this Lecture Activity Diagram Example

Software development of components for complex signal analysis on the example of adaptive recursive estimation methods.

Model Based Design: develpment of Electronic Systems

Counting the Number of Minimum Roman Dominating Functions of a Graph

1 Enterprise Modeler

Requirements Analysis

Modeling a Software Architecture. Paolo Ciancarini

An Improved Shuffled Frog-Leaping Algorithm for Knapsack Problem

On-line cursive letter recognition using sequences of local minima/maxima. Robert Powalka

Dynamic Analysis and Design Pattern Detection in Java Programs

Chapter 1. Introduction to Computers and C++ Programming. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

POMA: A Pattern-Oriented and Model-Driven Architecture

IncorporatingCluster-BasedRelationshipsin Web Rule Language

Rapid Frequent Pattern Growth and Possibilistic Fuzzy C-means Algorithms for Improving the User Profiling Personalized Web Page Recommendation System

What are Information Systems?

Neuro Fuzzy Model for Human Face Expression Recognition

Evaluation scheme for Tracking in AMI

ISSN (Print) Research Article. *Corresponding author Nengfa Hu

A Method of Malicious Application Detection

Improvement of the Orthogonal Code Convolution Capabilities Using FPGA Implementation

A New Morphological 3D Shape Decomposition: Grayscale Interframe Interpolation Method

SPIRAL DSP Transform Compiler:

Last class. n Scheme. n Equality testing. n eq? vs. equal? n Higher-order functions. n map, foldr, foldl. n Tail recursion

Software Architecture. Paolo Ciancarini

Interactive Systems Engineering: A Pattern-Oriented and Model-Driven Architecture

Introduction to Pattern Oriented Analysis and Design (POAD) Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU

Pseudocode ( 1.1) Analysis of Algorithms. Primitive Operations. Pseudocode Details. Running Time ( 1.1) Estimating performance

Python Programming: An Introduction to Computer Science

3D Model Retrieval Method Based on Sample Prediction

CSC 220: Computer Organization Unit 11 Basic Computer Organization and Design

Evaluation of Different Fitness Functions for the Evolutionary Testing of an Autonomous Parking System

Harris Corner Detection Algorithm at Sub-pixel Level and Its Application Yuanfeng Han a, Peijiang Chen b * and Tian Meng c

Improving Template Based Spike Detection

Chapter 5. Functions for All Subtasks. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Today s objectives. CSE401: Introduction to Compiler Construction. What is a compiler? Administrative Details. Why study compilers?

New Fuzzy Color Clustering Algorithm Based on hsl Similarity

Structuring Redundancy for Fault Tolerance. CSE 598D: Fault Tolerant Software

HADOOP: A NEW APPROACH FOR DOCUMENT CLUSTERING

A Case Study of Clustering the Source Code

An Effort Estimation by UML Points in the Early Stage of Software Development

Research Article Genetic Programming for Automating the Development of Data Management Algorithms in Information Technology Systems

Data diverse software fault tolerance techniques

An Empirical Study on Detecting and Fixing Buffer Overflow Bugs

What Is Object-Orientation?

Comparison of Abstract Data Type and Abstract State Encapsulation Detection Techniques for Architectural Understanding

COSC 1P03. Ch 7 Recursion. Introduction to Data Structures 8.1

Chapter 4 Threads. Operating Systems: Internals and Design Principles. Ninth Edition By William Stallings

Term Project Report. This component works to detect gesture from the patient as a sign of emergency message and send it to the emergency manager.

Chapter 8 Web Services Foundations

Empirical Validate C&K Suite for Predict Fault-Proneness of Object-Oriented Classes Developed Using Fuzzy Logic.

n Explore virtualization concepts n Become familiar with cloud concepts

Title: Robust Registration of Multimodal Remote Sensing Images Based on Structural Similarity.

INF5120 Modellbasert Systemutvikling Modelbased System development

Solutions to Final COMS W4115 Programming Languages and Translators Monday, May 4, :10-5:25pm, 309 Havemeyer

Keywords: Data integration, Peer-to-peer system, mappings

Analysis of Server Resource Consumption of Meteorological Satellite Application System Based on Contour Curve

Data Structures and Algorithms. Analysis of Algorithms

VALIDATING DIRECTIONAL EDGE-BASED IMAGE FEATURE REPRESENTATIONS IN FACE RECOGNITION BY SPATIAL CORRELATION-BASED CLUSTERING

Elementary Educational Computer

VISUALSLX AN OPEN USER SHELL FOR HIGH-PERFORMANCE MODELING AND SIMULATION. Thomas Wiedemann

Euclidean Distance Based Feature Selection for Fault Detection Prediction Model in Semiconductor Manufacturing Process

+ Cluster analysis. a generalization can be derived for each cluster and hence processing is done batch wise rather than individually

An Efficient Algorithm for Graph Bisection of Triangularizations

Computers and Scientific Thinking

Chapter 3 Classification of FFT Processor Algorithms

Shape Analysis and Applications 1

Dynamic Programming and Curve Fitting Based Road Boundary Detection

COP4020 Programming Languages. Functional Programming Prof. Robert van Engelen

Image Segmentation EEE 508

A Metric-based Approach to Detect Abstract Data Types and State Encapsulations

Text-based Image Indexing and Retrieval using Formal Concept Analysis

The Magma Database file formats

Outline and Reading. Analysis of Algorithms. Running Time. Experimental Studies. Limitations of Experiments. Theoretical Analysis

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Bayesian approach to reliability modelling for a probability of failure on demand parameter

Chapter 4. Procedural Abstraction and Functions That Return a Value. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

n We have discussed classes in previous lectures n Here, we discuss design of classes n Library design considerations

Method to match waves of ray-tracing simulations with 3- D high-resolution propagation measurements Guo, P.; van Dommele, A.R.; Herben, M.H.A.J.

Analysis of Class Design Coupling Based on Information Entropy Di Jiang 1,2, a, Hua Zhou 1,2,b and Xingping Sun 1,2,c

Running Time. Analysis of Algorithms. Experimental Studies. Limitations of Experiments

Application of rule rewriting system to software automated tuning

How do we evaluate algorithms?

Running Time ( 3.1) Analysis of Algorithms. Experimental Studies. Limitations of Experiments

Analysis of Algorithms

DCMIX: Generating Mixed Workloads for the Cloud Data Center

Analysis Metrics. Intro to Algorithm Analysis. Slides. 12. Alg Analysis. 12. Alg Analysis

Mining from Quantitative Data with Linguistic Minimum Supports and Confidences

EMPIRICAL ANALYSIS OF FAULT PREDICATION TECHNIQUES FOR IMPROVING SOFTWARE PROCESS CONTROL

Pruning and Summarizing the Discovered Time Series Association Rules from Mechanical Sensor Data Qing YANG1,a,*, Shao-Yu WANG1,b, Ting-Ting ZHANG2,c

Transcription:

Dyamic Aalysis ad Desig Patter Detectio i Java Programs Outlie Lei Hu Kamra Sartipi {hul4, sartipi}@mcmasterca Departmet of Computig ad Software McMaster Uiversity Caada Motivatio Research Problem Defiitio ad Solutio Proposed Framework for Feature-Orieted Desig Patter Detectio Feature-orieted Dyamic Aalysis Two-phase Desig Patter Detectio Process Case studies o Three Versios of JHotDraw s Cotributio SEKE 08 July 3, 2008 1 2 Motivatio Research Defiitio Software product lie is a group of software-itesive systems that share a commo set of features to satisfy the specific eeds from the market Developed based o a referece architecture which cosists of commo parts ad variable parts A evolutioary developmet of a software product lie starts from reverse egieerig activities Uderstadig the existig systems Locatig commo features to reuse Desig patter recovery ca support the costructio of software product lie Uderstadig the existig system at desig level Reusig the existig system s desig artefacts Research Ageda: To devise a methodology ad supportig tools for recoverig the istaces of desig patters from the implemetatio of software system s behavioural features, by the meas of a high level patter descriptio method Provided Solutio: We propose a reverse egieerig framework which combies feature-orieted dyamic aalysis with two-phase desig patter detectio techique to idetify the istaces of desig patters for differet software behavioural features 3 4 Foudatio of Reverse Egieerig Reverse Egieerig A process of aalyzig a software system to idetify a system s compoets ad their iterrelatioships, ad create represetatio of the system at a higher level of abstractio [Chikofsky&Cross ] Two major sub-areas i Reverse Egieerig Static Aalysis Clusterig Visualizatio Patter Matchig (Desig Patter Recovery) Dyamic Aalysis Feature idetificatio Behavioural desig model extractio Proposed Framework for Feature-orieted Desig Patter Detectio 5 6

(Dyamic Aalysis) Feature-orieted Dyamic Aalysis Elicit commo features of existig systems A group of similar systems i a domai 1 2 3 Subject (Static Aalysis) Two-phase Desig Patter Detectio Process Desig Patter Repository Obtai iter-class relatios by parsig the Subject features For each commo feature, geerate a set of featurespecific scearios for Subject Group of sceario sets Execute sceario sets o the istrumeted Subject to geerate executio traces Relatio matrices Approximate matchig usig class relatio cardiality Use cocept lattice to separate commo classes form feature specific classes Executio Patters Specific features f1 f2 Executio traces Extract executio patters usig sequetial patter miig Feature-specific classes Structural matchig usig iter-class relatios Source-class cluster Target patter from Repository Idetified Target patter istaces Dyamic Aalysis Feature-Orieted Dyamic Aalysis f3 f4 f5 Mappig betwee features ad feature-specific classes Correlate features with idetified desig patter istaces Mappig betwee features ad desig patter istaces 7 8 Feature-Orieted Dyamic Aalysis ----Executio Traces Geeratio Usig Eclipse Test ad Performace Tools Tools Platform Platform (TPTP) (TPTP) to collect to collect the executio the executio trac traces geerated geerated by ruig by ruig the scearios the scearios i the feature-specific i the feature-specific sceario set sceario set Reducig executio trace size usig filter set mechaism Feature-Specific Sceario Set - Start, Draw a Ellipse, move, Exit - Start, Draw a Lie, move, Exit - Start, Draw a Rectagle, move, Exit - - Start, Draw a Polygo, move, Exit TPTP O Eclipse Ruig the system i a profilig mode Executio traces Eter CH/ifa/draw/stadard/AbstractHadle Leave CH/ifa/draw/stadard/AbstractHadle Eter CH/ifa/draw/stadard/RelativeLocator Eter CH/ifa/draw/figures/RectagleFigure Leave CH/ifa/draw/figures/RectagleFigure Leave CH/ifa/draw/stadard/LocatorHadle Leave CH/ifa/draw/stadard/AbstractHadle Feature-Orieted Dyamic Aalysis ----Executio Patter Extractio Feature 1 Feature 2 Feature 3, C4, C3, C8, C4, 5, C2, C3, C8, 6, 5, C5, C3, C8, C4, 0, 8, C20, C7, C3, C8, C20, 3, 5, C4, C3, C8, C9, 5, C3, C8, C4, 0, 7, 8, C20, C3, C8, C4, 0, 8, C20 feature 1 2 3 Executio Patters Executio Traces for 3 Feature-specific Sceario Sets 5 C4, 0 8, C20, C4, C23, C28, C20, C2, C23, C28, 5, C5, C23, C28, C4, 0, 8, C20, C7, C23, C28, C20, 3, 5, C4, C23, C28, C9,, C4, 0, 5, C23, C28, C4, 0, 7, 8, C20 5 C4, 0 8, C20 5, C4, C33, C38, C4, 5, C2, C33, C38, 6, 5, C5, C33, C38, 5, C7, C33, C38, C20, 3, 5, C4, C33, C38, C9, 5, C9, C33, C38, 0, 5 Commo patter Noise patter Apply Sequetial Patter Miig to geerate Executio Patters 9 C3, C8 C23, C28 C33, C38 Feature-specific patter 10 Static Aalysis Two-Phase Desig Patter Detectio 11 Depth2-SubClass1 Describe Desig Patter usig PDL Differet types of the classes i PDL Mai-seed class, Depth1 class, Depth2 class ad Seed-depth1 class Example: Class diagram of a target desig patter Depth1-AssoClass Depth1-Subclass1 Depth1-SuperClass1 MaiSeedClass Depth1-Subclass1 PDL Represetatio of a target desig patter 1 Begi-PDL 2 Patter: TargetPatter 3 Mai-seed class: MaiSeedClass 4 Depth1: 5 Iherit_From: 6 Depth1-SuperClass1 7 Iherited_By: 8 Depth1-SubClass1; 9 Depth1-SubClass2 10 i_associatio: 11 Depth1-AssoClass 12 Depth2: 13 Seed-Depth1 : Depth1-AssoClass 14 Iherited_By: 15 Depth2-SubClass1 16 Ed-Patter 17 Ed-PDL 12

Two-phase Desig Patter Detectio Process Two-phase Desig Patter Detectio ----Approximate Matchig Subject Obtai iter-class relatios by parsig the Subject Structural Matchig Relatio matrices Depth1Matchig Approximate Matchig Depth1Matchig a list of sourceclass clusters Set of all combiatios of matched source-classes of all depth1-classes Desig Patter Repository Attribute Vector The attribute vector icludes the followig items: Number of Iherit _From / Iherited_By relatio Number of i _Associatio / out _Associatio relatio Number of isabstract relatio (0 or 1) Similarity Fuctio Give the attribute vector of the mai-seed class ad the attribute vector of ad a source-class, the approximate similarity fuctio is defied as: Depth2Matchig Set of all combiatios of matched source-classes of all depth2-classes Merge Depth1 combiatio ad Depth2 combiatio Idetified desig patter istaces 13 Result: a group of source-class clusters Two-phase Desig Patter Detectio ----Structural Matchig Idetifyig all the istaces of the target desig patter withi a source-class cluster A Example Class diagram of Bridge Desig Patter PDL represetatio of Bridge Desig Patter Depth1Matchig Iput: a source-class cluster, a cadidate mai-seed class, ad a target desig patter Output: set of all combiatios of matched source-classes of all the depth1-classes Depth2Matchig Iput: a source-class cluster, a combiatio of matched source-classes of all the depth1-classes ad a target desig patter Output: set of istaces of the target desig patter 15 Abstractio Implemetor RefiedAbstractio CocreteImplemetorA CocreteImplemetorB Attribute Vector Attr_Vec (Implemetor) = [0, 2, 1, 0, 1] 1 Begi-PDL 2 Patter: Bridge 3 Mai-seed class: Implemetor 4 Depth1: 5 Iherited_By: 6 CocreteImplemetorA; 7 CocreteImplemetorB 8 i_associatio: 9 Abstractio 10 Depth2: 11 Seed-Depth1 : Abstractio 12 Iherited_By: 13 RefiedAbstractio 14 AbstractClass: 15 Implemetor; 16 Abstractio 17 Ed-Patter 16 18 Ed-PDL A Example A Example Search Space Depth1Matchig Class diagram of Bridge Desig Patter A source-class cluster Abstractio Implemetor RefiedAbstractio CocreteImplemetorA CocreteImplemetorB Through applyig approximate matchig o the search space, we obtai two cadidates of mai-seed class C2 ad C3 Attr_Vec(C2)=[1, 2, 1, 1, 1] Attr_Vec(C3)=[1, 2, 1, 1, 1] Attr_Vec (Implemetor) = [0, 2, 1, 0, 1] 17 18

Experimets with JHotDraw Statistics of three versios of JHotDraw systems Experimets with JHotDraw Cocept lattice represetatio of features ad classes i JHotDraw 51 The experimetal results of executio patter extractio Leged : A / B / C A: data for JHotDraw 51 B: data for JHotDraw 60b1 C: data for JHotDraw 707 19 20 Experimets with JHotDraw Results of feature-specific classes assigmet for 10 features of JHotDraw 51 Experimets with JHotDraw Results of idetified Adapter desig patter istaces ad related features i JHotDraw 51 system 21 The Executio Trace for sceario Drawig ad Flippig Rectagle is Aotated with Descriptios of Executio Patters 22 Summary We preseted: A methodology to idetify idividual desig patter istaces from the implemetatio of system behavioural features A ew desig patter represetatio, PDL (Patter Descriptio Laguage), which eables users to describe the structural iformatio of desig patters efficietly ad coveietly A two-phase desig patter process (approximate matchig & structure matchig) to reduce the complexity of the matchig process A prototype toolkit for the proposed approach o the Eclipse ope platform Future Work Our future work will maily cocetrate o the followig directios: Extedig the patter repository to support more desig patters idetificatio Extractig more iter-class relatios, such as delegatio ad method ivocatio, to improve the accuracy of the techique Validatig our approach o large-scale software systems Trackig the evolutio of software systems at desig level by aalyzig the evolutio of desig patters 23 24

Dyamic Aalysis ad Desig Patter Detectio i Java Programs Lei Hu Kamra Sartipi {hul4, sartipi}@mcmasterca Departmet of Computig ad Software McMaster Uiversity Caada SEKE 08 July 3, 2008 25