NOSQL DATABASES Please remember to read the NOSQL Distilled book and the Seven Databases book.

Slides:



Advertisements
Similar presentations
Mongo An alternative database system. Installing Mongo We must install both the Mongo database and at least one GUI for managing Mongo See
Advertisements

XML DOCUMENTS AND DATABASES
What is a Database By: Cristian Dubon.
Fall 2014, project. XAMPP (or other stack) Go to Install a MySQL, Apache,
COLUMN-BASED DBS BigTable, HBase, SimpleDB, and Cassandra.
Relational Database Alternatives NoSQL. Choosing A Data Model Relational database underpin legacy applications and meet business needs However, companies.
ISSUES THE CLOUD AND DATABASES. WHAT KIND OF DATA MANAGEMENT IS A GOOD FIT WITH THE CLOUD? Analytical data management: data attributes Far more reads.
In 10 minutes Mohannad El Dafrawy Sara Rodriguez Lino Valdivia Jr.
1 Lecture 13: Database Heterogeneity Debriefing Project Phase 2.
Information retrieval Finding relevant data using irrelevant keys Example: database of photographic images sorted by number, date. DBMS: Well structured.
NoSQL and NewSQL Justin DeBrabant CIS Advanced Systems - Fall 2013.
Graph databases …the other end of the NoSQL spectrum. Material taken from NoSQL Distilled and Seven Databases in Seven Weeks.
Information systems and databases Database information systems Read the textbook: Chapter 2: Information systems and databases FOR MORE INFO...
1 CS428 Web Engineering Lecture 18 Introduction (PHP - I)
A Social blog using MongoDB ITEC-810 Final Presentation Lucero Soria Supervisor: Dr. Jian Yang.
Introduction To Databases IDIA 618 Fall 2014 Bridget M. Blodgett.
 Schema-less databases Really…? In actuality, there is no such thing as a schema-less database In a relational database, the schema is explicit and created.
1 Yasin N. Silva Arizona State University This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
XML, distributed databases, and OLAP/warehousing The semantic web and a lot more.
Databases with Scalable capabilities Presented by Mike Trischetta.
Lecture 3 – Data Storage with XML+AJAX and MySQL+socket.io
NoSQL and NOSQL Beginning with o-r databases. First, CRUD… Global notions of managing persistent data, regardless of the model or system Create, Read,
PostgreSQL and relational databases As well as assignment 4…
Systems analysis and design, 6th edition Dennis, wixom, and roth
MongoDB An introduction. What is MongoDB? The name Mongo is derived from Humongous To say that MongoDB can handle a humongous amount of data Document.
HBase A column-centered database 1. Overview An Apache project Influenced by Google’s BigTable Built on Hadoop ▫A distributed file system ▫Supports Map-Reduce.
Alternatives to relational DBs What and Why…. Relational DBs  SQL - Fixed schema, row oriented & optimized  SQL - Rigid 2Phase transactions, with locking.
Physical Database Design & Performance. Optimizing for Query Performance For DBs with high retrieval traffic as compared to maintenance traffic, optimizing.
Goodbye rows and tables, hello documents and collections.
Modern Databases NoSQL and NewSQL Willem Visser RW334.
Query optimization in relational DBs Leveraging the mathematical formal underpinnings of the relational model.
PostgreSQL and relational databases As well as assignment 4…
Moohanad Hassan Maedeh Pishvaei. Introduction Open Source Apache foundation project Relational DB: SQL Server CouchDB : JSON document-oriented DB (NoSQL)
Methodological Foundations of Biomedical Informatics (BMSC-GA 4449) Himanshu Grover.
© Copyright 2013 STI INNSBRUCK
Creating Dynamic Web Pages Using PHP and MySQL CS 320.
Info Systems Fall 2013 . The modern role of often not-so-modern database technology  We will look at MySQL SQL PHP  NoSQL DBs Mongo and GUIs for it.
Fall 2013, Databases, Exam 2 Questions for the second exam. Your answers are due by Dec. 18 at 4PM. (This is the final exam slot.) And please type your.
Database and Data File Management Oct 6/7/8, 2010 Fall 2010 | / Recitation 2.
MongoDB is a database management system designed for web applications and internet infrastructure. The data model and persistence strategies are built.
WEB MINING. In recent years the growth of the World Wide Web exceeded all expectations. Today there are several billions of HTML documents, pictures and.
Fall 2013, Databases, Exam 2 Questions for the second exam…
Management Information Systems, 4 th Edition 1 Chapter 8 Data and Knowledge Management.
Introduction to MongoDB
MongoDB First Light. Mongo DB Basics Mongo is a document based NoSQL. –A document is just a JSON object. –A collection is just a (large) set of documents.
Dynamo: Amazon’s Highly Available Key-value Store DAAS – Database as a service.
NoSQL Or Peles. What is NoSQL A collection of various technologies meant to work around RDBMS limitations (mostly performance) Not much of a definition...
NOSQL DATABASE Not Only SQL DATABASE
Fall CSE330/CIS550: Introduction to Database Management Systems Prof. Susan Davidson Office: 278 Moore Office hours: TTh
Introduction to MongoDB. Database compared.
Data and Information Systems Laboratory University of Illinois Urbana-Champaign Data Mining Meeting Mar, From SQL to NoSQL Xiao Yu Mar 2012.
NoSQL databases A brief introduction NoSQL databases1.
Copyright © 2016 Pearson Education, Inc. Modern Database Management 12 th Edition Jeff Hoffer, Ramesh Venkataraman, Heikki Topi CHAPTER 11: BIG DATA AND.
CS422 Principles of Database Systems Introduction to NoSQL Chengyu Sun California State University, Los Angeles.
Department of Computer Science, Johns Hopkins University EN Instructor: Randal Burns 24 September 2013 NoSQL Data Models and Systems.
Group members: Phạm Hoàng Long Nguyễn Huy Hùng Lê Minh Hiếu Phan Thị Thanh Thảo Nguyễn Đức Trí 1 BIG DATA & NoSQL Topic 1:
Intro to MIS – MGS351 Databases and Data Warehouses
CS122B: Projects in Databases and Web Applications Winter 2017
MongoDB Er. Shiva K. Shrestha ME Computer, NCIT
Introduction to Web programming
Post-relational databases What's wrong with web development?
NOSQL databases and Big Data Storage Systems
Databases and Data Warehouses Chapter 3
1 Demand of your DB is changing Presented By: Ashwani Kumar
Chapter 8 Working with Databases and MySQL
11/18/2018 2:14 PM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN.
another noSql customization for the HDB++ archiving system
relational thoughts on NoSql
Charles Tappert Seidenberg School of CSIS, Pace University
NoSQL & Document Stores
Presentation transcript:

