SlideShare a Scribd company logo
1 of 24
Download to read offline
UML for Data Architects:
A Painless Introduction

Dr. Vladimir Bacvanski
vladimir.bacvanski@scispike.com
About the Speaker: Dr. Vladimir Bacvanski

 Mission: to make organizations successful in
  solving problems through adoption of modern
  software technologies
  – Founder of SciSpike – a training and consulting firm
    specializing in advanced software technologies
  – Over two decades of experience with software and data
    technologies
  – Vladimir has helped a number of organizations
    including US Treasury, Federal Reserve Bank, US Navy,
    IBM, Dell, Hewlett Packard, JP Morgan Chase, Nokia,
                                      g
    Lucent, Nortel Networks, General Electric, BAE Systems,
    AMD, and others
  – Frequent speaker at leading industry events.
       q        p              g        y
  – For three years in a row awarded the title "IBM
    Information Champion" for his contributions to the
    information management community
                       g                  y


                        www.scispike.com   Copyright © SciSpike 2011   2
Outline

 What is UML?
 How to approach UML? (aka "Avoiding pain")
 UML diagrams: use only what you need!
         g             y      y
 Representing structure: class (aka type) diagrams
 UML for database design
 Automation
 Conclusion




                   www.scispike.com   Copyright © SciSpike 2011   3
What is UML?

 The UML is a graphical language for
  software intensive systems
    f
  – Note: UML is just a notation:
    the way we visualize our decisions
     h           i li        d ii
 UML covers a broad area of software
  development
  d l         t
 UML is a standard: it enables you to
  express your models i a way th t
                  d l in        that
  can be understood by others




                   www.scispike.com   Copyright © SciSpike 2011   4
Models and Diagrams




 Model is a view of a system from a particular perspective
 Diagram visually presents elements of a model
  – One model can be presented with several diagrams, each
    focusing on a separate aspect

                   www.scispike.com   Copyright © SciSpike 2011   5
UML Diagrams




                                                 Diagrams in italics are introduced in UML 2

           www.scispike.com   Copyright © SciSpike 2011                                        6
Choose your Approach to UML!

        Painful                                                  Painless

• Focus on > 95% of UML                   • Focus on < 5% of UML
  that
  th t you d 't need
           don't     d                      that
                                            th t you need d
• Start with a 1000+                      • Start with a subset
  pages UML Reference                       relevant to data
• Avoid practical                           modeling
  examples                                • Seek practical guides
• Use UML for all the                       and examples
  wrong reasons                           • Use UML to
                                            communicate and
                                            automate

                  www.scispike.com   Copyright © SciSpike 2011              7
Modeling Data with UML Class Diagrams

 A subset of UML Class Diagram is very close to notations
  used in d
     d data modeling
                 d l
 UML Class Diagrams have features not needed for data
  modeling:
    d l
  – Operations (methods)
  – Visibility (public, private, …)
 We can use only a subset that make sense for data modeling:
  – Classes (aka "types")
  – Attributes
  – Associations
  – Generalization

                    www.scispike.com   Copyright © SciSpike 2011   8
UML Classes and Attributes
                                    Class
                                    Similar to entity in ERD.
    Customer
                                    Class name
                                    Typically capitalized.

                                    Attribute Compartment
                                    The only compartment we care about. 
                                    UML classes can have other 
                                    compartments, e.g. for operations.
                                    It is fine to skip parts we don't need!
                                                     pp



                                                                    Note:
                                                                    N t
Attribute Name   Attribute Type                                     High level class 
Typically        E.g. String, Integer,…                             diagrams typically don't 
lowercase.       but also other class names                         need primary and 
                                                                    foreign keys. 
                 www.scispike.com       Copyright © SciSpike 2011                               9
UML Associations
 Association             Association Name                        Multiplicity
                         Usually skipped.                        *: zero or many
                                                                 1..*: one or many
                                                                 0..1: zero or one




 Association Role
 Start from a class, follow the 
 Start from a class follow the                                  Note:
 association, read the role of the                              Foreign key attributes are 
                                                                not needed
 associated objects.


                       www.scispike.com   Copyright © SciSpike 2011                           10
