SlideShare a Scribd company logo
Hackolade Tutorial
Part 3- Query driven data modeling based on access patterns
Copyright © 2016-2023 Hackolade 1
The rules of data modeling
• Data modeling for RDBMSs uses the rules of normalization
Copyright © 2016-2023 Hackolade 2
The rules of data modeling
• NoSQL databases are completely different
• Different data models
• Different sizing parameters and capabilities
• True “horizontal” scalability in infinitely distributed systems
• Different transactional capabilities
• immediate vs. eventual consistency
• ACID vs BASE
• Different use cases
• NoSQL requires a mindshift in schema design, adhering to different
rules and parameters
Copyright © 2016-2023 Hackolade 3
The rules of data modeling
• NoSQL advocates UNLEARNING the rules of normalisation
• NoSQL allows to aggregate information that belongs together
• join the data “on write”, instead of (time and time again) “on read”
Copyright © 2016-2023 Hackolade 4
The NoSQL mindshift
• From APPLICATION-AGNOSTIC to APPLICATION-SPECIFIC data
modeling
Copyright © 2016-2023 Hackolade 5
The ”Embedding” approach
Query driven data modeling
• first define the queries (aka “access patterns”) for the
application,
• then store the data according to the query needs
• Ideally, single db access should provide access to all related,
joined-up information: EMBEDDING the data into single
atomic document
<> “referencing” – leveraging data stored elsewhere using foreign keys, pulled
in with joins
Copyright © 2016-2023 Hackolade 6
Important factors for Query-driven Data Modeling
• Aggregate / Document size and transaction volume
• Cardinality of relationships
• Beware of unbounded arrays: consequences of unlimited growth!
• When embedding one-to-many relationships, one should estimate
the cardinality
Copyright © 2016-2023 Hackolade 7
Important factors for Query-driven Data Modeling
Referential integrity
• To ACID or not to ACID
• Embedding vs. ACID: documents are atomic units!
• Role of the application!
Indexing impacts
Polymorphic document designs can lead to proliferation of
indexes
Data duplication can be a good idea!
Copyright © 2016-2023 Hackolade 8
Schema versioning and migration
• Schemas can often be evolved without interruption of
database operations.
• Handle with care!
• Especially when multiple applications / reporting & analytical tools access
the same DB!
• Transition periods & strategies matter!
Copyright © 2016-2023 Hackolade 9
Schema versioning and migration
Different strategies are used:
• Eager: first migrate data, then application
• Does not leverage the benefits of JSON
• Lazy: only update the document when used
• Some documents will never be migrated!
• Incremental: migrate when lower load!
• Predictive migration: based on heuristics/estimates
• Also combinations of strategies: predictive migration
first, followed by incremental
• Endless versioning: not desirable!
• See entire chapter in MongoDB Data Modeling & Schema Design
book
Copyright © 2016-2023 Hackolade 10
Backward- and forward-compatibility
• No database is an island: many systems interacting with it
• Avoid the introduction of breaking changes: huge impacts on
agility and costs.
• Think through each evolution: features in schema standards
(JSON Schema, Avro, etc.) for full compatibility of schemas.
• consumers and producers can upgrade at their own pace!
Copyright © 2016-2023 Hackolade 11
Choice of partition / sharding keys
• NoSQL databases offer horizontal scaling
• through distribution of data across servers, data centers and
geographies
• Requires careful design
• find a scalable way to facilitate efficient retrieval of information
when serving queries, from a minimal number of shards
• a query should hit 1 shard!
Copyright © 2016-2023 Hackolade 12
Facilitating communication and collaboration
• The purpose of all Data Modeling!!!
• “Looking at the code” vs. sharing an ERD picture
• Data modeling and schema design for NOSQL databases and data
formats provides some guardrails in the face of unlimited flexibility
and power of NoSQL.
Copyright © 2016-2023 Hackolade 13
Reading material
• See Hackolade online documentation
• The Hackolade Blog
• This excellent new book:
MongoDB Data Modeling & Schema Design
• Many of the principles in the book are related to query
driven modeling based on access patterns!
• Hackolade’s on social media: LinkedIn page, Twitter page
• Download Hackolade studio for free
Copyright © 2016-2023 Hackolade 14
Questions?
Answers!
Copyright © 2016-2023 Hackolade 15

More Related Content

What's hot (20)

New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptxNew features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
Muralidharan Deenathayalan
 
