Midoin Reshapes Crypto with Horizontal Write Scalability and PostgreSQL Compatibility

Discover YugabyteDB Managed With the 7-in-7 Customer Series
Michael Haag

Midoin is reshaping the landscape of digital currency, focusing on accessibility and sustainability. With their flagship product—the Midoin app—they want to enable users to “mine” Midoins by just tapping on their smartphone. Because they are not based on blockchain technology, Midoins are a greener alternative to traditional cryptocurrencies.

Through its new digital currency platform, Midoin’s goal is to offer users:

  • Low Fees: Provide a cost-effective way to send and receive payments
  • Fast Transactions: Process transactions quickly, typically in just a few seconds
  • Security: Protect users’ funds, including PoR consensus, multi-signature wallets, and cold storage

To support their business and deliver these user benefits as their company grew, Midoin needed an easy-to-manage database solution that didn’t sacrifice performance, security, or scale. They chose YugabyteDB Managed, our fully managed DBaaS solution.

Technical Requirements For This Horizontally Scalable, PostgreSQL-Compatible Database

Midoin’s development teams frequently faced issues in scaling writes with their legacy PostgreSQL solution deployed on Heroku. They needed a write-scalable, PostgreSQL-compatible database that could be managed with minimal operational overhead. Their small IT team needed to focus on application development, and, as an early startup, managing expenses was critical.

The following parameters and requirements guided Midoin’s decision in choosing an alternative database to replace PostgreSQL:

  • Deployment: Single-region, single availability zones (AZ)
  • Primary Database Requirements: Horizontal write scalability to handle any sudden surge in usage and writes per second. The team needed an easy way to scale out (and down) as needed to support peak events and rapid growth in usage.
  • Cloud Used: AWS
  • Workload Characterization: Write-heavy workload that needed <20ms read and write latency
  • Throughput: Up to 8 billion operations per day
  • API Interfaces: YSQL (PostgreSQL-compatible API)
  • Additional Database Requirements:
    • Compatible with PostgreSQL
    • High availability
    • Hosted solution with minimal operational overhead

Transitioning to a Modern, Turbocharged PostgreSQL with High Availability

Based on the requirements above, Midoin chose to deploy YugabyteDB Managed, our fully-managed database-as-a-service (DBaaS), and migrate their applications from their legacy, single-node PostgreSQL.

Midoin’s environment was located in a single region and single availability zone. The new multi-node cluster increased availability by ensuring data was protected and customers would not be impacted if a node failed. This updated architecture provides a scalable path for Midoin to expand into additional zones and regions, ensuring higher availability to match any/all escalating growth demands.

Below are three key YugabyteDB Managed capabilities essential to their new architecture.

  1. Horizontal Write Scalability

    With their legacy environment, the development team managed to scale their original PostgreSQL database (on Heroku) through read replicas. However, as user numbers swelled, they could not scale their PostgreSQL environment horizontally. Heroku would hit a vertical scale wall at the highest number of nodes whenever a rapid increase in database writes per second occurred.

    With YugabyteDB Managed, Midoin could scale out as needed to meet sudden surges in demand and cover peak events. In terms of horizontal scaling, they could scale nodes in increments of one.

    In YugabyteDB, data is split (sharded) into tablets, and these multiple tablets are located across nodes in the cluster. When more nodes are added, some tablets are automatically moved to new nodes so that the cluster always remains in balance.

    Tablets can be split dynamically (as needed) to use the newly added resources; therefore, each node manages fewer tablets. As a result, Midoin’s entire cluster could handle more transactions and queries in parallel, increasing its capacity to handle larger workloads.

  2. Single-Zone High Availability

    Midoin’s initial setup with YugabyteDB involved a single-region, single-zone deployment. They upgraded from a single-node PostgreSQL to a more resilient 4-node cloud cluster for enhanced data protection.

    Along with a 4-node cluster, Midoin chose a replication factor of three (RF3). In this environment, YugabyteDB could continue to perform reads and writes even if a node failed. In the future, they can easily scale across zones to ensure protection against cloud availability zone outages.

    Single-region, single-zone deployment with protection against node failures.
  3. PostgreSQL Runtime Compatibility

    Midoin had existing applications that were originally written for standard PostgreSQL. Since YugabyteDB offers strong runtime compatibility with PostgreSQL, Midoin was able to migrate their existing applications without having to re-architect. The API layer remained the same, while the new underlying storage layer in YugabyteDB delivered automatic sharding and data distribution to meet scaling and availability requirements.

    All levels of PostgreSQL compatibility are not the same - social card
    Understand the different levels of PostgreSQL compatibility. They are not all the same.

In Summary….

Midoin’s experience is common among small, fast-growing companies: they leverage PostgreSQL for its robust features but quickly encounter the need for streamlined scalability beyond a single node, zone, or

Rather than invest in complex solutions or hire additional database expertise, Midoin found a fully managed DBaaS solution that met their exacting requirements and provided strong deployment flexibility. YugabyteDB’s strong PostgreSQL compatibility ensured an easy migration path, so they could instead focus on developing new core app features instead of database operations.

Learn more about YugabyteDB Managed and the features leveraged by Midoin through the following resources:

  1. Attend a Thursday demo to see geo-partitioning in action
  2. Sign up for a full-featured, free trial of YugabyteDB Managed to give geo-partitioning a try
  3. Visit our Docs and Blog space to discover how you can build a global application with YugabyteDB
Michael Haag

Related Posts

Explore Distributed SQL and YugabyteDB in Depth

Discover the future of data management.
Learn at Yugabyte University
Get Started Business
Browse Yugabyte Docs
Explore docs Business
Distributed SQL for Dummies
Read for Free Business