SlideShare una empresa de Scribd logo
1 de 56
NoSQL: Azure Table Storage & MongoDB 
Alternativas y escenarios de uso NoSQL 
@erincon Eladio Rincón 
Director Relacional 
MCT, MVP SQL Server 
@augurarte Miguel López 
Director Cloud | mlopez@solidq.com 
MCT, MCPD, MCTS, MCP 
1
Agenda 
Bases de datos relacionales y NoSQL 
Microsoft Azure Table Storage 
– Fundamentos MSATS 
– Diseño de NoSQL con MSATS 
– Programación del modelo 
MongoDB 
– Fundamentos 
– Diseño de NoSQL con MongoDB 
– Programación del modelo 
Escenarios 
Evaluación de costes 
3
NoSQL: Azure Table Storage & MongoDB 
BDD Relacionales y NoSQL 
Almacenamiento de table de Azure (MSATS) 
MongoDB 
Escenarios 
Costes
BDD Relacionales y NoSQL 
Las BDD Relacionales lideran el conjunto de sistemas 
de almacenamiento transaccional, escritura atómica, 
indexación de columnas, optimización de consultas y 
lenguaje de consulta declarative orientado a conjuntos. 
Las BDD NoSQL se emplean de forma generalizada en 
sitios Web de tipo social masivamente accedidos y que 
necesitan escalar de forma intensiva, donde la 
característica principal son conjuntos de datos simples 
(frente a consultas complejas) 
© 2012 SolidQ 5
Donde gasta el tiempo RDBMS en TPCC 
http://static.cs.brown.edu/courses/csci2270/papers/looking-glass.pdf
Teorema de CAP 
7
Teorema de CAP: Selección de variables 
8
NoSQL 
Next Generation Databases mostly addressing 
some of the points: being non-relational, 
distributed, open-source and horizontally 
scalable. 
http://NoSQL-database.org 9
NoSQL Evolución y características 
• Surgen a principios de 2009 
• Crecimiento exponencial. 
• Características comunes más importantes: 
• No se basan en esquema 
• Soporte de replicación sencillo 
• API de fácil utilización 
• Consistencia parcial (eventually consistent) / BASE (not ACID) 
• Enormes cantidades de información. 
• "nosql" es traducido tradicionalmente como "not only sql“, y se 
considera un alias que referencia la definición anterior. 
10
Modelos de datos NoSQL 
http://www.slideshare.net/emileifrem/nosql-east-a-nosql-overview-and-the-benefits-of-graph-databases 
11
Grandes familias NoSQL 
• Wide Column Store / Column Families 
• Document Store 
• Key Value / Tuple Store 
• Graph Databases 
• Multimodel Databases 
• Object Databases 
• Grid & Cloud Database Solutions 
• XML Databases 
• Multidimensional Databases 
• Multivalue Databases 
• Event Sourcing 
• Network Model 
12
DEMO 
13 
http://nosql-database.org 
Bases de datos NoSQL (listado)
NoSQL: Azure Table Storage & MongoDB 
BDD Relacionales y NoSQL 
Almacenamiento de table de Azure (MSATS) 
MongoDB 
Escenarios 
Costes
Almacenamiento de table Azure 
Windows Azure Table Service 
Windows Azure tables 
Designing Windows Azure Tables 
Implementing Windows Azure Tables 
Querying Windows Azure Tables 
Accessing table storage 
Table Storage Security 
– Set container permissions. 
– Use Shared Access Signatures (SAS) 
– Stored Access Policies 
15
Cuentas de almacenamiento MSA 
User creates a globally unique storage account name 
Choose the primary location to host storage account 
Three regions: 
– “North Central US”, “South Central US” 
– “North Europe”, “Europe West” 
– “South East Asia”, “East Asia” 
Table Service: 
http://myaccount.table.core.windows.net 
16
DEMO 
17 
Aprovisionamiento de una 
cuenta de almacenamiento 
de Azure
Características MSATS 
• Tabla de almacenamiento de Azure 
• Colección de entidades (parejas clave, valor) 
• La entidad tiene una clave principal y un conjunto 
aleatorio no definido (schema-less) de 
propiedades. 
• PartitionKey (Particionamiento / distribución de carga / escalado) 
• RowKey (conjuntos de filas relacionadas en una partición) 
• TimeStamp (Sólo lectura, TS creación) 
• Una propiedad es un par de nombre/valor (con tipo) 
similar a una columna 
• MSATS no fuerza la creación o validación de esquema 
• El desarrollador necesitará implementar un esquema 
concreto para su acceso 
18
Abstracciones MSATS 
19
DEMO 
20 
Aplicación 
https://haveibeenpwned.com/
Entidades del MSATS 
Entities are the basic data item stored in a table 
Collections of properties that are name value pairs. 
Each entity has 3 fixed properties called PartitionKey, 
RowKey and Timestamp. 
If we were to map this to concepts in a conventional 
database system, an entity is analogous to a row and 
property is analogous to a column. 
An entity can have up to 255 – 3 properties = 252 (3 
system properties are reserved). 
1 Entity = 1 MB of data (Maximum) 
21
Entidades: Tipos de datos de propiedades 
• Byte[] 
• Bool 
• DateTime 
• Double 
• Guid 
• Int32/Int 
• Int64/long 
• String 
22
Entidades: Indexación (Primary Key) 
• PartitionKey property 
• RowKey property 
• Timestamp property 
23
Características de las propiedades PK 
• Tablas particionadas para soportar balanceo de carga 
entre nodos de almacenamiento. 
• Las entidades se organizan por partición. 
• Una partición es un rango consecutive de entidades 
con la misma clave de partición. 
• Partition key: Identificador único de partición dentro 
de una tabla. 
• PK es la primera parte de la clave principal de una 
entidad. 
• PK puede ser una cadena de hasta 1KB de tamaño. 
• Incluir PartitionKey property en cada insert, update, y 
delete. 
24
Características de las propiedades RowKey 
RowKey 
• The row key is a unique identifier for an entity within 
a given partition. 
• Together the PartitionKey and RowKey uniquely 
identify every entity within a table. 
• The row key is a string value that may be up to 1 KB 
in size. 
• You must include the RowKey property in every 
insert, update, and delete operation. 
25
MSATS es una BDD sin esquema 
26 
PartitionKey: str 
2012102517USR91 
P 
V 
RowKey: str 
jobid0121 
P 
V 
TimeStamp: dt 
201210251715 
P 
V 
Name: st 
User_91 
P 
V 
PartitionKey: str 
2012102517USR10 
P 
V 
RowKey: str 
jobid0121 
P 
V 
TimeStamp: dt 
201210251735 
P 
V 
Status: st 
Processing 
P 
V 
Name: st 
User_10 
P 
V 
PartitionKey: str 
2012102517USR10 
P 
V 
RowKey: str 
jobid0125 
P 
V 
TimeStamp: dt 
201210251755 
P 
V 
RoleExec: st 
IN_121 
P 
V 
Name: st 
User_10 
P 
V 
LastOp: st 
Decrypt 
P 
V 
PartitionKey: str 
2012102517USR13 
P 
V 
RowKey: str 
jobid0002 
P 
V 
TimeStamp: dt 
201210251759 
P 
V 
Name: st 
User_13 
P 
V 
PartitionKey: str 
2012102517USR13 
P 
V 
RowKey: str 
jobid0001 
P 
V 
TimeStamp: dt 
201210251755 
P 
V 
Name: st 
User_13 
P 
V 
Status: st 
Aborted 
P 
V 
TABLE JOBEXECUTION
Consulta del servicio de tabla 
27 
PartitionKey: str 
2012102517USR91 
P 
V 
RowKey: str 
jobid0121 
P 
V 
TimeStamp: dt 
201210251715 
P 
V 
Name: st 
User_91 
P 
V 
PartitionKey: str 
2012102517USR10 
P 
V 
RowKey: str 
jobid0121 
P 
V 
TimeStamp: dt 
201210251735 
P 
V 
Status: st 
Processing 
P 
V 
Name: st 
User_10 
P 
V 
PartitionKey: str 
2012102517USR10 
P 
V 
RowKey: str 
jobid0125 
P 
V 
TimeStamp: dt 
201210251755 
P 
V 
RoleExec: st 
IN_121 
P 
V 
Name: st 
User_10 
P 
V 
LastOp: st 
Decrypt 
P 
V 
PartitionKey: str 
2012102517USR13 
P 
V 
RowKey: str 
jobid0002 
P 
V 
TimeStamp: dt 
201210251759 
P 
V 
Name: st 
User_13 
P 
V 
PartitionKey: str 
2012102517USR13 
P 
V 
RowKey: str 
jobid0001 
P 
V 
TimeStamp: dt 
201210251755 
P 
V 
Name: st 
User_13 
P 
V 
Status: st 
Aborted 
P 
V 
TABLE JOBEXECUTION
Particiones (nodos) MSATS 
28
Partitions and Partition Ranges
DEMO 
Acceso a un sistema MSATS 
en producción 
30
Table Storage Design 
Define your model 
Key selection 
31
Key selection: Considerations 
Entity Group Transactions 
Scalability 
Efficient queries 
32
DEMO 
33 
Gestión de tablas con cliente 
Windows
Modelo de programación 
Windows Azure Storage: Connection Strings 
Managing tables in WATS 
Entities: CRUD operations (Create, read, update, delete) 
Querying tables 
Perform Entity Group Transactions (EGT) 
34
Connection Strings in Visual Studio 2013 
Double click on the Web/Worker role in the solution 
© 2012 SolidQ 35
Managing tables in WATS 
Use Microsoft.WindowsAzure.StorageClient. There are 
several ways of creating tables. 
Initialize tables once: for example using session or 
Application start events. 
Use CreateCloudTableClient to interact with WATS 
For example, to create a table called ‘Products’: 
36 
using Microsoft.WindowsAzure; 
using Microsoft.WindowsAzure.StorageClient; 
var clAccount; 
clAccount = CloudStorageAccount.FromConfigurationSettings(“ProductStorage") 
var tableClient = clAccount.CreateCloudTableClient(); 
tableClient.CreateTableIfNotExists(“Products”)
Entidades: Operaciones CRUD 
Configurar las entidades (modelo de clases) 
Configurar un DataContext 
37
Configuración de las entidades 
Class modeling 
38
Operaciones CRUD 
Setting up data context 
Context class is required in .NET to access the WAT 
using WCF Data Services and the correspondent entity 
(GE06LDataEntry). 
39 
namespace GE06L_Data { 
public class GE06LDataContext : TableServiceContext { 
public GE06LDataContext(string baseAddress, 
Microsoft.WindowsAzure.StorageCredentials credentials) 
: base(baseAddress, credentials) {} 
public IQueryable<GE06LEntry> GE06LEntry { 
get { 
return this.CreateQuery<GE06LEntry>(“GE06LEntry");} 
} 
} 
}
Entities CRUD operations 
List, Add, Update 
// List (read) operation for GE06LEntry entities 
public IEnumerable<GE06LEntry> GetGE06LEntries() { 
var results = from g in this.context.GE06LEntry 
where g.PartitionKey == DateTime.UtcNow.ToString("MMddyyyy") 
40 
select g; 
return results; } 
// Add operation for GE06LEntry entities 
public void AddGE06LEntry(GE06LEntry newItem) { 
this.context.AddObject(“GE06LEntry", newItem); 
this.context.SaveChanges(); } 
// Update operation for GE06LEntry entities 
public void UpdateFileURL(string partitionKey, string rowKey, 
string fileUrl) { 
var results = from g in this.context.GE06LEntry 
where g.PartitionKey == partitionKey && g.RowKey == rowKey 
select g; 
var entry = results.FirstOrDefault<GE06LEntry>(); 
entry.FilelUrl = fileUrl; 
this.context.UpdateObject(entry); 
this.context.SaveChanges(); }
Consultar MSATS 
Single Entity (a.k.a. Point Queries) 
41 
var q = ( 
from pais in context.CreateQuery<Pais>(tableName) 
where pais.PartitionKey == “Paises“ && 
pais.RowKey == “España" 
select movie);
Consultar MSATS 
Range Queries - Row Range Scan 
var q = ( 
from movie in context.CreateQuery<Movie>(tableName) 
where 
movie.PartitionKey == "Action" && 
movie.RowKey.CompareTo("Alien") >= 0 && 
movie.RowKey.CompareTo("Terminator") <= 0 && 
movie.IsFavorite 
select movie 
); 
© 2012 SolidQ 42
Consultar MSATS 
Range Queries - Partition Range Scan 
43 
var q = ( 
from movie in context.CreateQuery<Movie>(tableName) 
where 
movie.PartitionKey == "Action" && 
movie.RowKey.CompareTo("Alien") >= 0 && 
movie.RowKey.CompareTo("Terminator") <= 0 && 
movie.IsFavorite 
select movie 
);
Consultar MSATS 
Full Table Scan 
var q = (from movie in context.CreateQuery<Movie>(tableName) 
44 
select movie ); 
var q = (from movie in context.CreateQuery<Movie>(tableName) 
where movie.PartitionKey.CompareTo("Action") != 0 
select movie ); 
var q = ( 
from movie in context.CreateQuery<Movie>(tableName) 
where movie.IsFavorite select movie); var q = 
(from movie in context.CreateQuery<Movie>(tableName) 
where movie.RowKey.CompareTo("Sh") >= 0 && 
movie.RowKey.CompareTo("Si") < 0 
select movie );
DEMO 
45 
Programación de MSATS
NoSQL: Azure Table Storage & MongoDB 
BDD Relacionales y NoSQL 
Almacenamiento de table de Azure (MSATS) 
MongoDB 
Escenarios 
Costes
MongoDB 
Motivación 
• ¿”Problemas” en RDBMs tradicionales? 
47 
• Transaciones 
• JOINs 
• Prescindimos de ellos 
• Transacciones a nivel de documento 
• No dejamos hacer JOINs
MongoDB 
Unidad de Información es el Documento 
48
MongoDB: Otro Paradigma 
49 
• Filosofía Schema On-Read 
• El Esquema es importante (aunque laxo) 
• En algún momento necesitas “modelar” 
• Antes o después 
• Modelos Mapeados en Memoria 
• “Cerveza con alcohol vs cerveza sin alcohol” by 
Garrigós 
• Importante arquitectura x64!
MongoDB: Conceptos Clave 
• Aunque veamos JSON, almacenado en binario 
50 
– BSON 
• Consola de administración  JavaScript y 
JSON 
• Varios GUI tipo SSMS 
• Drivers de Mongo para facilitar desarrollo 
• Driver para C# y usar LINQ 
• Modelos de persistencia para mapeo 
• MongoRepository 
• Sharding y Replicasets
DEMO 
51 
MongoDB en Azure con 
correos electrónicos
NoSQL: Azure Table Storage & MongoDB 
BDD Relacionales y NoSQL 
Almacenamiento de table de Azure (MSATS) 
MongoDB 
Escenarios 
Costes
Escenarios 
Aplicaciones altamente escalables que necesitan 
consultas sencillas y rápidas 
• ONU, datos georeferenciados, info calculada 
• Energética, metadatos 
• BIG Data, datos temporales/sensores 
• Información social / redes sociales 
• Aplicaciones de localización de correos, direcciones, etc. 
53
NoSQL: Azure Table Storage & MongoDB 
BDD Relacionales y NoSQL 
Almacenamiento de table de Azure (MSATS) 
MongoDB 
Escenarios 
Costes
Costes 
Microsoft Azure Table Storage 
MongoDB on Azure 
55
NoSQL: Azure Table Storage & MongoDB 
Bases de datos relacionales y NoSQL 
Microsoft Azure Table Storage 
– Fundamentos MSATS 
– Diseño de NoSQL con MSATS 
– Programación del modelo 
MongoDB 
– Fundamentos 
– Diseño de NoSQL con MongoDB 
– Programación del modelo 
Escenarios 
Evaluación de costes 
56
Si quieres disfrutar de las mejores sesiones de 
nuestros mentores de España y Latino América, 
ésta es tu oportunidad. 
http://summit.solidq.com 
Síguenos: 
58

Más contenido relacionado

La actualidad más candente

Comparación entre microsoft sql server express edition 2012 y oracle
Comparación entre microsoft sql server express edition 2012 y oracleComparación entre microsoft sql server express edition 2012 y oracle
Comparación entre microsoft sql server express edition 2012 y oracleOsmar Zaragoza
 
8. Acceso A Datos Con Microsoft Ado.Net
8.  Acceso A Datos Con Microsoft Ado.Net8.  Acceso A Datos Con Microsoft Ado.Net
8. Acceso A Datos Con Microsoft Ado.Netguest3cf6ff
 
Introduccion a las Bodegas de Datos
Introduccion a las Bodegas de DatosIntroduccion a las Bodegas de Datos
Introduccion a las Bodegas de DatosJoseph Lopez
 
03 acceso a datos con ado net
03 acceso a datos con ado net03 acceso a datos con ado net
03 acceso a datos con ado netELMER ÑAUPAS
 
Novedades sql server 2008 para developers
Novedades sql server 2008 para developersNovedades sql server 2008 para developers
Novedades sql server 2008 para developersEnrique Catala Bañuls
 
Administración de base de datos oracle - sesion 11
Administración de base de datos oracle  -  sesion 11Administración de base de datos oracle  -  sesion 11
Administración de base de datos oracle - sesion 11Sefira111
 
Azure sql database escalabilidad
Azure sql database escalabilidadAzure sql database escalabilidad
Azure sql database escalabilidadEduardo Castro
 
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...SpanishPASSVC
 
Introduccion a SQL Server 2016 Stretch Databases
Introduccion a SQL Server 2016 Stretch DatabasesIntroduccion a SQL Server 2016 Stretch Databases
Introduccion a SQL Server 2016 Stretch DatabasesEduardo Castro
 
Ado.net 2012
Ado.net 2012Ado.net 2012
Ado.net 2012pepelon_k
 
Recuperación ante desastres y continuidad del negocio con Azure SQL Database
Recuperación ante desastres y continuidad del negocio con Azure SQL DatabaseRecuperación ante desastres y continuidad del negocio con Azure SQL Database
Recuperación ante desastres y continuidad del negocio con Azure SQL DatabaseJoseph Lopez
 
Análisis de datos con Apache Spark
Análisis de datos con Apache SparkAnálisis de datos con Apache Spark
Análisis de datos con Apache SparkEduardo Castro
 
Consideraciones de sql server hardware
Consideraciones de sql server hardwareConsideraciones de sql server hardware
Consideraciones de sql server hardwareEduardo Castro
 
Vistazo a lo nuevo en SQL Server 2016
Vistazo a lo nuevo en SQL Server 2016Vistazo a lo nuevo en SQL Server 2016
Vistazo a lo nuevo en SQL Server 2016Eduardo Castro
 
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-netLuis Fernando Aguas Bucheli
 
Visual 2010 sql server 2008
Visual 2010 sql server 2008Visual 2010 sql server 2008
Visual 2010 sql server 2008Alex Vasquez
 

La actualidad más candente (20)

Comparación entre microsoft sql server express edition 2012 y oracle
Comparación entre microsoft sql server express edition 2012 y oracleComparación entre microsoft sql server express edition 2012 y oracle
Comparación entre microsoft sql server express edition 2012 y oracle
 
8. Acceso A Datos Con Microsoft Ado.Net
8.  Acceso A Datos Con Microsoft Ado.Net8.  Acceso A Datos Con Microsoft Ado.Net
8. Acceso A Datos Con Microsoft Ado.Net
 
Introduccion a las Bodegas de Datos
Introduccion a las Bodegas de DatosIntroduccion a las Bodegas de Datos
Introduccion a las Bodegas de Datos
 
03 acceso a datos con ado net
03 acceso a datos con ado net03 acceso a datos con ado net
03 acceso a datos con ado net
 
Novedades sql server 2008 para developers
Novedades sql server 2008 para developersNovedades sql server 2008 para developers
Novedades sql server 2008 para developers
 
Administración de base de datos oracle - sesion 11
Administración de base de datos oracle  -  sesion 11Administración de base de datos oracle  -  sesion 11
Administración de base de datos oracle - sesion 11
 
Azure sql database escalabilidad
Azure sql database escalabilidadAzure sql database escalabilidad
Azure sql database escalabilidad
 
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...
24 HOP edición Español - Patrones de escalalidad en microsoft azure sql datab...
 
Introduccion a SQL Server 2016 Stretch Databases
Introduccion a SQL Server 2016 Stretch DatabasesIntroduccion a SQL Server 2016 Stretch Databases
Introduccion a SQL Server 2016 Stretch Databases
 
JAVA CON BASE DE DATOS
JAVA CON BASE DE DATOSJAVA CON BASE DE DATOS
JAVA CON BASE DE DATOS
 
2. ssis 2008 r2
2. ssis 2008 r22. ssis 2008 r2
2. ssis 2008 r2
 
Ado.net 2012
Ado.net 2012Ado.net 2012
Ado.net 2012
 
Recuperación ante desastres y continuidad del negocio con Azure SQL Database
Recuperación ante desastres y continuidad del negocio con Azure SQL DatabaseRecuperación ante desastres y continuidad del negocio con Azure SQL Database
Recuperación ante desastres y continuidad del negocio con Azure SQL Database
 
Análisis de datos con Apache Spark
Análisis de datos con Apache SparkAnálisis de datos con Apache Spark
Análisis de datos con Apache Spark
 
ADO
ADOADO
ADO
 
Base de datos
Base de datosBase de datos
Base de datos
 
Consideraciones de sql server hardware
Consideraciones de sql server hardwareConsideraciones de sql server hardware
Consideraciones de sql server hardware
 
Vistazo a lo nuevo en SQL Server 2016
Vistazo a lo nuevo en SQL Server 2016Vistazo a lo nuevo en SQL Server 2016
Vistazo a lo nuevo en SQL Server 2016
 
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net
12-Unidad 2: Aplicaciones Windows Forms-2.3 Ado-net
 
Visual 2010 sql server 2008
Visual 2010 sql server 2008Visual 2010 sql server 2008
Visual 2010 sql server 2008
 

Similar a NoSQL Azure y MongoDB

Introducción a Microsoft Azure SQL Data Warehouse
Introducción a Microsoft Azure SQL Data WarehouseIntroducción a Microsoft Azure SQL Data Warehouse
Introducción a Microsoft Azure SQL Data WarehouseJoseph Lopez
 
TUTORIAL DE ADO.NET MUY BUENO
TUTORIAL DE ADO.NET MUY BUENOTUTORIAL DE ADO.NET MUY BUENO
TUTORIAL DE ADO.NET MUY BUENOiberhack
 
Datawarehouse como servicio en Azure (sqldw)
Datawarehouse como servicio en Azure (sqldw)Datawarehouse como servicio en Azure (sqldw)
Datawarehouse como servicio en Azure (sqldw)SolidQ
 
Datawarehouse como servicio en azure (sqldw)
Datawarehouse como servicio en azure (sqldw)Datawarehouse como servicio en azure (sqldw)
Datawarehouse como servicio en azure (sqldw)Enrique Catala Bañuls
 
ADO NET Entity FrameWork
ADO NET Entity FrameWorkADO NET Entity FrameWork
ADO NET Entity FrameWorkmascodigo
 
Mejores prácticas de Data Warehouse con SQL Server
Mejores prácticas de Data Warehouse con SQL ServerMejores prácticas de Data Warehouse con SQL Server
Mejores prácticas de Data Warehouse con SQL ServerSpanishPASSVC
 
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptxCarlosSaid7
 
Linq to sql 2
Linq to sql 2Linq to sql 2
Linq to sql 2jcfarit
 
Persistencia de un modelo de objetos
Persistencia de un modelo de objetosPersistencia de un modelo de objetos
Persistencia de un modelo de objetosJorge Ercoli
 
Administración y programación en sql server
Administración y programación en sql serverAdministración y programación en sql server
Administración y programación en sql serverIsabel_Samir
 
Bases de datos NoSQL - Huancayo - 2010
Bases de datos NoSQL - Huancayo - 2010Bases de datos NoSQL - Huancayo - 2010
Bases de datos NoSQL - Huancayo - 2010Antonio Ognio
 
Azure SQL Data Warehouse desde cada_angulo
Azure SQL Data Warehouse desde cada_anguloAzure SQL Data Warehouse desde cada_angulo
Azure SQL Data Warehouse desde cada_anguloAdrian Miranda
 
SQL Server rápido y furioso
SQL Server rápido y furiosoSQL Server rápido y furioso
SQL Server rápido y furiosoSpanishPASSVC
 
Investigacion alter, create y integridad referencial
Investigacion alter, create y integridad referencialInvestigacion alter, create y integridad referencial
Investigacion alter, create y integridad referencial500y
 
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptx
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptxEFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptx
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptxLuis Fernando Aguas Bucheli
 

Similar a NoSQL Azure y MongoDB (20)

Introducción a Microsoft Azure SQL Data Warehouse
Introducción a Microsoft Azure SQL Data WarehouseIntroducción a Microsoft Azure SQL Data Warehouse
Introducción a Microsoft Azure SQL Data Warehouse
 
Base de datos - Clase 1
Base de datos - Clase 1Base de datos - Clase 1
Base de datos - Clase 1
 
TUTORIAL DE ADO.NET MUY BUENO
TUTORIAL DE ADO.NET MUY BUENOTUTORIAL DE ADO.NET MUY BUENO
TUTORIAL DE ADO.NET MUY BUENO
 
ADO.NET
ADO.NETADO.NET
ADO.NET
 
Cubos ppt
Cubos pptCubos ppt
Cubos ppt
 
Datawarehouse como servicio en Azure (sqldw)
Datawarehouse como servicio en Azure (sqldw)Datawarehouse como servicio en Azure (sqldw)
Datawarehouse como servicio en Azure (sqldw)
 
Datawarehouse como servicio en azure (sqldw)
Datawarehouse como servicio en azure (sqldw)Datawarehouse como servicio en azure (sqldw)
Datawarehouse como servicio en azure (sqldw)
 
ADO NET Entity FrameWork
ADO NET Entity FrameWorkADO NET Entity FrameWork
ADO NET Entity FrameWork
 
Mejores prácticas de Data Warehouse con SQL Server
Mejores prácticas de Data Warehouse con SQL ServerMejores prácticas de Data Warehouse con SQL Server
Mejores prácticas de Data Warehouse con SQL Server
 
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx
1_ Introducción a Oracle, SqlDeveloper, Usuarios-Privilegios.pptx
 
Linq to sql 2
Linq to sql 2Linq to sql 2
Linq to sql 2
 
Persistencia de un modelo de objetos
Persistencia de un modelo de objetosPersistencia de un modelo de objetos
Persistencia de un modelo de objetos
 
sesion 01_sql basico.pdf
sesion 01_sql basico.pdfsesion 01_sql basico.pdf
sesion 01_sql basico.pdf
 
Administración y programación en sql server
Administración y programación en sql serverAdministración y programación en sql server
Administración y programación en sql server
 
Bases de datos NoSQL - Huancayo - 2010
Bases de datos NoSQL - Huancayo - 2010Bases de datos NoSQL - Huancayo - 2010
Bases de datos NoSQL - Huancayo - 2010
 
Azure SQL Data Warehouse desde cada_angulo
Azure SQL Data Warehouse desde cada_anguloAzure SQL Data Warehouse desde cada_angulo
Azure SQL Data Warehouse desde cada_angulo
 
SQL Server rápido y furioso
SQL Server rápido y furiosoSQL Server rápido y furioso
SQL Server rápido y furioso
 
Investigacion alter, create y integridad referencial
Investigacion alter, create y integridad referencialInvestigacion alter, create y integridad referencial
Investigacion alter, create y integridad referencial
 
SEVILLA Meetups23032023.pdf
SEVILLA Meetups23032023.pdfSEVILLA Meetups23032023.pdf
SEVILLA Meetups23032023.pdf
 
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptx
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptxEFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptx
EFC-Programación .net-Luis Fernando Aguas - 15012022 1500.pptx
 

Más de SolidQ

SolidQ Summit 2018 - Qué necesita saber un DBA de Integration Services
SolidQ Summit 2018 - Qué necesita saber un DBA de Integration ServicesSolidQ Summit 2018 - Qué necesita saber un DBA de Integration Services
SolidQ Summit 2018 - Qué necesita saber un DBA de Integration ServicesSolidQ
 
SolidQ Summit 2018 - Seguridad a nivel datos. RLS
SolidQ Summit 2018 - Seguridad a nivel datos. RLSSolidQ Summit 2018 - Seguridad a nivel datos. RLS
SolidQ Summit 2018 - Seguridad a nivel datos. RLSSolidQ
 
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...SolidQ
 
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...SolidQ
 
SolidQ Summit 2018 - Report Server: Nuevos mutantes
SolidQ Summit 2018 - Report Server: Nuevos mutantesSolidQ Summit 2018 - Report Server: Nuevos mutantes
SolidQ Summit 2018 - Report Server: Nuevos mutantesSolidQ
 
Cuando QueryStore no sirve, ¿qué opciones tenemos?
Cuando QueryStore no sirve, ¿qué opciones tenemos?Cuando QueryStore no sirve, ¿qué opciones tenemos?
Cuando QueryStore no sirve, ¿qué opciones tenemos?SolidQ
 
SQL Server 2017 en Linux
SQL Server 2017 en LinuxSQL Server 2017 en Linux
SQL Server 2017 en LinuxSolidQ
 
Columnstore en la vida real
Columnstore en la vida realColumnstore en la vida real
Columnstore en la vida realSolidQ
 
PowerApprízate
PowerApprízatePowerApprízate
PowerApprízateSolidQ
 
Jugando a ser rico: Machine Learning para predicción de stocks
Jugando a ser rico: Machine Learning para predicción de stocksJugando a ser rico: Machine Learning para predicción de stocks
Jugando a ser rico: Machine Learning para predicción de stocksSolidQ
 
Analizando tus Redes Sociales con Power BI
Analizando tus Redes Sociales con Power BIAnalizando tus Redes Sociales con Power BI
Analizando tus Redes Sociales con Power BISolidQ
 
Mantenimiento de SQL Server para Dummies
Mantenimiento de SQL Server para DummiesMantenimiento de SQL Server para Dummies
Mantenimiento de SQL Server para DummiesSolidQ
 
R en relacional
R en relacionalR en relacional
R en relacionalSolidQ
 
Cuando haces bot ya no hay stop!!
Cuando haces bot ya no hay stop!!Cuando haces bot ya no hay stop!!
Cuando haces bot ya no hay stop!!SolidQ
 
Arquitecturas lambda en Azure
Arquitecturas lambda en AzureArquitecturas lambda en Azure
Arquitecturas lambda en AzureSolidQ
 
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018SolidQ
 
BIE2E en Azure - SolidQ Summit 2018
BIE2E en Azure - SolidQ Summit 2018BIE2E en Azure - SolidQ Summit 2018
BIE2E en Azure - SolidQ Summit 2018SolidQ
 
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018SolidQ
 
Hilando fino en SSAS multidimensional - SolidQ Summit 2018
Hilando fino en SSAS multidimensional - SolidQ Summit 2018Hilando fino en SSAS multidimensional - SolidQ Summit 2018
Hilando fino en SSAS multidimensional - SolidQ Summit 2018SolidQ
 
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...SolidQ
 

Más de SolidQ (20)

SolidQ Summit 2018 - Qué necesita saber un DBA de Integration Services
SolidQ Summit 2018 - Qué necesita saber un DBA de Integration ServicesSolidQ Summit 2018 - Qué necesita saber un DBA de Integration Services
SolidQ Summit 2018 - Qué necesita saber un DBA de Integration Services
 
SolidQ Summit 2018 - Seguridad a nivel datos. RLS
SolidQ Summit 2018 - Seguridad a nivel datos. RLSSolidQ Summit 2018 - Seguridad a nivel datos. RLS
SolidQ Summit 2018 - Seguridad a nivel datos. RLS
 
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...
SolidQ Summit 2018 - Todo lo que un integrador de datos debería tener... y pa...
 
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...
SolidQ Summit 2018 - ¿Dificultades gestionando relaciones muchos a muchos? De...
 
SolidQ Summit 2018 - Report Server: Nuevos mutantes
SolidQ Summit 2018 - Report Server: Nuevos mutantesSolidQ Summit 2018 - Report Server: Nuevos mutantes
SolidQ Summit 2018 - Report Server: Nuevos mutantes
 
Cuando QueryStore no sirve, ¿qué opciones tenemos?
Cuando QueryStore no sirve, ¿qué opciones tenemos?Cuando QueryStore no sirve, ¿qué opciones tenemos?
Cuando QueryStore no sirve, ¿qué opciones tenemos?
 
SQL Server 2017 en Linux
SQL Server 2017 en LinuxSQL Server 2017 en Linux
SQL Server 2017 en Linux
 
Columnstore en la vida real
Columnstore en la vida realColumnstore en la vida real
Columnstore en la vida real
 
PowerApprízate
PowerApprízatePowerApprízate
PowerApprízate
 
Jugando a ser rico: Machine Learning para predicción de stocks
Jugando a ser rico: Machine Learning para predicción de stocksJugando a ser rico: Machine Learning para predicción de stocks
Jugando a ser rico: Machine Learning para predicción de stocks
 
Analizando tus Redes Sociales con Power BI
Analizando tus Redes Sociales con Power BIAnalizando tus Redes Sociales con Power BI
Analizando tus Redes Sociales con Power BI
 
Mantenimiento de SQL Server para Dummies
Mantenimiento de SQL Server para DummiesMantenimiento de SQL Server para Dummies
Mantenimiento de SQL Server para Dummies
 
R en relacional
R en relacionalR en relacional
R en relacional
 
Cuando haces bot ya no hay stop!!
Cuando haces bot ya no hay stop!!Cuando haces bot ya no hay stop!!
Cuando haces bot ya no hay stop!!
 
Arquitecturas lambda en Azure
Arquitecturas lambda en AzureArquitecturas lambda en Azure
Arquitecturas lambda en Azure
 
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018
Bot Framework: otra manera de acceder a tus datos - SolidQ Summit 2018
 
BIE2E en Azure - SolidQ Summit 2018
BIE2E en Azure - SolidQ Summit 2018BIE2E en Azure - SolidQ Summit 2018
BIE2E en Azure - SolidQ Summit 2018
 
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018
¿Qué viene GDPR? Mi SQL está preparado- SolidQ Summit 2018
 
Hilando fino en SSAS multidimensional - SolidQ Summit 2018
Hilando fino en SSAS multidimensional - SolidQ Summit 2018Hilando fino en SSAS multidimensional - SolidQ Summit 2018
Hilando fino en SSAS multidimensional - SolidQ Summit 2018
 
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...
Adaptive Query Processing: Mejoras en el motor de consulta de SQL Server 2017...
 

Último

CLASE DE TECNOLOGIA E INFORMATICA PRIMARIA
CLASE  DE TECNOLOGIA E INFORMATICA PRIMARIACLASE  DE TECNOLOGIA E INFORMATICA PRIMARIA
CLASE DE TECNOLOGIA E INFORMATICA PRIMARIAWilbisVega
 
pruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITpruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITMaricarmen Sánchez Ruiz
 
trabajotecologiaisabella-240424003133-8f126965.pdf
trabajotecologiaisabella-240424003133-8f126965.pdftrabajotecologiaisabella-240424003133-8f126965.pdf
trabajotecologiaisabella-240424003133-8f126965.pdfIsabellaMontaomurill
 
guía de registro de slideshare por Brayan Joseph
guía de registro de slideshare por Brayan Josephguía de registro de slideshare por Brayan Joseph
guía de registro de slideshare por Brayan JosephBRAYANJOSEPHPEREZGOM
 
Global Azure Lima 2024 - Integración de Datos con Microsoft Fabric
Global Azure Lima 2024 - Integración de Datos con Microsoft FabricGlobal Azure Lima 2024 - Integración de Datos con Microsoft Fabric
Global Azure Lima 2024 - Integración de Datos con Microsoft FabricKeyla Dolores Méndez
 
Redes direccionamiento y subredes ipv4 2024 .pdf
Redes direccionamiento y subredes ipv4 2024 .pdfRedes direccionamiento y subredes ipv4 2024 .pdf
Redes direccionamiento y subredes ipv4 2024 .pdfsoporteupcology
 
Herramientas de corte de alta velocidad.pptx
Herramientas de corte de alta velocidad.pptxHerramientas de corte de alta velocidad.pptx
Herramientas de corte de alta velocidad.pptxRogerPrieto3
 
International Women's Day Sucre 2024 (IWD)
International Women's Day Sucre 2024 (IWD)International Women's Day Sucre 2024 (IWD)
International Women's Day Sucre 2024 (IWD)GDGSucre
 
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...silviayucra2
 
Trabajo Mas Completo De Excel en clase tecnología
Trabajo Mas Completo De Excel en clase tecnologíaTrabajo Mas Completo De Excel en clase tecnología
Trabajo Mas Completo De Excel en clase tecnologíassuserf18419
 
Presentación guía sencilla en Microsoft Excel.pptx
Presentación guía sencilla en Microsoft Excel.pptxPresentación guía sencilla en Microsoft Excel.pptx
Presentación guía sencilla en Microsoft Excel.pptxLolaBunny11
 
Proyecto integrador. Las TIC en la sociedad S4.pptx
Proyecto integrador. Las TIC en la sociedad S4.pptxProyecto integrador. Las TIC en la sociedad S4.pptx
Proyecto integrador. Las TIC en la sociedad S4.pptx241521559
 
EPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveEPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveFagnerLisboa3
 
9egb-lengua y Literatura.pdf_texto del estudiante
9egb-lengua y Literatura.pdf_texto del estudiante9egb-lengua y Literatura.pdf_texto del estudiante
9egb-lengua y Literatura.pdf_texto del estudianteAndreaHuertas24
 
KELA Presentacion Costa Rica 2024 - evento Protégeles
KELA Presentacion Costa Rica 2024 - evento ProtégelesKELA Presentacion Costa Rica 2024 - evento Protégeles
KELA Presentacion Costa Rica 2024 - evento ProtégelesFundación YOD YOD
 

Último (15)

CLASE DE TECNOLOGIA E INFORMATICA PRIMARIA
CLASE  DE TECNOLOGIA E INFORMATICA PRIMARIACLASE  DE TECNOLOGIA E INFORMATICA PRIMARIA
CLASE DE TECNOLOGIA E INFORMATICA PRIMARIA
 
pruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITpruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNIT
 
trabajotecologiaisabella-240424003133-8f126965.pdf
trabajotecologiaisabella-240424003133-8f126965.pdftrabajotecologiaisabella-240424003133-8f126965.pdf
trabajotecologiaisabella-240424003133-8f126965.pdf
 
guía de registro de slideshare por Brayan Joseph
guía de registro de slideshare por Brayan Josephguía de registro de slideshare por Brayan Joseph
guía de registro de slideshare por Brayan Joseph
 
Global Azure Lima 2024 - Integración de Datos con Microsoft Fabric
Global Azure Lima 2024 - Integración de Datos con Microsoft FabricGlobal Azure Lima 2024 - Integración de Datos con Microsoft Fabric
Global Azure Lima 2024 - Integración de Datos con Microsoft Fabric
 
Redes direccionamiento y subredes ipv4 2024 .pdf
Redes direccionamiento y subredes ipv4 2024 .pdfRedes direccionamiento y subredes ipv4 2024 .pdf
Redes direccionamiento y subredes ipv4 2024 .pdf
 
Herramientas de corte de alta velocidad.pptx
Herramientas de corte de alta velocidad.pptxHerramientas de corte de alta velocidad.pptx
Herramientas de corte de alta velocidad.pptx
 
International Women's Day Sucre 2024 (IWD)
International Women's Day Sucre 2024 (IWD)International Women's Day Sucre 2024 (IWD)
International Women's Day Sucre 2024 (IWD)
 
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...
POWER POINT YUCRAElabore una PRESENTACIÓN CORTA sobre el video película: La C...
 
Trabajo Mas Completo De Excel en clase tecnología
Trabajo Mas Completo De Excel en clase tecnologíaTrabajo Mas Completo De Excel en clase tecnología
Trabajo Mas Completo De Excel en clase tecnología
 
Presentación guía sencilla en Microsoft Excel.pptx
Presentación guía sencilla en Microsoft Excel.pptxPresentación guía sencilla en Microsoft Excel.pptx
Presentación guía sencilla en Microsoft Excel.pptx
 
Proyecto integrador. Las TIC en la sociedad S4.pptx
Proyecto integrador. Las TIC en la sociedad S4.pptxProyecto integrador. Las TIC en la sociedad S4.pptx
Proyecto integrador. Las TIC en la sociedad S4.pptx
 
EPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveEPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial Uninove
 
9egb-lengua y Literatura.pdf_texto del estudiante
9egb-lengua y Literatura.pdf_texto del estudiante9egb-lengua y Literatura.pdf_texto del estudiante
9egb-lengua y Literatura.pdf_texto del estudiante
 
KELA Presentacion Costa Rica 2024 - evento Protégeles
KELA Presentacion Costa Rica 2024 - evento ProtégelesKELA Presentacion Costa Rica 2024 - evento Protégeles
KELA Presentacion Costa Rica 2024 - evento Protégeles
 

NoSQL Azure y MongoDB

  • 1. NoSQL: Azure Table Storage & MongoDB Alternativas y escenarios de uso NoSQL @erincon Eladio Rincón Director Relacional MCT, MVP SQL Server @augurarte Miguel López Director Cloud | mlopez@solidq.com MCT, MCPD, MCTS, MCP 1
  • 2. Agenda Bases de datos relacionales y NoSQL Microsoft Azure Table Storage – Fundamentos MSATS – Diseño de NoSQL con MSATS – Programación del modelo MongoDB – Fundamentos – Diseño de NoSQL con MongoDB – Programación del modelo Escenarios Evaluación de costes 3
  • 3. NoSQL: Azure Table Storage & MongoDB BDD Relacionales y NoSQL Almacenamiento de table de Azure (MSATS) MongoDB Escenarios Costes
  • 4. BDD Relacionales y NoSQL Las BDD Relacionales lideran el conjunto de sistemas de almacenamiento transaccional, escritura atómica, indexación de columnas, optimización de consultas y lenguaje de consulta declarative orientado a conjuntos. Las BDD NoSQL se emplean de forma generalizada en sitios Web de tipo social masivamente accedidos y que necesitan escalar de forma intensiva, donde la característica principal son conjuntos de datos simples (frente a consultas complejas) © 2012 SolidQ 5
  • 5. Donde gasta el tiempo RDBMS en TPCC http://static.cs.brown.edu/courses/csci2270/papers/looking-glass.pdf
  • 7. Teorema de CAP: Selección de variables 8
  • 8. NoSQL Next Generation Databases mostly addressing some of the points: being non-relational, distributed, open-source and horizontally scalable. http://NoSQL-database.org 9
  • 9. NoSQL Evolución y características • Surgen a principios de 2009 • Crecimiento exponencial. • Características comunes más importantes: • No se basan en esquema • Soporte de replicación sencillo • API de fácil utilización • Consistencia parcial (eventually consistent) / BASE (not ACID) • Enormes cantidades de información. • "nosql" es traducido tradicionalmente como "not only sql“, y se considera un alias que referencia la definición anterior. 10
  • 10. Modelos de datos NoSQL http://www.slideshare.net/emileifrem/nosql-east-a-nosql-overview-and-the-benefits-of-graph-databases 11
  • 11. Grandes familias NoSQL • Wide Column Store / Column Families • Document Store • Key Value / Tuple Store • Graph Databases • Multimodel Databases • Object Databases • Grid & Cloud Database Solutions • XML Databases • Multidimensional Databases • Multivalue Databases • Event Sourcing • Network Model 12
  • 12. DEMO 13 http://nosql-database.org Bases de datos NoSQL (listado)
  • 13. NoSQL: Azure Table Storage & MongoDB BDD Relacionales y NoSQL Almacenamiento de table de Azure (MSATS) MongoDB Escenarios Costes
  • 14. Almacenamiento de table Azure Windows Azure Table Service Windows Azure tables Designing Windows Azure Tables Implementing Windows Azure Tables Querying Windows Azure Tables Accessing table storage Table Storage Security – Set container permissions. – Use Shared Access Signatures (SAS) – Stored Access Policies 15
  • 15. Cuentas de almacenamiento MSA User creates a globally unique storage account name Choose the primary location to host storage account Three regions: – “North Central US”, “South Central US” – “North Europe”, “Europe West” – “South East Asia”, “East Asia” Table Service: http://myaccount.table.core.windows.net 16
  • 16. DEMO 17 Aprovisionamiento de una cuenta de almacenamiento de Azure
  • 17. Características MSATS • Tabla de almacenamiento de Azure • Colección de entidades (parejas clave, valor) • La entidad tiene una clave principal y un conjunto aleatorio no definido (schema-less) de propiedades. • PartitionKey (Particionamiento / distribución de carga / escalado) • RowKey (conjuntos de filas relacionadas en una partición) • TimeStamp (Sólo lectura, TS creación) • Una propiedad es un par de nombre/valor (con tipo) similar a una columna • MSATS no fuerza la creación o validación de esquema • El desarrollador necesitará implementar un esquema concreto para su acceso 18
  • 19. DEMO 20 Aplicación https://haveibeenpwned.com/
  • 20. Entidades del MSATS Entities are the basic data item stored in a table Collections of properties that are name value pairs. Each entity has 3 fixed properties called PartitionKey, RowKey and Timestamp. If we were to map this to concepts in a conventional database system, an entity is analogous to a row and property is analogous to a column. An entity can have up to 255 – 3 properties = 252 (3 system properties are reserved). 1 Entity = 1 MB of data (Maximum) 21
  • 21. Entidades: Tipos de datos de propiedades • Byte[] • Bool • DateTime • Double • Guid • Int32/Int • Int64/long • String 22
  • 22. Entidades: Indexación (Primary Key) • PartitionKey property • RowKey property • Timestamp property 23
  • 23. Características de las propiedades PK • Tablas particionadas para soportar balanceo de carga entre nodos de almacenamiento. • Las entidades se organizan por partición. • Una partición es un rango consecutive de entidades con la misma clave de partición. • Partition key: Identificador único de partición dentro de una tabla. • PK es la primera parte de la clave principal de una entidad. • PK puede ser una cadena de hasta 1KB de tamaño. • Incluir PartitionKey property en cada insert, update, y delete. 24
  • 24. Características de las propiedades RowKey RowKey • The row key is a unique identifier for an entity within a given partition. • Together the PartitionKey and RowKey uniquely identify every entity within a table. • The row key is a string value that may be up to 1 KB in size. • You must include the RowKey property in every insert, update, and delete operation. 25
  • 25. MSATS es una BDD sin esquema 26 PartitionKey: str 2012102517USR91 P V RowKey: str jobid0121 P V TimeStamp: dt 201210251715 P V Name: st User_91 P V PartitionKey: str 2012102517USR10 P V RowKey: str jobid0121 P V TimeStamp: dt 201210251735 P V Status: st Processing P V Name: st User_10 P V PartitionKey: str 2012102517USR10 P V RowKey: str jobid0125 P V TimeStamp: dt 201210251755 P V RoleExec: st IN_121 P V Name: st User_10 P V LastOp: st Decrypt P V PartitionKey: str 2012102517USR13 P V RowKey: str jobid0002 P V TimeStamp: dt 201210251759 P V Name: st User_13 P V PartitionKey: str 2012102517USR13 P V RowKey: str jobid0001 P V TimeStamp: dt 201210251755 P V Name: st User_13 P V Status: st Aborted P V TABLE JOBEXECUTION
  • 26. Consulta del servicio de tabla 27 PartitionKey: str 2012102517USR91 P V RowKey: str jobid0121 P V TimeStamp: dt 201210251715 P V Name: st User_91 P V PartitionKey: str 2012102517USR10 P V RowKey: str jobid0121 P V TimeStamp: dt 201210251735 P V Status: st Processing P V Name: st User_10 P V PartitionKey: str 2012102517USR10 P V RowKey: str jobid0125 P V TimeStamp: dt 201210251755 P V RoleExec: st IN_121 P V Name: st User_10 P V LastOp: st Decrypt P V PartitionKey: str 2012102517USR13 P V RowKey: str jobid0002 P V TimeStamp: dt 201210251759 P V Name: st User_13 P V PartitionKey: str 2012102517USR13 P V RowKey: str jobid0001 P V TimeStamp: dt 201210251755 P V Name: st User_13 P V Status: st Aborted P V TABLE JOBEXECUTION
  • 29. DEMO Acceso a un sistema MSATS en producción 30
  • 30. Table Storage Design Define your model Key selection 31
  • 31. Key selection: Considerations Entity Group Transactions Scalability Efficient queries 32
  • 32. DEMO 33 Gestión de tablas con cliente Windows
  • 33. Modelo de programación Windows Azure Storage: Connection Strings Managing tables in WATS Entities: CRUD operations (Create, read, update, delete) Querying tables Perform Entity Group Transactions (EGT) 34
  • 34. Connection Strings in Visual Studio 2013 Double click on the Web/Worker role in the solution © 2012 SolidQ 35
  • 35. Managing tables in WATS Use Microsoft.WindowsAzure.StorageClient. There are several ways of creating tables. Initialize tables once: for example using session or Application start events. Use CreateCloudTableClient to interact with WATS For example, to create a table called ‘Products’: 36 using Microsoft.WindowsAzure; using Microsoft.WindowsAzure.StorageClient; var clAccount; clAccount = CloudStorageAccount.FromConfigurationSettings(“ProductStorage") var tableClient = clAccount.CreateCloudTableClient(); tableClient.CreateTableIfNotExists(“Products”)
  • 36. Entidades: Operaciones CRUD Configurar las entidades (modelo de clases) Configurar un DataContext 37
  • 37. Configuración de las entidades Class modeling 38
  • 38. Operaciones CRUD Setting up data context Context class is required in .NET to access the WAT using WCF Data Services and the correspondent entity (GE06LDataEntry). 39 namespace GE06L_Data { public class GE06LDataContext : TableServiceContext { public GE06LDataContext(string baseAddress, Microsoft.WindowsAzure.StorageCredentials credentials) : base(baseAddress, credentials) {} public IQueryable<GE06LEntry> GE06LEntry { get { return this.CreateQuery<GE06LEntry>(“GE06LEntry");} } } }
  • 39. Entities CRUD operations List, Add, Update // List (read) operation for GE06LEntry entities public IEnumerable<GE06LEntry> GetGE06LEntries() { var results = from g in this.context.GE06LEntry where g.PartitionKey == DateTime.UtcNow.ToString("MMddyyyy") 40 select g; return results; } // Add operation for GE06LEntry entities public void AddGE06LEntry(GE06LEntry newItem) { this.context.AddObject(“GE06LEntry", newItem); this.context.SaveChanges(); } // Update operation for GE06LEntry entities public void UpdateFileURL(string partitionKey, string rowKey, string fileUrl) { var results = from g in this.context.GE06LEntry where g.PartitionKey == partitionKey && g.RowKey == rowKey select g; var entry = results.FirstOrDefault<GE06LEntry>(); entry.FilelUrl = fileUrl; this.context.UpdateObject(entry); this.context.SaveChanges(); }
  • 40. Consultar MSATS Single Entity (a.k.a. Point Queries) 41 var q = ( from pais in context.CreateQuery<Pais>(tableName) where pais.PartitionKey == “Paises“ && pais.RowKey == “España" select movie);
  • 41. Consultar MSATS Range Queries - Row Range Scan var q = ( from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey == "Action" && movie.RowKey.CompareTo("Alien") >= 0 && movie.RowKey.CompareTo("Terminator") <= 0 && movie.IsFavorite select movie ); © 2012 SolidQ 42
  • 42. Consultar MSATS Range Queries - Partition Range Scan 43 var q = ( from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey == "Action" && movie.RowKey.CompareTo("Alien") >= 0 && movie.RowKey.CompareTo("Terminator") <= 0 && movie.IsFavorite select movie );
  • 43. Consultar MSATS Full Table Scan var q = (from movie in context.CreateQuery<Movie>(tableName) 44 select movie ); var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey.CompareTo("Action") != 0 select movie ); var q = ( from movie in context.CreateQuery<Movie>(tableName) where movie.IsFavorite select movie); var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.RowKey.CompareTo("Sh") >= 0 && movie.RowKey.CompareTo("Si") < 0 select movie );
  • 45. NoSQL: Azure Table Storage & MongoDB BDD Relacionales y NoSQL Almacenamiento de table de Azure (MSATS) MongoDB Escenarios Costes
  • 46. MongoDB Motivación • ¿”Problemas” en RDBMs tradicionales? 47 • Transaciones • JOINs • Prescindimos de ellos • Transacciones a nivel de documento • No dejamos hacer JOINs
  • 47. MongoDB Unidad de Información es el Documento 48
  • 48. MongoDB: Otro Paradigma 49 • Filosofía Schema On-Read • El Esquema es importante (aunque laxo) • En algún momento necesitas “modelar” • Antes o después • Modelos Mapeados en Memoria • “Cerveza con alcohol vs cerveza sin alcohol” by Garrigós • Importante arquitectura x64!
  • 49. MongoDB: Conceptos Clave • Aunque veamos JSON, almacenado en binario 50 – BSON • Consola de administración  JavaScript y JSON • Varios GUI tipo SSMS • Drivers de Mongo para facilitar desarrollo • Driver para C# y usar LINQ • Modelos de persistencia para mapeo • MongoRepository • Sharding y Replicasets
  • 50. DEMO 51 MongoDB en Azure con correos electrónicos
  • 51. NoSQL: Azure Table Storage & MongoDB BDD Relacionales y NoSQL Almacenamiento de table de Azure (MSATS) MongoDB Escenarios Costes
  • 52. Escenarios Aplicaciones altamente escalables que necesitan consultas sencillas y rápidas • ONU, datos georeferenciados, info calculada • Energética, metadatos • BIG Data, datos temporales/sensores • Información social / redes sociales • Aplicaciones de localización de correos, direcciones, etc. 53
  • 53. NoSQL: Azure Table Storage & MongoDB BDD Relacionales y NoSQL Almacenamiento de table de Azure (MSATS) MongoDB Escenarios Costes
  • 54. Costes Microsoft Azure Table Storage MongoDB on Azure 55
  • 55. NoSQL: Azure Table Storage & MongoDB Bases de datos relacionales y NoSQL Microsoft Azure Table Storage – Fundamentos MSATS – Diseño de NoSQL con MSATS – Programación del modelo MongoDB – Fundamentos – Diseño de NoSQL con MongoDB – Programación del modelo Escenarios Evaluación de costes 56
  • 56. Si quieres disfrutar de las mejores sesiones de nuestros mentores de España y Latino América, ésta es tu oportunidad. http://summit.solidq.com Síguenos: 58

Notas del editor

  1. Key-Value Stores: Dynamo DHT, Voldemort (Used in Linkedin) Column Families: Google BigTable, Cassandra (Facebook) Document DBs: CouchDB, MongoDB () Graph DBs: Neo4j
  2. http://voltdb.com/downloads/datasheets_collateral/technical_overview.pdf http://static.cs.brown.edu/courses/csci2270/papers/looking-glass.pdf
  3. Note: Windows Azure Blob service has support for taking snapshots of blobs. The different between a snapshot and a blob copy is that snapshots are read-only and the original blob maintains a relationship to its snapshots; blob copies on the other hand are editable. Once a snapshot has been taken for a blob, this source blob can no longer be deleted. Before a source blob can be deleted, all of its snapshots must be deleted first. Security in WATS Once you have created a storage service account, you will receive two 512 bit secret keys called primary and secondary access keys. Any one of these secret keys is then used to authenticate user requests to the storage system by creating a HMAC SHA256 signature for the request. The signature is passed with each request to authenticate the user requests. The reason for the two access keys is that it allows you to regenerate keys by rotating between primary and secondary access keys in your existing live applications.
  4. Property Types The Table service supports a subset of data types defined by the WCF Data Services specification. By default a property is created as type String, unless you specify a different type. To explicitly type a property, specify its data type by using the appropriate WCF Data Services type in the Atom feed for an Insert Entity (REST API) or Update Entity (REST API) operation.
  5. This table contains a small subset of data for footrace event registrations. It presents a conceptual view of partitioning where the PartitionKey contains three different values comprised of the event's name and distance. In this example, there are two partition servers. Server A contains registrations for the half-marathon and 10 Km distances Server B contains only the full-marathon distances. The RowKey values are shown to provide context but are not meaningful for this example. Scalability Because a partition is always served from a single partition server and each partition server can serve one or more partitions, the efficiency of serving entities is correlated with the health of the server. Servers that encounter high traffic for their partitions may not be able to sustain a high throughput. For example, in the figure in the slide, if there are many requests for "2011 New York City Marathon__Half", server A may become too hot. To increase the throughput of the server, the storage system load-balances the partitions to other servers. The result is that the traffic is distributed across many other servers. For optimal load balancing of traffic, you should use more partitions because it will allow the Windows Azure Table service to distribute the partitions to more partition servers.
  6. Note: the TableServiceContext class is in the storage client API. This class derives from DataServiceContext in WCF Data Services and manages the credentials required to access your storage account as well as providing support for a retry policy for its operations.
  7. Type A. Single Entity (a.k.a. Point Queries): Point query is a query is to retrieve a single entity by specifying a single PartitionKey and RowKey using equality predicates. var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey == "Action" && movie.RowKey == "Terminator" select movie);
  8. Type B: Row Range Scan: Query results in scanning a range of rows within a single partition var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey == "Action" && movie.RowKey.CompareTo("Alien") >= 0   && movie.RowKey.CompareTo("Terminator") <= 0   && movie.IsFavorite select movie);
  9. Type C: Partition Range Scan: Query results in scanning a range of rows that may span across several partitions. var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey.CompareTo("Action") >= 0 && movie.PartitionKey.CompareTo("War") < 0 && movie.IsFavorite select movie);
  10. Type D: Full Table Scan: Query results in scanning the entire table i.e. all rows in all partitions in a table. var q = (from movie in context.CreateQuery<Movie>(tableName) select movie ); var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.PartitionKey.CompareTo("Action") != 0 select movie ); var q = ( from movie in context.CreateQuery<Movie>(tableName) where movie.IsFavorite select movie); var q = (from movie in context.CreateQuery<Movie>(tableName) where movie.RowKey.CompareTo("Sh") >= 0 && movie.RowKey.CompareTo("Si") < 0 select movie );