Angular Interview Questions & Answers
Angular Interview Questions & AnswersAngular Interview Questions & Answers
Angular Interview Questions & Answers
Ratnala Charan kumar
 
Migrating Oracle database to PostgreSQL
Migrating Oracle database to PostgreSQLMigrating Oracle database to PostgreSQL
Migrating Oracle database to PostgreSQL
Umair Mansoob
 
Programming the Semantic Web
Programming the Semantic WebProgramming the Semantic Web
Programming the Semantic Web
Luigi De Russis
 
LOD連続講義 第5回「LODの作り方・使い方」
LOD連続講義 第5回「LODの作り方・使い方」LOD連続講義 第5回「LODの作り方・使い方」
LOD連続講義 第5回「LODの作り方・使い方」
Fuyuko Matsumura
 
Angular
AngularAngular
Angular
Lilia Sfaxi
 
Shift: Real World Migration from MongoDB to Cassandra
Shift: Real World Migration from MongoDB to CassandraShift: Real World Migration from MongoDB to Cassandra
Shift: Real World Migration from MongoDB to Cassandra
DataStax
 
Learn REST in 18 Slides
Learn REST in 18 SlidesLearn REST in 18 Slides
Learn REST in 18 Slides
Suraj Gupta
 
Model Your Application Domain, Not Your JSON Structures
Model Your Application Domain, Not Your JSON StructuresModel Your Application Domain, Not Your JSON Structures
Model Your Application Domain, Not Your JSON Structures
Markus Lanthaler
 
SHACL: Shaping the Big Ball of Data Mud
SHACL: Shaping the Big Ball of Data MudSHACL: Shaping the Big Ball of Data Mud
SHACL: Shaping the Big Ball of Data Mud
Richard Cyganiak
 
Web-Socket
Web-SocketWeb-Socket
Web-Socket
Pankaj Kumar Sharma
 
RDF and OWL
RDF and OWLRDF and OWL
RDF and OWL
Rachel Lovinger
 
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Edureka!
 
Angular overview
Angular overviewAngular overview
Angular overview
Thanvilahari
 
Angular Data Binding
Angular Data BindingAngular Data Binding
Angular Data Binding
Jennifer Estrada
 
Angular 14.pptx
Angular 14.pptxAngular 14.pptx
Angular 14.pptx
MohaNedGhawar
 
Model View Presenter
Model View Presenter Model View Presenter
Model View Presenter
rendra toro
 
Angular 6 - The Complete Guide
Angular 6 - The Complete GuideAngular 6 - The Complete Guide
Angular 6 - The Complete Guide
Sam Dias
 
GraphQL vs REST
GraphQL vs RESTGraphQL vs REST
GraphQL vs REST
GreeceJS
 
Hackolade Tutorial - part 13 - Leverage a Polyglot data model
Hackolade Tutorial - part 13 - Leverage a Polyglot data modelHackolade Tutorial - part 13 - Leverage a Polyglot data model
Hackolade Tutorial - part 13 - Leverage a Polyglot data model
PascalDesmarets1
 
New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptxNew features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
New features of Minimal APIs in .NET 7 -Muralidharan Deenathayalan.pptx
Muralidharan Deenathayalan
 
Angular Interview Questions & Answers
Angular Interview Questions & AnswersAngular Interview Questions & Answers
Angular Interview Questions & Answers
Ratnala Charan kumar
 
Migrating Oracle database to PostgreSQL
Migrating Oracle database to PostgreSQLMigrating Oracle database to PostgreSQL
Migrating Oracle database to PostgreSQL
Umair Mansoob
 
Programming the Semantic Web
Programming the Semantic WebProgramming the Semantic Web
Programming the Semantic Web
Luigi De Russis
 
LOD連続講義 第5回「LODの作り方・使い方」
LOD連続講義 第5回「LODの作り方・使い方」LOD連続講義 第5回「LODの作り方・使い方」
LOD連続講義 第5回「LODの作り方・使い方」
Fuyuko Matsumura
 
Shift: Real World Migration from MongoDB to Cassandra
Shift: Real World Migration from MongoDB to CassandraShift: Real World Migration from MongoDB to Cassandra
Shift: Real World Migration from MongoDB to Cassandra
DataStax
 
Learn REST in 18 Slides
Learn REST in 18 SlidesLearn REST in 18 Slides
Learn REST in 18 Slides
Suraj Gupta
 
Model Your Application Domain, Not Your JSON Structures
Model Your Application Domain, Not Your JSON StructuresModel Your Application Domain, Not Your JSON Structures
Model Your Application Domain, Not Your JSON Structures
Markus Lanthaler
 
