A Closer Look at Serverless Databases: Fauna, PlanetScaleDB, NeonDB
profile picture Vishwasa Navada K
4 min read Oct 11, 2023

A Closer Look at Serverless Databases: Fauna, PlanetScaleDB, NeonDB

The serverless tech space is changing, offering new opportunities in the database architecture scene. Today, we’re zooming in on three serverless databases - Fauna, PlanetScaleDB, and NeonDB - each with its unique strengths and features.

Fauna

Fauna is a globally distributed NoSQL database, known for its consistently low latency times, strong consistency profile, and relational capabilities within the context of a flexible document-oriented data model. Its pay-as-you-go model means you’re only charged for actual usage - no costs during idle times. Plus, developers appreciate Fauna’s robust Fauna Query Language and its wide support for various languages.

PlanetScaleDB

For those in the SQL realm, PlanetScaleDB offers a great solution. This database is designed to manage and scale MySQL databases, providing high-performance reads and writes. Like Fauna, PlanetScaleDB also follows a usage-based model, so you only pay for the resources you consume.

NeonDB

NeonDB is built for real-time, high-performance applications. This PostgreSQL-based relational database stands out with its high-speed read and write operations. NeonDB follows a consumption-based model, charging customers only for the data they use.

TL;DR: Comparing Fauna, PlanetScaleDB, and NeonDB

DatabaseDB TypeFree Tier Offering, Pricing ModelRegion SupportDistinct Feature Offering
FaunaNoSQL/DocumentDB100k read ops, 50k write ops, 500k compute ops, and 5GB storage Free Monthly. Pay as you go starting from 25$/MonthGlobal (with data centers across North America, Europe, Asia-Pacific, South America, and India)Document-relational Model, Multi-Region Replication, and Backup, Official Driver support for C#, Go, Java, Javascript, Python, and Scala
PlanetScaleDBSQL (MySQL-based)Free tier: 10GB storage, 20 connections. Developer plan: $49/month, 10 databases, 20GB storage, 100 connections. Business plan: $999/month, 25 databases, 100GB storage, 500 connectionsGlobal: East Asia, Europe, North America, South Asia, AustraliaBranching, Non-blocking schema changes, Deploy schemas from CI/CD, Automated failover
NeonDBSQL (PostgreSQL-based)Free tier: Up to 1 million requests per day, 10GB storage. Pricing scales with usage, with additional costs for data transfer, backups, and replicationNorth Virginia, Oregon, Frankfurt, Ireland, Sydney, Mumbai, São Paulo, LondonDatabase Branching, Fully Serverless, Multi-Cloud and Multi-Region, Fine-Grained Security with PostgreSQL RLS

The Experiment

So we decided to see how fast our three chosen databases could go. We set up a test, and crunched the numbers with the following parameters:

  1. Compute: We ran the tests on AWS Lambda with its default configurations in the same region as the databases were set up (us-east-1/US North Virginia) and used API Gateway to invoke it.
  2. Schema: We created the same database schema in each service and populated them with identical volumes of data.
  3. Querying: We used the native drivers provided by each service to query the databases. We ran the tests for various row limits, specifically 10, 50, 100, 250, 500, 1000, 2500, and 5000 rows.
  4. Repetition and Averaging: Each data size query was performed multiple times for each database. This was done to account for any inconsistencies and to establish an average response time.

Results

Note that these numbers are excluding Lambda Cold Starts but could include Cold Starts from the Database Provider itself.

DatabaseRows: 10Rows: 50Rows: 100Rows: 250Rows: 500Rows: 1000Rows: 2500Rows: 5000
Fauna49.9 ms53.1 ms45.9 ms86.2 ms147.2 ms280.1 ms705.9 ms1293.5 ms
Neon56.4 ms18.7 ms20.8 ms44.5 ms56.4 ms107.4 ms160.7 ms304.6 ms
PlanetScale149 ms55.3 ms14.5 ms47.1 ms74.5 ms142.8 ms344.1 ms836.9 ms
service category

Innovate faster, and go farther with serverless-native application development. Explore limitless possibilities with AntStack's serverless solutions. Empowering your business to achieve your most audacious goals.

Build with us

Author(s)

Tags

Share this blog

Your Digital Journey deserves a great story.

Build one with us.

Recommended Blogs

cookie

These cookies are used to collect information about how you interact with this website and allow us to remember you. We use this information in order to improve and customize your browsing experience and for analytics and metrics about our visitors on this website.

If you decline, your information won’t be tracked when you visit this website. A single cookie will be used in your browser to remember your preference not to be tracked.

Build With Us