17
Aspect Oriented Aspect Oriented Architecture (AOA) Architecture (AOA) Why Why – to alleviate crosscutting in a system – to alleviate crosscutting in a system When When – 1984 - 1999 – 1984 - 1999 Where Where – Xerox Palo Alto Research Center – Xerox Palo Alto Research Center (PARC) (PARC) Who Who – Gregor Kiczales – Gregor Kiczales

Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

Embed Size (px)

Citation preview

Page 1: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

Aspect Oriented Aspect Oriented Architecture (AOA)Architecture (AOA)

WhyWhy – to alleviate crosscutting in a system – to alleviate crosscutting in a system

WhenWhen – 1984 - 1999 – 1984 - 1999

WhereWhere – Xerox Palo Alto Research Center (PARC) – Xerox Palo Alto Research Center (PARC)

WhoWho – Gregor Kiczales – Gregor Kiczales

Page 2: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AOA AOA the modelthe model

Join PointsJoin Points – areas of concern – areas of concern

The AspectThe Aspect – declared like a class – declared like a class

The PointcutThe Pointcut - - paramatizes join pointsparamatizes join points

The AdviceThe Advice – before, after, or around – before, after, or around

Page 3: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AlfrescoAlfresco a case studya case study

– – A content management system Using AOPA content management system Using AOP

• The RepositoryThe Repository

• Streamlines Communication between ComponentsStreamlines Communication between Components

• Reduce Coding While Improving FeaturesReduce Coding While Improving Features

• Increased Clarity of Communication ChannelsIncreased Clarity of Communication Channels

• Introduction of Web ServicesIntroduction of Web Services

Page 4: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AOP AOP andand JBoss JBoss a case studya case study

Interceptors vs. AdviceInterceptors vs. Advice

IntroductionsIntroductions

Meta DataMeta Data

PointcutsPointcuts

The role of XMLThe role of XML

Page 5: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AOA AOA Benefits and DisadvantagesBenefits and Disadvantages

Benefits:Benefits:

• Low Coupling between ComponentsLow Coupling between Components

• Separation of ConcernsSeparation of Concerns

• Easier Coding through Less EffortEasier Coding through Less Effort

• Cost SavingsCost Savings

Page 6: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AOA AOA Benefits and DisadvantagesBenefits and Disadvantages

DisadvantagesDisadvantages

• Harder to Inspect and Review CodeHarder to Inspect and Review Code

• More Difficult Unit TestingMore Difficult Unit Testing

• Difficulty in Testing, GenerallyDifficulty in Testing, Generally

• High Learning CurveHigh Learning Curve

Page 7: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – A simple case studyA simple case study

The Crosscutting ConcernThe Crosscutting Concern• Establishing Reliability MetricsEstablishing Reliability Metrics• Shared ResponsibilityShared Responsibility

The AspectThe Aspect• Separates ResponsibilitiesSeparates Responsibilities

The PointcutsThe Pointcuts• Methods of Interest (Join Points)Methods of Interest (Join Points)

Page 8: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – a cost analysisa cost analysis

Time Saved Using AOP with OOPTime Saved Using AOP with OOP

Less EffortLess Effort

Improved Maintenance Improved Maintenance

Reduced CostsReduced Costs

Page 9: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – quality attributesquality attributes

FunctionalityFunctionality

ReliabilityReliability

SecuritySecurity

PerformancePerformance

Page 10: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – quality attributesquality attributes

The ATAM The ATAM (Architecture Tradeoff Analysis Method)(Architecture Tradeoff Analysis Method)

• InputsInputs

Business Drivers – Quality Attributes – Business Drivers – Quality Attributes – ScenariosScenarios

Software Architecture – Architectural Software Architecture – Architectural Approaches – Architectural DecisionsApproaches – Architectural Decisions

Page 11: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – quality attributesquality attributes

• AnalysisAnalysis Stakeholder QuestionsStakeholder Questions

• OutputsOutputs TradeoffsTradeoffs Sensitivity PointsSensitivity Points Non-RisksNon-Risks RisksRisks

• Risk ThemesRisk Themes• Impacts InputsImpacts Inputs

Page 12: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – Risky ComponentsRisky Components

The Bidding ComponentThe Bidding Component

• AccuracyAccuracy

• ReliabilityReliability

• SecuritySecurity

Page 13: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay – EBay – Risky ComponentsRisky Components

The Data Store ComponentThe Data Store Component

• AvailabilityAvailability

• Data IntegrityData Integrity

Page 14: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay EBay Managing RisksManaging Risks

An Architectural Analysis TechniqueAn Architectural Analysis Technique

• To Determine Risky BehaviorTo Determine Risky Behavior

People-Centered Analysis (ATAM)People-Centered Analysis (ATAM) Model Driven AnalysisModel Driven Analysis Simulation Based TechniqueSimulation Based Technique

Page 15: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

AOA Model AOA Model Life Cycle EffectsLife Cycle Effects

Different Stakeholder ViewsDifferent Stakeholder Views

• The SDLC and EBayThe SDLC and EBay

Requirements ViewRequirements View Design ViewDesign View Implementation ViewImplementation View Deployment ViewDeployment View Maintenance ViewMaintenance View

Page 16: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

EBay EBay Requirements and ScopeRequirements and Scope

RequirementsRequirements

Stakeholder ConcernsStakeholder Concerns

Create Scope DefinitionCreate Scope Definition

Modeling the RequirementsModeling the Requirements

ScopeScope

Mapped to RequirementsMapped to Requirements

Used Throughout the SDLCUsed Throughout the SDLC

Modeling the Scope, a PrototypeModeling the Scope, a Prototype

Page 17: Aspect Oriented Architecture (AOA) Why – to alleviate crosscutting in a system Why – to alleviate crosscutting in a system When – 1984 - 1999 When – 1984

References:References: Alfresco Software (n.d.) “Open Source Enterprise Content Alfresco Software (n.d.) “Open Source Enterprise Content

Management” Management” http://dev.alfresco.com/resource/productdatasheet.pdfhttp://dev.alfresco.com/resource/productdatasheet.pdf

Retrieved February 2010Retrieved February 2010

Burke B. Brock A. (2003). “Aspect Oriented Programming and Burke B. Brock A. (2003). “Aspect Oriented Programming and JBoss” JBoss” http://onjava.com/pub/a/onjava/2003/05/28/aop_jboss.htmlhttp://onjava.com/pub/a/onjava/2003/05/28/aop_jboss.html

Retrieved February 2010.Retrieved February 2010.

Taylor R. N. Medvidovic N. Dashofy E. M. (2010). “Taylor R. N. Medvidovic N. Dashofy E. M. (2010). “Software Software ArchitectureArchitecture – – Foundations, Theory, and PracticeFoundations, Theory, and Practice” Chapter 7.” Chapter 7.