SHACL: Shaping the Big Ball of Data Mud
SHACL: Shaping the Big Ball of Data MudSHACL: Shaping the Big Ball of Data Mud
SHACL: Shaping the Big Ball of Data Mud
Richard Cyganiak
 
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Edureka!
 
Model View Presenter
Model View Presenter Model View Presenter
Model View Presenter
rendra toro
 
Angular 6 - The Complete Guide
Angular 6 - The Complete GuideAngular 6 - The Complete Guide
Angular 6 - The Complete Guide
Sam Dias
 
GraphQL vs REST
GraphQL vs RESTGraphQL vs REST
GraphQL vs REST
GreeceJS
 
Hackolade Tutorial - part 13 - Leverage a Polyglot data model
Hackolade Tutorial - part 13 - Leverage a Polyglot data modelHackolade Tutorial - part 13 - Leverage a Polyglot data model
Hackolade Tutorial - part 13 - Leverage a Polyglot data model
PascalDesmarets1
 

Similar to Hackolade Tutorial - part 3 - Query-driven data modeling based on access patterns (20)

NoSQL Simplified: Schema vs. Schema-less
NoSQL Simplified: Schema vs. Schema-lessNoSQL Simplified: Schema vs. Schema-less
NoSQL Simplified: Schema vs. Schema-less
InfiniteGraph
 
Hackolade Tutorial - part 1 - What is a data model
Hackolade Tutorial - part 1 - What is a data modelHackolade Tutorial - part 1 - What is a data model
Hackolade Tutorial - part 1 - What is a data model
PascalDesmarets1
 
UNIT-2.pptx
UNIT-2.pptxUNIT-2.pptx
UNIT-2.pptx
SIVAKUMARM603675
 
No SQL- The Future Of Data Storage
No SQL- The Future Of Data StorageNo SQL- The Future Of Data Storage
No SQL- The Future Of Data Storage
Bethmi Gunasekara
 
the rising no sql technology
the rising no sql technologythe rising no sql technology
the rising no sql technology
INFOGAIN PUBLICATION
 
introduction to NOSQL Database
introduction to NOSQL Databaseintroduction to NOSQL Database
introduction to NOSQL Database
nehabsairam
 
Introduction to NoSQL database technology
Introduction to NoSQL database technologyIntroduction to NoSQL database technology
Introduction to NoSQL database technology
nicolausalex722
 
NoSQL Architecture Overview
NoSQL Architecture OverviewNoSQL Architecture Overview
NoSQL Architecture Overview
Christopher Foot
 
NoSql Brownbag
NoSql BrownbagNoSql Brownbag
NoSql Brownbag
Sandeep Kumar
 
Muskan Kumari (1276) Intro to NoSql.pptx. pptx
Muskan Kumari (1276) Intro to NoSql.pptx.    pptxMuskan Kumari (1276) Intro to NoSql.pptx.    pptx
Muskan Kumari (1276) Intro to NoSql.pptx. pptx
jeetigangar18
 
Couchbase 3.0.2 d1
Couchbase 3.0.2  d1Couchbase 3.0.2  d1
Couchbase 3.0.2 d1
Sachin Kumar Kansal
 
Introduction to NoSQL and MongoDB
Introduction to NoSQL and MongoDBIntroduction to NoSQL and MongoDB
Introduction to NoSQL and MongoDB
Ahmed Farag
 
DBMS - Introduction.ppt
DBMS - Introduction.pptDBMS - Introduction.ppt
DBMS - Introduction.ppt
SATHYABAMAMADHANKUMA
 
NoSQL
NoSQLNoSQL
NoSQL
Radu Vunvulea
 
SQL vs NoSQL Data Modeling.pptx
SQL vs NoSQL Data Modeling.pptxSQL vs NoSQL Data Modeling.pptx
SQL vs NoSQL Data Modeling.pptx
GarimaHasija1
 
NoSQL(MongoDB and DynamoDB) Overview.pptx
NoSQL(MongoDB and DynamoDB) Overview.pptxNoSQL(MongoDB and DynamoDB) Overview.pptx
NoSQL(MongoDB and DynamoDB) Overview.pptx
nikhilaukhaj590
 
NoSQL and MongoDB
NoSQL and MongoDBNoSQL and MongoDB
NoSQL and MongoDB
Rajesh Menon
 
