Highly Available Greetings:
Greetz uses MariaDB Galera Cluster
for on-‐‑line Greeting Card Platform

Greetz provides on-‐‑line personalized greeting cards tothousands of customers. Their web-‐‑shop application is built
on Java and Hibernate (Object Relation mapping) and, prior
to moving to MariaDB Galera Cluster, used Oracle™ RAC as
its underlying database. Their infrastructure is based on
Linux and they use Ansible for configuration management.
Greetz approached Codershipʼ’s partner SkySQL (nowMariaDB Corp.) to provide them with a replacement
database technology for their web-‐‑shop that would
significantly reduce the total cost of ownership of theirdatabase, while ensuring high availability and a solid,predictable performance.

Challenges
Greetz was concerned by the shortage of internal Oracle
DBA resources and the increasing complexity of managing
their Oracle database as their business grew. They wanted areal-‐‑time replica of their production database in theirfacility in case of disaster, but they werenʼ’t able to have thisunder the existing MySQL database license terms they hadwith Oracle.
The inflexible approach to MySQL database licensing
pursued by Oracle became a significant barrier to Greetzʼ’sgrowth, would eventually become one of the key reasons
they switched to MariaDB.
A key part of any database implementation is the accuracyof data, together with its successful migration from the oldlegacy systems. This is particularly important in the e-‐‑commerce sector where customer details and purchasing
history must be fully traceable and auditable. This was to be
one of the main challenges of the project.

Solution
Greetz insisted that Linux, Hibernate andAnsible remain as part of any replacement
solution they might implement. They werewilling to replace only the database system.
Greetz was using MySQL for BusinessIntelligence, Disaster Recovery and other supplementaryservices. These servers were updated on a regular basis
using purpose-‐‑built scripts and programs. They wanted
them migrated from MySQL to MariaDB. However, Greetzʼ’s
existing Hibernate deployment used Hibernateʼ’s default
query setup, which ensured that there was no native SQL toreplace prior to the migration.
MariaDBʼ’s project team concluded that migrating theQuick Facts
Established in 2003
Site Started in 2004
About 60 Employees
Over 18 million
Cards Sent Since
Inception

Related Sites
GreetzGreetz U.S.
MariaDBCodership

About Greetz
Greetzprovidesanon-‐‑line
personalized greeting card service tothousands of customers in Europe andNorth America. It was established by
Johan van Vulpen and Simen Schimmel.
With more than 18 million greetingcards sold to date, Greetz has become
the largest on-‐‑line greeting card
service in the Netherlands. An
enthusiastic team of more than 60
employees is constantly working tobuild on this success.

application would consist of moving the database schemaand data, pointing Hibernate to the new database, end-‐‑to-‐‑end testing and then performance tuning. Only a few
difficulties were encountered during the migration process,but all were easily addressed.
The differences between Oracle and MariaDB Galera Cluster
presented a few problems related to Hibernate, but theywere resolved. This included the development of an Ansible
configuration for MariaDB and Galera Cluster. The loadbalancer / failover also needed to be configured, as well as
Galera Cluster itself.
Their table schema was fairly easy to migrate, but it wasoften adjusted during the migration process (e.g., data typemappings and indexing). The big issue with the migration ofdata was performance during scheduled downtime. During avery restricted time window, large amounts of data had tobe extracted from the existing servers, transferred to thenew ones and then imported into MariaDB Galera Cluster.

About Codership
Codership
Oyprovideshighavailability, no-‐‑data-‐‑loss and scalable
data
replicationandclusteringsolutions for open source databases.
Codership's flagship product is Galera
Cluster™
forMySQL,aTrue
Multimaster
Clusterbasedonsynchronousreplication.
GaleraCluster is an easy-‐‑to-‐‑use, high-‐‑availability solution which provides
high system uptime, no data loss andscalability for future growth. For more
information about Galera Cluster,
please contact info@galeracluster.com

The testing of the resulting schema and data was acontinuous process through the migration, including
application testing as well as automated verification ofmigrated data. As part of the migration, consideration wasalso given to Greetzʼ’s future data growth and services toensure the system could be scaled, both horizontally andvertically.

Results
The Greetz migration project set out todeploy a more scalable, more performant andhighly available database solution whileproviding real-‐‑time disaster recovery and BIdatabases.
From a performance point of view, the new MariaDB with
Galera Cluster setup is now faster than Oracle RAC andprovides just as good, if not better, stability and highavailability. MariaDB successfully reduced the total cost ofowership of Greetzʼ’s database solution by removing theneed for a SAN and significantly lowering license andmaintenance costs.
Today, MariaDB with Galera Cluster provides Greetz with astable, proven and reliable platform for its high capacity
web-‐‑shop, ensuring that it is highly available at all times.

Copyright 2014, Codership Oy. All Rights Reserved.
Galera, Galera Cluster, Galera Replication are trademarks of Codership Oy.
Pohjolankatu 64 A, 00600 Helsinki, Finland
info@galeracluster.com ♣ http://galeracluster.com ♣ +358 50 5179059