Navigability


                    1..*                             *
     Person                                                        Address
                                       homeAddress




 High level diagrams typically do not show navigability
 Navigability is a design decision!
  – It is a bad practice to assign navigability prematurely
  – Typically not needed for modeling when we target
    relational databases


                    www.scispike.com   Copyright © SciSpike 2011             11
Associations vs. Attributes


       Person
       P                       Multiplicity
                               M lti li it                                   Company
                                                                             C


 employer: Company[*]
   p y        p y[ ]                                                   employee: Person[1..*]
                                                                         p y           [    ]




 In UML, attributes and associations are equivalent!
 Choose the representation that is more suitable to the
  reader
 Important relationships are often represented as
  associations – they bring the visual emphasis

                        www.scispike.com   Copyright © SciSpike 2011                            12
Association Class




                                                                  Association 
                                                                  Class
                                                                  Cl




 Association class allows to attach information to an
  association
  – Often refined into two associations to a class


                   www.scispike.com   Copyright © SciSpike 2011                  13
Association Class Refined




 Association classes are commonly refined in lower level
                                 y
  diagrams



                   www.scispike.com   Copyright © SciSpike 2011   14
Semantics of Aggregation and Composition

                                           1
          Car                                                     Engine


                               Aggregation
                                           1
          Car                                                     Engine


                               Composition

 Aggregation: shortcut for "has" relationship
                             has
  – Does not have a well defined semantics. Use sparingly!
 Composition lifetime of the owner determines the lifetime
  Composition:
  of the owned objects
  – Similar to "cascading"
                cascading
                   www.scispike.com   Copyright © SciSpike 2011            15
Generalization (aka Inheritance)

                                     Employee
                                                                             Generalization
                                                                             G     li i




         Engineer                        Manager                          TechWriter




 Subclasses extend superclasses with additional attributes
  and associations
 This relationship eventually needs to be mapped to tables
  for relational database design
  – Several solutions possible with different performance impact. Choice
                                                          impact
    depends on the typical pattern of usage.
                      www.scispike.com        Copyright © SciSpike 2011                       16
Constraints




 Constraints can be expressed as:
  – Plain text
  – OCL: Object Constraint Language, part of UML
    • Not common in mainstream projects
    • Enforcable



                   www.scispike.com   Copyright © SciSpike 2011   17
Organizing UML Models: Packages

                                          A package is a
                                           structuring element
  Customer
 Management                                – It contains other
                                             elements and
                                             diagrams
   Sales
                                          P k
                                           Packages are important
                                                          i
                                           for managing
                                           complexity of models
                                          Prefer models organized
  Inventory                                into packages to huge
                                           diagrams


              www.scispike.com   Copyright © SciSpike 2011          18
Mapping UML to ER Models…

 Class  Entity
  – Add primary key
 Simple Attribute Type  Column Type
 Complex Attribute Type  Relationship to an entity for the
  attribute type
 Association  Foreign Key relationships
  – Use role names for foreign keys
  – Many-to-many association  add an associative table
  – Aggregation: treat as ordinary relationships




                   www.scispike.com   Copyright © SciSpike 2011   19
…Mapping UML to ER Models

 Generalization: use the usual mappings:
  – Table per class hierarchy
  – Table per subclass
  – Table per concrete class
 Constraints
  – Set constraints on the database
  – Some only enforceable in application logic
             y                 pp          g



  This is just a simplified set of rules to get you going!


                     www.scispike.com   Copyright © SciSpike 2011   20
UML for Database Design




 Agile teams often use UML for both software and database
  design
 UML data modeling profile introduces extensions to UML:
  – <<PK>>, <<FK>>, <<Auto Generated>>, <<Not Null>>,
    <<View>>, <<Stored Procedures>>,…
 Use relational data types
  – String  CHAR(x), VARCHAR(x)

                    www.scispike.com   Copyright © SciSpike 2011   21