Presentation On NoSQL Databases
Presentation On NoSQL DatabasesPresentation On NoSQL Databases
Presentation On NoSQL Databases
Abiral Gautam
 
Nosql-Module 1 PPT.pptx
Nosql-Module 1 PPT.pptxNosql-Module 1 PPT.pptx
Nosql-Module 1 PPT.pptx
Radhika R
 
Introduction to NoSQL
Introduction to NoSQLIntroduction to NoSQL
Introduction to NoSQL
balwinders
 
NoSQL Simplified: Schema vs. Schema-less
NoSQL Simplified: Schema vs. Schema-lessNoSQL Simplified: Schema vs. Schema-less
NoSQL Simplified: Schema vs. Schema-less
InfiniteGraph
 
Hackolade Tutorial - part 1 - What is a data model
Hackolade Tutorial - part 1 - What is a data modelHackolade Tutorial - part 1 - What is a data model
Hackolade Tutorial - part 1 - What is a data model
PascalDesmarets1
 
No SQL- The Future Of Data Storage
No SQL- The Future Of Data StorageNo SQL- The Future Of Data Storage
No SQL- The Future Of Data Storage
Bethmi Gunasekara
 
introduction to NOSQL Database
introduction to NOSQL Databaseintroduction to NOSQL Database
introduction to NOSQL Database
nehabsairam
 
Introduction to NoSQL database technology
Introduction to NoSQL database technologyIntroduction to NoSQL database technology
Introduction to NoSQL database technology
nicolausalex722
 
NoSQL Architecture Overview
NoSQL Architecture OverviewNoSQL Architecture Overview
NoSQL Architecture Overview
Christopher Foot
 
Muskan Kumari (1276) Intro to NoSql.pptx. pptx
Muskan Kumari (1276) Intro to NoSql.pptx.    pptxMuskan Kumari (1276) Intro to NoSql.pptx.    pptx
Muskan Kumari (1276) Intro to NoSql.pptx. pptx
jeetigangar18
 
Introduction to NoSQL and MongoDB
Introduction to NoSQL and MongoDBIntroduction to NoSQL and MongoDB
Introduction to NoSQL and MongoDB
Ahmed Farag
 
SQL vs NoSQL Data Modeling.pptx
SQL vs NoSQL Data Modeling.pptxSQL vs NoSQL Data Modeling.pptx
SQL vs NoSQL Data Modeling.pptx
GarimaHasija1
 
NoSQL(MongoDB and DynamoDB) Overview.pptx
NoSQL(MongoDB and DynamoDB) Overview.pptxNoSQL(MongoDB and DynamoDB) Overview.pptx
NoSQL(MongoDB and DynamoDB) Overview.pptx
nikhilaukhaj590
 
Presentation On NoSQL Databases
Presentation On NoSQL DatabasesPresentation On NoSQL Databases
Presentation On NoSQL Databases
Abiral Gautam
 
Nosql-Module 1 PPT.pptx
Nosql-Module 1 PPT.pptxNosql-Module 1 PPT.pptx
Nosql-Module 1 PPT.pptx
Radhika R
 
Introduction to NoSQL
Introduction to NoSQLIntroduction to NoSQL
Introduction to NoSQL
balwinders
 

More from PascalDesmarets1 (20)

Tutorial Workgroup - Working with Forks
Tutorial Workgroup - Working with ForksTutorial Workgroup - Working with Forks
Tutorial Workgroup - Working with Forks
PascalDesmarets1
 
Tutorial Advanced How-To - Oracle 23c Duality views
Tutorial Advanced How-To - Oracle 23c Duality viewsTutorial Advanced How-To - Oracle 23c Duality views
Tutorial Advanced How-To - Oracle 23c Duality views
PascalDesmarets1
 
Tutorial Expert How-To - Docker-based automation
Tutorial Expert How-To - Docker-based automationTutorial Expert How-To - Docker-based automation
Tutorial Expert How-To - Docker-based automation
PascalDesmarets1
 
Tutorial Getting Started part 4 - Domain-Driven Data Modeling
Tutorial Getting Started part 4 - Domain-Driven Data ModelingTutorial Getting Started part 4 - Domain-Driven Data Modeling
Tutorial Getting Started part 4 - Domain-Driven Data Modeling
PascalDesmarets1
 
Tutorial Getting Started part 3 - Metadata-as-Code
Tutorial Getting Started part 3 - Metadata-as-CodeTutorial Getting Started part 3 - Metadata-as-Code
Tutorial Getting Started part 3 - Metadata-as-Code
PascalDesmarets1
 
