Presentation is loading. Please wait.

Presentation is loading. Please wait.

On the Modularity Assessment of Aspect- Oriented Multi-Agent Systems Product Lines: a Quantitative Study Camila Nunes

Similar presentations


Presentation on theme: "On the Modularity Assessment of Aspect- Oriented Multi-Agent Systems Product Lines: a Quantitative Study Camila Nunes"— Presentation transcript:

1 On the Modularity Assessment of Aspect- Oriented Multi-Agent Systems Product Lines: a Quantitative Study Camila Nunes camila@les.inf.puc-rio.br

2 © LES/PUC-Rio Summary Introduction/Motivation –Aspect-Oriented Programming (AOP) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

3 © LES/PUC-Rio Introduction Aspect-oriented programming (AOP) techniques to improve the modularization of features in SPLs, object-oriented frameworks, and multi-agent systems The increasing complexity of modern applications motivates the use of AOP

4 © LES/PUC-Rio Introduction Improve separation of concerns Improve maintainability and reuse of classes and crosscutting concerns “Crosscutting Concerns” OO SolutionAspect-Oriented Solution Aspect Classes Join Points

5 © LES/PUC-Rio Introduction Problem –There are recent research and empirical studies exploring the use of AOP to modularize features –However, none of them analyzes the impact of adding agency features in evolution scenarios of a MAS-PL. –How to deal with the MAS-PL evolution? Evolution in SPLs requires appropriate mechanisms to lead with invasive changes. Implementation of variability mechanisms: –Conditional Compilation –Aspect-Oriented Programming (AOP)

6 © LES/PUC-Rio Introduction Our work –This work presents an empirical study of development and evolution of an MAS-PL –The aim is to compare the modularity of object- oriented (OO) and aspect-oriented (AO) different implementations of the MAS-PL. –Our study is based on a suite of modularity attributes and change impact metrics.

7 © LES/PUC-Rio Introduction Our goal is to answer some questions, such as: –(1) Which technique is more appropriate to allow superior stability in the implementation of agency features? –(2) Which technique required less intrusive modifications following the Open-Closed principle? –(3) Which technique supports the construction of reusable and maintainable MAS?

8 © LES/PUC-Rio Summary Introduction/Motivation –Software Product Lines (SPL) –Aspect-Oriented Programming (AOP) –Multi-agent Systems Product Line (MAS-PL) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

