Presentation is loading. Please wait.

Presentation is loading. Please wait.

Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 1 Informatics 43 Introduction to Software Engineering.

Similar presentations


Presentation on theme: "Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 1 Informatics 43 Introduction to Software Engineering."— Presentation transcript:

1 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 1 Informatics 43 Introduction to Software Engineering Lecture 4-2 October 22, 2015 Emily Navarro Duplication of course material for any commercial purpose without the explicit written permission of the professor is prohibited.

2 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 2 Today’s lecture Software architecture - recap Architectural styles Evolution Study guide for quiz 3 Some slides adopted and adopted from “Software Architecture: Foundations, Theory, & Practice” by Taylor, Medvidovic, and Dashofy

3 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 3 Today’s lecture Software architecture - recap Architectural styles Evolution Study guide for quiz 3

4 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 4 Defining software architecture A software system’s architecture is the set of principal design decisions about the system Design decisions Architectural decisions “Principal” Structure Behavior Interaction Non-functional properties

5 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 5 Defining software architecture Software architecture is the blueprint for a software system’s construction and evolution

6 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 6 Other definitions Clements, Bass, Kazman: The set of structures needed to reason about the system, which comprise software elements, relations among them, and properties of both. Spinellis: how your whole system (in the widest possible sense) will be decomposed into processes or services; how data are stored, communicated, and processed; and how all parts fit together to deliver the required functionality, reliability, capacity, scalability, maintainability, and portability.

7 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 7 Other definitions Fowler: The highest-level breakdown of a system into its parts; the decisions that are hard to change Natarén: The clear definition of multiple high-level components that, when working together, form your system and solve your problem

8 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 8 Example configuration ship course ship radar GPS unit function call component connector

9 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 9 Example configuration - simplified ship course ship radarGPS unit component connector

10 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 10 Prescriptive versus descriptive architecture A system’s prescriptive architecture captures the design decisions made prior to the system’s construction – it is the as-designed or as-intended architecture A system’s descriptive architecture describes how the system has been built – it is the as-implemented or as-realized architecture – as recovered from its implementation-level artifacts (e.g., source code, executable files, Java.class files, …)

11 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 11 Linux – prescriptive architecture

12 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 12 Linux – descriptive architecture

13 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 13 iRODS – prescriptive architecture

14 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 14 iRODS – descriptive architecture

15 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 15 HADOOP – prescriptive architecture

16 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 16 HADOOP – descriptive architecture

17 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 17 Gap A gap remains between the prescriptive architecture, which concerns decisions, and the descriptive architecture, which concerns programmatic elements

18 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 18 Architectural evolution When a system evolves, ideally its prescriptive architecture is modified first In practice, the system – and thus its descriptive architecture – is often directly modified This happens because of – developer sloppiness – perception of short deadlines which prevent thinking through and documenting – lack of documented prescriptive architecture – need or desire for code optimizations – inadequate techniques or tool support

19 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 19 Today’s lecture Software architecture - recap Architectural styles Evolution Study guide for quiz 3

20 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 20 Architectural style Certain design choices regularly result in solutions with superior properties – elegant, effective, efficient, dependable, evolvable, scalable… An architectural style is – a named collection of architectural design decisions that are applicable in a given development context constrain architectural design decisions result in beneficial qualities in each resulting system – a named, commonly used set of components/connectors/configurations Each component/connector has its own job

21 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 21 Architectural style Contemporary: Arts and Crafts:

22 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 22 Architectural style? Classical: Rock and Roll:

23 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 23 Style 1: object-oriented ship course ship radar GPS unit function call component connector

24 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 24 Style 1: object-oriented (simplified) ship course ship radarGPS unit component connector

25 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 25 Style 1: object-oriented Components are objects – Containing all the data and behavior relevant to the object Connectors are messages and function calls Key benefits – Objects expose a certain interface to other objects Abstraction – An object’s internal representation is hidden from other objects Anticipation of change – Objects in software are used to model real-world objects Understandability Examples – Business applications

26 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 26 Style 2: model-view-controller ATM display rules back account

27 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 27 Style 2: model-view-controller ATM display rules back account model controller view

28 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 28 Style 2: model-view-controller Components are models, views, and controllers Models store information about the state of the program View components present information to the user Controllers allow user to control model/view and tell models (views) to update

29 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 29 Style 2: model-view-controller Components are models, views, and controllers Models store information about the state of the program View components present information to the user Controllers allow user to control model/view and tell models (views) to update User interface

30 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 30 Style 2: model-view-controller Key benefits: – Decouples model and view – one model can support multiple views – Decouples view and controller – can change the way a view responds to user input – Modularity, anticipation of change Examples – Websites – Web applications

31 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 31 Style 3: client-server game client 2 game server remote call game client 1game client 3

32 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 32 Style 3: client-server (simplified) game client 2 game server game client 1game client 3

33 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 33 Style 3: client-server Components are clients and servers A server has computational resources that it provides to one or more clients Clients make requests of servers Generally used in distributed systems

34 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 34 Style 3: client-server Key benefits – Centralized security – Centralized data access and management Examples – email – Web browser-based programs

35 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 35 Style 4: layered