Tutorial Getting Started part 2 - Polyglot Data Modeling
Tutorial Getting Started part 2 - Polyglot Data ModelingTutorial Getting Started part 2 - Polyglot Data Modeling
Tutorial Getting Started part 2 - Polyglot Data Modeling
PascalDesmarets1
 
Tutorial Expert How-To - Create a model for Avro schemas
Tutorial Expert How-To - Create a model for Avro schemasTutorial Expert How-To - Create a model for Avro schemas
Tutorial Expert How-To - Create a model for Avro schemas
PascalDesmarets1
 
Tutorial Getting Started part 1 - Overview
Tutorial Getting Started part 1 - OverviewTutorial Getting Started part 1 - Overview
Tutorial Getting Started part 1 - Overview
PascalDesmarets1
 
Tutorial Expert How-To - Verify Data Model
Tutorial Expert How-To - Verify Data ModelTutorial Expert How-To - Verify Data Model
Tutorial Expert How-To - Verify Data Model
PascalDesmarets1
 
Tutorial Workgroup - Model versioning and collaboration
Tutorial Workgroup - Model versioning and collaborationTutorial Workgroup - Model versioning and collaboration
Tutorial Workgroup - Model versioning and collaboration
PascalDesmarets1
 
Tutorial Expert How-To - Naming Conventions
Tutorial Expert How-To - Naming ConventionsTutorial Expert How-To - Naming Conventions
Tutorial Expert How-To - Naming Conventions
PascalDesmarets1
 
Tutorial Expert How-To - Export-Import with Excel template
Tutorial Expert How-To - Export-Import with Excel templateTutorial Expert How-To - Export-Import with Excel template
Tutorial Expert How-To - Export-Import with Excel template
PascalDesmarets1
 
Tutorial Expert How-To - Compare and Merge
Tutorial Expert How-To - Compare and MergeTutorial Expert How-To - Compare and Merge
Tutorial Expert How-To - Compare and Merge
PascalDesmarets1
 
Tutorial Expert How-To - Custom properties
Tutorial Expert How-To - Custom propertiesTutorial Expert How-To - Custom properties
Tutorial Expert How-To - Custom properties
PascalDesmarets1
 
Tutorial Expert How-To - Command Line Interface (CLI)
Tutorial Expert How-To - Command Line Interface (CLI)Tutorial Expert How-To - Command Line Interface (CLI)
Tutorial Expert How-To - Command Line Interface (CLI)
PascalDesmarets1
 
Tutorial Expert How-To - Add reusable Definitions
Tutorial Expert How-To - Add reusable DefinitionsTutorial Expert How-To - Add reusable Definitions
Tutorial Expert How-To - Add reusable Definitions
PascalDesmarets1
 
Hackolade Tutorial - part 12 - Create a REST API model
Hackolade Tutorial - part  12 - Create a REST API modelHackolade Tutorial - part  12 - Create a REST API model
Hackolade Tutorial - part 12 - Create a REST API model
PascalDesmarets1
 
Hackolade Tutorial - part 9 - Export or forward-engineer.pdf
Hackolade Tutorial - part 9 - Export or forward-engineer.pdfHackolade Tutorial - part 9 - Export or forward-engineer.pdf
Hackolade Tutorial - part 9 - Export or forward-engineer.pdf
PascalDesmarets1
 
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdf
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdfHackolade Tutorial - part 8 - Import or reverse-engineer.pdf
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdf
PascalDesmarets1
 
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdfHackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
PascalDesmarets1
 
Tutorial Workgroup - Working with Forks
Tutorial Workgroup - Working with ForksTutorial Workgroup - Working with Forks
Tutorial Workgroup - Working with Forks
PascalDesmarets1
 
Tutorial Advanced How-To - Oracle 23c Duality views
Tutorial Advanced How-To - Oracle 23c Duality viewsTutorial Advanced How-To - Oracle 23c Duality views
Tutorial Advanced How-To - Oracle 23c Duality views
PascalDesmarets1
 
Tutorial Expert How-To - Docker-based automation
Tutorial Expert How-To - Docker-based automationTutorial Expert How-To - Docker-based automation
Tutorial Expert How-To - Docker-based automation
PascalDesmarets1
 
Tutorial Getting Started part 4 - Domain-Driven Data Modeling
Tutorial Getting Started part 4 - Domain-Driven Data ModelingTutorial Getting Started part 4 - Domain-Driven Data Modeling
Tutorial Getting Started part 4 - Domain-Driven Data Modeling
PascalDesmarets1
 
