• Save
Intro to-patterns-linda-rising[1]
Upcoming SlideShare
Loading in...5
×
 

Intro to-patterns-linda-rising[1]

on

  • 1,307 views

Linda Rising / PLoP Bootcamp 09

Linda Rising / PLoP Bootcamp 09
- original source : http://www.managing-expectations.com/wp-content/uploads/2011/01/Intro-to-patterns-Linda-Rising.pdf

Statistics

Views

Total Views
1,307
Views on SlideShare
1,242
Embed Views
65

Actions

Likes
0
Downloads
0
Comments
1

2 Embeds 65

http://arload.wordpress.com 64
http://www.slideshare.net 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
  • you download this presentation at
    http://www.managing-expectations.com/wp-content/uploads/2011/01/Intro-to-patterns-Linda-Rising.pdf
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Intro to-patterns-linda-rising[1] Intro to-patterns-linda-rising[1] Document Transcript

  • PLoP® Pattern Writing Bootcamp 2009 Chicago, IL Robert Hanmer hanmer@alcatel-lucent.com Linda Rising risingl@acm.orgAugust 27, 2009 - 1 PLoP is a registered Trademark of The Hillside Group. Agenda Introductions Pattern Basics Writers Workshops Pattern Languages Brainstorm architecture Write patterns! Workshop patterns Summary, de-brief, plan next meetingAugust 27, 2009 - 2 Copyright © 2007-2009. Alcatel-Lucent. 1
  • Part 1: Pattern Basics August 27, 2009 - 3 Patterns• “The pattern is, in short, at the same time a thing, which happens in the world, and the rule which tells us how to create that thing, and when we must create it. It is both a process and a thing; both a description of a thing which is alive, and a description of the process which will generate that thing.” -- Christopher Alexander, The Timeless Way of Building August 27, 2009 - 4 Copyright © 2007-2009. Alcatel-Lucent. 2
  • Christopher Alexander• Building architect and theorist• Many books on architecture and art: A Pattern Language The Timeless Way of Building The Oregon Experiment The Production of Houses A Foreshadowing of 21st Century Art -- The Color and Geometry of Very Early Turkish Carpets The Nature of Order (4 volumes)• http://www.livingneighborhoods.org August 27, 2009 - 5 The Quality Without A ame• “There is a central quality which is the root criterion of life and spirit in a man, a town, a building, or a wilderness. This quality is objective and precise, but it cannot be named.” – Alexander, The Timeless Way of Building• (“but with an acronym” -- Joe Davison) August 27, 2009 - 6 Copyright © 2007-2009. Alcatel-Lucent. 3
  • What is a Pattern?• Rule of 3• More than an algorithm• “At the same time, a thing that happens in the world … and the rules to make that thing …” August 27, 2009 - 7 Patterns Will ot:• … make you an instant expert• … provide a “turn the crank” approach to software• … eliminate the need for intelligence and taste• … make you rich and famous – unless you become a snake oil salesman• … generate code • Paul S. R. Chisholm, AT&T 10/94 August 27, 2009 - 8 Copyright © 2007-2009. Alcatel-Lucent. 4
  • Part 2: A Pattern’s Parts August 27, 2009 - 9 Parts of a Pattern• Name• Context• Statement of the Problem• Forces• Resolution/Solution• Sketch• Resulting Context• Authorship information• (and some optional parts) August 27, 2009 - 10 Copyright © 2007-2009. Alcatel-Lucent. 5
  • Context• Where does the problem exist?• What are the relevant preconditions?• What are the patterns that this pattern helps resolve?• Who is the target audience?• What are the constraints on the system that you cannot change or control? – Language choice – Memory space – etc. August 27, 2009 - 11 Statement of the Problem• What is the problem being solved?• What’s wrong in the current environment? August 27, 2009 - 12 Copyright © 2007-2009. Alcatel-Lucent. 6
  • Forces• What makes this a hard problem?• What are the tradeoffs?• Why aren’t the obvious solutions sufficient?• What are the constraints upon the system over which you have some control? August 27, 2009 - 13 Resolution/Solution• Succinctly state the action that the reader should take to resolve the problem• Build upon the forces and customize• Be specific• Ensure that the resolution resolves the stated problem – try reading them out loud, one after the other August 27, 2009 - 14 Copyright © 2007-2009. Alcatel-Lucent. 7
  • Sketch• “If you can’t draw a diagram of it, it isn’t a pattern.” – Alexander, TTWOB, p 267.• Sketch What? – Whatever will help convey the ideas to the reader. • UML diagrams • Block diagram • Image of a concrete example • etc. August 27, 2009 - 15 Resulting Context• What does the environment look like after the resolution/solution has been applied?• What new problems have been introduced?• What patterns will resolve the new problems?• This is a good place for war stories and anecdotes August 27, 2009 - 16 Copyright © 2007-2009. Alcatel-Lucent. 8
  • Author• Intellectual Currency – Ideas are worth more if given away. – We want to be able to give credit where credit is due• Identify the author• Identify the revision history – Patterns evolve • As our understanding grows • As they are workshoped and improved by reader feedback• Acknowledgements for shepherds, members of writers’ workshops and others that helped you shape the pattern August 27, 2009 - 17 ame• Choose with care – initially make a list of AKAs• Many views on what form the title should take – Noun Phrase- Corporate Sponsor, Model View Controller – Verb Phrase- Do Food, Shift to Multiply – Catchy Phrase- George Washington is still Dead• It will be part of a vocabulary or language• Choose with care August 27, 2009 - 18 Copyright © 2007-2009. Alcatel-Lucent. 9
  • Other Sections• Rationale• Sample Code• Related Patterns• Known Implementations• References August 27, 2009 - 19 Part 3: Writers Workshops August 27, 2009 - 20 Copyright © 2007-2009. Alcatel-Lucent. 10
  • Writers’ Workshops• Structured discussion of the merits and suggestions for improvement• “Criticism” is not welcome -- only suggestions for improvement. – “I suggest the author add a reference to the paper by Beck and Auer in the Context as it will help establish how their works complement each other.”• Praise is always welcome – What people like about a pattern is very important.• Author is present for note taking but does not participate except at very specific times.• Strong moderation. August 27, 2009 - 21 Writers’ Workshops• Jim Coplien has published a pattern language for Writers’ Workshops. – PLOPD4, chapter 25 – http://users.rcn.com/jcoplien/Patterns/WritersWorkshop/ – He (and co-author/shepherd Bobby Woolf) delve into the reasons behind way that Writers’ Workshops are structured. August 27, 2009 - 22 Copyright © 2007-2009. Alcatel-Lucent. 11
  • Writers’ Workshops• Moderator introduces pattern and the author(s)/editor(s)• The author stands and reads a short (1-4 sentence) excerpt of the paper• The author becomes a “fly on the wall” – Avoid eye contact with the author – The author is referred to as “the author”, NOT by name• A participant summarizes the pattern• Discuss the positive aspects of the paper – What should be kept in the next revision – What the readers found especially appealing• Offer suggestions for improvement.• Welcome the author back – Author thanks the group – This is not an opportunity to debate or explain the pattern – Author may only ask clarifying questions• Everyone (except author) stands and thank the author for the opportunity to workshop the work.• Take a different seat and tell an unrelated story. August 27, 2009 - 23 Part 4: Pattern Languages August 27, 2009 - 24 Copyright © 2007-2009. Alcatel-Lucent. 12
  • Pattern Languages• Individual patterns are useful, but . . .• they are most powerful when combined into a language• “Each pattern then, depends both on the smaller patterns it contains, and on the larger patterns within which it is contained.” Alexander, TTWOB, p 312. August 27, 2009 - 25 Pattern Languages• Individual Patterns are good – No individual pattern balances all the tradeoffs.• To address real sized problems, languages are really essential• A language is a collection of patterns that work together.• Within a pattern language the patterns build upon each other, resolving unbalanced forces from previous patterns. August 27, 2009 - 26 Copyright © 2007-2009. Alcatel-Lucent. 13
  • Pattern Languages (cont.)• Pattern languages must be complete in two ways – Morphologically • Patterns fit together to form a complete structure without gaps. – Functionally • Any new forces introduced by the patterns are resolved by the patterns themselves.• If they are not complete in these ways we refer to them as a “collection” – The GOF and POSA books are collections August 27, 2009 - 27 Example Pattern Languages:• Alexander’s Garden – The only known pattern language diagram from Alexander From The Timeless Way of Building August 27, 2009 - 28 Copyright © 2007-2009. Alcatel-Lucent. 14
  • Another Example• Telecommunications I/O From PLOPD4 August 27, 2009 - 29 Selected BibliographyA Pattern Language. Alexander et. Al. New York: Oxford University Press, 1977.Design Patterns - Elements of Reusable Object-Oriented Software. Gamma, Helm, Johnson and Vlissides (The “Gang of Four”). Reading, MA: Addison-Wesley, 1995.Pattern Oriented Software Architecture. Buschmann, Meunier, Rohnert, Sommerlad and Stal. Chichester, UK: Wiley & Sons, 1996.Pattern Oriented Software Architecture, Vol. 2. Schmidt, Stal, Rohnert, Buschmann. Chichester, UK: Wiley & Sons, 2000.PLOPD – PLOPD5: Pattern Languages of Program Design, volumes 1-5. Various editors. Reading, MA: Addison-Wesley, 1995-2006.The Pattern Handbook. Rising, ed. Cambridge: Cambridge University Press, 1998.PLoP Conference Proceedings: http://hillside.net/plop/The Pattern Almanac 2000. Rising. Reading, MA: Addison-Wesley, 2000.Fearless Change. Manns and Rising. Reading, MA: Addison-Wesley, 2004.The Timeless Way of Building. Alexander. New York: Oxford University Press, 1979.For more books: http://hillside.net/patterns/books/index.htm August 27, 2009 - 30 Copyright © 2007-2009. Alcatel-Lucent. 15