36 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 36 Style 4: layered Components are organized in hierarchical layers Connectors are protocols of layer interaction “Multi-level client server:” each layer acts as a – Service: service provider to layers “above” – Client: service consumer of layer(s) “below” Key benefits – Increasing abstraction levels – Changes in a layer affect at most the adjacent two layers Anticipation of change – Lower layers are easily reusable Examples – Operating systems – Networks

37 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 37 Style 4: layered example Consider a supplier of tennis balls. It has several departments (in no particular order): Rolling: forms tennis balls from green ooze Assembly: puts balls into canisters Receiving: accepts shipments of canisters from Acme Canister Co. Packaging: packs filled canisters into cardboard boxes Inventory: stores parts

38 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 38 Style 4: layered example The tennis ball supplier’s organization can be viewed as having a layered architecture: TOP: Packaging: packs filled canisters into cardboard boxes Assembly: puts balls into canisters Inventory: stores parts BOTTOM – Receiving: accepts shipments of canisters from Acme Canister Co. – Rolling: forms tennis balls from green ooze

39 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 39 Style 5: peer-to-peer skype 1 skype 3skype 2 stream

40 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 40 Style 5: peer-to-peer (simplified) skype 1 skype 3skype 2

41 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 41 Style 4: peer-to-peer Components (“peers”) are equals and can act as either clients or servers – Data and behavior are distributed among peers Connectors are network protocols Key benefits – Highly robust in the face of failure of any given node Examples – File sharing systems, Skype

42 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 42 Style 6: pipe-and-filter print records stream sort stream remove duplicates

43 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 43 Style 6: pipe-and-filter Components are filters – Transform input data streams into output data streams Connectors are pipes – Conduits for data streams Key benefits – Easy filter addition, replacement, and reuse Possible to hook any two filters together Examples – UNIX shell ls invoices | grep -e August | sort

44 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 44 Style 7: publish-subscribe (“pub-sub”) stock market remote call stream remote call trader 1trader 2trader 3

45 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 45 Style 7: pub-sub Components are publishers or subscribers – Subscribers register/deregister to receive specific messages/content – Publishers broadcast messages to subscribers Connectors are network protocols Key benefits – Efficient one-way dissemination of information – Scalability Examples – Stock market – News

46 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 46 Mixing styles is often necessary stock market server remote call stream remote call trader 1trader 2trader 3 procedure call purchasing rules stock database

47 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 47 Today’s lecture Software architecture - recap Architectural styles Evolution Study guide for quiz 3

48 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 48 Every successful software evolves http://www.youtube.com/watch?v=Nl7igMfeOvo https://www.youtube.com/watch?v=zl15BOtX5Pw http://info.cern.ch/hypertext/WWW/TheProject.html

49 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 49 Every successful software evolves

50 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 50 Every successful software evolves 2005 2007 2011 2012 2014

51 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 51 Airplane cockpit (Boeing 787) From: http://www.boeing.com/commercial/aeromagazine/articles/2012_q1/3/

52 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 52 Airplane cockpit (Boeing 787)

53 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 53 Airline cockpit (Boeing 747)

54 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 54 Airline cockpit (Boeing 747)

55 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 55 Angry Birds

56 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 56 Super Mario https://www.youtube.com/watch?v=JWvc-7suhvs

57 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 57 Evolution Essential part of software development Must be accommodated as much as possible Must be planned as much as possible

58 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 58 Evolution Essential part of software development Must be accommodated as much as possible Must be planned as much as possible Architecture is a key tool in accommodating evolution

59 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 59 Accommodating change ATM display procedure call rules back account New overdraft rule?

60 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 60 Accommodating change skype 1 skype 3skype 2 stream Another user?

61 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 61 Accommodating change? list records stream sort stream remove duplicates Only records names starting with a letter from the first half of the alphabet?

62 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 62 Accommodating change stock market server remote call stream remote call trader 1trader 2trader 3 procedure call purchasing rules stock database Another trader?

63 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 63 Accommodating change More users?

64 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 64 Accommodating change

65 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 65 Back to architectural evolution When a system evolves, ideally its prescriptive architecture is modified first In practice, the system – and thus its descriptive architecture – is often directly modified This happens because of – developer sloppiness – perception of short deadlines which prevent thinking through and documenting – lack of documented prescriptive architecture – need or desire for code optimizations – inadequate techniques or tool support

66 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 66 Today’s lecture Architectural styles Evolution Study guide for quiz 3

67 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 67 Quiz 3: software architecture Lectures: – Understand what software architecture is – Elements of software architecture – Prescriptive vs. descriptive architectures – Software/architectural evolution – What an architectural style is – The basics of the seven styles presented today Readings – Architectural styles: only those presented in lecture – Architectural views

68 Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 68 Next time Designs, Models, Notations Quiz 3 Homework 1 due tonight 11:55pm – Submit as a Word doc! – Use format given in template and include scoring sheet!! – If you submit late, your homework will not be accepted


Download ppt "Department of Informatics, UC Irvine SDCL Collaboration Laboratory Software Design and sdcl.ics.uci.edu 1 Informatics 43 Introduction to Software Engineering."

Similar presentations


Ads by Google