Tutorial Getting Started part 3 - Metadata-as-Code
Tutorial Getting Started part 3 - Metadata-as-CodeTutorial Getting Started part 3 - Metadata-as-Code
Tutorial Getting Started part 3 - Metadata-as-Code
PascalDesmarets1
 
Tutorial Getting Started part 2 - Polyglot Data Modeling
Tutorial Getting Started part 2 - Polyglot Data ModelingTutorial Getting Started part 2 - Polyglot Data Modeling
Tutorial Getting Started part 2 - Polyglot Data Modeling
PascalDesmarets1
 
Tutorial Expert How-To - Create a model for Avro schemas
Tutorial Expert How-To - Create a model for Avro schemasTutorial Expert How-To - Create a model for Avro schemas
Tutorial Expert How-To - Create a model for Avro schemas
PascalDesmarets1
 
Tutorial Getting Started part 1 - Overview
Tutorial Getting Started part 1 - OverviewTutorial Getting Started part 1 - Overview
Tutorial Getting Started part 1 - Overview
PascalDesmarets1
 
Tutorial Expert How-To - Verify Data Model
Tutorial Expert How-To - Verify Data ModelTutorial Expert How-To - Verify Data Model
Tutorial Expert How-To - Verify Data Model
PascalDesmarets1
 
Tutorial Workgroup - Model versioning and collaboration
Tutorial Workgroup - Model versioning and collaborationTutorial Workgroup - Model versioning and collaboration
Tutorial Workgroup - Model versioning and collaboration
PascalDesmarets1
 
Tutorial Expert How-To - Naming Conventions
Tutorial Expert How-To - Naming ConventionsTutorial Expert How-To - Naming Conventions
Tutorial Expert How-To - Naming Conventions
PascalDesmarets1
 
Tutorial Expert How-To - Export-Import with Excel template
Tutorial Expert How-To - Export-Import with Excel templateTutorial Expert How-To - Export-Import with Excel template
Tutorial Expert How-To - Export-Import with Excel template
PascalDesmarets1
 
Tutorial Expert How-To - Compare and Merge
Tutorial Expert How-To - Compare and MergeTutorial Expert How-To - Compare and Merge
Tutorial Expert How-To - Compare and Merge
PascalDesmarets1
 
Tutorial Expert How-To - Custom properties
Tutorial Expert How-To - Custom propertiesTutorial Expert How-To - Custom properties
Tutorial Expert How-To - Custom properties
PascalDesmarets1
 
Tutorial Expert How-To - Command Line Interface (CLI)
Tutorial Expert How-To - Command Line Interface (CLI)Tutorial Expert How-To - Command Line Interface (CLI)
Tutorial Expert How-To - Command Line Interface (CLI)
PascalDesmarets1
 
Tutorial Expert How-To - Add reusable Definitions
Tutorial Expert How-To - Add reusable DefinitionsTutorial Expert How-To - Add reusable Definitions
Tutorial Expert How-To - Add reusable Definitions
PascalDesmarets1
 
Hackolade Tutorial - part 12 - Create a REST API model
Hackolade Tutorial - part  12 - Create a REST API modelHackolade Tutorial - part  12 - Create a REST API model
Hackolade Tutorial - part 12 - Create a REST API model
PascalDesmarets1
 
Hackolade Tutorial - part 9 - Export or forward-engineer.pdf
Hackolade Tutorial - part 9 - Export or forward-engineer.pdfHackolade Tutorial - part 9 - Export or forward-engineer.pdf
Hackolade Tutorial - part 9 - Export or forward-engineer.pdf
PascalDesmarets1
 
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdf
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdfHackolade Tutorial - part 8 - Import or reverse-engineer.pdf
Hackolade Tutorial - part 8 - Import or reverse-engineer.pdf
PascalDesmarets1
 
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdfHackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
Hackolade Tutorial - part 6 - Add choice, conditional, pattern fields.pdf
PascalDesmarets1
 

Recently uploaded (20)

Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Vasileios Komianos
 
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Maarten Verwaest
 
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptxDevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
Justin Reock
 
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Alan Dix
 
Unlocking Generative AI in your Web Apps
Unlocking Generative AI in your Web AppsUnlocking Generative AI in your Web Apps
Unlocking Generative AI in your Web Apps
Maximiliano Firtman
 