Automation

                                                                        Code

                                 Transformer
                                                                        DDL

          Input
                                                                        Models
         Models
                                                                    Output

 Tools can convert from UML to ERD and vice versa
 Model transformation tools operate at a MOF/EMF level and
  can transform UML to various targets
  – Visual Domain Specific Languages (DSLs) based on UML may provide
    better alignment with the p
              g               problem domain than vanilla UML

                     www.scispike.com   Copyright © SciSpike 2011                22
Conclusion

 You will need just a small part of UML!
 UML is a common starting point for data models
 Mapping of UML to ER is quite straightforward
    pp g                  q          g
 Knowing UML makes you a more significant player in the
  software development p
                 p     process




                   www.scispike.com   Copyright © SciSpike 2011   23
Getting in Touch

 Email: vladimir.bacvanski@scispike.com
 Blog: http://www.OnBuildingSoftware.com/
 Twitter: http://twitter.com/OnSoftware
              p
 LinkedIn: http://www.linkedin.com/in/VladimirBacvanski


 SciSpike Training and Consulting:
  http://www.scispike.com
  http://www scispike com
  – Related training for data architects:
    • Visual Modeling with UML
    • Mastering Data Modeling with InfoSphere Data Architect


                   www.scispike.com   Copyright © SciSpike 2011   24

More Related Content

What's hot

A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016
A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016
A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016Daljit Banger
 
Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?DATAVERSITY
 
Unified MLOps: Feature Stores & Model Deployment
Unified MLOps: Feature Stores & Model DeploymentUnified MLOps: Feature Stores & Model Deployment
Unified MLOps: Feature Stores & Model DeploymentDatabricks
 
Enterprise Architecture
Enterprise ArchitectureEnterprise Architecture
Enterprise ArchitectureVikas Grover
 
Career Prospects and Scope of Data Science in India
Career Prospects and Scope of Data Science in IndiaCareer Prospects and Scope of Data Science in India
Career Prospects and Scope of Data Science in Indiaachaljain11
 
Zachman Framework vs Data Architecture
Zachman Framework vs Data ArchitectureZachman Framework vs Data Architecture
Zachman Framework vs Data ArchitectureCarol Harstad
 
Data Science Training | Data Science For Beginners | Data Science With Python...
Data Science Training | Data Science For Beginners | Data Science With Python...Data Science Training | Data Science For Beginners | Data Science With Python...
Data Science Training | Data Science For Beginners | Data Science With Python...Simplilearn
 
Data Science Introduction
Data Science IntroductionData Science Introduction
Data Science IntroductionGang Tao
 
Machine Learning Using Cloud Services
Machine Learning Using Cloud ServicesMachine Learning Using Cloud Services
Machine Learning Using Cloud ServicesSC5.io
 
Machine learning with Big Data power point presentation
Machine learning with Big Data power point presentationMachine learning with Big Data power point presentation
Machine learning with Big Data power point presentationDavid Raj Kanthi
 
Introduction to Microsoft Fabric.pdf
Introduction to Microsoft Fabric.pdfIntroduction to Microsoft Fabric.pdf
Introduction to Microsoft Fabric.pdfishaniuudeshika
 
Enterprise Architecture vs. Data Architecture
Enterprise Architecture vs. Data ArchitectureEnterprise Architecture vs. Data Architecture
Enterprise Architecture vs. Data ArchitectureDATAVERSITY
 
ArchiMate 3.0: A New Standard for Architecture
ArchiMate 3.0: A New Standard for ArchitectureArchiMate 3.0: A New Standard for Architecture
ArchiMate 3.0: A New Standard for ArchitectureIver Band
 
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...Edureka!
 
Data Science Tutorial | Introduction To Data Science | Data Science Training ...
Data Science Tutorial | Introduction To Data Science | Data Science Training ...Data Science Tutorial | Introduction To Data Science | Data Science Training ...
Data Science Tutorial | Introduction To Data Science | Data Science Training ...Edureka!
 
IT Enterprise architecture ppt
IT Enterprise architecture pptIT Enterprise architecture ppt
IT Enterprise architecture pptMonsif sakienah
 
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...Data Science Training | Data Science Tutorial for Beginners | Data Science wi...
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...Edureka!
 
