CASE STUDY

Retail

Modern application architecture for retail

How AllSaints is future-proofing its fast-growing global business with CockroachDB Dedicated

  • 27 year old retailer

  • 250+ stores

  • 26 countries

  • 20% revenue via wholesale

  • 6 members of DevOps team

  • 60+ microservices

What is AllSaints?

AllSaints is a global fashion retailer headquartered in the UK. In its 27 years in operation, the company has built a strong foundation with more than 250 brick and mortar stores across 26 countries, selling high street and fashion brand clothing, jewelry, fragrances, watches, and more.

Despite the pandemic, 2020 was AllSaints' best year ever thanks to its ability to pivot to online sales. The company saw strong growth in its consumer ecommerce business and its relatively new wholesale business. Like many retailers, AllSaints wants to continue to grow its business which relies on a stable infrastructure to power its applications and services.

The AllSaints operations team, which numbers just six despite the company’s size and global reach, recently moved its applications to Google Cloud Provider (GCP) and is now focused on simplifying their tech stack using Kubernetes. A few years ago, the operations team started to re-evaluate their choice in databases to support their move to the cloud and microservice-first initiative.

“CockroachDB has been exactly what we thought it would be and a little more. But this is just the beginning. We’re looking forward to growing the business and growing our use of CockroachDB alongside it.“ - Andy Dean, AllSaints Technical Operations Manager

Must-haves for a modern retail database

AllSaints’ legacy database systems were based on MySQL, but the company has found it challenging to scale as its customer base grows. When it came time to build infrastructure for the company’s new wholesale business, the team saw an opportunity to do something different and build an infrastructure that would be as simple and as flexible as possible.

AllSaints knew that they wanted to leverage microservices for increased efficiency, and they knew that they didn’t want to try to squeeze a square peg into a round hole by deploying MySQL on Kubernetes. They needed something more modern – something that was built with Kubernetes and microservices in mind.

Finally, AllSaints knew that high availability was an absolute necessity. Database downtime isn’t something that any retail or wholesale business can afford, and even a short outage can cause problems such as selling stock that doesn’t actually exist.

Specifically, AllSaints had the following demands for their wholesale database system:

  • Simple to work with so that the team can stay productive.
  • High-availability so that downtime never disrupts operations and to ensure a great user experience even at scale.
  • Compatibility with Kubernetes because AllSaints' broader development strategy revolves around using microservices to increase flexibility and resilience.
  • Managed service so that the AllSaints team can focus on other work without worrying about the database.
  • Cloud-neutral so that they weren’t locked into a single cloud provider in the long term.
  • Future-proof (but still affordable) so that they could commit to a set of tools that work together and grow with them as the business grows.

Having moved many of their microservices onto GCP, the AllSaints team was already aware of Google Spanner and knew that it ticked many of their boxes. However, Spanner also would have locked them into a single-provider setup, which the team was hoping to avoid. Thankfully, AllSaints Technical Architect Ali Rankine knew about a better solution: CockroachDB.

“Getting locked in compromises the application architecture flexibility. Realistically, we don’t need that flexibility now, but we will in the future and that’s what we’re architecting for.” - Andy Dean, AllSaints Technical Operations Manager

Why AllSaints chose CockroachDB Dedicated

CockroachDB met all of AllSaints' technical requirements for their new database system, offering lightning-fast performance at scale, high availability, and Kubernetes compatibility. They don’t have an in-house DBA team so the managed CockroachDB Dedicated option allows AllSaints to focus on building applications and services instead of worrying about the maintenance of the database.

The AllSaints team also appreciates that working with CockroachDB is simple and they remarked that their developers had an easy time adapting to a new database. There was one situation where they needed to make a tweak to performance on a high insert workload and it was all very straightforward because the documentation is so strong.

CockroachDB fits with AllSaints’ plan to build future-proof infrastructure that can scale as their business grows. CockroachDB’s support for multi-region, multi-cloud deployments is more horsepower than the company needs right now, but it aligns with where AllSaints is headed.

“It’s just a simple database to work with. Spinning up your first node is so simple. Querying the data is simple. Adding users is simple. Scaling is simple. In this respect, CockroachDB fits with our ethos.” - Andy Dean, AllSaints Technical Operations Manager

AllSaints’ wholesale workload on CockroachDB

The wholesale application currently running on CockroachDB Dedicated is an internal application the AllSaints sales team uses for processing orders from a growing list of wholesale partners that includes retailers such as Zappos, Bloomingdale’s, and Macy’s. It’s a newer application that’s built on 10+ microservices, managed with Kubernetes and connected to a 9-node cluster deployed on CockroachDB dedicated.

Since it’s internal-only, it’s run behind the Cloudflare WAF CDN. As you can see in the diagram below, AllSaints is running separate CockroachDB Dedicated databases for each of their services so that they can keep the number of tables in each database relatively small.

AllSaints Service Integration

Scaling up with CockroachDB

AllSaints is growing, and the new wholesale side of its business has been growing particularly fast, and now accounts for 20% of the company’s revenue. They’ve seen strong enough wholesale demand to plan for production increases that will help the wholesale side of the business scale up even further.

That’s part of why CockroachDB’s future-proof solution was so important: while the AllSaints team doesn’t need CockroachDB’s multi-region support right now, they do plan to make use of geo-partitioning in the future to improve performance and maintain regulatory compliance. They’ll also integrate the database with EDIs so that they can communicate more directly with wholesale partners.

And while CockroachDB is currently storing product information related to the wholesale business, the company ultimately plans to move all of its product data onto CockroachDB. This will allow other applications to take advantage of the high performance and availability that CockroachDB offers and give AllSaints a single system of record for all of their inventory data.

Ready to get started?