SlideShare une entreprise Scribd logo
1  sur  122
Télécharger pour lire hors ligne
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
1
Session: Software Architecture
Software Architectures
The Software Architekt
The Architectural process
Some words on patterns
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
2
Welcome
in
An investment in knowledge
always pays the best interest
--- Benjamin Franklin
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
3
Objectives
✔ Get a general idea about :
➢ What Software Architecture is about
➢ The role and the duties of a software architect
➢ The architectural process
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
4
Only a joke ?
As proposed by
the project
sponsor.
As specified in
the project
request
As designed by
the senior
analyst
As implemented
by developers
As installed at
user's site
What the user
wanted
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
5
The Chaos Report
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
6
Module
Software Architecture:
Definitions
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
7
Software Architecture
What is it about?
✔ As a maturing discipline with no clear rules on the
right way to build a system, designing software
architecture is still a mix of art and science.
– Djikstra
✔ Software-Architektur deals with abstraction,
decomposition and assembly, with style and
aesthetics
– Kruchten
Edsger Wybe Dijkstra
Phillipe Kruchten
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
8
Software Architecture
✔ What do we mean by a software architecture?
To me the term architecture
➢ conveys a notion of the core elements of the system
➢ the pieces that are difficult to change
➢ a foundation on which the rest must be built.
More than 50 different definitions to be found at:
http://www.sei.cmu.edu/architecture/start/glossary/community.cfm
Martin Fowler
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
9
Software architecture
✔ The software architecture of a program or computing system is the
structure of the system, which comprise:
➢ software components,
➢ the externally visible properties of those components,
➢ and the relationships between them
✔ "Externally visible" properties are those assumptions other
elements can make of an element, such as
➢ its provided services,
➢ performance characteristics,
➢ fault handling,
➢ shared resource usage, and so on.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
10
Software Architecture
Software architecture is
✔ commonly organized in views:
➢ Functional/logic view
➢ Code/module view
➢ Development/structural view
➢ Concurrency/process/thread view
➢ Physical/deployment view
➢ User action/feedback view
➢ Data view
✔ UML was established as a standard
"to model systems (and not just software)"
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
11
Software architecture
Software elements:
✔ An architecture is an abstraction of a system that
suppresses details of elements that do not affect
➢ how they use,
➢ are used by,
➢ relate to,
➢ or interact with other elements.
✔ Elements interact with each other by means of
interfaces that partition details about an element
into public and private parts.
✔ Architecture is concerned with the public side of this division;
private detail those having to do solely with internal
implementation are not architectural.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
12
Software architecture
Software architecture
✔ in between design and realisation
architecture bridges problem domain, subject
matter experts and technical realisation
✔ based upon various decisions
some of them deal with the components,
some of them deal with the technologies used
✔ the framework for flexible systems
considering external changes (organisational /
technical)
✔ is abstraction
systematically omit information not needed keeps architecture
clear.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
13
Software architecture
Why does it matter?
✔ Regarding the management software
architecture provides the first idea whether
requirements are met.
✔ Regarding new team members software
architecture provides the base to get familiar
with the structure of the system, it's design
and it's elements.
✔ Regarding maintenance and change of existing
systems, software architectures simplify impact
analysis of changes.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
14
Stakeholders
.. in a System’s Architecture
✔ Architects
✔ Developers
✔ Testers
✔ Managers
✔ Customers
✔ Users
✔ Vendors
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
15
Module
Software Architect
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
16
The lawyer of the customer and the consultant of the implementation team
– Gernot Starke
Software Architect
Software Architect:
✔ A general term with many accepted definitions,
which refers to a broad range of roles in
➢ Design
➢ Communication
✔ With a lot of responsibilities in various fields
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
17
Software Architect
Design:
✔ high-level design choices much more often
than low-level choices.
✔ sometimes dictate technical standards,
including (but mot limited to)
coding standards, tools, or platforms
✔ rarely deal with the physical architecture of the
hardware environment, confining themselves to the design
methodology of the code.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
18
Software Architect
Communication:
✔ have to communicate effectively, not only to
understand the business needs, but also to
advance their own architectural vision.
✔ can do so verbally, in writing, and through
various software architectural models that
specialize in communicating architecture.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
19
Software Architect
Architects construct and design:
✔ Components and subcomponents and
their respective responsibilities
✔ Interfaces through those the components interact
(design by contract)
✔ Interaction described by statical and
dynamical structures
Dr. Gernot Starke
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
20
Software architects
Architects decide
✔ Which components, which interfaces, which frameworks, to make
or to buy, which team develops which component, …
✔ All decisions might affect the system on the
long run, very often architects have to deal
with innovative frameworks
(so all decisions need to be documented well).
Architects guarantee meeting the requirements
✔ Feasibility and fulfillment are in the scope
of an architect as well
✔ Prototypes are unevitable part and also costs
are not out of scope.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
21
Software architects
Architects consult
✔ Regarding project plan and project organisation
✔ Project lead regarding management of the team, management of
technological risks
✔ The implementation teams in terms of
explaining, convincing and coaching
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
22
Software architects
Architects document
✔ Look out for templates, try arc42 (http://www.arc42.de/)
Architects communicate
✔ .. as mentioned before
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
23
Successful architects
According to „The mythical man month“
by Frederick P. Brooks (in 1975), an architect:
✔ "suggests" ("not dictates") implementation because
the programmer/coder/builder has the "inventive
and creative responsibility."
✔ should have an idea of how to implement his or
her architecture, but should be "prepared to accept any other way
that meets the objectives as well."
✔ should be "ready to forego credit for suggested improvements."
✔ should "listen to the builder's suggestions for architecture
improvements."
✔ should strive for work to be "spare and clean," avoiding "functional
ornamentation" and "extrapolation of functions that are obviated
by changes in assumptions and purposes."
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
24
Module
Software Architect
and software development
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
25
Software architects don't code?
or: the Microsoft perspective (from Microsoft Architect
Certificate)
✔ Enterprise architects: set the overall vision and framework
for the IT environment from a strategic business perspective.
✔ Solutions architects: design the solution to take advantage of
the existing assets, integrate them into the existing environment,
follow the enterprise architecture, and solve the business problems
of the business owner or unit.
✔ Infrastructure architects: responsible for creating an
architecture that meets the business and service level
agreement requirements of the business owners and supports the
applications and solutions that are required to operate their day-
to-day businesses.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
26
Software architects don't code?
According to previous slide, software architects:
✔ talk with the business, comes up with solutions and make bright
key decisions about architecture.
✔ they don’t program/implement
✔ during the course of the project
they ensure that developers
don’t spoil this great
architecture.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
27
Software architects don't code?
But in contrast, some architects:
✔ Might have outdated programming
knowledge and experience, loss of touch
with modern development approaches and
practices.
✔ Might don’t know much about evolving
system internals, but makes key technical
decisions.
✔ Might have often a completely irrelevant and unreal picture what is
happening with the system.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
28
Software architects don't code?
But in contrast, architects:
✔ Might tends to complex, premature and
generic solutions when the system is still
in infancy and nothing is clear.
✔ Applies latest modern buzzword
technologies as SOA, MDA, SaaS,
Software Factories, etc. which look so
beautiful in technical magazines,
conferences and CV, but cause unnecessary headache for
developers.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
29
Successfull architects
… in addition to Frederick P. Brooks:
✔ Guards a system against failure,
sensing worrying changes in the
project dynamic, system code and
business requests.
✔ Keeps the trinity of system qualities
in a balance and prevent degradation
and entropy:
➢ Firmitas (Strength) – the system is reliable, secure, has good
performance and easy to support
➢ Utilitas (Utility) – the system is usable, meets business business needs
and add business value every day instead of drifting into technology
trenches
➢ Venustas (Beauty) – code and system structure are clean, easy to
understand, minimal
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
30
Successfull architects
… in addition to Frederick P. Brooks (cont.):
✔ Encourages constant improving of the code design, enhancing
system abstractions and structure, removing duplication, defining
boundaries and interfaces of the subsystems.
✔ Keeps solutions as simple as possible, maintains intellectual control
over system and avoids over-engineering.
✔ Most important – grows and coaches
other developers to become architects
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
31
Module
The Architectural Process
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
32
Architectual process
An overview
As an architect you might follow/obey the following:
✔ Gather information
✔ Develop an idea about the system
✔ Identify drivers and boundary conditions
✔ Identify the risks
✔ Define the quality
✔ Develop strategies
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
33
Architectual process
Gather information
✔ How did others before?
Only very few things are build completely new, try to find similar
solutions.
✔ Scan for patterns
✔ Use your experience as the customer
expects profound knowledge technically
as well as within the domain
✔ In most of the cases, wide parts of
existing solutions can be reused.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
34
Architectual process
Develop an idea about the system
Some of the most important aspects of the system should be known:
✔ What is the purpose of the system
✔ Who uses the system and how is the
system used
✔ What kind of user interface will be used
✔ Where are interfaces to other systems
✔ How to use / store data
✔ How to administer the system
✔ What about printing, reporting, etc.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
35
Architectual process
Identify drivers and boundary conditions
Software architecture isn't dealing with technologies alone, a lot of
other things have some influence on the architecture
✔ Organisational aspects
✔ Resources
✔ Existing standards
✔ Rules and regulation
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
36
Architectual process
Identify the risks
There will be no single project where everything goes as expected, an
architect has to know about the risks and has to deal with them.
✔ Organisational risks
Lack of time, budget, knowledge
✔ Performance
… matters, no doubt about that
✔ Maintainability and flexibility
… design for changes with respect to
performance
✔ Availability
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
37
Architectual process
Define the quality
✔ Quality can't be measured directly as only specific features can be
measured (e.g. resource efficiency)
✔ Different stakeholders have different ideas of quality:
➢ Management: cost efficency, flexibility, maintainability
➢ Users: performance, usability
➢ Ops: administrability, security
✔ Architecture is prerequisite for quality but not
a guarantee (maybe poorly implemented),
excellent code does not imply good
architecture.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
38
Architectual process
Define the quality
✔ Quality of software systems is alway in relation to characteristics,
e.g. performance, availability, interoperability, usability, …
(@see DIN/ISO 9126)
✔ Quality attribute scenarios capture non-functional requirements of
a system in terms of standard quality attributes,
such as Availability, Modifiability, and so on.
✔ These are independent of specific functional
requirements and describe desired qualities
of a system.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
39
Quality attribute scenarios
✔ Statements like “a system will have high performance” or “a
system will be user friendly” are acceptable in the really early
stages of requirements elicitation process.
✔ As more information becomes available, the above statements
become useless as they are meaningless for the purpose of
actually designing a solution.
✔ Both statements are useless as they provide no tangible way of
measuring the behavior of the system.
✔ Writing detailed statements is only possible
when relevant requirements have been
identified and an idea of components has
been proposed.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
40
Quality attribute scenarios
✔ The quality attributes must be described in terms of scenarios,
such as “when 100 users initiate ‘complete payment’ transition, the
payment component, under normal circumstances, will process the
requests with an average latency of three seconds.”
✔ These kind of statements, or scenarios, allows an architect to make
quantifiable arguments about a system.
✔ A scenario defines:
➢ the source of stimulus (users),
➢ the actual stimulus (initiate transaction),
➢ the artifact affected (payment component),
➢ the environment in which it exists (normal operation),
➢ the effect of the action (transaction processed),
➢ and the response measure (within three seconds)
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
41
Architectual process
Develop strategies
✔ against lack of resources and be aware of:
➢ No one performs better if put under pressure
➢ Putting more members of a project team might
cause a bigger delay
➢ If management does not back the
project it will never become a
success
✔ towards increased performance
➢ Use profilers even at the early stages
➢ Hardware is cheaper than redesign
➢ Decrease abstraction
➢ ...
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
42
Architectual process
Develop strategies
✔ covering adaptability and flexibility
➢ Figure out, where it is needed (functionality, data model, 3rd
party
software, user interface, operating system, ...)
➢ Almost every time in contrast to performance
➢ What-if scenarios might be helpful
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
43
Module
Introduction to Patterns
Each pattern describes a problem which occurs over and over again in our environment,
and then describes the core of the solution to that problem, in such a way that you can use
this solution a million times over, without ever doing it the same way twice.
--- Christopher Alexander
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
44
Design, Architecture and … Patterns
Design is a challenging task:
➢ Balancing concerns, e.g. performance, adaptability, reliability.
➢ Defining components and their interrelationships.
Thus experienced designers:
➢ Rarely start from first principles
➢ Look for similarities to problems solved in the past.
➢ Apply a working "handbook" of approaches
Patterns make expert knowledge widely available
➢ Supports focusing on the truly distinctive design problems.
➢ Aids design evaluation at higher level of abstraction
➢ Provides a useful working vocabulary for design.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
45
What is it about ?
A Pattern:
✔ ... solves a real problem, reuse of solutions already designed.
✔ ... faculitates sharing of knowledge.
✔ ... forms a vocabulary for communication between software
architects.
✔ ... limits possible solutions to best practices.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
46
Types of pattern
Architectural Patterns:
✔ expresses a fundamental structural organization or schema for
software systems.
✔ provides a set of predefined subsystems, specifies their
responsibilities, and includes rules and guidelines for organizing
the relationships between them.
Design Patterns:
✔ a scheme for refining the subsystems or components of a software
system, or the relationships between them.
✔ describes commonly recurring structure of
communicating components that solves a
general design problem within a particular
context.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
47
Types of pattern
Idioms:
✔ low-level pattern specific to a programming language.
✔ An idiom describes how to implement particular aspects of
components or the relationships between them using the features
of the given language.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
48
History of ...
Overview:
✔ 1977: Christopher Alexander developed at Center
For Environmental Structure at Berkeley a theory of
using patterns within architecture.
✔ 1991: Erich Gamma wrote his Ph.D. dissertation about the usage
of patterns within software developments – only recognized
withing germany.
✔ 1995: Inspired by Alexander Ward Cunningham and Kent Beck
introduced the first five patterns for design of user interfaces.
✔ 1996: The book of the so-called „Gang-Of-Four“ sets
the pace to broad acceptance of patterns within
Software-Engineering.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
49
Patterns everywhere?
✔ Gang of Four Pattern: Erich Gamma, Richard Helm,
Ralph Johnson and John Vlissides
✔ POSA 1 Pattern: Pattern oriented software
architecture (Frank Buschmann et. al.)
✔ Core J2EE Pattern: Alur, Cupri, Malks
✔ Patterns of Enterprise Application Architecture:
Martin Fowler et. al.
✔ Enterprise Integration Patterns:
Hophe, Woolf et. al.
✔ Workflow Pattern: van der Aalst et. al.
✔ SOA Design Pattern: Thomas Erl
✔ SOA Pattern: Presentation of Michael Stal
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
50
Why using Patterns?
Pattern:
✔ ... are explicitly based on fundamental priciples of constructing
robust applications like information hiding or loose coupling.
✔ ... adress the importance of non-functional aspects like
maintainability or reliability.
✔ ... complement problem-centric methods to develop software by
guidelines to design.
✔ ... support analysis and design.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
51
Keys to Using Patterns Effectively
✔ Recognition comes with experience
✔ Searching is aided by a catalog taxonomy
✔ Recognize, search, instantiate:
➢ Recognize a problem as common (déjà vu).
➢ Recognize the key elements of the problem.
➢ Search a pattern catalog from proven solution templates.
➢ Instantiate the template for the specific problem.
➢ Algorithm and data structure selection.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
52
Patterns, the silver bullet ?
Pattern:
✔ ... If used wrong might make systems more complex than
needed.
✔ ... if used wrong might cause problems by themselves.
✔ ... shouldn‘t be used for the sake of themselves
„As a rule of thumb, the value of a method
is inversely proportional to it‘s universality. “
--- Michael A. Jackson 1995
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
53
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Name:
➢ A good, descriptive name is critical.
➢ Good names communicate.
➢ Poor names obfuscate.
➢ Goal: Increase design vocabulary.
➢ Goal: Raise level of design discussion.
✔ Problem:
➢ Brief, abstract description.
➢ Includes design context.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
54
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Solution:
➢ Components (classes/objects) and interconnections.
➢ Generic control and data flow supported by the pattern.
➢ Template, not a cookbook.
✔ Consequences & Tradeoffs:
➢ Positive results.
➢ Negative implications.
➢ Tradeoffs: time, space, flexibility, performance, etc.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
55
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Implementation issues:
➢ Effects of language (i.e., Java vs. C++).
➢ Alternative tactical approaches.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
56
Pattern and Frameworks
What is a framework
✔ A set of reusable designs and objects used to build applications
✔ Defines how objects work together to get something done
✔ Defines the superclasses or public interface for the object that you
develop
✔ Your objects work within the framework
✔ A framework is a "semi-complete" application
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
57
Pattern and Frameworks
What is a framework
✔ A framework usually supports a very specific domain
➢ GUI (large)
➢ Collections (small)
✔ Usual characteristics of a good framework
➢ Relatively easy to understand and use
➢ Provides a solution to a common problem
➢ Can be used over and over again
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
58
Pattern and Frameworks
Benefits of OO application frameworks:
✔ Modularity:
➢ enhance modularity by encapsulating volatile implementation details
behind stable interfaces
➢ reduces the effort required to understand and maintain existing
software.
✔ Reusability
➢ stable interfaces define generic components that can be reapplied to
create new applications.
➢ avoid re-creating and re-validating common solutions
to recurring application requirements and
software design challenges.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
59
Pattern and Frameworks
Benefits of OO application frameworks (contd.):
✔ Extensibility
➢ providing explicit hook methods that allow applications to extend its
stable interfaces.
➢ decouple the stable interfaces and behaviors of an application domain
from the variations required by instantiations of an application in a
particular context.
✔ Inversion of control
➢ allows the framework (rather than each application) to determine which
set of application-specific methods to invoke in response
to external events
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
60
Pattern and Frameworks
Conclusion:
✔ Patterns:
➢ focus on reuse of abstract designs and software micro-architectures.
➢ an be viewed as more abstract micro-architectural elements of
frameworks
➢ document and motivate the semantics of frameworks in an effective
way
✔ Frameworks:
➢ concrete reification of families of design patterns that are targeted for a
particular application-domain.
➢ represent recurring solutions to software development problems within
a particular context.
Patterns and frameworks both facilitate reuse by capturing successful
software development strategies.
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
61
Review
Session Review:
✔ What is the role of a software architect?
✔ Do software architects implement code by themselfes?
✔ How to get an idea of the software architecture within you
projects?
✔ What about pattern?
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 1
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
1
Session: Software Architecture
Software Architectures
The Software Architekt
The Architectural process
Some words on patterns
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 2
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
2
Welcome
in
An investment in knowledge
always pays the best interest
--- Benjamin Franklin
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 3
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
3
Objectives
✔ Get a general idea about :
➢ What Software Architecture is about
➢ The role and the duties of a software architect
➢ The architectural process
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 4
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
4
Only a joke ?
As proposed by
the project
sponsor.
As specified in
the project
request
As designed by
the senior
analyst
As implemented
by developers
As installed at
user's site
What the user
wanted
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 5
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
5
The Chaos Report
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 6
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
6
Module
Software Architecture:
Definitions
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 7
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
7
Software Architecture
What is it about?
✔ As a maturing discipline with no clear rules on the
right way to build a system, designing software
architecture is still a mix of art and science.
– Djikstra
✔ Software-Architektur deals with abstraction,
decomposition and assembly, with style and
aesthetics
– Kruchten
Edsger Wybe Dijkstra
Phillipe Kruchten
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 8
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
8
Software Architecture
✔ What do we mean by a software architecture?
To me the term architecture
➢ conveys a notion of the core elements of the system
➢ the pieces that are difficult to change
➢ a foundation on which the rest must be built.
More than 50 different definitions to be found at:
http://www.sei.cmu.edu/architecture/start/glossary/community.cfm
Martin Fowler
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 9
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
9
Software architecture
✔ The software architecture of a program or computing system is the
structure of the system, which comprise:
➢ software components,
➢ the externally visible properties of those components,
➢ and the relationships between them
✔ "Externally visible" properties are those assumptions other
elements can make of an element, such as
➢ its provided services,
➢ performance characteristics,
➢ fault handling,
➢ shared resource usage, and so on.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 10
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
10
Software Architecture
Software architecture is
✔ commonly organized in views:
➢ Functional/logic view
➢ Code/module view
➢ Development/structural view
➢ Concurrency/process/thread view
➢ Physical/deployment view
➢ User action/feedback view
➢ Data view
✔ UML was established as a standard
"to model systems (and not just software)"
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 11
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
11
Software architecture
Software elements:
✔ An architecture is an abstraction of a system that
suppresses details of elements that do not affect
➢ how they use,
➢ are used by,
➢ relate to,
➢ or interact with other elements.
✔ Elements interact with each other by means of
interfaces that partition details about an element
into public and private parts.
✔ Architecture is concerned with the public side of this division;
private detail those having to do solely with internal
implementation are not architectural.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 12
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
12
Software architecture
Software architecture
✔ in between design and realisation
architecture bridges problem domain, subject
matter experts and technical realisation
✔ based upon various decisions
some of them deal with the components,
some of them deal with the technologies used
✔ the framework for flexible systems
considering external changes (organisational /
technical)
✔ is abstraction
systematically omit information not needed keeps architecture
clear.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 13
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
13
Software architecture
Why does it matter?
✔ Regarding the management software
architecture provides the first idea whether
requirements are met.
✔ Regarding new team members software
architecture provides the base to get familiar
with the structure of the system, it's design
and it's elements.
✔ Regarding maintenance and change of existing
systems, software architectures simplify impact
analysis of changes.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 14
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
14
Stakeholders
.. in a System’s Architecture
✔ Architects
✔ Developers
✔ Testers
✔ Managers
✔ Customers
✔ Users
✔ Vendors
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 15
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
15
Module
Software Architect
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 16
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
16
The lawyer of the customer and the consultant of the implementation team
– Gernot Starke
Software Architect
Software Architect:
✔ A general term with many accepted definitions,
which refers to a broad range of roles in
➢ Design
➢ Communication
✔ With a lot of responsibilities in various fields
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 17
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
17
Software Architect
Design:
✔ high-level design choices much more often
than low-level choices.
✔ sometimes dictate technical standards,
including (but mot limited to)
coding standards, tools, or platforms
✔ rarely deal with the physical architecture of the
hardware environment, confining themselves to the design
methodology of the code.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 18
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
18
Software Architect
Communication:
✔ have to communicate effectively, not only to
understand the business needs, but also to
advance their own architectural vision.
✔ can do so verbally, in writing, and through
various software architectural models that
specialize in communicating architecture.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 19
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
19
Software Architect
Architects construct and design:
✔ Components and subcomponents and
their respective responsibilities
✔ Interfaces through those the components interact
(design by contract)
✔ Interaction described by statical and
dynamical structures
Dr. Gernot Starke
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 20
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
20
Software architects
Architects decide
✔ Which components, which interfaces, which frameworks, to make
or to buy, which team develops which component, …
✔ All decisions might affect the system on the
long run, very often architects have to deal
with innovative frameworks
(so all decisions need to be documented well).
Architects guarantee meeting the requirements
✔ Feasibility and fulfillment are in the scope
of an architect as well
✔ Prototypes are unevitable part and also costs
are not out of scope.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 21
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
21
Software architects
Architects consult
✔ Regarding project plan and project organisation
✔ Project lead regarding management of the team, management of
technological risks
✔ The implementation teams in terms of
explaining, convincing and coaching
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 22
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
22
Software architects
Architects document
✔ Look out for templates, try arc42 (http://www.arc42.de/)
Architects communicate
✔ .. as mentioned before
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 23
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
23
Successful architects
According to „The mythical man month“
by Frederick P. Brooks (in 1975), an architect:
✔ "suggests" ("not dictates") implementation because
the programmer/coder/builder has the "inventive
and creative responsibility."
✔ should have an idea of how to implement his or
her architecture, but should be "prepared to accept any other way
that meets the objectives as well."
✔ should be "ready to forego credit for suggested improvements."
✔ should "listen to the builder's suggestions for architecture
improvements."
✔ should strive for work to be "spare and clean," avoiding "functional
ornamentation" and "extrapolation of functions that are obviated
by changes in assumptions and purposes."
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 24
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
24
Module
Software Architect
and software development
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 25
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
25
Software architects don't code?
or: the Microsoft perspective (from Microsoft Architect
Certificate)
✔ Enterprise architects: set the overall vision and framework
for the IT environment from a strategic business perspective.
✔ Solutions architects: design the solution to take advantage of
the existing assets, integrate them into the existing environment,
follow the enterprise architecture, and solve the business problems
of the business owner or unit.
✔ Infrastructure architects: responsible for creating an
architecture that meets the business and service level
agreement requirements of the business owners and supports the
applications and solutions that are required to operate their day-
to-day businesses.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 26
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
26
Software architects don't code?
According to previous slide, software architects:
✔ talk with the business, comes up with solutions and make bright
key decisions about architecture.
✔ they don’t program/implement
✔ during the course of the project
they ensure that developers
don’t spoil this great
architecture.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 27
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
27
Software architects don't code?
But in contrast, some architects:
✔ Might have outdated programming
knowledge and experience, loss of touch
with modern development approaches and
practices.
✔ Might don’t know much about evolving
system internals, but makes key technical
decisions.
✔ Might have often a completely irrelevant and unreal picture what is
happening with the system.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 28
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
28
Software architects don't code?
But in contrast, architects:
✔ Might tends to complex, premature and
generic solutions when the system is still
in infancy and nothing is clear.
✔ Applies latest modern buzzword
technologies as SOA, MDA, SaaS,
Software Factories, etc. which look so
beautiful in technical magazines,
conferences and CV, but cause unnecessary headache for
developers.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 29
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
29
Successfull architects
… in addition to Frederick P. Brooks:
✔ Guards a system against failure,
sensing worrying changes in the
project dynamic, system code and
business requests.
✔ Keeps the trinity of system qualities
in a balance and prevent degradation
and entropy:
➢ Firmitas (Strength) – the system is reliable, secure, has good
performance and easy to support
➢ Utilitas (Utility) – the system is usable, meets business business needs
and add business value every day instead of drifting into technology
trenches
➢ Venustas (Beauty) – code and system structure are clean, easy to
understand, minimal
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 30
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
30
Successfull architects
… in addition to Frederick P. Brooks (cont.):
✔ Encourages constant improving of the code design, enhancing
system abstractions and structure, removing duplication, defining
boundaries and interfaces of the subsystems.
✔ Keeps solutions as simple as possible, maintains intellectual control
over system and avoids over-engineering.
✔ Most important – grows and coaches
other developers to become architects
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 31
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
31
Module
The Architectural Process
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 32
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
32
Architectual process
An overview
As an architect you might follow/obey the following:
✔ Gather information
✔ Develop an idea about the system
✔ Identify drivers and boundary conditions
✔ Identify the risks
✔ Define the quality
✔ Develop strategies
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 33
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
33
Architectual process
Gather information
✔ How did others before?
Only very few things are build completely new, try to find similar
solutions.
✔ Scan for patterns
✔ Use your experience as the customer
expects profound knowledge technically
as well as within the domain
✔ In most of the cases, wide parts of
existing solutions can be reused.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 34
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
34
Architectual process
Develop an idea about the system
Some of the most important aspects of the system should be known:
✔ What is the purpose of the system
✔ Who uses the system and how is the
system used
✔ What kind of user interface will be used
✔ Where are interfaces to other systems
✔ How to use / store data
✔ How to administer the system
✔ What about printing, reporting, etc.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 35
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
35
Architectual process
Identify drivers and boundary conditions
Software architecture isn't dealing with technologies alone, a lot of
other things have some influence on the architecture
✔ Organisational aspects
✔ Resources
✔ Existing standards
✔ Rules and regulation
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 36
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
36
Architectual process
Identify the risks
There will be no single project where everything goes as expected, an
architect has to know about the risks and has to deal with them.
✔ Organisational risks
Lack of time, budget, knowledge
✔ Performance
… matters, no doubt about that
✔ Maintainability and flexibility
… design for changes with respect to
performance
✔ Availability
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 37
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
37
Architectual process
Define the quality
✔ Quality can't be measured directly as only specific features can be
measured (e.g. resource efficiency)
✔ Different stakeholders have different ideas of quality:
➢ Management: cost efficency, flexibility, maintainability
➢ Users: performance, usability
➢ Ops: administrability, security
✔ Architecture is prerequisite for quality but not
a guarantee (maybe poorly implemented),
excellent code does not imply good
architecture.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 38
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
38
Architectual process
Define the quality
✔ Quality of software systems is alway in relation to characteristics,
e.g. performance, availability, interoperability, usability, …
(@see DIN/ISO 9126)
✔ Quality attribute scenarios capture non-functional requirements of
a system in terms of standard quality attributes,
such as Availability, Modifiability, and so on.
✔ These are independent of specific functional
requirements and describe desired qualities
of a system.
www.swenet.org/materials/127/quality%20attribute%20scenarios.doc
●
Availability is concerned with system failure and duration of system failures. System failure means … when
the system does not provide the service for which it was intended.
●
Modifiability is about the cost of change, both in time and money.
●
Performance is about time. Events occur and the system must respond in a timely fashion.
●
Security is the ability of the system to prevent or resist unauthorized access while providing access to
legitimate users. An attack is an attempt to breach security.
●
Testability refers to the ease with which the software can be made to demonstrate its faults or lack
thereof. To be testable the system must control inputs and be able to observe outputs.
●
Usability is how easy it is for the user to accomplish tasks and what support the system provides for the
user to accomplish this. Dimensions:
Learning system features
Using the system efficiently
Minimizing the impact of errors
Adapting the system to the user’s needs
Increasing confidence and satisfaction
From wikipedia:
ISO/IEC 9126 Software engineering — Product quality is an international standard for the evaluation of
software quality. The fundamental objective of this standard is to address some of the well known human
biases that can adversely affect the delivery and perception of a software development project. These biases
include changing priorities after the start of a project or not having any clear definitions of "success." By
clarifying, then agreeing on the project priorities and subsequently converting abstract priorities (compliance)
to measurable values (output data can be validated against schema X with zero intervention), ISO/IEC 9126
tries to develop a common understanding of the project's objectives and goals.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 39
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
39
Quality attribute scenarios
✔ Statements like “a system will have high performance” or “a
system will be user friendly” are acceptable in the really early
stages of requirements elicitation process.
✔ As more information becomes available, the above statements
become useless as they are meaningless for the purpose of
actually designing a solution.
✔ Both statements are useless as they provide no tangible way of
measuring the behavior of the system.
✔ Writing detailed statements is only possible
when relevant requirements have been
identified and an idea of components has
been proposed.
http://www.softwarearchitectures.com/go/Discipline/DesigningArchitecture/QualityAtt
ributes/tabid/64/Default.aspx
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 40
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
40
Quality attribute scenarios
✔ The quality attributes must be described in terms of scenarios,
such as “when 100 users initiate ‘complete payment’ transition, the
payment component, under normal circumstances, will process the
requests with an average latency of three seconds.”
✔ These kind of statements, or scenarios, allows an architect to make
quantifiable arguments about a system.
✔ A scenario defines:
➢ the source of stimulus (users),
➢ the actual stimulus (initiate transaction),
➢ the artifact affected (payment component),
➢ the environment in which it exists (normal operation),
➢ the effect of the action (transaction processed),
➢ and the response measure (within three seconds)
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 41
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
41
Architectual process
Develop strategies
✔ against lack of resources and be aware of:
➢ No one performs better if put under pressure
➢ Putting more members of a project team might
cause a bigger delay
➢ If management does not back the
project it will never become a
success
✔ towards increased performance
➢ Use profilers even at the early stages
➢ Hardware is cheaper than redesign
➢ Decrease abstraction
➢ ...
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 42
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
42
Architectual process
Develop strategies
✔ covering adaptability and flexibility
➢ Figure out, where it is needed (functionality, data model, 3rd
party
software, user interface, operating system, ...)
➢ Almost every time in contrast to performance
➢ What-if scenarios might be helpful
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 43
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
43
Module
Introduction to Patterns
Each pattern describes a problem which occurs over and over again in our environment,
and then describes the core of the solution to that problem, in such a way that you can use
this solution a million times over, without ever doing it the same way twice.
--- Christopher Alexander
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 44
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
44
Design, Architecture and … Patterns
Design is a challenging task:
➢ Balancing concerns, e.g. performance, adaptability, reliability.
➢ Defining components and their interrelationships.
Thus experienced designers:
➢ Rarely start from first principles
➢ Look for similarities to problems solved in the past.
➢ Apply a working "handbook" of approaches
Patterns make expert knowledge widely available
➢ Supports focusing on the truly distinctive design problems.
➢ Aids design evaluation at higher level of abstraction
➢ Provides a useful working vocabulary for design.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 45
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
45
What is it about ?
A Pattern:
✔ ... solves a real problem, reuse of solutions already designed.
✔ ... faculitates sharing of knowledge.
✔ ... forms a vocabulary for communication between software
architects.
✔ ... limits possible solutions to best practices.
Design Patterns describe simple but sophisticated solutions for specific problems
arising in the process of designing object oriented applications; they describe
solutions tested in practice. Design Patterns are no libraries, functions, they are
language agnostic by definition; they could be used in any programming language like
Java, Smalltalk, C++ or C#.
Definition (taken from wikipedia)
In software engineering, a design pattern is a general solution to a common
problem in software design. A design pattern isn't a finished design that can be
transformed directly into code, it is a description or template for how to solve a
problem that can be used in many different situations. Object-oriented design
patterns typically show relationships and interactions between classes or objects,
without specifying the exact classes or objects that are involved.
Design patterns can speed up the development process by providing tested, proven
development paradigms. Effective software design requires considering issues that
may not become visible until later in the implementation. Reusing design patterns
helps to prevent subtle issues that can cause major problems.
Often, people only understand how to apply certain software design techniques to
certain problems. These techniques are difficult to apply to a broader range of
problems. Design patterns provide general solutions, documented in a format that
doesn't require specifics tied to a particular problem.
Patterns allow developers to communicate using well-known, well understood names
for software interactions. Common design patterns can be improved over time,
making them likely to perform better than ad-hoc designs.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 46
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
46
Types of pattern
Architectural Patterns:
✔ expresses a fundamental structural organization or schema for
software systems.
✔ provides a set of predefined subsystems, specifies their
responsibilities, and includes rules and guidelines for organizing
the relationships between them.
Design Patterns:
✔ a scheme for refining the subsystems or components of a software
system, or the relationships between them.
✔ describes commonly recurring structure of
communicating components that solves a
general design problem within a particular
context.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 47
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
47
Types of pattern
Idioms:
✔ low-level pattern specific to a programming language.
✔ An idiom describes how to implement particular aspects of
components or the relationships between them using the features
of the given language.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 48
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
48
History of ...
Overview:
✔ 1977: Christopher Alexander developed at Center
For Environmental Structure at Berkeley a theory of
using patterns within architecture.
✔ 1991: Erich Gamma wrote his Ph.D. dissertation about the usage
of patterns within software developments – only recognized
withing germany.
✔ 1995: Inspired by Alexander Ward Cunningham and Kent Beck
introduced the first five patterns for design of user interfaces.
✔ 1996: The book of the so-called „Gang-Of-Four“ sets
the pace to broad acceptance of patterns within
Software-Engineering.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 49
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
49
Patterns everywhere?
✔ Gang of Four Pattern: Erich Gamma, Richard Helm,
Ralph Johnson and John Vlissides
✔ POSA 1 Pattern: Pattern oriented software
architecture (Frank Buschmann et. al.)
✔ Core J2EE Pattern: Alur, Cupri, Malks
✔ Patterns of Enterprise Application Architecture:
Martin Fowler et. al.
✔ Enterprise Integration Patterns:
Hophe, Woolf et. al.
✔ Workflow Pattern: van der Aalst et. al.
✔ SOA Design Pattern: Thomas Erl
✔ SOA Pattern: Presentation of Michael Stal
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 50
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
50
Why using Patterns?
Pattern:
✔ ... are explicitly based on fundamental priciples of constructing
robust applications like information hiding or loose coupling.
✔ ... adress the importance of non-functional aspects like
maintainability or reliability.
✔ ... complement problem-centric methods to develop software by
guidelines to design.
✔ ... support analysis and design.
●
Architectural Pattern
●
expresses a fundamental structural organization or schema for software systems.
●
provides a set of predefined subsystems, specifies their responsibilities, and
includes rules and guidelines for organizing the relationships between them.
●
Design Pattern
●
provides a scheme for refining the subsystems or components of a software
system, or the relationships between them.
●
describes commonly recurring structure of communicating components that
solves a general design problem within a particular context.
●
Idiom
●
low-level pattern specific to a programming language.
●
describes how to implement particular aspects of components or the relationships
between them using the features of the given language.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 51
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
51
Keys to Using Patterns Effectively
✔ Recognition comes with experience
✔ Searching is aided by a catalog taxonomy
✔ Recognize, search, instantiate:
➢ Recognize a problem as common (déjà vu).
➢ Recognize the key elements of the problem.
➢ Search a pattern catalog from proven solution templates.
➢ Instantiate the template for the specific problem.
➢ Algorithm and data structure selection.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 52
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
52
Patterns, the silver bullet ?
Pattern:
✔ ... If used wrong might make systems more complex than
needed.
✔ ... if used wrong might cause problems by themselves.
✔ ... shouldn‘t be used for the sake of themselves
„As a rule of thumb, the value of a method
is inversely proportional to it‘s universality. “
--- Michael A. Jackson 1995
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 53
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
53
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Name:
➢ A good, descriptive name is critical.
➢ Good names communicate.
➢ Poor names obfuscate.
➢ Goal: Increase design vocabulary.
➢ Goal: Raise level of design discussion.
✔ Problem:
➢ Brief, abstract description.
➢ Includes design context.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 54
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
54
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Solution:
➢ Components (classes/objects) and interconnections.
➢ Generic control and data flow supported by the pattern.
➢ Template, not a cookbook.
✔ Consequences & Tradeoffs:
➢ Positive results.
➢ Negative implications.
➢ Tradeoffs: time, space, flexibility, performance, etc.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 55
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
55
Pattern taxonomy/catalogues
… or: How to describe and order them?
✔ Implementation issues:
➢ Effects of language (i.e., Java vs. C++).
➢ Alternative tactical approaches.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 56
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
56
Pattern and Frameworks
What is a framework
✔ A set of reusable designs and objects used to build applications
✔ Defines how objects work together to get something done
✔ Defines the superclasses or public interface for the object that you
develop
✔ Your objects work within the framework
✔ A framework is a "semi-complete" application
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 57
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
57
Pattern and Frameworks
What is a framework
✔ A framework usually supports a very specific domain
➢ GUI (large)
➢ Collections (small)
✔ Usual characteristics of a good framework
➢ Relatively easy to understand and use
➢ Provides a solution to a common problem
➢ Can be used over and over again
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 58
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
58
Pattern and Frameworks
Benefits of OO application frameworks:
✔ Modularity:
➢ enhance modularity by encapsulating volatile implementation details
behind stable interfaces
➢ reduces the effort required to understand and maintain existing
software.
✔ Reusability
➢ stable interfaces define generic components that can be reapplied to
create new applications.
➢ avoid re-creating and re-validating common solutions
to recurring application requirements and
software design challenges.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 59
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
59
Pattern and Frameworks
Benefits of OO application frameworks (contd.):
✔ Extensibility
➢ providing explicit hook methods that allow applications to extend its
stable interfaces.
➢ decouple the stable interfaces and behaviors of an application domain
from the variations required by instantiations of an application in a
particular context.
✔ Inversion of control
➢ allows the framework (rather than each application) to determine which
set of application-specific methods to invoke in response
to external events
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 60
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
60
Pattern and Frameworks
Conclusion:
✔ Patterns:
➢ focus on reuse of abstract designs and software micro-architectures.
➢ an be viewed as more abstract micro-architectural elements of
frameworks
➢ document and motivate the semantics of frameworks in an effective
way
✔ Frameworks:
➢ concrete reification of families of design patterns that are targeted for a
particular application-domain.
➢ represent recurring solutions to software development problems within
a particular context.
Patterns and frameworks both facilitate reuse by capturing successful
software development strategies.
Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 61
Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt
61
Review
Session Review:
✔ What is the role of a software architect?
✔ Do software architects implement code by themselfes?
✔ How to get an idea of the software architecture within you
projects?
✔ What about pattern?

Contenu connexe

En vedette (10)

Java EE Pattern: Entity Control Boundary Pattern and Java EE
Java EE Pattern: Entity Control Boundary Pattern and Java EEJava EE Pattern: Entity Control Boundary Pattern and Java EE
Java EE Pattern: Entity Control Boundary Pattern and Java EE
 
Industry 4.0
Industry 4.0Industry 4.0
Industry 4.0
 
Java EE Pattern: The Boundary Layer
Java EE Pattern: The Boundary LayerJava EE Pattern: The Boundary Layer
Java EE Pattern: The Boundary Layer
 
Software Architecture Design for Begginers
Software Architecture Design for BegginersSoftware Architecture Design for Begginers
Software Architecture Design for Begginers
 
Fundamentals Of Software Architecture
Fundamentals Of Software ArchitectureFundamentals Of Software Architecture
Fundamentals Of Software Architecture
 
software architecture
software architecturesoftware architecture
software architecture
 
Software design methodologies
Software design methodologiesSoftware design methodologies
Software design methodologies
 
Software design
Software designSoftware design
Software design
 
Industrie 4.0: Symposium an der RFH Köln
Industrie 4.0: Symposium an der RFH KölnIndustrie 4.0: Symposium an der RFH Köln
Industrie 4.0: Symposium an der RFH Köln
 
Design concepts and principles
Design concepts and principlesDesign concepts and principles
Design concepts and principles
 

Similaire à Bro110 5 1_software_architecture

SE 18CS35 Module 1.pdf
SE 18CS35 Module 1.pdfSE 18CS35 Module 1.pdf
SE 18CS35 Module 1.pdfbalaji984829
 
Swe 03 (st 2013) agile software engineering
Swe 03 (st 2013)   agile software engineeringSwe 03 (st 2013)   agile software engineering
Swe 03 (st 2013) agile software engineeringsarahflieger
 
Swe 03 (st 2013) agile software engineering
Swe 03 (st 2013)   agile software engineeringSwe 03 (st 2013)   agile software engineering
Swe 03 (st 2013) agile software engineeringsarahflieger
 
76 May 2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx
76 May  2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx76 May  2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx
76 May 2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docxevonnehoggarth79783
 
ARIS 9 Big Innovations in Focus
ARIS 9 Big Innovations in FocusARIS 9 Big Innovations in Focus
ARIS 9 Big Innovations in FocusSoftware AG
 
What a Good Software Architect Does
What a Good Software Architect DoesWhat a Good Software Architect Does
What a Good Software Architect DoesEberhard Wolff
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptDrTThendralCompSci
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptDrTThendralCompSci
 
You're the Engineer! Think Big!
You're the Engineer! Think Big!You're the Engineer! Think Big!
You're the Engineer! Think Big!Fatih Karatana
 
SE chp1 update and learning management .pptx
SE chp1 update and learning management .pptxSE chp1 update and learning management .pptx
SE chp1 update and learning management .pptxssuserdee5bb1
 
Hardware Software Co-Design - White Paper
Hardware Software Co-Design - White PaperHardware Software Co-Design - White Paper
Hardware Software Co-Design - White PaperMistral Solutions
 
Kelis king - introduction to s.e.
Kelis king -  introduction to s.e.Kelis king -  introduction to s.e.
Kelis king - introduction to s.e.KelisKing
 
software product development services.pdf
software product development services.pdfsoftware product development services.pdf
software product development services.pdfXlogia Tech
 
Sofware engineering
Sofware engineeringSofware engineering
Sofware engineeringnstjelja
 
Good Design is Good Business: Business Design with RSA and SA
Good Design is Good Business: Business Design with RSA and SAGood Design is Good Business: Business Design with RSA and SA
Good Design is Good Business: Business Design with RSA and SARoger Snook
 
Software Engineering Unit-1
Software Engineering Unit-1Software Engineering Unit-1
Software Engineering Unit-1Samura Daniel
 
Introduction to Software Engineering
Introduction to Software EngineeringIntroduction to Software Engineering
Introduction to Software EngineeringSADEED AMEEN
 

Similaire à Bro110 5 1_software_architecture (20)

SE 18CS35 Module 1.pdf
SE 18CS35 Module 1.pdfSE 18CS35 Module 1.pdf
SE 18CS35 Module 1.pdf
 
Swe 03 (st 2013) agile software engineering
Swe 03 (st 2013)   agile software engineeringSwe 03 (st 2013)   agile software engineering
Swe 03 (st 2013) agile software engineering
 
Swe 03 (st 2013) agile software engineering
Swe 03 (st 2013)   agile software engineeringSwe 03 (st 2013)   agile software engineering
Swe 03 (st 2013) agile software engineering
 
76 May 2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx
76 May  2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx76 May  2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx
76 May 2007Vol. 50, No. 5 COMMUNICATIONS OF THE ACM COMMUNIC.docx
 
ARIS 9 Big Innovations in Focus
ARIS 9 Big Innovations in FocusARIS 9 Big Innovations in Focus
ARIS 9 Big Innovations in Focus
 
What a Good Software Architect Does
What a Good Software Architect DoesWhat a Good Software Architect Does
What a Good Software Architect Does
 
sw1.pdf
sw1.pdfsw1.pdf
sw1.pdf
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.ppt
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.ppt
 
You're the Engineer! Think Big!
You're the Engineer! Think Big!You're the Engineer! Think Big!
You're the Engineer! Think Big!
 
SE chp1 update and learning management .pptx
SE chp1 update and learning management .pptxSE chp1 update and learning management .pptx
SE chp1 update and learning management .pptx
 
Hardware Software Co-Design - White Paper
Hardware Software Co-Design - White PaperHardware Software Co-Design - White Paper
Hardware Software Co-Design - White Paper
 
Kelis king - introduction to s.e.
Kelis king -  introduction to s.e.Kelis king -  introduction to s.e.
Kelis king - introduction to s.e.
 
software product development services.pdf
software product development services.pdfsoftware product development services.pdf
software product development services.pdf
 
Sofware engineering
Sofware engineeringSofware engineering
Sofware engineering
 
Good Design is Good Business: Business Design with RSA and SA
Good Design is Good Business: Business Design with RSA and SAGood Design is Good Business: Business Design with RSA and SA
Good Design is Good Business: Business Design with RSA and SA
 
Software Engineering Unit-1
Software Engineering Unit-1Software Engineering Unit-1
Software Engineering Unit-1
 
Introduction to Software Engineering
Introduction to Software EngineeringIntroduction to Software Engineering
Introduction to Software Engineering
 
Software engineering
Software engineeringSoftware engineering
Software engineering
 
software engineering
software engineeringsoftware engineering
software engineering
 

Plus de Brockhaus Consulting GmbH (14)

Zeitreihen in Apache Cassandra
Zeitreihen in Apache CassandraZeitreihen in Apache Cassandra
Zeitreihen in Apache Cassandra
 
M2M infrastructure using Docker
M2M infrastructure using DockerM2M infrastructure using Docker
M2M infrastructure using Docker
 
Arquillian in a nutshell
Arquillian in a nutshellArquillian in a nutshell
Arquillian in a nutshell
 
Big Data and Business Intelligence
Big Data and Business IntelligenceBig Data and Business Intelligence
Big Data and Business Intelligence
 
Microservices und das Entity Control Boundary Pattern
Microservices und das Entity Control Boundary PatternMicroservices und das Entity Control Boundary Pattern
Microservices und das Entity Control Boundary Pattern
 
OPC -Connectivity using Java
OPC -Connectivity using JavaOPC -Connectivity using Java
OPC -Connectivity using Java
 
Mobile Endgeräte in der Produktion
Mobile Endgeräte in der ProduktionMobile Endgeräte in der Produktion
Mobile Endgeräte in der Produktion
 
Intro 2 Machine Learning
Intro 2 Machine LearningIntro 2 Machine Learning
Intro 2 Machine Learning
 
Messaging im Internet of Things: MQTT
Messaging im Internet of Things: MQTTMessaging im Internet of Things: MQTT
Messaging im Internet of Things: MQTT
 
Architekturbewertung
ArchitekturbewertungArchitekturbewertung
Architekturbewertung
 
Work shop worldbank
Work shop worldbankWork shop worldbank
Work shop worldbank
 
Certification isec 2012 program committee (bohnen, matthias) 2
Certification isec 2012 program committee (bohnen, matthias) 2Certification isec 2012 program committee (bohnen, matthias) 2
Certification isec 2012 program committee (bohnen, matthias) 2
 
Java flyer final_2014
Java flyer final_2014Java flyer final_2014
Java flyer final_2014
 
Cartel java ee 2nd ed
Cartel java ee 2nd edCartel java ee 2nd ed
Cartel java ee 2nd ed
 

Dernier

SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentationcamerronhm
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and ModificationsMJDuyan
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxAreebaZafar22
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxVishalSingh1417
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsKarakKing
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsMebane Rash
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...christianmathematics
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin ClassesCeline George
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibitjbellavia9
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxAmanpreet Kaur
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxJisc
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfNirmal Dwivedi
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxDenish Jangid
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseAnaAcapella
 
Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structuredhanjurrannsibayan2
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfSherif Taha
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxDr. Sarita Anand
 
Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Association for Project Management
 

Dernier (20)

SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functions
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptx
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structure
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdf
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptx
 
Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...
 

Bro110 5 1_software_architecture

  • 1. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 1 Session: Software Architecture Software Architectures The Software Architekt The Architectural process Some words on patterns
  • 2. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 2 Welcome in An investment in knowledge always pays the best interest --- Benjamin Franklin
  • 3. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 3 Objectives ✔ Get a general idea about : ➢ What Software Architecture is about ➢ The role and the duties of a software architect ➢ The architectural process
  • 4. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 4 Only a joke ? As proposed by the project sponsor. As specified in the project request As designed by the senior analyst As implemented by developers As installed at user's site What the user wanted
  • 5. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 5 The Chaos Report
  • 6. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 6 Module Software Architecture: Definitions
  • 7. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 7 Software Architecture What is it about? ✔ As a maturing discipline with no clear rules on the right way to build a system, designing software architecture is still a mix of art and science. – Djikstra ✔ Software-Architektur deals with abstraction, decomposition and assembly, with style and aesthetics – Kruchten Edsger Wybe Dijkstra Phillipe Kruchten
  • 8. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 8 Software Architecture ✔ What do we mean by a software architecture? To me the term architecture ➢ conveys a notion of the core elements of the system ➢ the pieces that are difficult to change ➢ a foundation on which the rest must be built. More than 50 different definitions to be found at: http://www.sei.cmu.edu/architecture/start/glossary/community.cfm Martin Fowler
  • 9. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 9 Software architecture ✔ The software architecture of a program or computing system is the structure of the system, which comprise: ➢ software components, ➢ the externally visible properties of those components, ➢ and the relationships between them ✔ "Externally visible" properties are those assumptions other elements can make of an element, such as ➢ its provided services, ➢ performance characteristics, ➢ fault handling, ➢ shared resource usage, and so on.
  • 10. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 10 Software Architecture Software architecture is ✔ commonly organized in views: ➢ Functional/logic view ➢ Code/module view ➢ Development/structural view ➢ Concurrency/process/thread view ➢ Physical/deployment view ➢ User action/feedback view ➢ Data view ✔ UML was established as a standard "to model systems (and not just software)"
  • 11. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 11 Software architecture Software elements: ✔ An architecture is an abstraction of a system that suppresses details of elements that do not affect ➢ how they use, ➢ are used by, ➢ relate to, ➢ or interact with other elements. ✔ Elements interact with each other by means of interfaces that partition details about an element into public and private parts. ✔ Architecture is concerned with the public side of this division; private detail those having to do solely with internal implementation are not architectural.
  • 12. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 12 Software architecture Software architecture ✔ in between design and realisation architecture bridges problem domain, subject matter experts and technical realisation ✔ based upon various decisions some of them deal with the components, some of them deal with the technologies used ✔ the framework for flexible systems considering external changes (organisational / technical) ✔ is abstraction systematically omit information not needed keeps architecture clear.
  • 13. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 13 Software architecture Why does it matter? ✔ Regarding the management software architecture provides the first idea whether requirements are met. ✔ Regarding new team members software architecture provides the base to get familiar with the structure of the system, it's design and it's elements. ✔ Regarding maintenance and change of existing systems, software architectures simplify impact analysis of changes.
  • 14. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 14 Stakeholders .. in a System’s Architecture ✔ Architects ✔ Developers ✔ Testers ✔ Managers ✔ Customers ✔ Users ✔ Vendors
  • 15. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 15 Module Software Architect
  • 16. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 16 The lawyer of the customer and the consultant of the implementation team – Gernot Starke Software Architect Software Architect: ✔ A general term with many accepted definitions, which refers to a broad range of roles in ➢ Design ➢ Communication ✔ With a lot of responsibilities in various fields
  • 17. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 17 Software Architect Design: ✔ high-level design choices much more often than low-level choices. ✔ sometimes dictate technical standards, including (but mot limited to) coding standards, tools, or platforms ✔ rarely deal with the physical architecture of the hardware environment, confining themselves to the design methodology of the code.
  • 18. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 18 Software Architect Communication: ✔ have to communicate effectively, not only to understand the business needs, but also to advance their own architectural vision. ✔ can do so verbally, in writing, and through various software architectural models that specialize in communicating architecture.
  • 19. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 19 Software Architect Architects construct and design: ✔ Components and subcomponents and their respective responsibilities ✔ Interfaces through those the components interact (design by contract) ✔ Interaction described by statical and dynamical structures Dr. Gernot Starke
  • 20. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 20 Software architects Architects decide ✔ Which components, which interfaces, which frameworks, to make or to buy, which team develops which component, … ✔ All decisions might affect the system on the long run, very often architects have to deal with innovative frameworks (so all decisions need to be documented well). Architects guarantee meeting the requirements ✔ Feasibility and fulfillment are in the scope of an architect as well ✔ Prototypes are unevitable part and also costs are not out of scope.
  • 21. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 21 Software architects Architects consult ✔ Regarding project plan and project organisation ✔ Project lead regarding management of the team, management of technological risks ✔ The implementation teams in terms of explaining, convincing and coaching
  • 22. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 22 Software architects Architects document ✔ Look out for templates, try arc42 (http://www.arc42.de/) Architects communicate ✔ .. as mentioned before
  • 23. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 23 Successful architects According to „The mythical man month“ by Frederick P. Brooks (in 1975), an architect: ✔ "suggests" ("not dictates") implementation because the programmer/coder/builder has the "inventive and creative responsibility." ✔ should have an idea of how to implement his or her architecture, but should be "prepared to accept any other way that meets the objectives as well." ✔ should be "ready to forego credit for suggested improvements." ✔ should "listen to the builder's suggestions for architecture improvements." ✔ should strive for work to be "spare and clean," avoiding "functional ornamentation" and "extrapolation of functions that are obviated by changes in assumptions and purposes."
  • 24. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 24 Module Software Architect and software development
  • 25. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 25 Software architects don't code? or: the Microsoft perspective (from Microsoft Architect Certificate) ✔ Enterprise architects: set the overall vision and framework for the IT environment from a strategic business perspective. ✔ Solutions architects: design the solution to take advantage of the existing assets, integrate them into the existing environment, follow the enterprise architecture, and solve the business problems of the business owner or unit. ✔ Infrastructure architects: responsible for creating an architecture that meets the business and service level agreement requirements of the business owners and supports the applications and solutions that are required to operate their day- to-day businesses.
  • 26. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 26 Software architects don't code? According to previous slide, software architects: ✔ talk with the business, comes up with solutions and make bright key decisions about architecture. ✔ they don’t program/implement ✔ during the course of the project they ensure that developers don’t spoil this great architecture.
  • 27. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 27 Software architects don't code? But in contrast, some architects: ✔ Might have outdated programming knowledge and experience, loss of touch with modern development approaches and practices. ✔ Might don’t know much about evolving system internals, but makes key technical decisions. ✔ Might have often a completely irrelevant and unreal picture what is happening with the system.
  • 28. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 28 Software architects don't code? But in contrast, architects: ✔ Might tends to complex, premature and generic solutions when the system is still in infancy and nothing is clear. ✔ Applies latest modern buzzword technologies as SOA, MDA, SaaS, Software Factories, etc. which look so beautiful in technical magazines, conferences and CV, but cause unnecessary headache for developers.
  • 29. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 29 Successfull architects … in addition to Frederick P. Brooks: ✔ Guards a system against failure, sensing worrying changes in the project dynamic, system code and business requests. ✔ Keeps the trinity of system qualities in a balance and prevent degradation and entropy: ➢ Firmitas (Strength) – the system is reliable, secure, has good performance and easy to support ➢ Utilitas (Utility) – the system is usable, meets business business needs and add business value every day instead of drifting into technology trenches ➢ Venustas (Beauty) – code and system structure are clean, easy to understand, minimal
  • 30. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 30 Successfull architects … in addition to Frederick P. Brooks (cont.): ✔ Encourages constant improving of the code design, enhancing system abstractions and structure, removing duplication, defining boundaries and interfaces of the subsystems. ✔ Keeps solutions as simple as possible, maintains intellectual control over system and avoids over-engineering. ✔ Most important – grows and coaches other developers to become architects
  • 31. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 31 Module The Architectural Process
  • 32. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 32 Architectual process An overview As an architect you might follow/obey the following: ✔ Gather information ✔ Develop an idea about the system ✔ Identify drivers and boundary conditions ✔ Identify the risks ✔ Define the quality ✔ Develop strategies
  • 33. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 33 Architectual process Gather information ✔ How did others before? Only very few things are build completely new, try to find similar solutions. ✔ Scan for patterns ✔ Use your experience as the customer expects profound knowledge technically as well as within the domain ✔ In most of the cases, wide parts of existing solutions can be reused.
  • 34. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 34 Architectual process Develop an idea about the system Some of the most important aspects of the system should be known: ✔ What is the purpose of the system ✔ Who uses the system and how is the system used ✔ What kind of user interface will be used ✔ Where are interfaces to other systems ✔ How to use / store data ✔ How to administer the system ✔ What about printing, reporting, etc.
  • 35. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 35 Architectual process Identify drivers and boundary conditions Software architecture isn't dealing with technologies alone, a lot of other things have some influence on the architecture ✔ Organisational aspects ✔ Resources ✔ Existing standards ✔ Rules and regulation
  • 36. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 36 Architectual process Identify the risks There will be no single project where everything goes as expected, an architect has to know about the risks and has to deal with them. ✔ Organisational risks Lack of time, budget, knowledge ✔ Performance … matters, no doubt about that ✔ Maintainability and flexibility … design for changes with respect to performance ✔ Availability
  • 37. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 37 Architectual process Define the quality ✔ Quality can't be measured directly as only specific features can be measured (e.g. resource efficiency) ✔ Different stakeholders have different ideas of quality: ➢ Management: cost efficency, flexibility, maintainability ➢ Users: performance, usability ➢ Ops: administrability, security ✔ Architecture is prerequisite for quality but not a guarantee (maybe poorly implemented), excellent code does not imply good architecture.
  • 38. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 38 Architectual process Define the quality ✔ Quality of software systems is alway in relation to characteristics, e.g. performance, availability, interoperability, usability, … (@see DIN/ISO 9126) ✔ Quality attribute scenarios capture non-functional requirements of a system in terms of standard quality attributes, such as Availability, Modifiability, and so on. ✔ These are independent of specific functional requirements and describe desired qualities of a system.
  • 39. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 39 Quality attribute scenarios ✔ Statements like “a system will have high performance” or “a system will be user friendly” are acceptable in the really early stages of requirements elicitation process. ✔ As more information becomes available, the above statements become useless as they are meaningless for the purpose of actually designing a solution. ✔ Both statements are useless as they provide no tangible way of measuring the behavior of the system. ✔ Writing detailed statements is only possible when relevant requirements have been identified and an idea of components has been proposed.
  • 40. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 40 Quality attribute scenarios ✔ The quality attributes must be described in terms of scenarios, such as “when 100 users initiate ‘complete payment’ transition, the payment component, under normal circumstances, will process the requests with an average latency of three seconds.” ✔ These kind of statements, or scenarios, allows an architect to make quantifiable arguments about a system. ✔ A scenario defines: ➢ the source of stimulus (users), ➢ the actual stimulus (initiate transaction), ➢ the artifact affected (payment component), ➢ the environment in which it exists (normal operation), ➢ the effect of the action (transaction processed), ➢ and the response measure (within three seconds)
  • 41. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 41 Architectual process Develop strategies ✔ against lack of resources and be aware of: ➢ No one performs better if put under pressure ➢ Putting more members of a project team might cause a bigger delay ➢ If management does not back the project it will never become a success ✔ towards increased performance ➢ Use profilers even at the early stages ➢ Hardware is cheaper than redesign ➢ Decrease abstraction ➢ ...
  • 42. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 42 Architectual process Develop strategies ✔ covering adaptability and flexibility ➢ Figure out, where it is needed (functionality, data model, 3rd party software, user interface, operating system, ...) ➢ Almost every time in contrast to performance ➢ What-if scenarios might be helpful
  • 43. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 43 Module Introduction to Patterns Each pattern describes a problem which occurs over and over again in our environment, and then describes the core of the solution to that problem, in such a way that you can use this solution a million times over, without ever doing it the same way twice. --- Christopher Alexander
  • 44. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 44 Design, Architecture and … Patterns Design is a challenging task: ➢ Balancing concerns, e.g. performance, adaptability, reliability. ➢ Defining components and their interrelationships. Thus experienced designers: ➢ Rarely start from first principles ➢ Look for similarities to problems solved in the past. ➢ Apply a working "handbook" of approaches Patterns make expert knowledge widely available ➢ Supports focusing on the truly distinctive design problems. ➢ Aids design evaluation at higher level of abstraction ➢ Provides a useful working vocabulary for design.
  • 45. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 45 What is it about ? A Pattern: ✔ ... solves a real problem, reuse of solutions already designed. ✔ ... faculitates sharing of knowledge. ✔ ... forms a vocabulary for communication between software architects. ✔ ... limits possible solutions to best practices.
  • 46. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 46 Types of pattern Architectural Patterns: ✔ expresses a fundamental structural organization or schema for software systems. ✔ provides a set of predefined subsystems, specifies their responsibilities, and includes rules and guidelines for organizing the relationships between them. Design Patterns: ✔ a scheme for refining the subsystems or components of a software system, or the relationships between them. ✔ describes commonly recurring structure of communicating components that solves a general design problem within a particular context.
  • 47. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 47 Types of pattern Idioms: ✔ low-level pattern specific to a programming language. ✔ An idiom describes how to implement particular aspects of components or the relationships between them using the features of the given language.
  • 48. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 48 History of ... Overview: ✔ 1977: Christopher Alexander developed at Center For Environmental Structure at Berkeley a theory of using patterns within architecture. ✔ 1991: Erich Gamma wrote his Ph.D. dissertation about the usage of patterns within software developments – only recognized withing germany. ✔ 1995: Inspired by Alexander Ward Cunningham and Kent Beck introduced the first five patterns for design of user interfaces. ✔ 1996: The book of the so-called „Gang-Of-Four“ sets the pace to broad acceptance of patterns within Software-Engineering.
  • 49. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 49 Patterns everywhere? ✔ Gang of Four Pattern: Erich Gamma, Richard Helm, Ralph Johnson and John Vlissides ✔ POSA 1 Pattern: Pattern oriented software architecture (Frank Buschmann et. al.) ✔ Core J2EE Pattern: Alur, Cupri, Malks ✔ Patterns of Enterprise Application Architecture: Martin Fowler et. al. ✔ Enterprise Integration Patterns: Hophe, Woolf et. al. ✔ Workflow Pattern: van der Aalst et. al. ✔ SOA Design Pattern: Thomas Erl ✔ SOA Pattern: Presentation of Michael Stal
  • 50. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 50 Why using Patterns? Pattern: ✔ ... are explicitly based on fundamental priciples of constructing robust applications like information hiding or loose coupling. ✔ ... adress the importance of non-functional aspects like maintainability or reliability. ✔ ... complement problem-centric methods to develop software by guidelines to design. ✔ ... support analysis and design.
  • 51. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 51 Keys to Using Patterns Effectively ✔ Recognition comes with experience ✔ Searching is aided by a catalog taxonomy ✔ Recognize, search, instantiate: ➢ Recognize a problem as common (déjà vu). ➢ Recognize the key elements of the problem. ➢ Search a pattern catalog from proven solution templates. ➢ Instantiate the template for the specific problem. ➢ Algorithm and data structure selection.
  • 52. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 52 Patterns, the silver bullet ? Pattern: ✔ ... If used wrong might make systems more complex than needed. ✔ ... if used wrong might cause problems by themselves. ✔ ... shouldn‘t be used for the sake of themselves „As a rule of thumb, the value of a method is inversely proportional to it‘s universality. “ --- Michael A. Jackson 1995
  • 53. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 53 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Name: ➢ A good, descriptive name is critical. ➢ Good names communicate. ➢ Poor names obfuscate. ➢ Goal: Increase design vocabulary. ➢ Goal: Raise level of design discussion. ✔ Problem: ➢ Brief, abstract description. ➢ Includes design context.
  • 54. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 54 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Solution: ➢ Components (classes/objects) and interconnections. ➢ Generic control and data flow supported by the pattern. ➢ Template, not a cookbook. ✔ Consequences & Tradeoffs: ➢ Positive results. ➢ Negative implications. ➢ Tradeoffs: time, space, flexibility, performance, etc.
  • 55. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 55 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Implementation issues: ➢ Effects of language (i.e., Java vs. C++). ➢ Alternative tactical approaches.
  • 56. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 56 Pattern and Frameworks What is a framework ✔ A set of reusable designs and objects used to build applications ✔ Defines how objects work together to get something done ✔ Defines the superclasses or public interface for the object that you develop ✔ Your objects work within the framework ✔ A framework is a "semi-complete" application
  • 57. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 57 Pattern and Frameworks What is a framework ✔ A framework usually supports a very specific domain ➢ GUI (large) ➢ Collections (small) ✔ Usual characteristics of a good framework ➢ Relatively easy to understand and use ➢ Provides a solution to a common problem ➢ Can be used over and over again
  • 58. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 58 Pattern and Frameworks Benefits of OO application frameworks: ✔ Modularity: ➢ enhance modularity by encapsulating volatile implementation details behind stable interfaces ➢ reduces the effort required to understand and maintain existing software. ✔ Reusability ➢ stable interfaces define generic components that can be reapplied to create new applications. ➢ avoid re-creating and re-validating common solutions to recurring application requirements and software design challenges.
  • 59. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 59 Pattern and Frameworks Benefits of OO application frameworks (contd.): ✔ Extensibility ➢ providing explicit hook methods that allow applications to extend its stable interfaces. ➢ decouple the stable interfaces and behaviors of an application domain from the variations required by instantiations of an application in a particular context. ✔ Inversion of control ➢ allows the framework (rather than each application) to determine which set of application-specific methods to invoke in response to external events
  • 60. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 60 Pattern and Frameworks Conclusion: ✔ Patterns: ➢ focus on reuse of abstract designs and software micro-architectures. ➢ an be viewed as more abstract micro-architectural elements of frameworks ➢ document and motivate the semantics of frameworks in an effective way ✔ Frameworks: ➢ concrete reification of families of design patterns that are targeted for a particular application-domain. ➢ represent recurring solutions to software development problems within a particular context. Patterns and frameworks both facilitate reuse by capturing successful software development strategies.
  • 61. Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 61 Review Session Review: ✔ What is the role of a software architect? ✔ Do software architects implement code by themselfes? ✔ How to get an idea of the software architecture within you projects? ✔ What about pattern?
  • 62. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 1 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 1 Session: Software Architecture Software Architectures The Software Architekt The Architectural process Some words on patterns
  • 63. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 2 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 2 Welcome in An investment in knowledge always pays the best interest --- Benjamin Franklin
  • 64. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 3 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 3 Objectives ✔ Get a general idea about : ➢ What Software Architecture is about ➢ The role and the duties of a software architect ➢ The architectural process
  • 65. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 4 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 4 Only a joke ? As proposed by the project sponsor. As specified in the project request As designed by the senior analyst As implemented by developers As installed at user's site What the user wanted
  • 66. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 5 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 5 The Chaos Report
  • 67. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 6 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 6 Module Software Architecture: Definitions
  • 68. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 7 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 7 Software Architecture What is it about? ✔ As a maturing discipline with no clear rules on the right way to build a system, designing software architecture is still a mix of art and science. – Djikstra ✔ Software-Architektur deals with abstraction, decomposition and assembly, with style and aesthetics – Kruchten Edsger Wybe Dijkstra Phillipe Kruchten
  • 69. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 8 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 8 Software Architecture ✔ What do we mean by a software architecture? To me the term architecture ➢ conveys a notion of the core elements of the system ➢ the pieces that are difficult to change ➢ a foundation on which the rest must be built. More than 50 different definitions to be found at: http://www.sei.cmu.edu/architecture/start/glossary/community.cfm Martin Fowler
  • 70. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 9 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 9 Software architecture ✔ The software architecture of a program or computing system is the structure of the system, which comprise: ➢ software components, ➢ the externally visible properties of those components, ➢ and the relationships between them ✔ "Externally visible" properties are those assumptions other elements can make of an element, such as ➢ its provided services, ➢ performance characteristics, ➢ fault handling, ➢ shared resource usage, and so on.
  • 71. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 10 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 10 Software Architecture Software architecture is ✔ commonly organized in views: ➢ Functional/logic view ➢ Code/module view ➢ Development/structural view ➢ Concurrency/process/thread view ➢ Physical/deployment view ➢ User action/feedback view ➢ Data view ✔ UML was established as a standard "to model systems (and not just software)"
  • 72. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 11 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 11 Software architecture Software elements: ✔ An architecture is an abstraction of a system that suppresses details of elements that do not affect ➢ how they use, ➢ are used by, ➢ relate to, ➢ or interact with other elements. ✔ Elements interact with each other by means of interfaces that partition details about an element into public and private parts. ✔ Architecture is concerned with the public side of this division; private detail those having to do solely with internal implementation are not architectural.
  • 73. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 12 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 12 Software architecture Software architecture ✔ in between design and realisation architecture bridges problem domain, subject matter experts and technical realisation ✔ based upon various decisions some of them deal with the components, some of them deal with the technologies used ✔ the framework for flexible systems considering external changes (organisational / technical) ✔ is abstraction systematically omit information not needed keeps architecture clear.
  • 74. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 13 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 13 Software architecture Why does it matter? ✔ Regarding the management software architecture provides the first idea whether requirements are met. ✔ Regarding new team members software architecture provides the base to get familiar with the structure of the system, it's design and it's elements. ✔ Regarding maintenance and change of existing systems, software architectures simplify impact analysis of changes.
  • 75. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 14 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 14 Stakeholders .. in a System’s Architecture ✔ Architects ✔ Developers ✔ Testers ✔ Managers ✔ Customers ✔ Users ✔ Vendors
  • 76. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 15 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 15 Module Software Architect
  • 77. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 16 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 16 The lawyer of the customer and the consultant of the implementation team – Gernot Starke Software Architect Software Architect: ✔ A general term with many accepted definitions, which refers to a broad range of roles in ➢ Design ➢ Communication ✔ With a lot of responsibilities in various fields
  • 78. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 17 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 17 Software Architect Design: ✔ high-level design choices much more often than low-level choices. ✔ sometimes dictate technical standards, including (but mot limited to) coding standards, tools, or platforms ✔ rarely deal with the physical architecture of the hardware environment, confining themselves to the design methodology of the code.
  • 79. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 18 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 18 Software Architect Communication: ✔ have to communicate effectively, not only to understand the business needs, but also to advance their own architectural vision. ✔ can do so verbally, in writing, and through various software architectural models that specialize in communicating architecture.
  • 80. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 19 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 19 Software Architect Architects construct and design: ✔ Components and subcomponents and their respective responsibilities ✔ Interfaces through those the components interact (design by contract) ✔ Interaction described by statical and dynamical structures Dr. Gernot Starke
  • 81. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 20 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 20 Software architects Architects decide ✔ Which components, which interfaces, which frameworks, to make or to buy, which team develops which component, … ✔ All decisions might affect the system on the long run, very often architects have to deal with innovative frameworks (so all decisions need to be documented well). Architects guarantee meeting the requirements ✔ Feasibility and fulfillment are in the scope of an architect as well ✔ Prototypes are unevitable part and also costs are not out of scope.
  • 82. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 21 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 21 Software architects Architects consult ✔ Regarding project plan and project organisation ✔ Project lead regarding management of the team, management of technological risks ✔ The implementation teams in terms of explaining, convincing and coaching
  • 83. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 22 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 22 Software architects Architects document ✔ Look out for templates, try arc42 (http://www.arc42.de/) Architects communicate ✔ .. as mentioned before
  • 84. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 23 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 23 Successful architects According to „The mythical man month“ by Frederick P. Brooks (in 1975), an architect: ✔ "suggests" ("not dictates") implementation because the programmer/coder/builder has the "inventive and creative responsibility." ✔ should have an idea of how to implement his or her architecture, but should be "prepared to accept any other way that meets the objectives as well." ✔ should be "ready to forego credit for suggested improvements." ✔ should "listen to the builder's suggestions for architecture improvements." ✔ should strive for work to be "spare and clean," avoiding "functional ornamentation" and "extrapolation of functions that are obviated by changes in assumptions and purposes."
  • 85. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 24 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 24 Module Software Architect and software development
  • 86. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 25 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 25 Software architects don't code? or: the Microsoft perspective (from Microsoft Architect Certificate) ✔ Enterprise architects: set the overall vision and framework for the IT environment from a strategic business perspective. ✔ Solutions architects: design the solution to take advantage of the existing assets, integrate them into the existing environment, follow the enterprise architecture, and solve the business problems of the business owner or unit. ✔ Infrastructure architects: responsible for creating an architecture that meets the business and service level agreement requirements of the business owners and supports the applications and solutions that are required to operate their day- to-day businesses.
  • 87. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 26 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 26 Software architects don't code? According to previous slide, software architects: ✔ talk with the business, comes up with solutions and make bright key decisions about architecture. ✔ they don’t program/implement ✔ during the course of the project they ensure that developers don’t spoil this great architecture.
  • 88. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 27 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 27 Software architects don't code? But in contrast, some architects: ✔ Might have outdated programming knowledge and experience, loss of touch with modern development approaches and practices. ✔ Might don’t know much about evolving system internals, but makes key technical decisions. ✔ Might have often a completely irrelevant and unreal picture what is happening with the system.
  • 89. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 28 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 28 Software architects don't code? But in contrast, architects: ✔ Might tends to complex, premature and generic solutions when the system is still in infancy and nothing is clear. ✔ Applies latest modern buzzword technologies as SOA, MDA, SaaS, Software Factories, etc. which look so beautiful in technical magazines, conferences and CV, but cause unnecessary headache for developers.
  • 90. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 29 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 29 Successfull architects … in addition to Frederick P. Brooks: ✔ Guards a system against failure, sensing worrying changes in the project dynamic, system code and business requests. ✔ Keeps the trinity of system qualities in a balance and prevent degradation and entropy: ➢ Firmitas (Strength) – the system is reliable, secure, has good performance and easy to support ➢ Utilitas (Utility) – the system is usable, meets business business needs and add business value every day instead of drifting into technology trenches ➢ Venustas (Beauty) – code and system structure are clean, easy to understand, minimal
  • 91. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 30 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 30 Successfull architects … in addition to Frederick P. Brooks (cont.): ✔ Encourages constant improving of the code design, enhancing system abstractions and structure, removing duplication, defining boundaries and interfaces of the subsystems. ✔ Keeps solutions as simple as possible, maintains intellectual control over system and avoids over-engineering. ✔ Most important – grows and coaches other developers to become architects
  • 92. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 31 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 31 Module The Architectural Process
  • 93. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 32 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 32 Architectual process An overview As an architect you might follow/obey the following: ✔ Gather information ✔ Develop an idea about the system ✔ Identify drivers and boundary conditions ✔ Identify the risks ✔ Define the quality ✔ Develop strategies
  • 94. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 33 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 33 Architectual process Gather information ✔ How did others before? Only very few things are build completely new, try to find similar solutions. ✔ Scan for patterns ✔ Use your experience as the customer expects profound knowledge technically as well as within the domain ✔ In most of the cases, wide parts of existing solutions can be reused.
  • 95. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 34 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 34 Architectual process Develop an idea about the system Some of the most important aspects of the system should be known: ✔ What is the purpose of the system ✔ Who uses the system and how is the system used ✔ What kind of user interface will be used ✔ Where are interfaces to other systems ✔ How to use / store data ✔ How to administer the system ✔ What about printing, reporting, etc.
  • 96. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 35 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 35 Architectual process Identify drivers and boundary conditions Software architecture isn't dealing with technologies alone, a lot of other things have some influence on the architecture ✔ Organisational aspects ✔ Resources ✔ Existing standards ✔ Rules and regulation
  • 97. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 36 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 36 Architectual process Identify the risks There will be no single project where everything goes as expected, an architect has to know about the risks and has to deal with them. ✔ Organisational risks Lack of time, budget, knowledge ✔ Performance … matters, no doubt about that ✔ Maintainability and flexibility … design for changes with respect to performance ✔ Availability
  • 98. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 37 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 37 Architectual process Define the quality ✔ Quality can't be measured directly as only specific features can be measured (e.g. resource efficiency) ✔ Different stakeholders have different ideas of quality: ➢ Management: cost efficency, flexibility, maintainability ➢ Users: performance, usability ➢ Ops: administrability, security ✔ Architecture is prerequisite for quality but not a guarantee (maybe poorly implemented), excellent code does not imply good architecture.
  • 99. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 38 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 38 Architectual process Define the quality ✔ Quality of software systems is alway in relation to characteristics, e.g. performance, availability, interoperability, usability, … (@see DIN/ISO 9126) ✔ Quality attribute scenarios capture non-functional requirements of a system in terms of standard quality attributes, such as Availability, Modifiability, and so on. ✔ These are independent of specific functional requirements and describe desired qualities of a system. www.swenet.org/materials/127/quality%20attribute%20scenarios.doc ● Availability is concerned with system failure and duration of system failures. System failure means … when the system does not provide the service for which it was intended. ● Modifiability is about the cost of change, both in time and money. ● Performance is about time. Events occur and the system must respond in a timely fashion. ● Security is the ability of the system to prevent or resist unauthorized access while providing access to legitimate users. An attack is an attempt to breach security. ● Testability refers to the ease with which the software can be made to demonstrate its faults or lack thereof. To be testable the system must control inputs and be able to observe outputs. ● Usability is how easy it is for the user to accomplish tasks and what support the system provides for the user to accomplish this. Dimensions: Learning system features Using the system efficiently Minimizing the impact of errors Adapting the system to the user’s needs Increasing confidence and satisfaction From wikipedia: ISO/IEC 9126 Software engineering — Product quality is an international standard for the evaluation of software quality. The fundamental objective of this standard is to address some of the well known human biases that can adversely affect the delivery and perception of a software development project. These biases include changing priorities after the start of a project or not having any clear definitions of "success." By clarifying, then agreeing on the project priorities and subsequently converting abstract priorities (compliance) to measurable values (output data can be validated against schema X with zero intervention), ISO/IEC 9126 tries to develop a common understanding of the project's objectives and goals.
  • 100. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 39 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 39 Quality attribute scenarios ✔ Statements like “a system will have high performance” or “a system will be user friendly” are acceptable in the really early stages of requirements elicitation process. ✔ As more information becomes available, the above statements become useless as they are meaningless for the purpose of actually designing a solution. ✔ Both statements are useless as they provide no tangible way of measuring the behavior of the system. ✔ Writing detailed statements is only possible when relevant requirements have been identified and an idea of components has been proposed. http://www.softwarearchitectures.com/go/Discipline/DesigningArchitecture/QualityAtt ributes/tabid/64/Default.aspx
  • 101. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 40 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 40 Quality attribute scenarios ✔ The quality attributes must be described in terms of scenarios, such as “when 100 users initiate ‘complete payment’ transition, the payment component, under normal circumstances, will process the requests with an average latency of three seconds.” ✔ These kind of statements, or scenarios, allows an architect to make quantifiable arguments about a system. ✔ A scenario defines: ➢ the source of stimulus (users), ➢ the actual stimulus (initiate transaction), ➢ the artifact affected (payment component), ➢ the environment in which it exists (normal operation), ➢ the effect of the action (transaction processed), ➢ and the response measure (within three seconds)
  • 102. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 41 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 41 Architectual process Develop strategies ✔ against lack of resources and be aware of: ➢ No one performs better if put under pressure ➢ Putting more members of a project team might cause a bigger delay ➢ If management does not back the project it will never become a success ✔ towards increased performance ➢ Use profilers even at the early stages ➢ Hardware is cheaper than redesign ➢ Decrease abstraction ➢ ...
  • 103. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 42 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 42 Architectual process Develop strategies ✔ covering adaptability and flexibility ➢ Figure out, where it is needed (functionality, data model, 3rd party software, user interface, operating system, ...) ➢ Almost every time in contrast to performance ➢ What-if scenarios might be helpful
  • 104. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 43 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 43 Module Introduction to Patterns Each pattern describes a problem which occurs over and over again in our environment, and then describes the core of the solution to that problem, in such a way that you can use this solution a million times over, without ever doing it the same way twice. --- Christopher Alexander
  • 105. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 44 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 44 Design, Architecture and … Patterns Design is a challenging task: ➢ Balancing concerns, e.g. performance, adaptability, reliability. ➢ Defining components and their interrelationships. Thus experienced designers: ➢ Rarely start from first principles ➢ Look for similarities to problems solved in the past. ➢ Apply a working "handbook" of approaches Patterns make expert knowledge widely available ➢ Supports focusing on the truly distinctive design problems. ➢ Aids design evaluation at higher level of abstraction ➢ Provides a useful working vocabulary for design.
  • 106. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 45 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 45 What is it about ? A Pattern: ✔ ... solves a real problem, reuse of solutions already designed. ✔ ... faculitates sharing of knowledge. ✔ ... forms a vocabulary for communication between software architects. ✔ ... limits possible solutions to best practices. Design Patterns describe simple but sophisticated solutions for specific problems arising in the process of designing object oriented applications; they describe solutions tested in practice. Design Patterns are no libraries, functions, they are language agnostic by definition; they could be used in any programming language like Java, Smalltalk, C++ or C#. Definition (taken from wikipedia) In software engineering, a design pattern is a general solution to a common problem in software design. A design pattern isn't a finished design that can be transformed directly into code, it is a description or template for how to solve a problem that can be used in many different situations. Object-oriented design patterns typically show relationships and interactions between classes or objects, without specifying the exact classes or objects that are involved. Design patterns can speed up the development process by providing tested, proven development paradigms. Effective software design requires considering issues that may not become visible until later in the implementation. Reusing design patterns helps to prevent subtle issues that can cause major problems. Often, people only understand how to apply certain software design techniques to certain problems. These techniques are difficult to apply to a broader range of problems. Design patterns provide general solutions, documented in a format that doesn't require specifics tied to a particular problem. Patterns allow developers to communicate using well-known, well understood names for software interactions. Common design patterns can be improved over time, making them likely to perform better than ad-hoc designs.
  • 107. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 46 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 46 Types of pattern Architectural Patterns: ✔ expresses a fundamental structural organization or schema for software systems. ✔ provides a set of predefined subsystems, specifies their responsibilities, and includes rules and guidelines for organizing the relationships between them. Design Patterns: ✔ a scheme for refining the subsystems or components of a software system, or the relationships between them. ✔ describes commonly recurring structure of communicating components that solves a general design problem within a particular context.
  • 108. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 47 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 47 Types of pattern Idioms: ✔ low-level pattern specific to a programming language. ✔ An idiom describes how to implement particular aspects of components or the relationships between them using the features of the given language.
  • 109. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 48 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 48 History of ... Overview: ✔ 1977: Christopher Alexander developed at Center For Environmental Structure at Berkeley a theory of using patterns within architecture. ✔ 1991: Erich Gamma wrote his Ph.D. dissertation about the usage of patterns within software developments – only recognized withing germany. ✔ 1995: Inspired by Alexander Ward Cunningham and Kent Beck introduced the first five patterns for design of user interfaces. ✔ 1996: The book of the so-called „Gang-Of-Four“ sets the pace to broad acceptance of patterns within Software-Engineering.
  • 110. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 49 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 49 Patterns everywhere? ✔ Gang of Four Pattern: Erich Gamma, Richard Helm, Ralph Johnson and John Vlissides ✔ POSA 1 Pattern: Pattern oriented software architecture (Frank Buschmann et. al.) ✔ Core J2EE Pattern: Alur, Cupri, Malks ✔ Patterns of Enterprise Application Architecture: Martin Fowler et. al. ✔ Enterprise Integration Patterns: Hophe, Woolf et. al. ✔ Workflow Pattern: van der Aalst et. al. ✔ SOA Design Pattern: Thomas Erl ✔ SOA Pattern: Presentation of Michael Stal
  • 111. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 50 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 50 Why using Patterns? Pattern: ✔ ... are explicitly based on fundamental priciples of constructing robust applications like information hiding or loose coupling. ✔ ... adress the importance of non-functional aspects like maintainability or reliability. ✔ ... complement problem-centric methods to develop software by guidelines to design. ✔ ... support analysis and design. ● Architectural Pattern ● expresses a fundamental structural organization or schema for software systems. ● provides a set of predefined subsystems, specifies their responsibilities, and includes rules and guidelines for organizing the relationships between them. ● Design Pattern ● provides a scheme for refining the subsystems or components of a software system, or the relationships between them. ● describes commonly recurring structure of communicating components that solves a general design problem within a particular context. ● Idiom ● low-level pattern specific to a programming language. ● describes how to implement particular aspects of components or the relationships between them using the features of the given language.
  • 112. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 51 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 51 Keys to Using Patterns Effectively ✔ Recognition comes with experience ✔ Searching is aided by a catalog taxonomy ✔ Recognize, search, instantiate: ➢ Recognize a problem as common (déjà vu). ➢ Recognize the key elements of the problem. ➢ Search a pattern catalog from proven solution templates. ➢ Instantiate the template for the specific problem. ➢ Algorithm and data structure selection.
  • 113. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 52 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 52 Patterns, the silver bullet ? Pattern: ✔ ... If used wrong might make systems more complex than needed. ✔ ... if used wrong might cause problems by themselves. ✔ ... shouldn‘t be used for the sake of themselves „As a rule of thumb, the value of a method is inversely proportional to it‘s universality. “ --- Michael A. Jackson 1995
  • 114. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 53 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 53 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Name: ➢ A good, descriptive name is critical. ➢ Good names communicate. ➢ Poor names obfuscate. ➢ Goal: Increase design vocabulary. ➢ Goal: Raise level of design discussion. ✔ Problem: ➢ Brief, abstract description. ➢ Includes design context.
  • 115. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 54 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 54 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Solution: ➢ Components (classes/objects) and interconnections. ➢ Generic control and data flow supported by the pattern. ➢ Template, not a cookbook. ✔ Consequences & Tradeoffs: ➢ Positive results. ➢ Negative implications. ➢ Tradeoffs: time, space, flexibility, performance, etc.
  • 116. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 55 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 55 Pattern taxonomy/catalogues … or: How to describe and order them? ✔ Implementation issues: ➢ Effects of language (i.e., Java vs. C++). ➢ Alternative tactical approaches.
  • 117. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 56 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 56 Pattern and Frameworks What is a framework ✔ A set of reusable designs and objects used to build applications ✔ Defines how objects work together to get something done ✔ Defines the superclasses or public interface for the object that you develop ✔ Your objects work within the framework ✔ A framework is a "semi-complete" application
  • 118. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 57 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 57 Pattern and Frameworks What is a framework ✔ A framework usually supports a very specific domain ➢ GUI (large) ➢ Collections (small) ✔ Usual characteristics of a good framework ➢ Relatively easy to understand and use ➢ Provides a solution to a common problem ➢ Can be used over and over again
  • 119. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 58 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 58 Pattern and Frameworks Benefits of OO application frameworks: ✔ Modularity: ➢ enhance modularity by encapsulating volatile implementation details behind stable interfaces ➢ reduces the effort required to understand and maintain existing software. ✔ Reusability ➢ stable interfaces define generic components that can be reapplied to create new applications. ➢ avoid re-creating and re-validating common solutions to recurring application requirements and software design challenges.
  • 120. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 59 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 59 Pattern and Frameworks Benefits of OO application frameworks (contd.): ✔ Extensibility ➢ providing explicit hook methods that allow applications to extend its stable interfaces. ➢ decouple the stable interfaces and behaviors of an application domain from the variations required by instantiations of an application in a particular context. ✔ Inversion of control ➢ allows the framework (rather than each application) to determine which set of application-specific methods to invoke in response to external events
  • 121. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 60 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 60 Pattern and Frameworks Conclusion: ✔ Patterns: ➢ focus on reuse of abstract designs and software micro-architectures. ➢ an be viewed as more abstract micro-architectural elements of frameworks ➢ document and motivate the semantics of frameworks in an effective way ✔ Frameworks: ➢ concrete reification of families of design patterns that are targeted for a particular application-domain. ➢ represent recurring solutions to software development problems within a particular context. Patterns and frameworks both facilitate reuse by capturing successful software development strategies.
  • 122. Copyright by Brockhaus AG - Brockhaus GmbH © 2009 - 61 Copyright by Brockhaus GmbH, alle Rechte reserviert, unautorisierte Vervielfältigung untersagt 61 Review Session Review: ✔ What is the role of a software architect? ✔ Do software architects implement code by themselfes? ✔ How to get an idea of the software architecture within you projects? ✔ What about pattern?