Announcing PolyScale, the global edge cache for databases

Ben Hagan
Jul 01, 2021

Polyscale is a plug-and-play global database cache that reduces global query latency for databases. Using Polyscale, database reads can be distributed and cached, seamlessly scaling your current database without writing code or altering query or transactional semantics.

Today we are excited to announce that Polyscale is in early access. In this article, we discuss why we built Polyscale and explore the challenges of keeping data-driven applications fast, no matter the scale or geographical locations of the application users.

PolyScale Database Cache

Performance Matters

It is well documented that poor performance kills the user experience. This paradigm spans industries and application types from ecommerce to blogging impacting brands and revenues accordingly. Akamai, for example, reported AliExpress reduced load time by 36% and saw a 10.5% increase in orders and a 27% increase in conversion for new customers. In fact, an entire industry (APM - Application Performance Monitoring) has evolved and reshaped how businesses think about and measure their customer digital experiences.

The ubiquity of high performance, data-driven applications exemplified by global technology companies such as Facebook, Apple, Microsoft, Google and Amazon with seemingly unlimited architectural and developer budgets, sets a high bar for performance and scale expectations. Many enterprises fall short of these goals, especially smaller organizations where skilled resources are limited. Whatever the size of the project, teams inevitably end up investing significant resources, impacting overall product agility.

Customers expect responsive and fast interactions as default, no matter what the underlying complexities these can entail. Milliseconds matter.

The shift to globally distributed applications

The complexities of building and scaling modern applications vary greatly. It is widely recognized that scaling static applications with little interactivity or personalization is a simpler task than database driven applications with high read and/or write query workloads. This is primarily due to the fact that static applications can easily be copied and served by multiple web servers i.e. scaled horizontally.

Content Delivery Networks (CDN’s) such as Fastly and Amazon CloudFront now make it incredibly easy and affordable to deploy static assets globally. If you are building a web application today, it is hard to imagine why you would not deploy using a CDN. Deploying via a CDN provides immediate global presence of the static assets and hence keeps regional latencies low.

Modern application architectures such as the JAMstack enforce separation of concerns by moving the data and persistence requirements to the API. Cleanly separating static content, business logic and data persistence allows each to be scaled and managed independently.

Many enterprises are also focused on decoupling their monolithic applications to utilize microservices and are often deploying within serverless environments. This shift to more decoupling for better environmental isolation can also provide better regional agility with regards to where business logic is deployed to and how it is scaled.

Whether deploying monolithic or microservices applications, edge platforms such as and AWS Lambda@Edge offer deployments in multiple locations around the world as part of CI/CD and scale automatically on demand.

Multi-region data is complex

With these cloud and edge tools at their disposal, enterprises can distribute both static content (images, html etc) and code (business logic) as needed. Scaling the data to support globally dynamic web experiences typically poses greater challenges, especially when considering multi-region data consistency. As enterprises strive to move from “the database” to “the data” as a distributed service, these challenges quickly become apparent. Often enterprises are forced to migrate individual features to entirely new platforms such as key/value stores.

The costs and complexities of caching

Most caching solutions are developed and implemented by development teams using in-memory data stores such as Redis. The complexities of how to model data, perform integration testing, defining what data to cache, eviction policies are all left to the developers to solve.

An alternative solution, scaling reads via database replication, also comes with costs and complexities. Provisioning and managing infrastructure in multiple locations around the world, updates to application control flow (reads vs writes) and observability overheads all lead to additional financial cost and management headaches.

For most enterprises the aforementioned problems get amplified by the use of multiple databases to fulfil different workload requirements. For example transactional, search and data warehouses, each with their own query language and storage requirements. Likewise, as new features are rolled out into products, caching must always be considered and implemented, and differences in strategies across teams and organizational departments can hinder productivity.

Introducing PolyScale

Polyscale is a plug-and-play global database cache as a service that reduces global query latency for databases. Using Polyscale, database reads can be distributed and cached, seamlessly scaling your current database without writing code or altering query or transactional semantics.

Polyscale’s proxies and caches database traffic globally using native database wire protocols such as MySQL and PostgreSQL. This means Polyscale looks just like your existing database to your application, so can be used without any code or infrastructure changes: just update your application’s database origin to use Polyscale instead of your database directly. Reads (SQL SELECT) can be cached geographically close to the requesting source for accelerated performance. All other traffic (INSERT, UPDATE and DELETE etc) passes through to the origin database as normal, remaining strongly consistent.

Polyscale looks just like your existing database to your application so you dont need to write code.

Ben Hagan

PolyScale Founder

No code, serverless database caching.

Polyscale plugs seamlessly into your current database. That means no code changes are required to your applications or microservices and there is no database migration, or changes to query language or ORM’s. No need for topology-aware client drivers. No developer or devops overheads. Nothing changes except for the improvements caching brings.

Simply update the database connection origin of the application connecting to your database. Typically this is a simple config change to an environment variable. Once updated, your application database traffic will be passing through the Polyscale edge network where it can be cached powering low latency applications globally

AI Cache Management & Invalidation

Today, Polyscale uses time based cache invalidation. Time To Live (TTL) values can be configured for individual queries, query templates that span queries with common structure, and even entire tables. This gives fine grained control over what is cached and for how long.

Cache configuration is a trade-off of recency for immediacy. A cache provides the benefit of immediacy, instantly providing a query result, at the cost of recency, that result may not be the most recent and up to date. In order to configure well, the pattern of queries arriving at the database must be understood. While in some cases, this understanding may be available, in general, acquiring this understanding is an on-going data-driven statistical process.

At Polyscale we are excited about the future. We are building machine based intelligent cache configuration and invalidation rules using statistical analysis of query patterns. This analysis runs continuously in the background. At any time, the most up to date recommendations on optimal cache configurations are available and ready to be applied. That application can occur manually by the user, or in hands free mode, automatically adapting to conditions.

Our goal is to make global caching effortless for developers.

What Does PolyScale Solve?

Polyscale solves four areas of database performance and scaling, without writing code or adding DevOps or Developer workload:

Regional Latency - Make data-driven apps blisteringly fast, no matter where the audience resides.

Read Query Performance - Execute any database query in single digit milliseconds, while also reducing performance variability.

High Scalability & Availability - Scale to thousands of concurrent connections with multi-region failover.

Reduced DB Workloads & Costs - Decouple reads to free up resources for writes, reduce infrastructure costs.

We are building a holistic database caching platform for developers to effortlessly scale database reads, without any code or configuration.

Ben Hagan

PolyScale Founder

Next Steps

Ready to try Sign up for a free account here (no credit card required). Or try out PolyScale without bringing your own database with our live interactive demo playground.

Read the Quick Start Guide to understand how easily PolyScale can be integrated without code and without deploying servers.

Written by

Ben Hagan