SlideShare a Scribd company logo
Uncoupling
Michael T. Nygard
@mtnygard
About the Speaker
Developer
Architect
Operations
Blog: http://www.michaelnygard.com/
Twitter: http://twitter.com/mtnygard
Tensegrity
This Photo by Unknown Author is licensed under CC BY
No-tegrity
This Photo by Unknown Author is licensed under CC BY-NC-SA
Coupling
Scharfenberg Coupler
Watt’s
Linkage
Chebyshev
Linkage
Standard Model
Particle
Interactions
Coupling
Coupling
•Determines degrees of freedom.
Coupling
•Determines degrees of freedom.
•Enables some movements.
Coupling
•Determines degrees of freedom.
•Enables some movements.
•Inhibits other movements.
Coupling
•Determines degrees of freedom.
•Enables some movements.
•Inhibits other movements.
•Connects effects.
Everything is coupled to everything
• Ambient temperature
• Ambient atmosphere
• Acoustic vibrations
• Electromagnetic field
• Gravity
• Higgs field
We cannot attend to all things all the
time
Kinds of Coupling
Type Effect
Operational Consumer cannot run without the provider
Development Changes in producer and consumer must be
coordinated
Semantic Change together because of shared concepts
Functional Change together because of shared responsibility
Incidental Change together for no good reason.
Analyzing Coupling I
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Email Component
[Component: C#]
Sends emails
Analyzing Coupling I
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Email Component
[Component: C#]
Sends emails
Operational: Strong. SMTP is synchronous, connection-oriented, conversational
Analyzing Coupling I
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Email Component
[Component: C#]
Sends emails
Operational: Strong. SMTP is synchronous, connection-oriented, conversational
Development: Weak. SMTP is well-defined standard with history of interoperability
Analyzing Coupling I
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Email Component
[Component: C#]
Sends emails
Operational: Strong. SMTP is synchronous, connection-oriented, conversational
Development: Weak. SMTP is well-defined standard with history of interoperability
Semantic: Very strong. SMTP defines entities, attributes, and allowed values.
Analyzing Coupling I
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Email Component
[Component: C#]
Sends emails
Operational: Strong. SMTP is synchronous, connection-oriented, conversational
Development: Weak. SMTP is well-defined standard with history of interoperability
Semantic: Very strong. SMTP defines entities, attributes, and allowed values.
Functional: Very weak. Sender and MTA both use network connections.
Analyzing Coupling II-A
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
SQL connection
to RDBMS
Analyzing Coupling II-A
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
SQL connection
to RDBMS
Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy
Analyzing Coupling II-A
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
SQL connection
to RDBMS
Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy
Development: Very strong. Dependent on schema, server version, protocol version.
Analyzing Coupling II-A
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
SQL connection
to RDBMS
Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy
Development: Very strong. Dependent on schema, server version, protocol version.
Semantic: Very strong. Tables, columns, and joins must be known to both parties.
Analyzing Coupling II-A
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy
Development: Very strong. Dependent on schema, server version, protocol version.
Semantic: Very strong. Tables, columns, and joins must be known to both parties.
Functional: Weak. Functions of data maintenance don’t overlap with retrieval into objects.
SQL connection
to RDBMS
Suppose we use REST instead of SQL?
Analyzing Coupling II-B
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
HTTPS request
to REST API
Analyzing Coupling II-B
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Operational: Strong, but less than before. Dependent on availability of server.
HTTPS request
to REST API
Analyzing Coupling II-B
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Operational: Strong, but less than before. Dependent on availability of server.
Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling
HTTPS request
to REST API
Analyzing Coupling II-B
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Operational: Strong, but less than before. Dependent on availability of server.
Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling
Semantic: Still very strong. REST resources and C# entities must align. Concepts will still map 1:1
HTTPS request
to REST API
Analyzing Coupling II-B
Reference Data System
[Software System]
Managesreference data for all
counterpartiesthe bank interacts
with
Getscounterparty
datafrom
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Operational: Strong, but less than before. Dependent on availability of server.
Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling
Semantic: Still very strong. REST resources and C# entities must align. Concepts will still map 1:1
Functional: Still weak. Different languages, techniques, design patterns apply.
HTTPS request
to REST API
What if we invert the flow of control?
Analyzing Coupling II-C
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Reference Data Receiver
[Component: C#]
Accepts and caches data from the
reference datasystem
Broadcasts
Message Broker
[Software System]
Pub/sub hub, bub
Broadcasts
Analyzing Coupling II-C
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Reference Data Receiver
[Component: C#]
Accepts and caches data from the
reference datasystem
Broadcasts
Message Broker
[Software System]
Pub/sub hub, bub
Broadcasts
Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken.
Analyzing Coupling II-C
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Reference Data Receiver
[Component: C#]
Accepts and caches data from the
reference datasystem
Broadcasts
Message Broker
[Software System]
Pub/sub hub, bub
Broadcasts
Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken.
Development: Weak. Insulated from schema changes.
Analyzing Coupling II-C
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Reference Data Receiver
[Component: C#]
Accepts and caches data from the
reference datasystem
Broadcasts
Message Broker
[Software System]
Pub/sub hub, bub
Broadcasts
Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken.
Development: Weak. Insulated from schema changes.
Semantic: Strong, but not as strong. Broker allows for remapping concepts.
Analyzing Coupling II-C
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Reference Data Receiver
[Component: C#]
Accepts and caches data from the
reference datasystem
Broadcasts
Message Broker
[Software System]
Pub/sub hub, bub
Broadcasts
Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken.
Development: Weak. Insulated from schema changes.
Semantic: Strong, but not as strong. Broker allows for remapping concepts.
Functional: Moderate. All components must share the same messaging tech.
Coupling was present in all examples –
It is necessary and inescapable
Development &
semantic coupling
inhibit change more
than operational
coupling
Semantic Chains of Coupling
Chains of Coupling
Retek IBM PIM Informatica
Everybody
Else
Dotcom
Catalog
3rd
Party Data
Vendors
Reviews,
Ratings,
Imagery
Dotcom
Promotions
Online
Store
Faceted
Search
SKU SKU SKU
SKU
SKU SKU SKU
SKU
Chains of Coupling
Retek IBM PIM Informatica
Everybody
Else
Dotcom
Catalog
3rd
Party Data
Vendors
Reviews,
Ratings,
Imagery
Dotcom
Promotions
Online
Store
Faceted
Search
SKU SKU SKU
SKU
SKU SKU SKU
SKU
Price Point
Chains of Coupling
Retek IBM PIM Informatica
Everybody
Else
Dotcom
Catalog
3rd
Party Data
Vendors
Reviews,
Ratings,
Imagery
Dotcom
Promotions
Online
Store
Faceted
Search
SKU SKU SKU
SKU
SKU SKU SKU
SKU
Price Point Price Point
Price Point
Price Point Price Point
Price Point
Price Point
Chains of Coupling – Semantic Polymer
Retek IBM PIM Informatica
Everybody
Else
Dotcom
Catalog
3rd
Party Data
Vendors
Reviews,
Ratings,
Imagery
Dotcom
Promotions
Online
Store
Faceted
Search
SKU SKU SKU
SKU
SKU SKU SKU
SKU
Price Point Price Point
Price Point
Price Point Price Point
Price Point
Price Point
Development
Coupling -
Long Arrows
Each “interface” was really a chain
1. Extract tables to files
2. Push files across network
3. Load tables into “LZ”
4. Process into “cold” DB
5. Swap hot & cold DBs (hours later)
1. Send message to queue
2. Take message from queue, unwrap, inspect,
and dispatch to 1-of-N other queues.
3. Drain queue to file
4. Batch job wakes up 2 times a day, does FTP
to remote end
5. Another batch job pulls a reconciliation file,
drops file into file system
6. Parser reads the file, shreds it into
messages, puts them on another queue
Operational Characteristics in Long Chains
• Latency strictly worse than the slowest link in the chain.
• Availability strictly worse than the least available link.
• Throughput strictly worse than the throughput of the worst bottleneck
• Security strictly worse than the security of the weakest link
Digging Out
Information Hiding
“On the Criteria To Be Used in
Decomposing Systems into Modules",
David Parnas,
CACM, 1972
A KWIC Example
• Input
Software comprises an endless supply of structures.
• Output
an endless supply of structures. Software comprises
comprises an endless supply of structures. Software
endless supply of structures. Software comprises an
of structures. Software comprises an endless supply
Software comprises an endless supply of structures.
structures. Software comprises an endless supply of
supply of structures. Software comprises an endless
Modularization 1
1. Input
Read EBCDIC characters, store them in core. 6-bit
characters packed 4 per word. EOL is a special character.
2. Circular shifter
Prepare index; pair of addr of first char of shift, original
index of line in input array
3. Alphabetizer
Take arrays from 1 & 2, produce new array of pairs like
in 2, but in alphabetical order.
4. Output
Using arrays from 1 & 3, format output
5. Control
Allocate memory, call operations in1 - 4, report errors.
Consider the Effect of Changes
For each change case listed here, how many modules have to be changed?
• Read and print ASCII instead of EBCDIC.
• Stop using packed characters, store one character per word.
• Write index for circular shifts to offline storage instead of core to support larger
input documents.
Modularization 2
1. Line Storage
Offers functional interface: SETCH, GETCH, GETW,
DELW, DELLINE
2. Input
Reads EBCDIC chars, calls line storage to put them into
lines.
3. Circular Shifter
Offers same interface as line storage. Makes it appear to
have all shifts of all lines.
4. Alphabetizer
Offers sort function INIT, and access function iTH that
gets a line.
5. Output
Repeatedly call iTH on alphabetizer, printing the line.
6. Control
Similar to first approach, call each module in sequence.
Consider the Effect of Changes
For each change case listed here, how many modules have to be changed?
• Read and print ASCII instead of EBCDIC.
• Stop using packed characters, store one character per word.
• Write index for circular shifts to offline storage instead of core to support larger
input documents.
Why is the second one better?
• It hides decisions inside modules.
• Functional interfaces provide an abstract representation of the underlying data.
• Information hiding
Line
Line
Line
Line
Line
Ordered
Ordered
Storage
Input
Circular Shifter
Alphabetizer
Output
"Needs an interface"
"Offers an interface"
Why did the second
modularization survive
change better?
• Very few data types
• Small number of well
defined interfaces
• Highly composable
LineLine
LineLine
Line
Ordered Storage
Input
Circular ShifterOutput
Ordered
Alphabetizer
Controller run
run
Creates all
components
Composing Interfaces
LineLine
LineLine
Line
Ordered Storage
Input
Circular ShifterOutput
Ordered
Alphabetizer
Controller run
run
Creates all
components
Composing Interfaces
Consider each connector with respect to
Operational, Development, Semantic, and Functional coupling
Better Composability
Fewer interfaces
Fewer data types
Uncoupling
Orthogonality in Software
• Separation of concerns
• High cohesion within a module or component
• Low coupling between modules or components
• Little overlap in functionality between modules
• Information hiding / decision hiding
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Risk calculator produces a data structure that the
report generator must consume.
Example from c4model.com
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Risk calculator produces a data structure that the
report generator must consume.
Data importers probably have similar
implementation needs
Example from c4model.com
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Risk calculator produces a data structure that the
report generator must consume.
Data importers probably have similar
implementation needs
Report checker doesn’t appear to connect with
the file system that holds the reports. FS location
is latent coupling that will be a nasty surprise later.
Example from c4model.com
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Risk calculator produces a data structure that the
report generator must consume.
Data importers probably have similar
implementation needs
Report checker doesn’t appear to connect with
the file system that holds the reports. FS location
is latent coupling that will be a nasty surprise later.
Orchestrator might end need
to do lots of data
transformation to bridge
interfaces.
Example from c4model.com
Batch Process
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Reference Data System
[Software System]
Manages reference data for all
counterparties the bank interacts
with
Central Monitoring Service
[Software System]
The bank-wide monitoringand
alertingdashboard
Trade Data System
[Software System]
The system of record for trades of
type X
E-mail system
[Software System]
Microsoft Exchange
Sendsanotification that
areport isready to
Getstrade datafrom
Sendscritical failure alertsto
[SNMP]
Getscounterparty
datafrom
Email Component
[Component: C#]
Sends emails
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Sendsemail
using
Importsdata
using
Importsdata
using
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Scheduler
[Component: Quartz.net]
Starts the risk calculation process
at 5 p.m. New York time
Starts
Starts
Publishesthe risk
report using
Risk calculator produces a data structure that the
report generator must consume.
Data importers probably have similar
implementation needs
Report checker doesn’t appear to connect with
the file system that holds the reports. FS location
is latent coupling that will be a nasty surprise later.
Orchestrator might end need
to do lots of data
transformation to bridge
interfaces.
Example from c4model.com
Let’s explore options to uncouple these
Problem: Risk calculator
produces a data structure
that the report generator
must consume.
Solutions depend on architectural style
Here we’re in a Windows service so we
might use a shared library to define the interface.
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Risk Calculator
[Component: C#]
Does math
Report Generator
[Component: C# and
Microsoft.Office.Interop.Excel]
Generates an Excel compatible
risk report
Generatesthe risk
report using
Calculatesrisk
using
Problem: Redundant implementation details
This would be a good place to use a
shared library for common implementation.
Trade Data Importer
[Component: C#]
Imports data from the trade data
system
Reference Data Importer
[Component: C#]
Imports data from the reference
datasystem
Orchestrator
[Component: C#]
Orchestrates the risk calculation
process
Importsdata
using
Importsdata
using
File System
[Container: Network File Share]
Stores risk reports
Report Distributor
[Component: C#]
Publishes the report for the web
application
Publishesrisk reportsto
Report Checker
[Component: C#]
Checks that the report has been
generated by 9 a.m. Singapore
time
Alerter
[Component: C# with SNMP
library]
Sends SNMPalerts
Sendsalerts using
Scheduler
[Component: Quartz.net]
Starts
Publishesthe risk
Problem: Latent coupling about filesystem
layout.
Solution: A module to hide the decision
about filesystem layout from
both the Report Distributor and the
Report Checker
Find solutions by rotating your perspective
• When looking at components, think about modules
• When looking at modules, think about components
• When looking at data, think about code
• When looking at code, think about data
Use all your tools
1. Module structure – layout of your code and libraries
2. Component structure – interactions between runtime components
3. Abstraction – Emphasize similar interfaces & data formats
Coupling
• Determines degrees of freedom.
• Enables some movements.
• Inhibits other movements.
• Connects effects.
Kinds of Coupling
• Operational
• Development
• Semantic
• Functional
• Incidental
Summary
• Hide decisions
• Choose degrees of freedom that matter
• Avoid semantic polymers
• Use static and dynamic structures
• Find more instances of fewer, more general interfaces
• Prefer explicit to tacit
Uncoupling
Michael T. Nygard
@mtnygard

More Related Content

What's hot

Basics of BI and Data Management (Summary).pdf
Basics of BI and Data Management (Summary).pdfBasics of BI and Data Management (Summary).pdf
Basics of BI and Data Management (Summary).pdf
amorshed
 
Neo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j – The Fastest Path to Scalable Real-Time AnalyticsNeo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j
 
DevOps + DataOps = Digital Transformation
DevOps + DataOps = Digital Transformation DevOps + DataOps = Digital Transformation
DevOps + DataOps = Digital Transformation
Delphix
 
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4j
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4jAdobe Behance Scales to Millions of Users at Lower TCO with Neo4j
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4j
Neo4j
 
Introduction to Knowledge Graphs
Introduction to Knowledge GraphsIntroduction to Knowledge Graphs
Introduction to Knowledge Graphs
mukuljoshi
 
Creating a data driven culture
Creating a data driven cultureCreating a data driven culture
Creating a data driven culture
Poojitha B
 
Data Migration Steps PowerPoint Presentation Slides
Data Migration Steps PowerPoint Presentation Slides Data Migration Steps PowerPoint Presentation Slides
Data Migration Steps PowerPoint Presentation Slides
SlideTeam
 
Databricks secure deployments and security baselines, doug march 2022
Databricks secure deployments and security baselines, doug march 2022Databricks secure deployments and security baselines, doug march 2022
Databricks secure deployments and security baselines, doug march 2022
Henrik Brattlie
 
Platform Strategy to Deliver Digital Experiences on Azure
Platform Strategy to Deliver Digital Experiences on AzurePlatform Strategy to Deliver Digital Experiences on Azure
Platform Strategy to Deliver Digital Experiences on Azure
WSO2
 
Modern Data Platforms
Modern Data Platforms Modern Data Platforms
Modern Data Platforms
Arne Roßmann
 
Cognitive AI Tutorial | Edureka
Cognitive AI Tutorial | EdurekaCognitive AI Tutorial | Edureka
Cognitive AI Tutorial | Edureka
Edureka!
 
Speak to Your Data
Speak to Your DataSpeak to Your Data
Speak to Your Data
Amer Radwan , PMP , CSM
 
Demystifying Data Warehousing as a Service - DFW
Demystifying Data Warehousing as a Service - DFWDemystifying Data Warehousing as a Service - DFW
Demystifying Data Warehousing as a Service - DFW
Kent Graziano
 
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine LearnGraphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
Neo4j
 
DataOps with Project Amaterasu
DataOps with Project AmaterasuDataOps with Project Amaterasu
DataOps with Project Amaterasu
DataWorks Summit/Hadoop Summit
 
Data Catalog for Better Data Discovery and Governance
Data Catalog for Better Data Discovery and GovernanceData Catalog for Better Data Discovery and Governance
Data Catalog for Better Data Discovery and Governance
Denodo
 
Business Value Metrics for Data Governance
Business Value Metrics for Data GovernanceBusiness Value Metrics for Data Governance
Business Value Metrics for Data Governance
DATAVERSITY
 
Understanding DataOps and Its Impact on Application Quality
Understanding DataOps and Its Impact on Application QualityUnderstanding DataOps and Its Impact on Application Quality
Understanding DataOps and Its Impact on Application Quality
DevOps.com
 
Cloudera SDX
Cloudera SDXCloudera SDX
Cloudera SDX
Cloudera, Inc.
 
Graphs for Finance - AML with Neo4j Graph Data Science
Graphs for Finance - AML with Neo4j Graph Data Science Graphs for Finance - AML with Neo4j Graph Data Science
Graphs for Finance - AML with Neo4j Graph Data Science
Neo4j
 

What's hot (20)

Basics of BI and Data Management (Summary).pdf
Basics of BI and Data Management (Summary).pdfBasics of BI and Data Management (Summary).pdf
Basics of BI and Data Management (Summary).pdf
 
Neo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j – The Fastest Path to Scalable Real-Time AnalyticsNeo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j – The Fastest Path to Scalable Real-Time Analytics
 
DevOps + DataOps = Digital Transformation
DevOps + DataOps = Digital Transformation DevOps + DataOps = Digital Transformation
DevOps + DataOps = Digital Transformation
 
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4j
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4jAdobe Behance Scales to Millions of Users at Lower TCO with Neo4j
Adobe Behance Scales to Millions of Users at Lower TCO with Neo4j
 
Introduction to Knowledge Graphs
Introduction to Knowledge GraphsIntroduction to Knowledge Graphs
Introduction to Knowledge Graphs
 
Creating a data driven culture
Creating a data driven cultureCreating a data driven culture
Creating a data driven culture
 
Data Migration Steps PowerPoint Presentation Slides
Data Migration Steps PowerPoint Presentation Slides Data Migration Steps PowerPoint Presentation Slides
Data Migration Steps PowerPoint Presentation Slides
 
Databricks secure deployments and security baselines, doug march 2022
Databricks secure deployments and security baselines, doug march 2022Databricks secure deployments and security baselines, doug march 2022
Databricks secure deployments and security baselines, doug march 2022
 
Platform Strategy to Deliver Digital Experiences on Azure
Platform Strategy to Deliver Digital Experiences on AzurePlatform Strategy to Deliver Digital Experiences on Azure
Platform Strategy to Deliver Digital Experiences on Azure
 
Modern Data Platforms
Modern Data Platforms Modern Data Platforms
Modern Data Platforms
 
Cognitive AI Tutorial | Edureka
Cognitive AI Tutorial | EdurekaCognitive AI Tutorial | Edureka
Cognitive AI Tutorial | Edureka
 
Speak to Your Data
Speak to Your DataSpeak to Your Data
Speak to Your Data
 
Demystifying Data Warehousing as a Service - DFW
Demystifying Data Warehousing as a Service - DFWDemystifying Data Warehousing as a Service - DFW
Demystifying Data Warehousing as a Service - DFW
 
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine LearnGraphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
Graphs in Retail: Know Your Customers and Make Your Recommendations Engine Learn
 
DataOps with Project Amaterasu
DataOps with Project AmaterasuDataOps with Project Amaterasu
DataOps with Project Amaterasu
 
Data Catalog for Better Data Discovery and Governance
Data Catalog for Better Data Discovery and GovernanceData Catalog for Better Data Discovery and Governance
Data Catalog for Better Data Discovery and Governance
 
Business Value Metrics for Data Governance
Business Value Metrics for Data GovernanceBusiness Value Metrics for Data Governance
Business Value Metrics for Data Governance
 
Understanding DataOps and Its Impact on Application Quality
Understanding DataOps and Its Impact on Application QualityUnderstanding DataOps and Its Impact on Application Quality
Understanding DataOps and Its Impact on Application Quality
 
Cloudera SDX
Cloudera SDXCloudera SDX
Cloudera SDX
 
Graphs for Finance - AML with Neo4j Graph Data Science
Graphs for Finance - AML with Neo4j Graph Data Science Graphs for Finance - AML with Neo4j Graph Data Science
Graphs for Finance - AML with Neo4j Graph Data Science
 

Similar to Michael Nygard - Uncoupling

Uncoupling
UncouplingUncoupling
Uncoupling
Michael Nygard
 
Monitoring as an entry point for collaboration
Monitoring as an entry point for collaborationMonitoring as an entry point for collaboration
Monitoring as an entry point for collaboration
Julien Pivotto
 
Cilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPFCilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPF
Cynthia Thomas
 
Redis Streams for Event-Driven Microservices
Redis Streams for Event-Driven MicroservicesRedis Streams for Event-Driven Microservices
Redis Streams for Event-Driven Microservices
Redis Labs
 
Building A Distributed Build System at Google Scale (StrangeLoop 2016)
Building A Distributed Build System at Google Scale (StrangeLoop 2016)Building A Distributed Build System at Google Scale (StrangeLoop 2016)
Building A Distributed Build System at Google Scale (StrangeLoop 2016)
Aysylu Greenberg
 
Using Data Science for Cybersecurity
Using Data Science for CybersecurityUsing Data Science for Cybersecurity
Using Data Science for Cybersecurity
VMware Tanzu
 
TheTricky Bits of Deployment Automation
TheTricky Bits of Deployment Automation TheTricky Bits of Deployment Automation
TheTricky Bits of Deployment Automation
IBM UrbanCode Products
 
My past-3 yeas-developer-journey-at-linkedin-by-iantsai
My past-3 yeas-developer-journey-at-linkedin-by-iantsaiMy past-3 yeas-developer-journey-at-linkedin-by-iantsai
My past-3 yeas-developer-journey-at-linkedin-by-iantsai
Kim Kao
 
Data Collection and Consumption
Data Collection and ConsumptionData Collection and Consumption
Data Collection and Consumption
Brian Greig
 
Meetup Microservices Commandments
Meetup Microservices CommandmentsMeetup Microservices Commandments
Meetup Microservices Commandments
Bill Zajac
 
Building Event-Driven (Micro)Services with Apache Kafka
Building Event-Driven (Micro)Services with Apache KafkaBuilding Event-Driven (Micro)Services with Apache Kafka
Building Event-Driven (Micro)Services with Apache Kafka
Guido Schmutz
 
Work with data in ASP.NET
Work with data in ASP.NETWork with data in ASP.NET
Work with data in ASP.NET
Peter Gfader
 
Streaming real time data with Vibe Data Stream
Streaming real time data with Vibe Data StreamStreaming real time data with Vibe Data Stream
Streaming real time data with Vibe Data Stream
InformaticaMarketplace
 
4
44
Introduction to R2DBC
Introduction to R2DBCIntroduction to R2DBC
Introduction to R2DBC
Rob Hedgpeth
 
Sukumar Nayak-Agile-DevOps-Cloud Management
Sukumar Nayak-Agile-DevOps-Cloud ManagementSukumar Nayak-Agile-DevOps-Cloud Management
Sukumar Nayak-Agile-DevOps-Cloud Management
Sukumar Nayak
 
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
VMware Tanzu
 
Cloud to hybrid edge cloud evolution Jun112020.pptx
Cloud to hybrid edge cloud evolution Jun112020.pptxCloud to hybrid edge cloud evolution Jun112020.pptx
Cloud to hybrid edge cloud evolution Jun112020.pptx
Michel Burger
 
Microsoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
Microsoft Sync Framework (part 1) ABTO Software Lecture GarntsarikMicrosoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
Microsoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
ABTO Software
 
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
Impetus Technologies
 

Similar to Michael Nygard - Uncoupling (20)

Uncoupling
UncouplingUncoupling
Uncoupling
 
Monitoring as an entry point for collaboration
Monitoring as an entry point for collaborationMonitoring as an entry point for collaboration
Monitoring as an entry point for collaboration
 
Cilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPFCilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPF
 
Redis Streams for Event-Driven Microservices
Redis Streams for Event-Driven MicroservicesRedis Streams for Event-Driven Microservices
Redis Streams for Event-Driven Microservices
 
Building A Distributed Build System at Google Scale (StrangeLoop 2016)
Building A Distributed Build System at Google Scale (StrangeLoop 2016)Building A Distributed Build System at Google Scale (StrangeLoop 2016)
Building A Distributed Build System at Google Scale (StrangeLoop 2016)
 
Using Data Science for Cybersecurity
Using Data Science for CybersecurityUsing Data Science for Cybersecurity
Using Data Science for Cybersecurity
 
TheTricky Bits of Deployment Automation
TheTricky Bits of Deployment Automation TheTricky Bits of Deployment Automation
TheTricky Bits of Deployment Automation
 
My past-3 yeas-developer-journey-at-linkedin-by-iantsai
My past-3 yeas-developer-journey-at-linkedin-by-iantsaiMy past-3 yeas-developer-journey-at-linkedin-by-iantsai
My past-3 yeas-developer-journey-at-linkedin-by-iantsai
 
Data Collection and Consumption
Data Collection and ConsumptionData Collection and Consumption
Data Collection and Consumption
 
Meetup Microservices Commandments
Meetup Microservices CommandmentsMeetup Microservices Commandments
Meetup Microservices Commandments
 
Building Event-Driven (Micro)Services with Apache Kafka
Building Event-Driven (Micro)Services with Apache KafkaBuilding Event-Driven (Micro)Services with Apache Kafka
Building Event-Driven (Micro)Services with Apache Kafka
 
Work with data in ASP.NET
Work with data in ASP.NETWork with data in ASP.NET
Work with data in ASP.NET
 
Streaming real time data with Vibe Data Stream
Streaming real time data with Vibe Data StreamStreaming real time data with Vibe Data Stream
Streaming real time data with Vibe Data Stream
 
4
44
4
 
Introduction to R2DBC
Introduction to R2DBCIntroduction to R2DBC
Introduction to R2DBC
 
Sukumar Nayak-Agile-DevOps-Cloud Management
Sukumar Nayak-Agile-DevOps-Cloud ManagementSukumar Nayak-Agile-DevOps-Cloud Management
Sukumar Nayak-Agile-DevOps-Cloud Management
 
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
Welcome to the Reactive Revolution:RSocket and Spring Cloud Gateway - Spencer...
 
Cloud to hybrid edge cloud evolution Jun112020.pptx
Cloud to hybrid edge cloud evolution Jun112020.pptxCloud to hybrid edge cloud evolution Jun112020.pptx
Cloud to hybrid edge cloud evolution Jun112020.pptx
 
Microsoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
Microsoft Sync Framework (part 1) ABTO Software Lecture GarntsarikMicrosoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
Microsoft Sync Framework (part 1) ABTO Software Lecture Garntsarik
 
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
Planning your Next-Gen Change Data Capture (CDC) Architecture in 2019 - Strea...
 

More from DevOpsDays DFW

Michael Coté - The Eternal Recurrence of DevOps
Michael Coté - The Eternal Recurrence of DevOpsMichael Coté - The Eternal Recurrence of DevOps
Michael Coté - The Eternal Recurrence of DevOps
DevOpsDays DFW
 
Nigel Thurlow - DevOps is Enterprise Wide.pdf
Nigel Thurlow - DevOps is Enterprise Wide.pdfNigel Thurlow - DevOps is Enterprise Wide.pdf
Nigel Thurlow - DevOps is Enterprise Wide.pdf
DevOpsDays DFW
 
Dan Barker - Understanding Risk Can Fund Transformation
Dan Barker - Understanding Risk Can Fund TransformationDan Barker - Understanding Risk Can Fund Transformation
Dan Barker - Understanding Risk Can Fund Transformation
DevOpsDays DFW
 
Vijay Challa - SSO on Cloud - Gateway Approach
Vijay Challa - SSO on Cloud - Gateway ApproachVijay Challa - SSO on Cloud - Gateway Approach
Vijay Challa - SSO on Cloud - Gateway Approach
DevOpsDays DFW
 
Aaron Mell - The Continuous Improvement Toolbox: Post-Mortems
Aaron Mell - The Continuous Improvement Toolbox: Post-MortemsAaron Mell - The Continuous Improvement Toolbox: Post-Mortems
Aaron Mell - The Continuous Improvement Toolbox: Post-Mortems
DevOpsDays DFW
 
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
DevOpsDays DFW
 
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
DevOpsDays DFW
 
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple StepsBjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
DevOpsDays DFW
 
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
DevOpsDays DFW
 
Dana Finster - DevOps - Do the Math
Dana Finster - DevOps - Do the MathDana Finster - DevOps - Do the Math
Dana Finster - DevOps - Do the Math
DevOpsDays DFW
 
Detangling complex systems with compassion & production excellence
Detangling complex systems with compassion & production excellenceDetangling complex systems with compassion & production excellence
Detangling complex systems with compassion & production excellence
DevOpsDays DFW
 
Speeding Up Innovation
Speeding Up InnovationSpeeding Up Innovation
Speeding Up Innovation
DevOpsDays DFW
 
DevOps Theory vs. Practice: A Song of Ice and Tire-Fire
DevOps Theory vs. Practice: A Song of Ice and Tire-FireDevOps Theory vs. Practice: A Song of Ice and Tire-Fire
DevOps Theory vs. Practice: A Song of Ice and Tire-Fire
DevOpsDays DFW
 
Hidden Costs of Chasing the Mythical 'Five Nines'
Hidden Costs of Chasing the Mythical 'Five Nines'Hidden Costs of Chasing the Mythical 'Five Nines'
Hidden Costs of Chasing the Mythical 'Five Nines'
DevOpsDays DFW
 
Stepping Up Your DevOps With Step Functions
Stepping Up Your DevOps With Step FunctionsStepping Up Your DevOps With Step Functions
Stepping Up Your DevOps With Step Functions
DevOpsDays DFW
 
DevSecOps Through Blunt Force Trauma, I'm the Trauma
DevSecOps Through Blunt Force Trauma, I'm the TraumaDevSecOps Through Blunt Force Trauma, I'm the Trauma
DevSecOps Through Blunt Force Trauma, I'm the Trauma
DevOpsDays DFW
 
Avoid the Distributed Monolith!!
Avoid the Distributed Monolith!!Avoid the Distributed Monolith!!
Avoid the Distributed Monolith!!
DevOpsDays DFW
 
Using Docker to Build Software
Using Docker to Build SoftwareUsing Docker to Build Software
Using Docker to Build Software
DevOpsDays DFW
 
Managing Cloud Infrastructure at Scale
Managing Cloud Infrastructure at ScaleManaging Cloud Infrastructure at Scale
Managing Cloud Infrastructure at Scale
DevOpsDays DFW
 
The 12 Layer Burrito VS The 12 Factor APP
The 12 Layer Burrito VS The 12 Factor APPThe 12 Layer Burrito VS The 12 Factor APP
The 12 Layer Burrito VS The 12 Factor APP
DevOpsDays DFW
 

More from DevOpsDays DFW (20)

Michael Coté - The Eternal Recurrence of DevOps
Michael Coté - The Eternal Recurrence of DevOpsMichael Coté - The Eternal Recurrence of DevOps
Michael Coté - The Eternal Recurrence of DevOps
 
Nigel Thurlow - DevOps is Enterprise Wide.pdf
Nigel Thurlow - DevOps is Enterprise Wide.pdfNigel Thurlow - DevOps is Enterprise Wide.pdf
Nigel Thurlow - DevOps is Enterprise Wide.pdf
 
Dan Barker - Understanding Risk Can Fund Transformation
Dan Barker - Understanding Risk Can Fund TransformationDan Barker - Understanding Risk Can Fund Transformation
Dan Barker - Understanding Risk Can Fund Transformation
 
Vijay Challa - SSO on Cloud - Gateway Approach
Vijay Challa - SSO on Cloud - Gateway ApproachVijay Challa - SSO on Cloud - Gateway Approach
Vijay Challa - SSO on Cloud - Gateway Approach
 
Aaron Mell - The Continuous Improvement Toolbox: Post-Mortems
Aaron Mell - The Continuous Improvement Toolbox: Post-MortemsAaron Mell - The Continuous Improvement Toolbox: Post-Mortems
Aaron Mell - The Continuous Improvement Toolbox: Post-Mortems
 
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
Steve Shangguan - The Unreasonable Effectiveness of Combining and Correlating...
 
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
Farrah Campbell - Open Mind, Open Doors. Change your narrative and achieve wh...
 
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple StepsBjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
Bjorn Edwin - Start Your Own DevOps Dojo in 8 Simple Steps
 
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
Crux Conception - 'TECH-LIVES MATTER, HANDS UP, DON'T REBOOT'
 
Dana Finster - DevOps - Do the Math
Dana Finster - DevOps - Do the MathDana Finster - DevOps - Do the Math
Dana Finster - DevOps - Do the Math
 
Detangling complex systems with compassion & production excellence
Detangling complex systems with compassion & production excellenceDetangling complex systems with compassion & production excellence
Detangling complex systems with compassion & production excellence
 
Speeding Up Innovation
Speeding Up InnovationSpeeding Up Innovation
Speeding Up Innovation
 
DevOps Theory vs. Practice: A Song of Ice and Tire-Fire
DevOps Theory vs. Practice: A Song of Ice and Tire-FireDevOps Theory vs. Practice: A Song of Ice and Tire-Fire
DevOps Theory vs. Practice: A Song of Ice and Tire-Fire
 
Hidden Costs of Chasing the Mythical 'Five Nines'
Hidden Costs of Chasing the Mythical 'Five Nines'Hidden Costs of Chasing the Mythical 'Five Nines'
Hidden Costs of Chasing the Mythical 'Five Nines'
 
Stepping Up Your DevOps With Step Functions
Stepping Up Your DevOps With Step FunctionsStepping Up Your DevOps With Step Functions
Stepping Up Your DevOps With Step Functions
 
DevSecOps Through Blunt Force Trauma, I'm the Trauma
DevSecOps Through Blunt Force Trauma, I'm the TraumaDevSecOps Through Blunt Force Trauma, I'm the Trauma
DevSecOps Through Blunt Force Trauma, I'm the Trauma
 
Avoid the Distributed Monolith!!
Avoid the Distributed Monolith!!Avoid the Distributed Monolith!!
Avoid the Distributed Monolith!!
 
Using Docker to Build Software
Using Docker to Build SoftwareUsing Docker to Build Software
Using Docker to Build Software
 
Managing Cloud Infrastructure at Scale
Managing Cloud Infrastructure at ScaleManaging Cloud Infrastructure at Scale
Managing Cloud Infrastructure at Scale
 
The 12 Layer Burrito VS The 12 Factor APP
The 12 Layer Burrito VS The 12 Factor APPThe 12 Layer Burrito VS The 12 Factor APP
The 12 Layer Burrito VS The 12 Factor APP
 

Recently uploaded

HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Malak Abu Hammad
 
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
saastr
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
Hiroshi SHIBATA
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Wask
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
Mariano Tinti
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
Zilliz
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
Daiki Mogmet Ito
 
Columbus Data & Analytics Wednesdays - June 2024
Columbus Data & Analytics Wednesdays - June 2024Columbus Data & Analytics Wednesdays - June 2024
Columbus Data & Analytics Wednesdays - June 2024
Jason Packer
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
SitimaJohn
 
Taking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdfTaking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdf
ssuserfac0301
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Recommendation System using RAG Architecture
Recommendation System using RAG ArchitectureRecommendation System using RAG Architecture
Recommendation System using RAG Architecture
fredae14
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
Zilliz
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
UI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentationUI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentation
Wouter Lemaire
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
innovationoecd
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Speck&Tech
 

Recently uploaded (20)

HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
 
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
 
Columbus Data & Analytics Wednesdays - June 2024
Columbus Data & Analytics Wednesdays - June 2024Columbus Data & Analytics Wednesdays - June 2024
Columbus Data & Analytics Wednesdays - June 2024
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
 
Taking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdfTaking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdf
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Recommendation System using RAG Architecture
Recommendation System using RAG ArchitectureRecommendation System using RAG Architecture
Recommendation System using RAG Architecture
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
UI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentationUI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentation
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
 

Michael Nygard - Uncoupling

  • 2. About the Speaker Developer Architect Operations Blog: http://www.michaelnygard.com/ Twitter: http://twitter.com/mtnygard
  • 3.
  • 4.
  • 5. Tensegrity This Photo by Unknown Author is licensed under CC BY
  • 6. No-tegrity This Photo by Unknown Author is licensed under CC BY-NC-SA
  • 14. Coupling •Determines degrees of freedom. •Enables some movements.
  • 15. Coupling •Determines degrees of freedom. •Enables some movements. •Inhibits other movements.
  • 16. Coupling •Determines degrees of freedom. •Enables some movements. •Inhibits other movements. •Connects effects.
  • 17.
  • 18.
  • 19.
  • 20. Everything is coupled to everything • Ambient temperature • Ambient atmosphere • Acoustic vibrations • Electromagnetic field • Gravity • Higgs field
  • 21. We cannot attend to all things all the time
  • 22. Kinds of Coupling Type Effect Operational Consumer cannot run without the provider Development Changes in producer and consumer must be coordinated Semantic Change together because of shared concepts Functional Change together because of shared responsibility Incidental Change together for no good reason.
  • 23. Analyzing Coupling I E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Email Component [Component: C#] Sends emails
  • 24. Analyzing Coupling I E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Email Component [Component: C#] Sends emails Operational: Strong. SMTP is synchronous, connection-oriented, conversational
  • 25. Analyzing Coupling I E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Email Component [Component: C#] Sends emails Operational: Strong. SMTP is synchronous, connection-oriented, conversational Development: Weak. SMTP is well-defined standard with history of interoperability
  • 26. Analyzing Coupling I E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Email Component [Component: C#] Sends emails Operational: Strong. SMTP is synchronous, connection-oriented, conversational Development: Weak. SMTP is well-defined standard with history of interoperability Semantic: Very strong. SMTP defines entities, attributes, and allowed values.
  • 27. Analyzing Coupling I E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Email Component [Component: C#] Sends emails Operational: Strong. SMTP is synchronous, connection-oriented, conversational Development: Weak. SMTP is well-defined standard with history of interoperability Semantic: Very strong. SMTP defines entities, attributes, and allowed values. Functional: Very weak. Sender and MTA both use network connections.
  • 28.
  • 29. Analyzing Coupling II-A Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem SQL connection to RDBMS
  • 30. Analyzing Coupling II-A Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem SQL connection to RDBMS Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy
  • 31. Analyzing Coupling II-A Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem SQL connection to RDBMS Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy Development: Very strong. Dependent on schema, server version, protocol version.
  • 32. Analyzing Coupling II-A Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem SQL connection to RDBMS Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy Development: Very strong. Dependent on schema, server version, protocol version. Semantic: Very strong. Tables, columns, and joins must be known to both parties.
  • 33. Analyzing Coupling II-A Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem Operational: Very strong. Dependent on availability of server. Must be aware of topology and failover strategy Development: Very strong. Dependent on schema, server version, protocol version. Semantic: Very strong. Tables, columns, and joins must be known to both parties. Functional: Weak. Functions of data maintenance don’t overlap with retrieval into objects. SQL connection to RDBMS
  • 34. Suppose we use REST instead of SQL?
  • 35. Analyzing Coupling II-B Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem HTTPS request to REST API
  • 36. Analyzing Coupling II-B Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem Operational: Strong, but less than before. Dependent on availability of server. HTTPS request to REST API
  • 37. Analyzing Coupling II-B Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem Operational: Strong, but less than before. Dependent on availability of server. Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling HTTPS request to REST API
  • 38. Analyzing Coupling II-B Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem Operational: Strong, but less than before. Dependent on availability of server. Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling Semantic: Still very strong. REST resources and C# entities must align. Concepts will still map 1:1 HTTPS request to REST API
  • 39. Analyzing Coupling II-B Reference Data System [Software System] Managesreference data for all counterpartiesthe bank interacts with Getscounterparty datafrom Reference Data Importer [Component: C#] Imports data from the reference datasystem Operational: Strong, but less than before. Dependent on availability of server. Development: Strong, but less. Insulated from data format changes. Open encoding can further reduce coupling Semantic: Still very strong. REST resources and C# entities must align. Concepts will still map 1:1 Functional: Still weak. Different languages, techniques, design patterns apply. HTTPS request to REST API
  • 40. What if we invert the flow of control?
  • 41. Analyzing Coupling II-C Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Reference Data Receiver [Component: C#] Accepts and caches data from the reference datasystem Broadcasts Message Broker [Software System] Pub/sub hub, bub Broadcasts
  • 42. Analyzing Coupling II-C Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Reference Data Receiver [Component: C#] Accepts and caches data from the reference datasystem Broadcasts Message Broker [Software System] Pub/sub hub, bub Broadcasts Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken.
  • 43. Analyzing Coupling II-C Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Reference Data Receiver [Component: C#] Accepts and caches data from the reference datasystem Broadcasts Message Broker [Software System] Pub/sub hub, bub Broadcasts Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken. Development: Weak. Insulated from schema changes.
  • 44. Analyzing Coupling II-C Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Reference Data Receiver [Component: C#] Accepts and caches data from the reference datasystem Broadcasts Message Broker [Software System] Pub/sub hub, bub Broadcasts Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken. Development: Weak. Insulated from schema changes. Semantic: Strong, but not as strong. Broker allows for remapping concepts.
  • 45. Analyzing Coupling II-C Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Reference Data Receiver [Component: C#] Accepts and caches data from the reference datasystem Broadcasts Message Broker [Software System] Pub/sub hub, bub Broadcasts Operational: Very weak. Receiver can run with stale data when either broker or upstream are broken. Development: Weak. Insulated from schema changes. Semantic: Strong, but not as strong. Broker allows for remapping concepts. Functional: Moderate. All components must share the same messaging tech.
  • 46. Coupling was present in all examples – It is necessary and inescapable
  • 47. Development & semantic coupling inhibit change more than operational coupling
  • 48. Semantic Chains of Coupling
  • 49. Chains of Coupling Retek IBM PIM Informatica Everybody Else Dotcom Catalog 3rd Party Data Vendors Reviews, Ratings, Imagery Dotcom Promotions Online Store Faceted Search SKU SKU SKU SKU SKU SKU SKU SKU
  • 50. Chains of Coupling Retek IBM PIM Informatica Everybody Else Dotcom Catalog 3rd Party Data Vendors Reviews, Ratings, Imagery Dotcom Promotions Online Store Faceted Search SKU SKU SKU SKU SKU SKU SKU SKU Price Point
  • 51. Chains of Coupling Retek IBM PIM Informatica Everybody Else Dotcom Catalog 3rd Party Data Vendors Reviews, Ratings, Imagery Dotcom Promotions Online Store Faceted Search SKU SKU SKU SKU SKU SKU SKU SKU Price Point Price Point Price Point Price Point Price Point Price Point Price Point
  • 52. Chains of Coupling – Semantic Polymer Retek IBM PIM Informatica Everybody Else Dotcom Catalog 3rd Party Data Vendors Reviews, Ratings, Imagery Dotcom Promotions Online Store Faceted Search SKU SKU SKU SKU SKU SKU SKU SKU Price Point Price Point Price Point Price Point Price Point Price Point Price Point
  • 54. Each “interface” was really a chain 1. Extract tables to files 2. Push files across network 3. Load tables into “LZ” 4. Process into “cold” DB 5. Swap hot & cold DBs (hours later) 1. Send message to queue 2. Take message from queue, unwrap, inspect, and dispatch to 1-of-N other queues. 3. Drain queue to file 4. Batch job wakes up 2 times a day, does FTP to remote end 5. Another batch job pulls a reconciliation file, drops file into file system 6. Parser reads the file, shreds it into messages, puts them on another queue
  • 55. Operational Characteristics in Long Chains • Latency strictly worse than the slowest link in the chain. • Availability strictly worse than the least available link. • Throughput strictly worse than the throughput of the worst bottleneck • Security strictly worse than the security of the weakest link
  • 57. Information Hiding “On the Criteria To Be Used in Decomposing Systems into Modules", David Parnas, CACM, 1972
  • 58. A KWIC Example • Input Software comprises an endless supply of structures. • Output an endless supply of structures. Software comprises comprises an endless supply of structures. Software endless supply of structures. Software comprises an of structures. Software comprises an endless supply Software comprises an endless supply of structures. structures. Software comprises an endless supply of supply of structures. Software comprises an endless
  • 59. Modularization 1 1. Input Read EBCDIC characters, store them in core. 6-bit characters packed 4 per word. EOL is a special character. 2. Circular shifter Prepare index; pair of addr of first char of shift, original index of line in input array 3. Alphabetizer Take arrays from 1 & 2, produce new array of pairs like in 2, but in alphabetical order. 4. Output Using arrays from 1 & 3, format output 5. Control Allocate memory, call operations in1 - 4, report errors.
  • 60. Consider the Effect of Changes For each change case listed here, how many modules have to be changed? • Read and print ASCII instead of EBCDIC. • Stop using packed characters, store one character per word. • Write index for circular shifts to offline storage instead of core to support larger input documents.
  • 61. Modularization 2 1. Line Storage Offers functional interface: SETCH, GETCH, GETW, DELW, DELLINE 2. Input Reads EBCDIC chars, calls line storage to put them into lines. 3. Circular Shifter Offers same interface as line storage. Makes it appear to have all shifts of all lines. 4. Alphabetizer Offers sort function INIT, and access function iTH that gets a line. 5. Output Repeatedly call iTH on alphabetizer, printing the line. 6. Control Similar to first approach, call each module in sequence.
  • 62. Consider the Effect of Changes For each change case listed here, how many modules have to be changed? • Read and print ASCII instead of EBCDIC. • Stop using packed characters, store one character per word. • Write index for circular shifts to offline storage instead of core to support larger input documents.
  • 63. Why is the second one better? • It hides decisions inside modules. • Functional interfaces provide an abstract representation of the underlying data. • Information hiding
  • 64. Line Line Line Line Line Ordered Ordered Storage Input Circular Shifter Alphabetizer Output "Needs an interface" "Offers an interface" Why did the second modularization survive change better? • Very few data types • Small number of well defined interfaces • Highly composable
  • 66. LineLine LineLine Line Ordered Storage Input Circular ShifterOutput Ordered Alphabetizer Controller run run Creates all components Composing Interfaces Consider each connector with respect to Operational, Development, Semantic, and Functional coupling
  • 69. Orthogonality in Software • Separation of concerns • High cohesion within a module or component • Low coupling between modules or components • Little overlap in functionality between modules • Information hiding / decision hiding
  • 70. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using
  • 71. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using Risk calculator produces a data structure that the report generator must consume. Example from c4model.com
  • 72. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using Risk calculator produces a data structure that the report generator must consume. Data importers probably have similar implementation needs Example from c4model.com
  • 73. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using Risk calculator produces a data structure that the report generator must consume. Data importers probably have similar implementation needs Report checker doesn’t appear to connect with the file system that holds the reports. FS location is latent coupling that will be a nasty surprise later. Example from c4model.com
  • 74. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using Risk calculator produces a data structure that the report generator must consume. Data importers probably have similar implementation needs Report checker doesn’t appear to connect with the file system that holds the reports. FS location is latent coupling that will be a nasty surprise later. Orchestrator might end need to do lots of data transformation to bridge interfaces. Example from c4model.com
  • 75. Batch Process File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Reference Data System [Software System] Manages reference data for all counterparties the bank interacts with Central Monitoring Service [Software System] The bank-wide monitoringand alertingdashboard Trade Data System [Software System] The system of record for trades of type X E-mail system [Software System] Microsoft Exchange Sendsanotification that areport isready to Getstrade datafrom Sendscritical failure alertsto [SNMP] Getscounterparty datafrom Email Component [Component: C#] Sends emails Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Orchestrator [Component: C#] Orchestrates the risk calculation process Sendsemail using Importsdata using Importsdata using Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using Scheduler [Component: Quartz.net] Starts the risk calculation process at 5 p.m. New York time Starts Starts Publishesthe risk report using Risk calculator produces a data structure that the report generator must consume. Data importers probably have similar implementation needs Report checker doesn’t appear to connect with the file system that holds the reports. FS location is latent coupling that will be a nasty surprise later. Orchestrator might end need to do lots of data transformation to bridge interfaces. Example from c4model.com
  • 76. Let’s explore options to uncouple these
  • 77. Problem: Risk calculator produces a data structure that the report generator must consume. Solutions depend on architectural style Here we’re in a Windows service so we might use a shared library to define the interface. Orchestrator [Component: C#] Orchestrates the risk calculation process Risk Calculator [Component: C#] Does math Report Generator [Component: C# and Microsoft.Office.Interop.Excel] Generates an Excel compatible risk report Generatesthe risk report using Calculatesrisk using
  • 78. Problem: Redundant implementation details This would be a good place to use a shared library for common implementation. Trade Data Importer [Component: C#] Imports data from the trade data system Reference Data Importer [Component: C#] Imports data from the reference datasystem Orchestrator [Component: C#] Orchestrates the risk calculation process Importsdata using Importsdata using
  • 79. File System [Container: Network File Share] Stores risk reports Report Distributor [Component: C#] Publishes the report for the web application Publishesrisk reportsto Report Checker [Component: C#] Checks that the report has been generated by 9 a.m. Singapore time Alerter [Component: C# with SNMP library] Sends SNMPalerts Sendsalerts using Scheduler [Component: Quartz.net] Starts Publishesthe risk Problem: Latent coupling about filesystem layout. Solution: A module to hide the decision about filesystem layout from both the Report Distributor and the Report Checker
  • 80. Find solutions by rotating your perspective • When looking at components, think about modules • When looking at modules, think about components • When looking at data, think about code • When looking at code, think about data
  • 81. Use all your tools 1. Module structure – layout of your code and libraries 2. Component structure – interactions between runtime components 3. Abstraction – Emphasize similar interfaces & data formats
  • 82. Coupling • Determines degrees of freedom. • Enables some movements. • Inhibits other movements. • Connects effects.
  • 83. Kinds of Coupling • Operational • Development • Semantic • Functional • Incidental
  • 84. Summary • Hide decisions • Choose degrees of freedom that matter • Avoid semantic polymers • Use static and dynamic structures • Find more instances of fewer, more general interfaces • Prefer explicit to tacit

Editor's Notes

  1. You’ve been working in your system for a year. Things are going well.
  2. You think it’s made of small pieces arranged beautifully. Until the day everything changes. You get the one new requirements that just doesn’t fit. You move one part, but that forces you to change something on the other side of the world. You change that and find that a different part breaks for no apparent reason.
  3. You begin to realize that your system is not a lovely arrangement of isolated pieces. It is more like a nest of opposing forces, it wants to fly apart or collapse at any time. It’s only held back from chaos by a network of interwoven dependencies. You pull one part and it tugs on a dozen others. You push a piece and it pushes back.
  4. You fight. The system fights back. Eventually, you are consumed by the chaos. A rewrite starts to sound better and better. After all, it should only take two weeks. You have fallen prey to coupling. This is the “choose your own adventure” page that says “You have died, go to page 1.”
  5. As we dissolve large systems into pieces, coupling ever more important. Moving from static equilibrium to dynamic equilibrium. Coupling is a dirty word in our industry. “Coupled” basically means “bad.” Coupling keeps us from making changes. It keeps our business from evolving. Coupling not a dirty word in other fields. Coupling means connector. It enables structure.
  6. Coupling as safety. Keeping two parts together.
  7. Coupling allows matter to exist.
  8. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  9. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  10. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  11. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  12. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  13. Note: Sometimes called the "Death Star" moon. Two tone coloring observed by Giovanni Cassini. In 2009, discovered that the likely cause is Phoebe.
  14. This is Phoebe.  213 km mean diameter.
  15. Note: Phoebe has a ring, Saturn's largest and most diffuse. 40x biggest than the entirety of the other rings. Ablated from Phoebe by micrometeorites. Solar pressure causes ring material to spiral toward Saturn. Swept up by Iapetus (which is tidally locked to Saturn.)
  16. Tell story of screaming at disks.
  17. What could we do about this to reduce the degree of coupling.
  18. What could we do about this to reduce the degree of coupling.
  19. What could we do about this to reduce the degree of coupling.
  20. What could we do about this to reduce the degree of coupling.
  21. What could we do about this to reduce the degree of coupling.
  22. Assume this is a direct database connection
  23. Assume this is a direct database connection
  24. Assume this is a direct database connection
  25. Assume this is a direct database connection
  26. Assume this is a direct database connection
  27. Assume this is a direct database connection
  28. Assume this is a direct database connection
  29. Assume this is a direct database connection
  30. Assume this is a direct database connection
  31. Assume this is a direct database connection
  32. Assume this is a direct database connection
  33. Assume this is a direct database connection
  34. Assume this is a direct database connection
  35. Assume this is a direct database connection
  36. Assume this is a direct database connection
  37. But not as difficult to manage in every case.
  38. SKU = “stock keeping unit”.
  39. SKU = “stock keeping unit”.
  40. SKU = “stock keeping unit”.
  41. SKU = “stock keeping unit”.
  42. Easy to see how this works. Module 1 creates an array which 2, 3, 4 use. Module 2 creates array which 3 uses. Module 3 creates array that 4 uses.
  43. I expect: 1: (1, 4); 2: (1, 2, 3, 4); 3: (2, 3, 4); 4: (1, 2, 3, 4) Change eff. = (20 – 11)/20 = 45%
  44. Interesting difference is the idea of defined interfaces and multiple implementors of the interface.
  45. I expect: 1: (1, 4); 2: (1, 2, 3, 4); 3: (2, 3, 4); 4: (1, 2, 3, 4) Change eff. = (20 – 11)/20 = 45%
  46. Operational high in all cases… was running in a single process. Development weakened thanks to functional interface. Semantic reduced due to interface instead of direct access to arrays. Functional also reduced by not having array manip & char packing/unpacking in all modules.
  47. Explain what this view is.
  48. Architecture by tesseract
  49. Knee bends in one plane. Doesn’t bend in other planes. (Not without damage anyway!)
  50. This is Phoebe.  213 km mean diameter.