9 © LES/PUC-Rio The ExpertCommittee Web based System Conference Management System Typical web-based application Functionalities to support the complete process of the management of conferences and workshops –Paper submission –Reviewing processes Examples –EasyChair (http://www.easychair.org/)http://www.easychair.org/ –JEMS (https://submissoes.sbc.org.br/)https://submissoes.sbc.org.br/

10 © LES/PUC-Rio Generation of the MAS-PL Releases First it was implemented the SPL base architecture of the EC. A series of change scenarios, adding optional and alternative features in the SPL architecture. Seven new releases of the EC MAS-PL were generated Each release of our MAS-PL was always implemented in two different versions: –(i) one codified in Java with conditional compilation –(ii) the other one codified in AspectJ

11 © LES/PUC-Rio Generation of the MAS-PL Releases ReleasesDescriptionChange Type R1ExpertCommittee core R2Addition of the Reviewer role.Inclusion of optional feature. R3New feature added to include user agents including the author and chair roles. New feature to allow the suggestion of conferences to the authors. Inclusion of optional feature. R4Addition of a Notifier agent to send messages to the system users through email and SMS. Inclusion of optional and alternative feature. R5Addition of the Deadline agent. This agent is responsible for monitoring the conference deadlines. Inclusion of optional feature. R6Addition of a feature that allows the chair to automatically assign papers to reviewers. Extension of the deadline agent to allow reminder deadlines. Inclusion of alternative feature and extension of deadline monitoring feature. R7Addition of a Task agent.Inclusion of optional feature.

12 © LES/PUC-Rio Generation of the MAS-PL Releases MAS-PL Features Types: –(i) new conference management features: typical kind of feature addressed in SPL –(ii) new autonomous behavior: Introduction of agents –(iii) new behaviors and roles for an agent: Features that have impact inside of agents, internal variabilities

13 © LES/PUC-Rio MAS-PL Object Design

14 © LES/PUC-Rio MAS-PL Object Design

15 © LES/PUC-Rio MAS-PL Object Design

16 © LES/PUC-Rio MAS-PL Aspect Oriented Design

17 © LES/PUC-Rio MAS-PL Aspect Oriented Design

18 © LES/PUC-Rio MAS-PL Aspect Oriented Design

19 © LES/PUC-Rio The Metrics AttributesMetricsDefinition Separation of Concerns Concern Diffusion over Components (CDC) It counts the number of classes and aspects whose main purpose is to contribute to the implementation of a concern and the number of other classes and aspects that access them. Concern Diffusion over Operations (CDO) It counts the number of methods and advices whose main purpose is to contribute to the implementation of a concern and the number of other methods and advices that access them. Concern Diffusion over LOC (CDLOC)It counts the number of transition points for each concern through the lines of code. Transition points are points in the code where there is a “concern switch”. Interaction Between Concerns Component-level Interlacing Between Concerns (CIBC) It counts the number of other concerns with which a given concern shares at least a component. SizeLines of Code (LOC)It counts the lines of code. Number of Components (NOC)It counts the number of components. Number of Operations (NOO)It counts the number of operations of a given component.

20 © LES/PUC-Rio The Metrics AttributesMetricDefinition Coupling Coupling Between Components (CBC) Counts the number of other classes and aspects to which a class or an aspect is coupled. CohesionLack of Cohesion Operations (LCCO) Measures the lack of cohesion of a class or an aspect in terms of the amount of method and advice pairs that do not access the same instance variable.

21 © LES/PUC-Rio Summary Introduction/Motivation –Software Product Lines (SPL) –Aspect-Oriented Programming (AOP) –Multi-agent Systems Product Line (MAS-PL) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

22 © LES/PUC-Rio Separation of Roles and Agents Concerns Concern Diffusion over Operations (CDO) Concern Diffusion over Lines of Code (CDLOC)

23 © LES/PUC-Rio SoC – Reviewer Feature Concern Diffusion over Components (CDC)

24 © LES/PUC-Rio SoC – User Agents Feature Concern Diffusion over Operations (CDO)

25 © LES/PUC-Rio SoC – User Agents Feature Concern Diffusion over Components (CDC)

26 © LES/PUC-Rio SoC – User Agents Feature Concern Diffusion over Lines of Code (CDLOC)

27 © LES/PUC-Rio SoC – Notifier Agent Concern Diffusion over Components (CDC)

28 © LES/PUC-Rio Size Metrics

29 © LES/PUC-Rio Size Metrics

30 © LES/PUC-Rio Interaction between Concerns

31 © LES/PUC-Rio Coupling Between Components (CBC)

32 © LES/PUC-Rio Lack of Cohesion over Operations (LCOO)

33 © LES/PUC-Rio Change Propagation Metrics R2R3R4R5R6R7 Added ComponentsOO327113326 OA935206834 Changed Components OO9688713 OA000000 Added OperationsOO32103312920128 OA43112354927145 Changed OperationsOO42152231 OA000000 Added PointcutsOA5791119 Changed PointcutsOA000000 Added LOC OO41811346393912492203 OA51112027844704962166

34 © LES/PUC-Rio Summary Introduction/Motivation –Software Product Lines (SPL) –Aspect-Oriented Programming (AOP) –Multi-agent Systems Product Line (MAS-PL) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

35 © LES/PUC-Rio Discussions and Lessons Learned Aspects as “glue” between Roles and Agents: –several aspects in our MAS-PL worked as a “glue” code. Feature Management: –Some agency features, such as: User Agents and Notifier Agent, caused a high number of new components (classes and aspects) in the AO solution. –Although the use of aspects increases the number of components in these cases, it was also useful to reduce the tangling and coupling between the concerns/features.

36 © LES/PUC-Rio Discussions and Lessons Learned Code Understanding: –In our study, it was observed that the AO solution exhibits higher values for all the size metrics (LOC, NOC, and NOO). –This was a negative finding of the AO implementation

37 © LES/PUC-Rio Discussions and Lessons Learned Recent research has pointed AOP as a good technique for implementation and management of variabilities in SPL. The aspect-oriented approach required less modification and extension of the selected MAS The implementation of variabilities with AOP also brings another benefit: the capacity of pluging/unpluging aspects from the SPL core implementation.

38 © LES/PUC-Rio Summary Introduction/Motivation –Software Product Lines (SPL) –Aspect-Oriented Programming (AOP) –Multi-agent Systems Product Line (MAS-PL) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

39 © LES/PUC-Rio Related Work Figueiredo, E. et al (2008). Evolving software product lines with aspects: An empirical study on design stability –Empirical study focusing on evolution requirements of two product-lines. –Analyzes the evolution of product lines in terms of metrics for modularity, change propagation and feature interaction. Apel, S. and Batory, D. (2006). When to use features and aspects?: a case study. –A study comparing the feature-oriented programming (FOP) and aspect-oriented programming (AOP) Kastner, C. et al. (2007). A case study implementing features using aspectj. –Refactoring legacy application into an SPL using aspects to implement features.

40 © LES/PUC-Rio Summary Introduction/Motivation –Software Product Lines (SPL) –Aspect-Oriented Programming (AOP) –Multi-agent Systems Product Line (MAS-PL) Study Settings Modularity Analysis Discussions and Lessons Learned Related Work Final Remarks

41 © LES/PUC-Rio Final Remarks Exploratory study of development and evolution of a MAS-PL –Traditional web-based system Support conference management process –Incorporation of a series of new agency features We compared two different versions of the MAS-PL implemented using the following technologies: –(i) OO with conditional compilation using the Java language –(ii) AO programming using the AspectJ language.

42 © LES/PUC-Rio Final Remarks AO implementation exhibits a better separation of concerns/features (CDLOC metric) and interaction between concerns, but in terms of the CDC and CDO metrics the AO implementation presented superior values. The NOC, NOO and LOC increased in the AO implementation, bringing complexity to manage the new aspects that modularize some agency features.

43 © LES/PUC-Rio Final Remarks Separation of Concerns –Aspects (and classes) encapsulate the agency features of interest Reusability –Reuse of Aspects and Classes Maintainability –Obliviousness –Quantification

44 © LES/PUC-Rio Questions?


Download ppt "On the Modularity Assessment of Aspect- Oriented Multi-Agent Systems Product Lines: a Quantitative Study Camila Nunes"

Similar presentations


Ads by Google