41
Lecture 08 Architecture Considerations

L08 architecture considerations

Embed Size (px)

DESCRIPTION

Hönnun hugbúnaðar er sjaldan þannig að maður getur valið hvað sem maður vill. Oftar en ekki höfum við ekki aðeins kröfur um hvað forritið á að gera, heldur einnig hvernig það gerir það. Má nefna gæðakröfur, hraða, skalanleika og allskyns non-functional kröfur. Einnig geta verið kröfur um tungumál og aðllögun að ólíkum löndum. Erfitt getur verið að fá þessar kröfur upp úr þeim sem eru að óska eftir hugbúnaðnum séum við að skrifa hann fyrir aðra. Hugbúnaður hefur einnig takmarkanir eins og hvaða tækni má nota, hvaða staðla og annað sem þegar er ákveðið. Þar fyrir utan eru takmarkanir sem stafa af þróunarteymum og fleirl. Í þessum fyrirlestri ætlum við að líta á þá þætti sem þarf að huga að þegar verið er að hanna hugbúnað og ætti að negla niður áður en farið er að útfæra.

Citation preview

Page 1: L08 architecture considerations

Lecture 08Architecture Considerations

Page 2: L08 architecture considerations

Agenda Goals Architecture Drivers Non-functional Requirements Constraints Principles

Page 3: L08 architecture considerations

Reading Brown: III Designing software– Chapters 21-25 (both included)

Page 4: L08 architecture considerations

Goals of an Enterprise Architecture Be robust Be performing and scalable Take advantage of OO design principles Avoid unnecessary complexity Be maintainable and extensible Be easy to test Promote reuse

Page 5: L08 architecture considerations

Requirement Considerations Goals based on business requirements– Support for multiple client types– Portability

Support for multiple client types– Does we need to support different client types?– Do we need abstraction layer?

Portability– Does the application need to be independent of

a particular middleware, like databases?– Do we need abstraction layer?

Page 6: L08 architecture considerations

ARCHITECTUREDRIVERS

Page 7: L08 architecture considerations

Architectural Drivers Functional Requirements Quality Attributes Constraints Principles

Page 8: L08 architecture considerations

Architectural Drivers We must understand these drivers at a

high-level– Creativity can come from constraints

Clear VISION– Architecture is about STRUCTURE and VISION– Must be communicated

Will help in the decision process– When faced with a decision, the vision will tell

you

Page 9: L08 architecture considerations

Quality Attributes Requirements are easy to understand– People can (mostly) explain the features they

want It’s the non-functional requirements that

are more tricky– The “ilites”

Page 10: L08 architecture considerations

Performance Performance is about how fast something

is– This must always be a consideration

Applies on multiple levels:– Hardware specification– Network setup and security– Architecture of the software– The programming of the software– Protocols used– Middleware and containers

Page 11: L08 architecture considerations

Performance Response Time is the amount of time for

the system to process a request from the outside

server processing…client request

network

response

The user waits until the transactionis done

Page 12: L08 architecture considerations

Performance Responsiveness is how quickly the

system acknowledges a request as opposed to processing it

server processing…client request

network

responsewaiting…

The user sees that the system isdoing something

Page 13: L08 architecture considerations

Performance Latency is the minimum time required to

get any form of response, even if the work to be done is nonexistent

nothing…client request

network

response

The overhead of the request andnetwork transfer

Page 14: L08 architecture considerations

Performance Throughput is how much stuff you can

do in a given amount of time

t1 t2time

records processed…

Page 15: L08 architecture considerations

Performance Load is a statement of how much stress a

system is under

Page 16: L08 architecture considerations

Performance Load sensitivity is an expression of how

the response time varies with the load

Page 17: L08 architecture considerations

Performance Efficiency is a performance divided by

resources Capacity of a system is an indication of

maximum effective load

Page 18: L08 architecture considerations

Scalability The measure of how adding a resource

affects the performance– Vertical: Make the hardware faster, more

memory etc– Horizontal: Get more hardware – scaling out

How many concurrent transaction can the system handle– Request per second or per minute

Page 19: L08 architecture considerations

Availability The degree to which your software is

operational– Measured in terms of “nines”– 99.99% per year - four nines, uptime in terms

of percent Usually specified in Service Level

Agreements (SLA) 99.99% is downtime:– Daily: 8.6s– Weekly: 1m 0.5s– Monthly: 4m 23.0s– Yearly: 52m 35.7s