NOSQL DATABASES Please remember to read the NOSQL Distilled book and the Seven Databases book

Before we start The classification of the various nosql databases is imprecise, semi-controversial, and we have to be careful about reading too much into it. Rather than focusing on categorizing dbs, we should be concerned with what they do, how they relate to each other with respect to functionality, and how they compare to sql databases.

Key-value and key-document DBs Databases that access aggregate data Key-value dbs know nothing about the structure of the aggregate Key-document databases do know, but the interpretation of these aggregates happens outside the db Keep in mind that these two categories of databases overlap in practice Importantly, both of these two database systems categories focus on storing and retrieving individual aggregates, and not on interrelating (horizontally) multiple aggregates There is something similar to this in SQL DBs – and that is highly un-normalized tables

Important notions… It can be a difficult problem to represent some domains as key-value or key-document databases, as the boundaries of aggregates might not be easy to determine. This basic data modeling issue has a lot of influence on the sort of database you should use. Relational databases don’t manipulate aggregates, but they are aggregate neutral for the most part, leaving the construction of aggregates to run time … but we might have hidden, un-normalized tables that make some commonly used aggregates much faster to materialize

Key-value vs. key-document In key-value databases, we can only retrieve data via a key In key-document databases, we may be able to ask questions about the content of documents – but again, we are not cross-associating them Mongo is perhaps the most talked about key-document system, and so we will start there

Installing Mongo Mongo A GUI

Mongo overview Document based Focuses on clusters for extremely large scaling Supports nested documents Uses JavaScript for queries No schema

Terminology A database consists of collections Collections are made up of documents A document is made up of fields There are also indices There are also cursors

When to use Mongo Medical records and other large document systems Read heavy environments like analytics and mining Partnered with relational databases Relational for live data Mongo for huge largely read only archives Online applications Massively wide e-commerce

Mongo documents and queries Documents Self-defining, with hierarchical structure like XML Or JSON, which uses javascript to define docs in a human-readable form Documents can vary in structure, even in the same collection You can add attributes to new documents in a collection without having the change the existing ones in the collection Queries: db.order.find({“customerId”:”99”})

Consistency and transactions There is a tailor-able consistency command that can be used the level you want for updating replicas of documents No multi-document atomic transactions are supported CAP theorem, which basically says there is a tradeoff between availability and consistency You can embed references to other documents in a document, but this tends to create a “join effect” DBRef is the command

Selectors Used for finding, counting, updating, and removing docs from collections {} is the null search and matches all documents We could run: {gender:’f’} {field1: value1, field2: value2} creates an ‘and’ operation Also, less than, greater than, etc. (e.g., $gt) $exists, $or

Some notes on Mongo There are a few GUIs that seem pretty good Mongo-vision: (web page) Needs Prudence as a web server MongoVue: but Windows onlyhttp://mongovue.com RockMongo (web based): (web page) Needs an apache web server Very easy to install, just download

Getting an Apache web server XAMPP for windows (mac version is way out of date) MAMP for Macs (on the app store) WAMP for windows (bitnami.org) All of these give you PHP and MySQL as well. If we have time, we will look at MySQL full text search. You might want to install PostgreSQL, too. There is a bitnami stack. If there is time, we will look at PostgreSQL UDTs and full text search.

Another document DB: CouchDB Major focus: surviving network problems Engineered for web use No ad hoc querying, searching is via map reduce-based indices We will get back to CouchDB

Map Reduce Focus is on performing data operations on parallel hardware This is a paradigm, not a specific programmatic technique Each map reduce process has two phases Convert a list into a desired sort of list with the map operator Convert the new list into a small number of atomic values via a reduce operator This allows us to spread an process across a wide array of servers, with each server performing an independent map reduce process

Map reduce example, from Seven DBs Map phase: go through a list of items and find all that are related to Canada, and turning them to 1’s Reduce phase: compress this second list by adding up the 1’s to get the cardinality The first list could be spread across an array of machines, with the results being filtered into a smaller number, and the final result filtered into a final, single machine.