AI Governance and Ethics - Industry Standards
AI Governance and Ethics - Industry StandardsAI Governance and Ethics - Industry Standards
AI Governance and Ethics - Industry StandardsAnsgar Koene
 
Machine Learning and AI
Machine Learning and AIMachine Learning and AI
Machine Learning and AIJames Serra
 

What's hot (20)

A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016
A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016
A Day in the Life of an Enterprise Architect (Role Play Exercise) 2016
 
Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?
 
Unified MLOps: Feature Stores & Model Deployment
Unified MLOps: Feature Stores & Model DeploymentUnified MLOps: Feature Stores & Model Deployment
Unified MLOps: Feature Stores & Model Deployment
 
Enterprise Architecture
Enterprise ArchitectureEnterprise Architecture
Enterprise Architecture
 
Career Prospects and Scope of Data Science in India
Career Prospects and Scope of Data Science in IndiaCareer Prospects and Scope of Data Science in India
Career Prospects and Scope of Data Science in India
 
CismPrepGuide
CismPrepGuideCismPrepGuide
CismPrepGuide
 
Zachman Framework vs Data Architecture
Zachman Framework vs Data ArchitectureZachman Framework vs Data Architecture
Zachman Framework vs Data Architecture
 
Data Science Training | Data Science For Beginners | Data Science With Python...
Data Science Training | Data Science For Beginners | Data Science With Python...Data Science Training | Data Science For Beginners | Data Science With Python...
Data Science Training | Data Science For Beginners | Data Science With Python...
 
Data Science Introduction
Data Science IntroductionData Science Introduction
Data Science Introduction
 
Machine Learning Using Cloud Services
Machine Learning Using Cloud ServicesMachine Learning Using Cloud Services
Machine Learning Using Cloud Services
 
Machine learning with Big Data power point presentation
Machine learning with Big Data power point presentationMachine learning with Big Data power point presentation
Machine learning with Big Data power point presentation
 
Introduction to Microsoft Fabric.pdf
Introduction to Microsoft Fabric.pdfIntroduction to Microsoft Fabric.pdf
Introduction to Microsoft Fabric.pdf
 
Enterprise Architecture vs. Data Architecture
Enterprise Architecture vs. Data ArchitectureEnterprise Architecture vs. Data Architecture
Enterprise Architecture vs. Data Architecture
 
ArchiMate 3.0: A New Standard for Architecture
ArchiMate 3.0: A New Standard for ArchitectureArchiMate 3.0: A New Standard for Architecture
ArchiMate 3.0: A New Standard for Architecture
 
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...
Data Science For Beginners | Who Is A Data Scientist? | Data Science Tutorial...
 
Data Science Tutorial | Introduction To Data Science | Data Science Training ...
Data Science Tutorial | Introduction To Data Science | Data Science Training ...Data Science Tutorial | Introduction To Data Science | Data Science Training ...
Data Science Tutorial | Introduction To Data Science | Data Science Training ...
 
IT Enterprise architecture ppt
IT Enterprise architecture pptIT Enterprise architecture ppt
IT Enterprise architecture ppt
 
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...Data Science Training | Data Science Tutorial for Beginners | Data Science wi...
Data Science Training | Data Science Tutorial for Beginners | Data Science wi...
 
AI Governance and Ethics - Industry Standards
AI Governance and Ethics - Industry StandardsAI Governance and Ethics - Industry Standards
AI Governance and Ethics - Industry Standards
 
Machine Learning and AI
Machine Learning and AIMachine Learning and AI
Machine Learning and AI
 

Viewers also liked

Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...Govt.Engineering college, Idukki
 
UML and Data Modeling - A Reconciliation
UML and Data Modeling - A ReconciliationUML and Data Modeling - A Reconciliation
UML and Data Modeling - A Reconciliationdmurph4
 
Data Modeling for Big Data
Data Modeling for Big DataData Modeling for Big Data
Data Modeling for Big DataDATAVERSITY
 
Win Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsWin Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsVladimir Bacvanski, PhD
 
High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...Vladimir Bacvanski, PhD
 
Introduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceIntroduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceAvkash Chauhan
 
Introduction to Apache Pig
Introduction to Apache PigIntroduction to Apache Pig
Introduction to Apache PigAvkash Chauhan
 
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessData-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessDATAVERSITY
 
CDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyCDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyDATAVERSITY
 
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsData-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsDATAVERSITY
 
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenData-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenDATAVERSITY
 
Data strategy in a Big Data world
Data strategy in a Big Data worldData strategy in a Big Data world
Data strategy in a Big Data worldCraig Milroy
 
Data Governance
Data GovernanceData Governance
Data GovernanceSambaSoup
 
A New Way of Thinking About MDM
A New Way of Thinking About MDMA New Way of Thinking About MDM
A New Way of Thinking About MDMDATAVERSITY
 
Big Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapBig Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapSrinath Perera
 
Data Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesData Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesAlan McSweeney
 

Viewers also liked (20)

Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
 
UML and Data Modeling - A Reconciliation
UML and Data Modeling - A ReconciliationUML and Data Modeling - A Reconciliation
UML and Data Modeling - A Reconciliation
 
Data Modeling for Big Data
Data Modeling for Big DataData Modeling for Big Data
Data Modeling for Big Data
 
Win Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsWin Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLs
 
Introduction to pig
Introduction to pigIntroduction to pig
Introduction to pig
 
High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...
 
Introduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceIntroduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 Conference
 
Introduction to Apache Pig
Introduction to Apache PigIntroduction to Apache Pig
Introduction to Apache Pig
 
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessData-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
 
CDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyCDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data Strategy
 
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsData-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
 
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenData-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
 
Big Data Modeling
Big Data ModelingBig Data Modeling
Big Data Modeling
 
Data strategy in a Big Data world
Data strategy in a Big Data worldData strategy in a Big Data world
Data strategy in a Big Data world
 
Data Governance
Data GovernanceData Governance
Data Governance
 
Data Strategy
Data StrategyData Strategy
Data Strategy
 
A New Way of Thinking About MDM
A New Way of Thinking About MDMA New Way of Thinking About MDM
A New Way of Thinking About MDM
 
8 Steps to Creating a Data Strategy
8 Steps to Creating a Data Strategy8 Steps to Creating a Data Strategy
8 Steps to Creating a Data Strategy
 
Big Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapBig Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and Roadmap
 
Data Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesData Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management Initiatives
 

Similar to UML for Data Architects (20)

SE UML.ppt
SE UML.pptSE UML.ppt
SE UML.ppt
 
Bai giang-uml-14jan14
Bai giang-uml-14jan14Bai giang-uml-14jan14
Bai giang-uml-14jan14
 
Presentation on uml
Presentation on umlPresentation on uml
Presentation on uml
 
UML and Case study
UML and Case study UML and Case study
UML and Case study
 
UNIFIED MODELLING LANGUAGE (UML)
UNIFIED MODELLING LANGUAGE (UML)UNIFIED MODELLING LANGUAGE (UML)
UNIFIED MODELLING LANGUAGE (UML)
 
DISE - OOAD Using UML
DISE - OOAD Using UMLDISE - OOAD Using UML
DISE - OOAD Using UML
 
Ooad lab manual
Ooad  lab manualOoad  lab manual
Ooad lab manual
 
UML.pdf
UML.pdfUML.pdf
UML.pdf
 
Uml Presentation
Uml PresentationUml Presentation
Uml Presentation
 
UML
UMLUML
UML
 
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdfPhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
 
Case stydy cs701
Case stydy cs701 Case stydy cs701
Case stydy cs701
 
Uml overview modified
Uml overview modifiedUml overview modified
Uml overview modified
 
Unit-II(STATIC UML DIAGRAMS).ppt
Unit-II(STATIC UML DIAGRAMS).pptUnit-II(STATIC UML DIAGRAMS).ppt
Unit-II(STATIC UML DIAGRAMS).ppt
 
l1_introuml.pdf
l1_introuml.pdfl1_introuml.pdf
l1_introuml.pdf
 
Srs
SrsSrs
Srs
 