Page 20: L08 architecture considerations

Security Overall all security issues are vital– Authentication and authorization– Hardware access restrictions on network levels– Firewalls– Open Web Application Security Project

(OWASP)– Security Roles for people– Securing sensitive information, for example

encrypting data

Page 21: L08 architecture considerations

Disaster Recovery Response to failures– Disk crash, faulty network card etc– Network downtime

External disaster – force major– Fires, earthquake

Business Continuity Plan– Specifies how a business can recover from

disasters

Page 22: L08 architecture considerations

Monitoring Infrastructure to track activities in the

system– Hardware capacity, such as disk space,

memory, CPU load– System transactions

Monitoring software– SNMP standard– Viewing tools

Page 23: L08 architecture considerations

Auditing Traceability of what happens in the system– Logging of events– Software to track changes

Some software must allow for external auditing– All transactions are logged– All changes to record data is logged– Any event can be viewed

Page 24: L08 architecture considerations

Software Requirements Flexibility– The ability for non-technical people to modify

business rules within the system Extensibility– The ability to extend and modify software for

new needs Maintainability– Think about the cost of running software over

some time

Page 25: L08 architecture considerations

Other Requirements Legal, regulatory and compliance– Laws that regulate industries

Internationalization (i18n)– What languages must be supported

Localization (L10n)– Does the software need to be adapted to local

cultures

Page 26: L08 architecture considerations

NON-FUNCTIONALREQUIREMENTS

Page 27: L08 architecture considerations

Non-Functional Requirements The challenge is to capture the non-

functional requirement Instead of asking how much availability (-

ability) ask specific questions– “How much downtime can you tolerate?”– “How many users are there max?”– “How much do you expect to sell?”

Page 28: L08 architecture considerations

Non-Functional Requirements Categorize non-functional requirements– Sometimes the best solution is really not what

is needed– Sometimes features are not required to begin

with Use MoSCoW– Must, Should, Could, Wont

Page 29: L08 architecture considerations

CONSTRANTS

Page 30: L08 architecture considerations

Constraints Time and budget constraints– There is always a deadline

Technology constraints– Approved technology – Technology Stack

Existing System and Interoperability– Middleware or standards used

Target Deployment Platform– Must run in Windows or Linux

Page 31: L08 architecture considerations

Constraints Technology Maturity– Established middleware or bleeding edge

Open Source– Use of proprietary software or open source

Vendor Relationship– Firms make partnerships with technical

vendors Past Failures– We tried this technology and it did not work

and we don’t want it

Page 32: L08 architecture considerations

Constraints Internal Intellectual Property– Developed in house and must be used

Corporate Policies– Reports, memos, approvals

Consultants– Have all the answers, of course

Page 33: L08 architecture considerations

People Constraints People set constrains– Size of Teams – Two Pizza Teams are common– Skillset and combination of skills– Hiring and training of new employee –

scalability – Who can work with whom – social status

problems

Page 34: L08 architecture considerations

Organization Constraints Politics– Obstacles, people protecting their turf

Strategic software or tactical– Affect priority and resource allocations

Communications paths– Conway’s Law

Access to support– Are you important enough?

Page 35: L08 architecture considerations

Risk Management All projects have risks– Track risk by two metrics: likelihood (0-100)

and impact (0-5)– Highest risk is the highest likelihood x impact– For each have a mitigation plan, i.e. explain

how you react if risk becomes reality Risks examples– External vendor does not deliver, hardware is

not there on time, development problems, politics, bugs

Page 36: L08 architecture considerations

Practical Considerations Solutions are designed and implemented

according to time schedule and budget– Hardest part is management of people

Page 37: L08 architecture considerations

Practical Considerations Risk is in feature creep and things out of

control

Page 38: L08 architecture considerations

PRINCIPLES

Page 39: L08 architecture considerations

Principles Guidelines for how to work– Keeps development effort uniform

Development Principles– Coding standards– Automated unit tests– Static analytic tools– Build strategy– Deployment strategy

Page 40: L08 architecture considerations

Principles Architecture Principles– Layering– Business Logic– Statelessness– High Cohesion, Low Coupling or SOLID– Persistence strategy– Domain model– HTTP protocols– Consistency strategy

Page 41: L08 architecture considerations

Summary Goals– High-level vision for the architecture

Architecture Drivers– Quality, Performance, scalability, etc.

Non-functional Requirements– Capturing

Constraints– We always have to work within some boundary

Principles