1
0 Comments

Dramatic Performance Boosts on FlippedNormals: A Case Study

After months of troubleshooting and optimizing, we’re thrilled to share the results of a major performance overhaul on our marketplace platform. The changes were essential to address issues with stability, load times, and scalability, which were critical during peak times like sales events.

Key Improvements in Numbers

Our performance metrics tell the story best. Before optimization, load times across various pages were significantly slower, with some averaging as high as 57.97 seconds under load. Now, the highest load time is 6.38 seconds, with lows reaching an impressive 0.80 seconds. Average improvements across key pages range from 60% to over 90%, as highlighted in the table below:

| Page | Pre-Optimization (s) | Current (s) | Improvement (%) |

|---------------------|----------------------|-------------|-----------------|

| Homepage | 15.70 | 4.01 | 74.43% |

| Best Selling Tutorials | 8.34 | 3.11 | 62.66% |

| Latest Daz Products | 19.95 | 2.82 | 85.86% |

| FN Exclusives | 8.77 | 3.50 | 60.13% |

| Realistic Dino | 31.81 | 2.01 | 93.69% |

Optimizations That Made This Possible

1. Batching for Re-Indexing: One of the biggest improvements came from batching product re-indexing during high-load times, like sales. Previously, our system queried all products (currently 42k) at once, often leading to crashes and timeouts. With batching, resource usage is now more balanced, preventing these disruptions.

2. Switch to Eager Loading: We tackled performance bottlenecks by switching from lazy loading to eager loading. We also eliminated a lot of N+1 query issues by creating custom queries. This helped stabilize load times and reduced the strain on our database, making the site more responsive.

3. Session Management with Memcached: To address forced logouts during server restarts, we’ve implemented Memcached for session storage, rather than storing session cookies directly on our EC2 instances. This change should resolve the annoying log-out issue users experienced during crashes.

Results and Impact

With these optimizations in place, we’re hopeful for a smoother, more reliable experience across the board. We aim for an end to the frustrating forced logouts, more consistent delivery of emails (like verification and password resets), and stable load times, even during peak traffic. Our hope is that products no longer get “stuck” on sale due to job processing issues, providing a seamless experience for our users.

A Look Ahead

Achieving these performance improvements has been a long journey, but our platform is now stable and ready for the next phase of development. With the groundwork for performance laid, we’re excited to focus on new features and enhancements that will continue improving our marketplace experience.

---

This performance overhaul is not just about speed; it’s about delivering a stable, enjoyable experience for our users, even during peak load times.

posted toAvatar for product FlippedNormals
FlippedNormals