Cover Page....2
Table of Contents....3
Preface....4
Part 1: The Architecture....12
Chapter 1: Understanding the Laravel Web Application Architecture....13
Technical requirements....15
Exploring the Laravel ecosystem....15
Understanding the HTTP request lifecycle....18
Getting to know the application server for Laravel Octane....24
Understanding performance measurement in Laravel Octane....32
Summary....38
Part 2: The Application Server....39
Chapter 2: Configuring the RoadRunner Application Server....40
Technical requirements....41
Setting up a basic Laravel application....42
Installing RoadRunner....46
Installing Laravel Octane....53
Launching Laravel Octane....55
Laravel Octane and RoadRunner advanced configuration....57
Summary....62
Chapter 3: Configuring the Swoole Application Server....63
Technical requirements....64
Setting up Laravel Octane with Swoole using Laravel Sail....66
Installing Open Swoole....72
Before editing the code....74
Exploring Swoole features....75
Summary....90
Part 3: Laravel Octane – a Complete Tour....92
Chapter 4: Building a Laravel Octane Application....93
Technical requirements....95
Installing and setting up the dashboard application....95
Creating a dashboard application....108
Making parallel HTTP requests....126
Understanding the caching mechanism....131
Refactoring the dashboard....136
The cache configuration....139
Summary....140
Chapter 5: Reducing Latency and Managing Data with an Asynchronous Approach....141
Technical requirements....142
Optimizing queries with indexes....142
Making the cache mechanism asynchronous....153
Summary....157
Part 4: Speeding Up....158
Chapter 6: Using Queues to Apply the Asynchronous Approach in Your Application....159
Technical requirements....160
Introducing the queue mechanism in Laravel....160
Installing and configuring the queue....162
Managing the queues....165
Managing queues with Redis and monitoring them....173
Summary....182
Chapter 7: Configuring the Laravel Octane Application for the Production Environment....184
Technical requirements....184
Introducing the production architecture....185
Prepping a Laravel application for production....196
Deployment approaches....199
Summary....206
Index....208
Why subscribe?....217
Other Books You May Enjoy....219
Packt is searching for authors like you....222
Download a free PDF copy of this book....223
Laravel Octane is a very powerful component in the Laravel ecosystem that can help you achieve remarkable app performance. With Laravel Octane, you will find tools (queues, cache, and tables) that facilitate a new asynchronous approach for improving application performance.
This book highlights how Laravel Octane works, what steps to take in designing an application from the start, what tools you have at your disposal, and how to set up production environments. It provides complete coverage of the strategies, tools, and best practices to make your apps scalable and performant. This is especially important as optimization is usually the overlooked part in the application development lifecycle. You will explore the asynchronous approach in Laravel and be able to release high-performing applications that have a positive impact on the end-user experience.
By the end of this book, you will find yourself designing, developing, and releasing high-performance applications.
The book is for existing Laravel developers who want to improve their software architecture, from a basic or standard architecture to a more scalable and performant one. Basic knowledge of Laravel fundamentals is required.