Agentic Automation - Delhi UiPath Community Meetup
Agentic Automation - Delhi UiPath Community MeetupAgentic Automation - Delhi UiPath Community Meetup
Agentic Automation - Delhi UiPath Community Meetup
Manoj Batra (1600 + Connections)
 
An Overview of Salesforce Health Cloud & How is it Transforming Patient Care
An Overview of Salesforce Health Cloud & How is it Transforming Patient CareAn Overview of Salesforce Health Cloud & How is it Transforming Patient Care
An Overview of Salesforce Health Cloud & How is it Transforming Patient Care
Cyntexa
 
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Christian Folini
 
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
Toru Tamaki
 
Shoehorning dependency injection into a FP language, what does it take?
Shoehorning dependency injection into a FP language, what does it take?Shoehorning dependency injection into a FP language, what does it take?
Shoehorning dependency injection into a FP language, what does it take?
Eric Torreborre
 
Cybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft CertificateCybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft Certificate
VICTOR MAESTRE RAMIREZ
 
Building the Customer Identity Community, Together.pdf
Building the Customer Identity Community, Together.pdfBuilding the Customer Identity Community, Together.pdf
Building the Customer Identity Community, Together.pdf
Cheryl Hung
 
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Cyntexa
 
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
Ivano Malavolta
 
Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)
Kaya Weers
 
Mastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B LandscapeMastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B Landscape
marketing943205
 
fennec fox optimization algorithm for optimal solution
fennec fox optimization algorithm for optimal solutionfennec fox optimization algorithm for optimal solution
fennec fox optimization algorithm for optimal solution
shallal2
 
May Patch Tuesday
May Patch TuesdayMay Patch Tuesday
May Patch Tuesday
Ivanti
 
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
ICT Frame Magazine Pvt. Ltd.
 
Config 2025 presentation recap covering both days
Config 2025 presentation recap covering both daysConfig 2025 presentation recap covering both days
Config 2025 presentation recap covering both days
TrishAntoni1
 
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Vasileios Komianos
 
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Limecraft Webinar - 2025.3 release, featuring Content Delivery, Graphic Conte...
Maarten Verwaest
 
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptxDevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
Justin Reock
 
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Who's choice? Making decisions with and about Artificial Intelligence, Keele ...
Alan Dix
 
Unlocking Generative AI in your Web Apps
Unlocking Generative AI in your Web AppsUnlocking Generative AI in your Web Apps
Unlocking Generative AI in your Web Apps
Maximiliano Firtman
 
An Overview of Salesforce Health Cloud & How is it Transforming Patient Care
An Overview of Salesforce Health Cloud & How is it Transforming Patient CareAn Overview of Salesforce Health Cloud & How is it Transforming Patient Care
An Overview of Salesforce Health Cloud & How is it Transforming Patient Care
Cyntexa
 
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Crazy Incentives and How They Kill Security. How Do You Turn the Wheel?
Christian Folini
 
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
論文紹介:"InfLoRA: Interference-Free Low-Rank Adaptation for Continual Learning" ...
Toru Tamaki
 
Shoehorning dependency injection into a FP language, what does it take?
Shoehorning dependency injection into a FP language, what does it take?Shoehorning dependency injection into a FP language, what does it take?
Shoehorning dependency injection into a FP language, what does it take?
Eric Torreborre
 
Cybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft CertificateCybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft Certificate
VICTOR MAESTRE RAMIREZ
 
Building the Customer Identity Community, Together.pdf
Building the Customer Identity Community, Together.pdfBuilding the Customer Identity Community, Together.pdf
Building the Customer Identity Community, Together.pdf
Cheryl Hung
 
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Why Slack Should Be Your Next Business Tool? (Tips to Make Most out of Slack)
Cyntexa
 
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
On-Device or Remote? On the Energy Efficiency of Fetching LLM-Generated Conte...
Ivano Malavolta
 
Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)
Kaya Weers
 
Mastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B LandscapeMastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B Landscape
marketing943205
 
fennec fox optimization algorithm for optimal solution
fennec fox optimization algorithm for optimal solutionfennec fox optimization algorithm for optimal solution
fennec fox optimization algorithm for optimal solution
shallal2
 
May Patch Tuesday
May Patch TuesdayMay Patch Tuesday
May Patch Tuesday
Ivanti
 
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
MULTI-STAKEHOLDER CONSULTATION PROGRAM On Implementation of DNF 2.0 and Way F...
ICT Frame Magazine Pvt. Ltd.
 
