In the previous part we showed how NDB will parallelise a
2-way join query from TPC-H. In this part we will describe how
the pushdown of joins to a storage engine works in the MySQL Server.
First a quick introduction to how a SQL engine handles a query.
The query normally goes through 5 different phases:
1) Receive query on the client connection
2) Query parsing
3) Query optimisation
4) Query execution
5) Send result of query on client connection
The result of 1) is a text string that contains the SQL query to
execute. In this simplistic view of the SQL engine we will ignore
any such things as prepared statements and other things making the
model more complex.
The text string is parsed by 2) into a data structure that represents
the query in objects that match concepts in the SQL engine.
In the previous part we showed how NDB will parallelise a
When we explore strategies to scale our MySQL-based database layer, we realize that there are many different options. As opposed to proprietary solutions, open-source products nourish themselves from their communities and novel architectures or enhanced versions are generated, often incorporating other open source technologies. MySQL is not an exception.
Other players build completely different engines aiming to mitigate some of MySQL well-known weaknesses, but still support its wire protocol, with the challenge of sacrificing as little compatibility as possible.
In this white paper, we briefly discuss the scale-up vs scale-out dilemma, to then review the different scale-out strategies. We are also going to go over some of the most common MySQL architectures and products with horizontal scaling in mind.
Finally, we will share some guidelines to …[Read more]
I remember wanting to create MySQL Cluster sandboxes several years ago. By then, however, MySQL-Sandbox technology was not flexible enough to allow an easy inclusion, and the cluster software itself was not as easy to install as it is today. Thus, I kept postponing the implementation, until I started working with dbdeployer.
I included the skeleton of support for MySQL Cluster since the beginning (by keeping a range of ports dedicated for this technology, but I didn’t do anything until June 2018, when I made public my intentions to add support for NDB in dbdeployer with issue #20 (Add support for MySQL Cluster)). The issue had just a bare idea, but I needed help from someone, as my expertise with …[Read more]
MySQL NDB Cluster uses row level locks instead of a single shared
commit lock in order to prevent inconsistency in simultaneous
distributed transactions. This gives NDB a great advantage over
all other MySQL clustering solutions and is one reason behind
cluster’s unmatched ability to scale both reads and
NDB is a transactional data store. The lowest and only isolation level available in NDB is Read Committed. There are no dirty reads in NDB and only committed rows can be read by other transactions.
All write transactions in NDB will result in exclusive row locks of all individual rows changed during the transaction. Any other transaction is allowed to read any committed row independent of their lock status. Reads are lock-free reads.
The great advantage is that committed reads in NDB never block during writes to the same data and always the latest committed changes are read. A select doesn't block concurrent …
Last time I mentioned four great MySQL books
for 2018. I was tactfully reminded of two books I
overlooked. First is Dr. Charles Bell's Introducing InnoDB
Cluster which I have not read (but it is on order).
|Introducing InnoDB Cluster|
And last, but not least, is Mikael Ronstrum's MySQL
Cluster 7.5 Inside and Out. This is another book on
NDB cluster and is a 'msut have' for those running NDB
Someone once told me you can tell how healthy a software project
is by the number of new books each year. For
the past few years the MySQL community has been blessed with one
or two books each year. Part of that was the major shift with
MySQL 8 changes but part of it was that the vast majority of the
changes were fairly minor and did not need detailed explanations.
But this year we have been blessed with four new
books. Four very good books on new facets of MySQL.
Introducing the MySQL 8 Document Store is the latest book from Dr. Charles Bell on MySQL. If you have read any other of Dr. Chuck's book you know they are well written with lots of examples. This is more than a simple introduction with many intermediate and advanced concepts covered in detail.
In the first delivery of this series of posts, delivered for whom who are interested to understand the basics of MySQL Cluster “by examples”, I wrote about installing MySQL Cluster with a python utility called ndb_setup-py, which offers a nice web graphical interface to define and start our brand new cluster.
In this post I will share an example to do everything from scratch and manually, instead. Doing things manually is always the best recommendation to learn everything about processes life cycle through their:
- Administration (start/stop/reconfigure)
- Monitoring (logs/counters/status)
The resulting topology I’d like to setup is composed of 2 data …[Read more]
I have been playing with MySQL Cluster for some years now, and today I’d like to start writing a bit about it, how to set it up, configure, backup and also how to use it, as there’s plenty of ways to drive operations towards the Cluster for brutal speed and concurrency. MySQL Cluster, the open source in memory database from Oracle MySQL, is available for free from MySQL Cluster download page (Community version has GPL license).
But before starting with an overview of installation and setup, if you’re new to MySQL Cluster, I would strongly recommend to have a look at this video.
What I find more interesting about MySQL Cluster, is that it is possible to have a setup running on commodity hardware (the bare laptop), as it can be configured to have a minimum footprint in terms of memory and storage requirements. About high availability, MySQL Cluster …[Read more]
In the old days, when we wanted to strengthen our skills the only option was to buy a good book. Nowadays one can find a lot of resources on the Internet, however quality is often poor. Fortunately there are still some great people who are brave enough to write new books that will help a new generation of women and men to build modern applications with MySQL the world's most popular open source database. Let me introduce you 3 MySQL books : Introducing the MySQL 8 Document Store / MySQL and JSON: A Practical Programming Guide / Pro MySQL NDB Cluster
In this blog, I will provide answers to the Q & A for the Troubleshooting MySQL Concurrency Issues with Load Testing Tools webinar.
First, I want to thank everybody for attending my May 23, 2018, webinar on troubleshooting tools for MySQL. The recording and slides for the webinar are available here. Below is the list of your questions that I was unable to answer fully during the webinar.
Q: What do you recommend for benchmarking NDB cluster? Which should be used and how?
A: The issue with benchmarking NDB cluster is not the tool choice, …[Read more]