Download presentation
Presentation is loading. Please wait.
Published byElla Cox Modified over 8 years ago
1
Copyright © Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy. All rights reserved. Software Connectors Software Architecture Lecture 7
2
Software Architecture: Foundations, Theory, and Practice What is a Software Connector? Architectural element that models u Interactions among components u Rules that govern those interactions Simple interactions u Procedure calls u Shared variable access Complex & semantically rich interactions u Client-server protocols u Database access protocols u Asynchronous event multicast Each connector provides u Interaction duct(s) u Transfer of control and/or data 2
3
Software Architecture: Foundations, Theory, and Practice Where are Connectors in Software Systems? 3 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
4
Software Architecture: Foundations, Theory, and Practice Implemented vs. Conceptual Connectors Connectors in software system implementations u Frequently no dedicated code u Frequently no identity u Typically do not correspond to compilation units u Distributed implementation Across multiple modules Across interaction mechanisms 4
5
Software Architecture: Foundations, Theory, and Practice Implemented vs. Conceptual Connectors (cont’d) Connectors in software architectures u First-class entities u Have identity u Describe all system interaction u Entitled to their own specifications & abstractions 5
6
Software Architecture: Foundations, Theory, and Practice Reasons for Treating Connectors Independently Connector Component u Components provide application-specific functionality u Connectors provide application-independent interaction mechanisms Interaction abstraction and/or parameterization Specification of complex interactions u Binary vs. N-ary u Asymmetric vs. Symmetric u Interaction protocols 6
7
Software Architecture: Foundations, Theory, and Practice Treating Connectors Independently (cont’d) Localization of interaction definition Extra-component system (interaction) information Component independence Component interaction flexibility 7
8
Software Architecture: Foundations, Theory, and Practice Benefits of First-Class Connectors Separate computation from interaction Minimize component interdependencies Support software evolution u At component-, connector-, & system-level Potential for supporting dynamism Facilitate heterogeneity Become points of distribution Aid system analysis & testing 8
9
Software Architecture: Foundations, Theory, and Practice An Example of Explicit Connectors 9 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
10
Software Architecture: Foundations, Theory, and Practice An Example of Explicit Connectors (cont’d) 10 ? Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
11
Software Architecture: Foundations, Theory, and Practice Software Connector Roles Locus of interaction among set of components Protocol specification (sometimes implicit) that defines its properties u Types of interfaces it is able to mediate u Assurances about interaction properties u Rules about interaction ordering u Interaction commitments (e.g., performance) Roles u Communication u Coordination u Conversion u Facilitation 11
12
Software Architecture: Foundations, Theory, and Practice Connectors as Communicators Main role associated with connectors Supports u Different communication mechanisms e.g. procedure call, RPC, shared data access, message passing u Constraints on communication structure/direction e.g. pipes u Constraints on quality of service e.g. persistence Separates communication from computation May influence non-functional system characteristics u e.g. performance, scalability, security 12
13
Software Architecture: Foundations, Theory, and Practice Connectors as Coordinators Determine computation control Control delivery of data Separates control from computation Orthogonal to communication, conversion, and facilitation u Elements of control are in communication, conversion and facilitation 13
14
Software Architecture: Foundations, Theory, and Practice Connectors as Converters Enable interaction of independently developed, mismatched components Mismatches based on interaction u Type u Number u Frequency u Order Examples of converters u Adaptors u Wrappers 14
15
Software Architecture: Foundations, Theory, and Practice Connectors as Facilitators Enable interaction of components intended to interoperate u Mediate and streamline interaction Govern access to shared information Ensure proper performance profiles u e.g., load balancing Provide synchronization mechanisms u Critical sections u Monitors 15
16
Software Architecture: Foundations, Theory, and Practice Connector Types Procedure call Data access Event Stream Linkage Distributor Arbitrator Adaptor 16
17
Software Architecture: Foundations, Theory, and Practice A Framework for Classifying Connectors 17 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
18
Software Architecture: Foundations, Theory, and Practice Procedure Call Connectors 18 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
19
Software Architecture: Foundations, Theory, and Practice Event Connectors 19 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
20
Software Architecture: Foundations, Theory, and Practice Data Access Connectors 20 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
21
Software Architecture: Foundations, Theory, and Practice Linkage Connectors 21 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
22
Software Architecture: Foundations, Theory, and Practice Stream Connectors 22 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
23
Software Architecture: Foundations, Theory, and Practice Arbitrator Connectors 23 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
24
Software Architecture: Foundations, Theory, and Practice Adaptor Connectors 24 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
25
Software Architecture: Foundations, Theory, and Practice Distributor Connectors 25 Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
26
Software Architecture: Foundations, Theory, and Practice How Does One Select a Connector? Determine a system’s interconnection and interaction needs u Software interconnection models can help Determine roles to be fulfilled by the system’s connectors u Communication, coordination, conversion, facilitation For each connector u Determine its appropriate type(s) u Determine its dimensions of interest u Select appropriate values for each dimension For multi-type, i.e., composite connectors u Determine the atomic connector compatibilities 26
27
Software Architecture: Foundations, Theory, and Practice Simple Example System components will execute in two processes on the same host u Mostly intra-process u Occasionally inter-process The interaction among the components is synchronous The components are primarily computation-intensive u There are some data storage needs, but those are secondary 27
28
Software Architecture: Foundations, Theory, and Practice Simple Example (cont’d) Select procedure call connectors for intra-process interaction Combine procedure call connectors with distributor connectors for inter-process interaction RPC Select the values for the different connector dimensions What are the appropriate values? What values are imposed by your favorite programming language(s)? 28
29
Software Architecture: Foundations, Theory, and Practice Two Connector Types in Tandem 29 Select the appropriate values for PC and RPC! Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
30
Software Architecture: Foundations, Theory, and Practice Software Interconnection Models Interconnection models (IM) as defined by Perry u Unit interconnection u Syntactic interconnection u Semantic interconnection All three are present in each system Are all equally appropriate at architectural level? 30
31
Software Architecture: Foundations, Theory, and Practice Unit Interconnection Defines relations between system’s units u Units are components (modules or files) u Basic unit relationship is dependency Unit-IM = ({units},{“depends on”}) Examples u Determining context of compilation e.g., C preprocessor IM = ({files},{“include”}) u Determining recompilation strategies e.g., Make facility IM = ({compile_units},{“depends on”,“has changed”}) u System modeling e.g., RCS, DVS, SVS, SCCS IM = ({systems, files},{“is composed of”}) 31
32
Software Architecture: Foundations, Theory, and Practice Syntactic Interconnection Describes relations among syntactic elements of programming languages u Variable definition/use u Method definition/invocation IM = ({methods, types, variables, locations}, {“is def at”, “is set at”, “is used at”, “is del from”, “is changed to”, “is added to”}) Examples u Automated software change management e.g., Interlisp’s masterscope u Static analysis e.g., Detection of unreachable code by compilers u Smart recompilation Changes inside unit recompilation of only the changes u System modeling Finer level of granularity than unit-IM 32
33
Software Architecture: Foundations, Theory, and Practice Semantic Interconnection Expresses how system components are meant to be used u Component designers’ intentions Captures how system components are actually used u Component users’ (i.e., system builders’) intention Interconnection semantics can be formally specified u Pre- & post-conditions u Dynamic interaction protocols (e.g. CSP, FSM) IM = ({methods, types, variables,..., predicates}, {“is set at”, “is used at”, “calls”, “called by”,..., “satisfies”}) 33
34
Software Architecture: Foundations, Theory, and Practice Composing Basic Connectors In many systems a connector of multiple types may be required to service (a subset of) the components All connectors cannot be composed u Some are naturally interoperable u Some are incompatible u All are likely to require trade-offs The composition can be considered at the level of connector type dimensions and subdimensions 34
35
Software Architecture: Foundations, Theory, and Practice Well Known Composite Connectors Grid connectors (e.g., Globus) u Procedure call u Data access u Stream u Distributor Peer-to-peer connectors (e.g., Bittorrent) u Arbitrator u Data access u Stream u Distributor Client-server connectors Event-based connectors 35
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.