Unified Modeling Language
Unified Modeling LanguageUnified Modeling Language
Unified Modeling Language
 
Intro Uml
Intro UmlIntro Uml
Intro Uml
 
Claas diagram
Claas diagramClaas diagram
Claas diagram
 
Claas diagram
Claas diagramClaas diagram
Claas diagram
 

Recently uploaded

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DaySri Ambati
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 

Recently uploaded (20)

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 

UML for Data Architects

  • 1. UML for Data Architects: A Painless Introduction Dr. Vladimir Bacvanski vladimir.bacvanski@scispike.com
  • 2. About the Speaker: Dr. Vladimir Bacvanski  Mission: to make organizations successful in solving problems through adoption of modern software technologies – Founder of SciSpike – a training and consulting firm specializing in advanced software technologies – Over two decades of experience with software and data technologies – Vladimir has helped a number of organizations including US Treasury, Federal Reserve Bank, US Navy, IBM, Dell, Hewlett Packard, JP Morgan Chase, Nokia, g Lucent, Nortel Networks, General Electric, BAE Systems, AMD, and others – Frequent speaker at leading industry events. q p g y – For three years in a row awarded the title "IBM Information Champion" for his contributions to the information management community g y www.scispike.com Copyright © SciSpike 2011 2
  • 3. Outline  What is UML?  How to approach UML? (aka "Avoiding pain")  UML diagrams: use only what you need! g y y  Representing structure: class (aka type) diagrams  UML for database design  Automation  Conclusion www.scispike.com Copyright © SciSpike 2011 3
  • 4. What is UML?  The UML is a graphical language for software intensive systems f – Note: UML is just a notation: the way we visualize our decisions h i li d ii  UML covers a broad area of software development d l t  UML is a standard: it enables you to express your models i a way th t d l in that can be understood by others www.scispike.com Copyright © SciSpike 2011 4
  • 5. Models and Diagrams  Model is a view of a system from a particular perspective  Diagram visually presents elements of a model – One model can be presented with several diagrams, each focusing on a separate aspect www.scispike.com Copyright © SciSpike 2011 5
  • 6. UML Diagrams Diagrams in italics are introduced in UML 2 www.scispike.com Copyright © SciSpike 2011 6
  • 7. Choose your Approach to UML! Painful Painless • Focus on > 95% of UML • Focus on < 5% of UML that th t you d 't need don't d that th t you need d • Start with a 1000+ • Start with a subset pages UML Reference relevant to data • Avoid practical modeling examples • Seek practical guides • Use UML for all the and examples wrong reasons • Use UML to communicate and automate www.scispike.com Copyright © SciSpike 2011 7
  • 8. Modeling Data with UML Class Diagrams  A subset of UML Class Diagram is very close to notations used in d d data modeling d l  UML Class Diagrams have features not needed for data modeling: d l – Operations (methods) – Visibility (public, private, …)  We can use only a subset that make sense for data modeling: – Classes (aka "types") – Attributes – Associations – Generalization www.scispike.com Copyright © SciSpike 2011 8
  • 9. UML Classes and Attributes Class Similar to entity in ERD. Customer Class name Typically capitalized. Attribute Compartment The only compartment we care about.  UML classes can have other  compartments, e.g. for operations. It is fine to skip parts we don't need! pp Note: N t Attribute Name Attribute Type High level class  Typically  E.g. String, Integer,…  diagrams typically don't  lowercase.  but also other class names need primary and  foreign keys.  www.scispike.com Copyright © SciSpike 2011 9
  • 10. UML Associations Association Association Name Multiplicity Usually skipped. *: zero or many 1..*: one or many 0..1: zero or one Association Role Start from a class, follow the  Start from a class follow the Note: association, read the role of the  Foreign key attributes are  not needed associated objects. www.scispike.com Copyright © SciSpike 2011 10
  • 11. Navigability 1..* * Person Address homeAddress  High level diagrams typically do not show navigability  Navigability is a design decision! – It is a bad practice to assign navigability prematurely – Typically not needed for modeling when we target relational databases www.scispike.com Copyright © SciSpike 2011 11
  • 12. Associations vs. Attributes Person P Multiplicity M lti li it Company C employer: Company[*] p y p y[ ] employee: Person[1..*] p y [ ]  In UML, attributes and associations are equivalent!  Choose the representation that is more suitable to the reader  Important relationships are often represented as associations – they bring the visual emphasis www.scispike.com Copyright © SciSpike 2011 12
  • 13. Association Class Association  Class Cl  Association class allows to attach information to an association – Often refined into two associations to a class www.scispike.com Copyright © SciSpike 2011 13
  • 14. Association Class Refined  Association classes are commonly refined in lower level y diagrams www.scispike.com Copyright © SciSpike 2011 14
  • 15. Semantics of Aggregation and Composition 1 Car Engine Aggregation 1 Car Engine Composition  Aggregation: shortcut for "has" relationship has – Does not have a well defined semantics. Use sparingly!  Composition lifetime of the owner determines the lifetime Composition: of the owned objects – Similar to "cascading" cascading www.scispike.com Copyright © SciSpike 2011 15
  • 16. Generalization (aka Inheritance) Employee Generalization G li i Engineer Manager TechWriter  Subclasses extend superclasses with additional attributes and associations  This relationship eventually needs to be mapped to tables for relational database design – Several solutions possible with different performance impact. Choice impact depends on the typical pattern of usage. www.scispike.com Copyright © SciSpike 2011 16
  • 17. Constraints  Constraints can be expressed as: – Plain text – OCL: Object Constraint Language, part of UML • Not common in mainstream projects • Enforcable www.scispike.com Copyright © SciSpike 2011 17
  • 18. Organizing UML Models: Packages  A package is a structuring element Customer Management – It contains other elements and diagrams Sales  P k Packages are important i for managing complexity of models  Prefer models organized Inventory into packages to huge diagrams www.scispike.com Copyright © SciSpike 2011 18
  • 19. Mapping UML to ER Models…  Class  Entity – Add primary key  Simple Attribute Type  Column Type  Complex Attribute Type  Relationship to an entity for the attribute type  Association  Foreign Key relationships – Use role names for foreign keys – Many-to-many association  add an associative table – Aggregation: treat as ordinary relationships www.scispike.com Copyright © SciSpike 2011 19
  • 20. …Mapping UML to ER Models  Generalization: use the usual mappings: – Table per class hierarchy – Table per subclass – Table per concrete class  Constraints – Set constraints on the database – Some only enforceable in application logic y pp g This is just a simplified set of rules to get you going! www.scispike.com Copyright © SciSpike 2011 20
  • 21. UML for Database Design  Agile teams often use UML for both software and database design  UML data modeling profile introduces extensions to UML: – <<PK>>, <<FK>>, <<Auto Generated>>, <<Not Null>>, <<View>>, <<Stored Procedures>>,…  Use relational data types – String  CHAR(x), VARCHAR(x) www.scispike.com Copyright © SciSpike 2011 21
  • 22. Automation Code Transformer DDL Input Models Models Output  Tools can convert from UML to ERD and vice versa  Model transformation tools operate at a MOF/EMF level and can transform UML to various targets – Visual Domain Specific Languages (DSLs) based on UML may provide better alignment with the p g problem domain than vanilla UML www.scispike.com Copyright © SciSpike 2011 22
  • 23. Conclusion  You will need just a small part of UML!  UML is a common starting point for data models  Mapping of UML to ER is quite straightforward pp g q g  Knowing UML makes you a more significant player in the software development p p process www.scispike.com Copyright © SciSpike 2011 23
  • 24. Getting in Touch  Email: vladimir.bacvanski@scispike.com  Blog: http://www.OnBuildingSoftware.com/  Twitter: http://twitter.com/OnSoftware p  LinkedIn: http://www.linkedin.com/in/VladimirBacvanski  SciSpike Training and Consulting: http://www.scispike.com http://www scispike com – Related training for data architects: • Visual Modeling with UML • Mastering Data Modeling with InfoSphere Data Architect www.scispike.com Copyright © SciSpike 2011 24