tastyworks

Consultancy and Support from 2ndQuadrant for online trading platform boosts PostgreSQL performance by 400%

tastyworks is a retail brokerage firm based in Chicago, IL that is leading a financial revolution for the do-it-yourself investor. It is a sibling company of tastytrade.com, which is one of the fastest growing online financial networks in the world. tastyworks is a wholly-owned subsidiary of tastytrade, Inc.

tastyworks provides a powerful and easy-to-use trading platform that interacts with the firm’s distributed microservices infrastructure. PostgreSQL was their database of choice, as the in-house team had previously implemented it in other parts of the company’s infrastructure. The database powering the tastyworks infrastructure was configured with basic replication and a baseline configuration suited for a mix of transactional and analytical workload. tastyworks subsequently launched in the brokerage sector, and began facilitating customer trades in January of 2017.
 


Challenge

Shortly after launching, the rapid success of the tastyworks platform created a larger than expected production volume, leading to unforeseen performance issues.

As the volume of the high throughput transactional workload grew, the technical team’s existing knowledge from running PostgreSQL on other projects did not provide insight into the specific performance and scalability issues that were manifesting. The team quickly realized that it would be necessary to diagnose bottlenecks and scale out the hardware appropriately to achieve immediate performance improvements and prepare the platform for future growth.

Faced with additional engineering and scaling challenges, the team felt a strong need to bring in specialists for architectural consultancy. tastyworks began to explore the options on how to best scale their database infrastructure and tackle performance issues simultaneously.

Solution

tastyworks conducted thorough research and reached out to several PostgreSQL service providers to discuss consultancy services, database assessment, and support. 2ndQuadrant stood out above all others for having a more in-depth technical knowledge and superior services. tastyworks was especially impressed to see that the core PostgreSQL committers at 2ndQuadrant were directly involved in the consultancy and support services.

2ndQuadrant experts performed an architectural health check of tastyworks’ PostgreSQL database. A thorough analysis was conducted, which revealed a variety of sporadic performance issues that were responsible for slowing down the database. Consultancy services early on helped tastyworks pin down issues that were caused due to overzealous auto-analyze and auto-vacuum operations.

Performance Enhancements

2ndquadrant webinar

After the analysis was completed, 2ndQuadrant recommended changes needed to ensure a high-performing database. Due to the critical nature of their data, tastyworks chose to have an in-house team implement the recommended changes. Coupled with 24/7 Production Support and the guidance of 2ndQuadrant Consultants, tastyworks was successful in optimizing their database by:

  • Implementing repmgr for replication between servers to easily manage High Availability, and enhancing overall productivity by reducing administrative overhead.

  • Introducing pgbouncer for connection pooling. Repmgr and Pgbouncer worked together in the scaling of the overall infrastructure and to reduce connection overhead.

  • Updating their PostgreSQL configuration and tuning Linux to meet best practices.

  • Designing, configuring, and seamlessly migrating to new, purpose-built server hardware for optimal performance and a substantial increase in headroom for forward growth.

After implementing these changes, tastyworks was able to scale their microservices infrastructure horizontally. This allowed them to manage thousands of simultaneous client connections while maintaining high levels of performance for the underlying PostgreSQL systems. This more robust architecture resulted in the ability to maintain high performing end-user trading platforms, even during periods of peak volume.

Deploying PGBouncer allowed us to stay ahead of performance issues that we knew we'd run in to due to increasing transactional volume. It was implemented in parallel with other re-engineering and performance optimization work and the impact was immediately noticeable. During our daily load test, we observed an immediate 2-4x improvement in peak throughput.

Jordan von Kluck, CTO, tastyworks

Seeing the drastic improvements in performance, tastyworks realized the importance of having PostgreSQL experts available around the clock, and they initiated a partnership with 2ndQuadrant under their 24/7 Platinum Support Plan.

Working with 2ndQuadrant has been an excellent experience. Their support team has a wealth of knowledge and always provides an in-depth answer to our questions in a very timely fashion. Between support, consulting on specific issues and guidance on overall best practices, 2ndQuadrant has been an invaluable resource to us at tastyworks.

Jordan von Kluck, CTO, tastyworks

Services provided

  • 24/7 PostgreSQL Production Support
  • Architectural Health Check
  • Consultancy

About 2ndQuadrant

2ndQuadrant provides PostgreSQL solutions for the Enterprise. Our support engineers have over 100 years of combined code contributions to the PostgreSQL project, making us the only company to contribute enterprise features to all of the last 13 releases.

This is paired with 17+ years of hands-on experience through client engagements and allows us to integrate customized solutions with our customers - making 2ndQuadrant the Gold Standard for PostgreSQL products & services.

       

2ndQuadrant Updates


Stay in touch with us

Subscribe to our monthly newsletter to hear the latest developments from 2ndQuadrant and related technologies.

We’ll also send you any important news or updates that we think you’ll find useful.

We value your privacy and will not pass your details on to anyone else.

Cookie Settings

2ndQuadrant Updates