working session on patterns - polytechnique...

11
Patterns: From Cities Building to Software Engineering (SE) Examples of Patterns Families in SE Open Questions... Working Session on Patterns Aminata Saban´ e ´ Ecole Polytechnique de Montr´ eal, Qu´ ebec, Canada March 5th, 2013 Aminata Saban´ e March 5th, 2013 1 / 11

Upload: others

Post on 18-Aug-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Working Session on Patterns

Aminata Sabane

Ecole Polytechnique de Montreal, Quebec, Canada

March 5th, 2013

Aminata Sabane March 5th, 2013 1 / 11

Page 2: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Patterns: From Cities Building to Software Engineering(SE)

Aminata Sabane March 5th, 2013 2 / 11

Page 3: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Example 1: Test-Specific Subclass PatternExample 1: Test-Specific Subclass PatternExample 2:SOA Patterns

Examples of Patterns Families in SE

Requirement [Duran, ’99], [Withall,’07]

Architectural [Gamma et al, ’94], [Fowler, ’02]

Design [Gamma et al, ’94]

Testing [Binder, ’94] , [Meszaros, ’07]

User Interface [Tidwell, ’02, ’10], [Duyne,’2003]

SOA [Rotem-Gal-Oz, ’12], [Erl et al, ’12]

SQL [Tropashko, ’07]

Security [Wheeler, ’99], [Bishop, ’03]

Aminata Sabane March 5th, 2013 3 / 11

Page 4: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Example 1: Test-Specific Subclass PatternExample 1: Test-Specific Subclass PatternExample 2:SOA Patterns

Example 1: Test-Specific Subclass Pattern

Testing Pattern

Problem: System under test (SUT) not designed specificallyto be testable

How It Works: Define a subclass of the SUT and addmethods that modify the behavior of the SUT just enough tomake it testable by implementing control points andobservation points.

When To Use It : Use a Test-Specific Subclass whenever weneed to modify the SUT to improve its testability but doing sodirectly would result in Test Logic in Production(page X).

Aminata Sabane March 5th, 2013 4 / 11

Page 5: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Example 1: Test-Specific Subclass PatternExample 1: Test-Specific Subclass PatternExample 2:SOA Patterns

Example 1: Test-Specific Subclass Pattern

Aminata Sabane March 5th, 2013 5 / 11

Page 6: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

Example 1: Test-Specific Subclass PatternExample 1: Test-Specific Subclass PatternExample 2:SOA Patterns

Example 2:SOA Patterns

SOA Patterns

Problem: Different service consumers may have differentrequirements for how data provided by a given servicecapability needs to be formatted or represented.

Solution: Allow the service capability to support alternativeformats and representations by providing a means by whichconsumer and service can negotiate data characteristics atruntime.

Application: The media type of the data is decoupled fromthe data itself, allowing the service to support a range ofmedia types.

Impacts: Support old and new service consumer versionsconcurrently; can introduce consumer to serviceimplementation coupling (antipattern).

Aminata Sabane March 5th, 2013 6 / 11

Page 7: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

What is a pattern?How to formalize patterns?Are Patterns Really Good?How Should We Promote Patterns?

Open Questions...

Aminata Sabane March 5th, 2013 7 / 11

Page 8: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

What is a pattern?How to formalize patterns?Are Patterns Really Good?How Should We Promote Patterns?

What is a pattern?

When a solution becomes a pattern? [Gamma et al, ’94]

How to collect patterns? [Hentrich et al, ’06]

How to validate or evaluate proposed patterns? [Laverdiere etal., ’09]

How to rely on proposed patterns?

Aminata Sabane March 5th, 2013 8 / 11

Page 9: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

What is a pattern?How to formalize patterns?Are Patterns Really Good?How Should We Promote Patterns?

How to formalize patterns?

Formal vs Informal? [France et al, ’04], [Gamma et al, ’94]

Template within or across families? [Franch et al, ’10]

Collection of patterns or Patterns Language? [Gamma et al,’94], [van Welie, ’03]

Aminata Sabane March 5th, 2013 9 / 11

Page 10: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

What is a pattern?How to formalize patterns?Are Patterns Really Good?How Should We Promote Patterns?

Are Patterns Really Good? Should We Promote Them?

Pros

Knowledge package for best practices

Help non experts to access to and implement good solutions

Make tasks easier and faster to achieve

Lead to better quality (confirmation by few studies [Lange etal, ’95 ], [Peter Hegedus et al, ’12])

Cons

Not enough quantitative evidence on their cost-effectiveness

Step backward compared to reuse of components

Inappropriate use increase complexity or leads to antipatterns[Kerievsky, ’04], [Brown et al, 98]

Some studies show their negative impact [Vokac, ’04],[Khomh et al., ’08]Aminata Sabane March 5th, 2013 10 / 11

Page 11: Working Session on Patterns - Polytechnique Montréalppap.soccerlab.polymtl.ca/ppap2013/presentations/PPAP...Working Session on Patterns Aminata Saban e Ecole Polytechnique de Montr

Patterns: From Cities Building to Software Engineering (SE)Examples of Patterns Families in SE

Open Questions...

What is a pattern?How to formalize patterns?Are Patterns Really Good?How Should We Promote Patterns?

How Should We Promote Patterns?

Which way is the way to go?

How to make patterns more useful, helpful for practitioners?

How to convince practitioners to learn and use patterns?

How to learn patterns?

Aminata Sabane March 5th, 2013 11 / 11