Rebuilding the Spreaker web listening experience with PHP and Serverless

Our brand new listening platform: https://next.spreaker.com

Web development is constantly evolving, and staying ahead of the curve is essential for businesses to remain competitive. In this blog post, we’ll explore how at Spreaker, we embraced innovation by breaking free from monolithic architectures and adopting modern technologies like Livewire and Serverless.

Our tech lead Simone D’Amico recently presented our journey at the WebDay 2024 conference in Milan.

Challenges Faced

The journey towards modernization wasn’t without its challenges. We faced technical constraints, including a decade-old monolith that hindered product evolution and heavily indexed contents. Moreover, the team primarily skilled in PHP needed to find innovative solutions to modernize their infrastructure while leveraging the pre-existent team skills.

The Solution

To overcome these challenges, we embarked on a journey of exploration and experimentation. We conducted proof of concepts, evaluating different technologies and frameworks. Eventually, we settled on a combination of Bref and Octane, leveraging the power of AWS Lambda for serverless deployment and high-performance request handling for Laravel applications.

Spreaker NEXT Architecture Diagram

Why Bref and Octane

Bref provided the infrastructure needed to deploy PHP applications on AWS Lambda, while Octane offered high-performance, concurrent request handling, caching Laravel applications in RAM for faster response times. By adopting these technologies, we were able to build a scalable and resilient architecture capable of handling millions of requests per day.

Leveraging Livewire

In addition to Bref and Octane, we used Livewire for frontend development. Livewire allowed us to write interactive web interfaces using mainly PHP, eliminating the need for complex JavaScript frameworks. With real-time updates and seamless integration with Laravel, Livewire proved to be a game-changer in enhancing the developer experience without sacrificing the UX of our product.

Challenges Overcome

Of course, the journey wasn’t without its bumps. We encountered challenges such as coexistence with the current website, shared sessions, and some extra care to avoid Octane memory leaks. However, through continuous iteration, we were able to overcome these obstacles and deliver a seamless listening experience to our users.

The Results

With Spreaker Next, we were able to deliver a modern and scalable application that poses as a solid basis for our ambition to innovate podcast listening.

Conclusion

By embracing modern technologies like Livewire, Bref and Serverless, we were able to stay ahead of the curve and deliver a cutting-edge product to our users.

Key Takeaways

  • Modernizing web applications is possible with PHP in 2024
  • Experimentation and innovation are essential for staying ahead
  • Embracing technologies like Livewire and Serverless can lead to scalable and resilient architectures capable of delivering exceptional user experience

Read the full presentation