Config 2025 presentation recap covering both days
Config 2025 presentation recap covering both daysConfig 2025 presentation recap covering both days
Config 2025 presentation recap covering both days
TrishAntoni1
 

Hackolade Tutorial - part 3 - Query-driven data modeling based on access patterns

  • 1. Hackolade Tutorial Part 3- Query driven data modeling based on access patterns Copyright © 2016-2023 Hackolade 1
  • 2. The rules of data modeling • Data modeling for RDBMSs uses the rules of normalization Copyright © 2016-2023 Hackolade 2
  • 3. The rules of data modeling • NoSQL databases are completely different • Different data models • Different sizing parameters and capabilities • True “horizontal” scalability in infinitely distributed systems • Different transactional capabilities • immediate vs. eventual consistency • ACID vs BASE • Different use cases • NoSQL requires a mindshift in schema design, adhering to different rules and parameters Copyright © 2016-2023 Hackolade 3
  • 4. The rules of data modeling • NoSQL advocates UNLEARNING the rules of normalisation • NoSQL allows to aggregate information that belongs together • join the data “on write”, instead of (time and time again) “on read” Copyright © 2016-2023 Hackolade 4
  • 5. The NoSQL mindshift • From APPLICATION-AGNOSTIC to APPLICATION-SPECIFIC data modeling Copyright © 2016-2023 Hackolade 5
  • 6. The ”Embedding” approach Query driven data modeling • first define the queries (aka “access patterns”) for the application, • then store the data according to the query needs • Ideally, single db access should provide access to all related, joined-up information: EMBEDDING the data into single atomic document <> “referencing” – leveraging data stored elsewhere using foreign keys, pulled in with joins Copyright © 2016-2023 Hackolade 6
  • 7. Important factors for Query-driven Data Modeling • Aggregate / Document size and transaction volume • Cardinality of relationships • Beware of unbounded arrays: consequences of unlimited growth! • When embedding one-to-many relationships, one should estimate the cardinality Copyright © 2016-2023 Hackolade 7
  • 8. Important factors for Query-driven Data Modeling Referential integrity • To ACID or not to ACID • Embedding vs. ACID: documents are atomic units! • Role of the application! Indexing impacts Polymorphic document designs can lead to proliferation of indexes Data duplication can be a good idea! Copyright © 2016-2023 Hackolade 8
  • 9. Schema versioning and migration • Schemas can often be evolved without interruption of database operations. • Handle with care! • Especially when multiple applications / reporting & analytical tools access the same DB! • Transition periods & strategies matter! Copyright © 2016-2023 Hackolade 9
  • 10. Schema versioning and migration Different strategies are used: • Eager: first migrate data, then application • Does not leverage the benefits of JSON • Lazy: only update the document when used • Some documents will never be migrated! • Incremental: migrate when lower load! • Predictive migration: based on heuristics/estimates • Also combinations of strategies: predictive migration first, followed by incremental • Endless versioning: not desirable! • See entire chapter in MongoDB Data Modeling & Schema Design book Copyright © 2016-2023 Hackolade 10
  • 11. Backward- and forward-compatibility • No database is an island: many systems interacting with it • Avoid the introduction of breaking changes: huge impacts on agility and costs. • Think through each evolution: features in schema standards (JSON Schema, Avro, etc.) for full compatibility of schemas. • consumers and producers can upgrade at their own pace! Copyright © 2016-2023 Hackolade 11
  • 12. Choice of partition / sharding keys • NoSQL databases offer horizontal scaling • through distribution of data across servers, data centers and geographies • Requires careful design • find a scalable way to facilitate efficient retrieval of information when serving queries, from a minimal number of shards • a query should hit 1 shard! Copyright © 2016-2023 Hackolade 12
  • 13. Facilitating communication and collaboration • The purpose of all Data Modeling!!! • “Looking at the code” vs. sharing an ERD picture • Data modeling and schema design for NOSQL databases and data formats provides some guardrails in the face of unlimited flexibility and power of NoSQL. Copyright © 2016-2023 Hackolade 13
  • 14. Reading material • See Hackolade online documentation • The Hackolade Blog • This excellent new book: MongoDB Data Modeling & Schema Design • Many of the principles in the book are related to query driven modeling based on access patterns! • Hackolade’s on social media: LinkedIn page, Twitter page • Download Hackolade studio for free Copyright © 2016-2023 Hackolade 14
  翻译: