More Related Content Similar to MySQL para Desenvolvedores de Games (20) More from MySQL Brasil (20) MySQL para Desenvolvedores de Games1. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 121
Airton Lastori
airton.lastori@oracle.com
07-jun-2013
MySQL para Desenvolvedores de Games
2. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 122
@MySQLBR
meetup.com/MySQL-BR
facebook.com/MySQLBR
MySQLBR
3. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 123
Alguns clientes MySQL
4. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 124
Alguns clientes MySQL
fonte: alexa.com/topsites 30-jan-2013
5. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 125
Alguns clientes MySQL
mysql.com/customers
6. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 126
Alguns clientes MySQL
mysql.com/customers
7. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 127
MySQL: casos de sucesso
+ de 20 indústrias
mysql.com/customers
8. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 128
Indústria: Games
mysql.com/customers/industry/?id=83
9. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 129
Seu game precisa de um SGBD?
Qual o tipo de distribuição do game?
Download, Streaming, Online, Mobile...
10. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1210
Quase todos tipos de games modernos
necessitam de um sistema robusto de
armazenamento de dados
Dependendo da distribuição, o banco de dados pode ser
embarcado, centralizado ou distribuído.
11. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1211
Game sem UI
MySQLgame
mysqlgame.com
12. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1212
Como escolher um SGBD?
Desafio de desenvolvedor #1
13. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1213
…pense nos requisitos não funcionais…
14. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1214
Na escolha da solução, considerar...
Escalabilidade, performance, disponibilidade,
estabilidade, segurança, simplicidade, flexibilidade,
custo total de propriedade, conhecimento da equipe...
Ah! Não esqueça da fase de produção, dos DBAs...
ferramentas, suporte, rotinas de manutenção.
15. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1215
Como o MySQL atende
Alguns destes requisitos?
16. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1216
MySQL para desenvolvedores
Portfolio
Ambiente de
desenvolvimento
Escalabilidade e
Alta-disponibilidade
Conhecendo melhor o
universo MySQL para
fazer boas escolhas…
17. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1217
MySQL para desenvolvedores
Portfolio
Ambiente de
desenvolvimento
Escalabilidade e
Alta-disponibilidade
Conhecendo melhor o
universo MySQL para
fazer boas escolhas…
18. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1218
MySQL Database Community Server
MySQL Cluster
MySQL Workbench
MySQL Connectors
MySQL Proxy
Documentação não GPL
Forums, Lists, Bugs, Blogs…
Compromisso Oracle com MySQL Community
Portfólio disponível para download e uso sob GPL
19. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1219
Conectores: amplo suporte a várias linguagens
Oracle
• Connector/ODBC
• Connector/Net (ADO.NET)
• Connector/Python
• Connector/J (JDBC)
• Connector/C (C API)
• Connector/C++ (C++ API)
Comunidade
• PHP
• Perl
• Ruby
• TCL
• Eiffel
• …
dev.mysql.com/doc/refman/5.5/en/connectors-apis.html
20. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1220
Oracle Premier
Lifetime Support
Oracle Product
Certifications/Integrations
MySQL Enterprise
High Availability
MySQL Enterprise
Security
MySQL Enterprise
Scalability
MySQL Enterprise
Backup
MySQL Enterprise
Monitor/Query Analyzer
MySQL Workbench
MySQL Enterprise Edition
Maior produtividade e mitigação de riscos
MySQL Enterprise
Audit
21. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1221
MySQL para desenvolvedores
Portfolio
Ambiente de
desenvolvimento
Escalabilidade e
Alta-disponibilidade
Conhecendo melhor o
universo MySQL para
fazer boas escolhas…
22. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1222
Desafio de desenvolvedor #2
Instalação básica, ambiente de
desenvolvimento…
...em 15 minutos, ou menos!
23. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1223
24. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1224
mysql.com/downloads/mysql
No Linux ou Mac, prefira os binários
25. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1225
Client
mysql / mysql.exe
Server
mysqld / mysqld.exe
Cliente-Servidor
26. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1226
Iniciar ou Parar o servidor MySQL no Windows
…ou via MySQL Notifier
27. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1227
Iniciar ou Parar o servidor MySQL no Linux
/usr/local/mysql/bin> mysqld_safe --defaults-file=/etc/my.cnf &
/usr/local/mysql/bin> mysqladmin shutdown
Parar:
Iniciar:
dev.mysql.com/doc/refman/5.5/en/mysqld-safe.html
28. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1228
Primeira conexão
C:Program FilesMySQLMySQL Server 5.5bin>mysql -uroot -p
Enter password: ****
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 8
Server version: 5.5.28 MySQL Community Server (GPL)
Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
mysql>
29. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1229
Teste via MySQL Workbench 1/2
30. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1230
Teste via MySQL Workbench 2/2
31. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1231
App + Connector
JDBC, ODBC, .Net, PHP, Python, Perl, Ruby, Native C API…
Server
mysqld / mysqld.exe
Cliente-Servidor
32. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1232
Desafio de desenvolvedor #3
Hello World…
...em Java
33. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1233
Adicione o driver MySQL ao CLASSPATH
caminho completo do .jar
C:>set CLASSPATH
CLASSPATH=.;C:Program Files (x86)Javajre6libextQTJava.zip;C:Program
FilesMySQLmysql-connector-java-5.1.22mysql-connector-java-5.1.22-bin.jar
Confira:
34. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1234
HelloMysql.java 1/2
import java.sql.*;
public class HelloMysql {
public static void main(String args[]){
System.out.println("Tentando conectar ao MySQL...");
try {
Class.forName("com.mysql.jdbc.Driver");
String url = "jdbc:mysql://localhost:3306/mysql";
String usuario = "root";
String senha = "root";
Connection con = DriverManager.getConnection(url, usuario, senha);
System.out.println("URL: " + url);
System.out.println("Connection: " + con);
Continua…
35. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1235
HelloMysql.java 2/2
Statement stmt = con.createStatement(); //objeto Statement
ResultSet rs; //objeto ResultSet
rs = stmt.executeQuery("SELECT * FROM world.country");
System.out.println("Ola mundo!");
while(rs.next()){
String nomePais = rs.getString("Name");
System.out.print(nomePais + ", ");
}//end while
con.close();
} catch( Exception e ) {
e.printStackTrace();
}//end catch
}//end main
}//end class HelloMysql
PRONTO!
36. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1236
java HelloMysql
C:tutorial>javac HelloMysql.java
C:tutorial>java HelloMysql
Tentando conectar ao MySQL...
URL: jdbc:mysql://localhost:3306/mysql
Connection: com.mysql.jdbc.JDBC4Connection@ed07f45
Ola mundo!
Aruba, Afghanistan, Angola, Anguilla, Albania, Andorra, Netherlands Antilles, Un
ited Arab Emirates, Argentina, Armenia, American Samoa, Antarctica, French South
ern territories, Antigua and Barbuda, Australia, Austria, Azerbaijan, Burundi, B
elgium, Benin, Burkina Faso, Bangladesh, Bulgaria, Bahrain, Bahamas, Bosnia and
Herzegovina, Belarus, Belize, Bermuda, Bolivia, Brazil, Barbados, Brunei, Bhutan
…
ietnam, Vanuatu, Wallis and Futuna, Samoa, Yemen, Yugoslavia, South Africa, Zamb
ia, Zimbabwe,
37. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1237
Próximo passo: documentação
Reference Manual
1. Tutorial
2. SQL Syntax
3. Connectors & APIs, Memcached
4. Functions, Views, Stored Programs
5. Optimization
dev.mysql.com/doc/refman/5.5/en/index.html
38. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1238
MySQL para desenvolvedores
Portfolio
Ambiente de
desenvolvimento
Escalabilidade e
Alta-disponibilidade
Conhecendo melhor o
universo MySQL para
fazer boas escolhas…
39. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1239
Desafio do desenvolvedor #4
Projetar uma solução para
disponibilidade 24x7…
...a famosa alta-disponibilidade
40. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1240
Alta-Disponibilidade
41. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1241
Aplicação
Master Slave
• Modelo unidirecional assíncrono (padrão)
• Modelo semi-síncrono (a partir da versão 5.5)
Escritas & Leituras
Replicação MySQL
42. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1242
Aplicação
Master Slave
• Master down
• Slave promovido para Master
Escritas & Leituras
MySQL failover
43. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1243
Alta-Disponibilidade
44. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1244
Soluções certificadas MySQL HA: resumo
mysql.com/why-mysql/white-papers/mysql_wp_ha_strategy_guide.php
MySQL 5.6
Replication
Windows
Cluster
Solaris
Cluster
Oracle VM
Template
DRBD
MySQL
Cluster
Nível de disponibilidade 99.9% 99.95% 99.99% 99.99% 99.99% 99.999%
Auto-Failover ✔ ✔ ✔ ✔ ✔ ✔
Sem perda de dados durante
failover
✔
Semi-Sync
✔ ✔ ✔ ✔ ✔
Plataformas suportadas All Windows Solaris Linux Linux All
Modo de clusterização
Master +
Slaves
Active /
Passive
Active /
Passive
Active /
Passive
Active /
Passive
Multi-
Master
Dispensa Shared Storage ✔ ✖ ✖ ✖ ✔ ✔
Ponto único de suporte ✔ ✖ ✔ ✔ ✔ ✔
45. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1245
Desafio do desenvolvedor #5
Projetar uma solução que possa
crescer para comportar milhões
de usuários…
46. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1246
Scale Out
• Adicionar mais servidores para
aumentar performance
• MySQL adota esta abordagem
em sistemas altamente
escaláveis em hardware
commodity (Intel / AMD)
Scale Up
• Trocar por hardware mais
poderoso, adicionar memória,
CPU
• Outras soluções normalmente
usam hardware proprietário
(SMP)
Escalabilidade: horizontal vs vertical
47. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1250
Escalabilidade horizontal
Replicação MySQL
• método mais simples e
mais comum
• indicado para aplicações
de LEITURA intensiva
• problemas com cache
duplicado em aplicações
com datasets grandes
Particionamento
Funcional
• dividir a carga em múltiplos
nós, com responsabilidades
distintas
• os nós podem ter
redundância via replicação
para alta-disponibilidade
• normalmente não é
transparente para a aplicação
e também recorre ao scale up
para cada database funcional,
o que impõe limites
Data Sharding
• método de maior sucesso
para escalar aplicações
MySQL de grande porte
hoje
• dados compartilhados em
tabelas/caches globais,
SOA
• difícil de adaptar
aplicações legadas
48. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1251
Replicação MySQL: escalando LEITURAS
• Divisão de leituras e escritas (R/W Split)
• É possível adicionar mais slaves, dividir a carga
Leituras
Aplicação
Master Slave
Escritas & Leituras Leituras
Slave
…
49. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1252
Data Node 1
Data Node 2
Data Node 3
Data Node 4
Table T1
P2
P3
P4
P1
Data Sharding: escalando ESCRITAS
50. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1253
Data Node 1
Data Node 2
F1
Data Node 3
Data Node 4
Table T1
P2
P3
P4
P1
Data Sharding: escalando ESCRITAS
51. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1254
Data Node 1
Data Node 2
F1
F3
Data Node 3
Data Node 4
Table T1
P2
P3
P4
P1
Data Sharding: escalando ESCRITAS
52. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1255
Data Node 1
Data Node 2
F1
F3
Data Node 3
Data Node 4
F2
Table T1
P2
P3
P4
P1
Data Sharding: escalando ESCRITAS
53. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1256
Data Node 1
Data Node 2
F1
F3
Data Node 3
Data Node 4
F2
F4
Table T1
P2
P3
P4
P1
Data Sharding: escalando ESCRITAS
54. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1257
Desafios do desenvolvedor #4 + #5
É possível combinar alta-
disponibilidade e escalabilidade?
...assim como Facebook, Twitter, Youtube
55. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1258
Data Node 1
Data Node 2
F1
F1
Data Node 3
Data Node 4
Table T1
P2
P3
P4
P1
Data Sharding + Replicação
56. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1259
Data Node 1
Data Node 2
F1 F3
F1
Data Node 3
Data Node 4
Table T1
P2
P3
P4
P1
F3
Data Sharding + Replicação
57. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1260
Data Node 1
Data Node 2
F1 F3
F3 F1
Data Node 3
Data Node 4
F2
F2
Table T1
P2
P3
P4
P1
Alta-Disponibilidade: Replicação Síncrona
58. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1261
Data Node 1
Data Node 2
F1 F3
F3 F1
Data Node 3
Data Node 4
F2 F4
F4 F2
Table T1
P2
P3
P4
P1
Data Sharding + Replicação
59. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1262
Data Node 1
Data Node 2
F1 F3
F3 F1
Data Node 3
Data Node 4
F2 F4
F4 F2
Group1
Table T1
P2
P3
P4
P1
Data Sharding + Replicação
Group2
60. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1263
Data Node 1
Data Node 2
F1 F3
F3 F1
Data Node 3
Data Node 4
F2 F4
F4 F2
Group1
Table T1
P2
P3
P4
P1
Data Sharding + Replicação
Group2
61. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1265
Desafios do desenvolvedor #4 + #5
É possível ter alta-disponibilidade
e escalabilidade com menor
esforço de implementação?
62. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1266
MySQL Cluster
• Arquitetura shared-nothing in-memory parallel
• Modelo relacional ACID, SQL
Carrier Grade
Database
• 99.999% de disponibilidade
• Self-healing, failover abaixo de 1 segundo
Alta Disponibilidade
• Performance em tempo real para altas cargas
• Latência baixa e preditiva
Alta Performance
• Elasticidade, crescimento incremental
• Escalabilidade linear, distribuition aware
Escalabilidade
• Open Source, hardware commodity
• APIs NoSQL (C++, Java, Memcached, Node.js)
Open Source
63. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1267
Alguns Clientes MySQL Cluster
64. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1268
Alguns Clientes MySQL Cluster
65. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1269
MySQL Cluster Data Nodes
Data Layer
Clients
Application Layer
Management
mgm_ndbd
MySQL Cluster: auto-sharding
Table T1
P2
P3
P4
P1F1
F3
F3
F1
F2
F4
F4
F2
Management
mgm_ndbd
mysqldmysqld
ndbd ndbd ndbd ndbd
66. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1270
MySQL Cluster Data Nodes
Data Layer
Clients
Application Layer
Management
mgm_ndbd
MySQL Cluster: alta-disponibilidade
Table T1
F1
F3
F3
F1
F2
F4
F4
F2
Management
mgm_ndbd
mysqldmysqld
ndbd ndbd ndbd ndbd
67. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1271
MySQL Cluster Data Nodes
Data Layer
Clients
Application Layer
Management
MySQL Cluster: auto-sharding
Table T1
P2
P3
P4
P1F1
F3
F3
F1
F2
F4
F4
F2
Management
68. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1272
•2 milhões usuários, com 30.000 novos
usuários por dia
•10.000 usuários concorrentes
•10.000 Transações Por Segundo
•99.999% uptime
“The MySQL support service has
been essential in helping us for
troubleshooting and giving
recommendations for the production
cluster.”
Carlos Morales (DBA), Playfulplay.com
blogs.oracle.com/MySQL/entry/mysql_cluster_powers_el_chavo
Caso de sucesso
69. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1273
Bônus para o desenvolvedor
Escreva via NoSQL (schemaless)
e consulte via SQL
70. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1274
Os mesmos dados
acessados
simultaneamente
através de interfaces
SQL e NoSQL
APIs de Acesso aos Dados
71. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1275
<estado:SP,Campinas>
prefix key value
<estado:SP,Campinas>
key value
Prefix Table Key-col Val-col policy
estado: mapa.cidades sigla_estado cidade cluster
Config tables
sigla_estado ... cidade ...
SP ... Campinas ...
Tabela cidades do DB mapa
visão da Aplicação
visão MySQL Cluster
Cluster & Memcached
Schema configurável
SELECT * FROM mapa.cidades
WHERE cidade LIKE ’C%’;
72. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1276
Exemplos Memcached API
On-demand Webinar:
NoSQL Memcached API for MySQL Cluster
22 August 2012
mysql.com/news-and-events/on-demand-webinars/display-od-723.html
73. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1277
Exemplos JavaScript / Node.js API
Blog:
Tutorial Getting Started with the NoSQL JavaScript / Node.js API for
MySQL Cluster
10 June 2012
blogs.oracle.com/MySQL/entry/tutorial_getting_started_with_the
74. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1278
MySQL Cluster Auto-Install (beta)
Simples de instalar e provisionar clusters multi-node
Complementa MySQL Cluster Manager no gerenciamento de cliclo de vida
75. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1279
1. Download MCM/Cluster edelivery.oracle.com:
2. Unzip e execute o comando com usuário diferente de root:
MySQL Cluster Manager
Para testes em uma única máquina
C:MySQLmcmbin> mcmd --bootstrap
MySQL Cluster Manager 1.1.2 started
Connect to MySQL Cluster Manager by running “C:MySQLmcmbinmcm" -a NOVA:1862
Configuring default cluster 'mycluster'...
Starting default cluster 'mycluster'...
Cluster 'mycluster' started successfully
ndb_mgmd NOVA:1186
ndbd NOVA
ndbd NOVA
mysqld NOVA:3306
mysqld NOVA:3307
ndbapi *
Connect to the database by running “C:MySQLmcmclusterbinmysql" -h NOVA -P 3306 -u root
76. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1280
Mais sobre como começar com MySQL Cluster
Whitepaper:
MySQL Cluster Evaluation Guide
February 2012
mysql.com/why-mysql/white-papers/mysql-
cluster-evaluation-guide/
77. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1281
Sumário
O MySQL é o banco de dados open source mais popular do
mundo, usado em grandes sites, games, aplicações mobile e
embarcadas.
Há várias opções de arquiteturas e APIs, oferecendo enorme
flexibilidade, escalabilidade e alta-disponibilidade.
Instale e comece a usar em menos de 15min. Use e abuse da
documentação!
78. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1282
@MySQLBR
meetup.com/MySQL-BR
facebook.com/MySQLBR
Obrigado!
79. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1283
Perguntas?
MySQL para Desenvolvedores
80. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1284
MySQL Boot Camp
Accelerated
MySQL Performance
Tuning Boot Camp
Accelerated
MySQL for Begginers
MySQL for Database
Administrators
MySQL Performance
Tuning
MySQL High Availability
MySQL Cluster
MySQL DBA
MySQL Boot Camp
Accelerated
MySQL for Developers
MySQL Performance
Tuning Boot Camp
Accelerated
MySQL for Begginers
MySQL and PHP
Developing Dynamic
Web Applicationg
MySQL Advanced Stored
Procedures
MySQLDeveloper
mysql.com/training
Certificações
Opcional
Necessário
Treinamentos e certificações
81. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1285
Clients & Connectors
Native C API, JDBC, ODBC, .Net, PHP, Ruby, Python, VB, Perl
Connection Pool, SQL Interface, Parser, Optimizer, Caches
Enterprise Management
Services and Utilities
Backup & Recovery
Monitor
Workbench
Utilities
mysqld
Clients and Apps
Arquitetura MySQL Server
Storage Engines
InnoDB, MyISAM, Memory, Archive, Cluster (NDB API), etc…
Filesystems, Files and Logs
Data, Index, Redo, Undo, Binary, Error, Slow
82. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 1286
Storage Engines
MyISAM InnoDB NDB Cluster
Transações ✖ ✔ ✔
Nível de Lock Tabela Linha Linha
Replicação
Assíncrona ou
Semi-síncrona
Assíncrona ou
Semi-síncrona
Síncrona, Multi-master
Foreign Keys ✖ ✔ a partir da v7.3
Full-text indexes ✔ a partir da v5.6 ✖
Compressão de dados somente Leitura ✔ ✖
Caches somente Índices Dados e Índices Dados e Índices
Suporte Geospacial Tipos de Dados e Índices somente Tipos de Dados somente Tipos de Dados
Limite de armazenamento 256TB 64TB 384EB
dev.mysql.com/doc/refman/5.5/en/storage-engines.html