TOP
紅利積點抵現金,消費購書更貼心
Mastering Swoole PHP: Build High Performance Concurrent System with Async and Coroutines
滿額折

Mastering Swoole PHP: Build High Performance Concurrent System with Async and Coroutines

商品資訊

定價
:NT$ 2031 元
無庫存,下單後進貨(到貨天數約30-45天)
下單可得紅利積點:60 點
商品簡介

商品簡介

Build your high performance large scale concurrent system in a more flexible and efficient way than ever before with this first & only Swoole PHP book, with PHP 8 ready.

Introduction
Introducing a new execution model of PHP applications, how Swoole PHP works and the pitfalls of new developers coming into the Swoole PHP world.
This book is also about the general concepts behind building a high concurrency and high-performance web system and how these concepts are implemented in Swoole PHP and how advanced PHP works.
This book provides just enough Linux OS kernel knowledges with code samples helping you understand how async I/O, concurrency and coroutine works.
When start learning or using a new framework, people always carry some assumption coming from the previous experience. Some of these experiences are helpful to understand the new system, but some of these experiences may lead to the misunderstanding of the new system. This book introduces the pitfalls to avoid if you are an experienced PHP developer.
This book is for the developers who have already know the basics about how a web system works such as PHP web application or application in the other programming languages such as Node.js, Golang or Java.
After reading this book, you should be able to build a high concurrent Swoole PHP system with confidence.

Reviews from experts
"Swoole is a strategic development in the evolution of PHP, bringing high performance async-IO based apps to the mainstream of the platform. This book is everything you need to unlock that power of your new async-PHP apps " - Zeev Suraski, co-founder and CTO of Zend Technologies.

"Swoole is a tremendous technology and a game changer for PHP developers. I started to play with it in 2017 and I created the first runtime for Expressive framework. The results have been incredible, huge performance improvement without using a web server, amazing If you want to design asynchronous applications in PHP the book of Bruce Dou is a must." - Enrico Zimuel, Principal Software Engineer at Elastic

Table of contents

  • Introduction

  • Background
    - Stateless PHP-FPM
    - Performance problem
    - Concurrency problem
    - PHP CLI

  • General concepts
    - Executor and execution containers
    - Lifecycle
    - Decoupling and layers
    - Queue, Buffer, Buffering and Batching
    - Pipe and Channel
    - Context, stack and context switch
    - Singleplex vs multiplexing
    - Asynchronous
    - State, stateless, stateful and pooling
    - File descriptor, I/O stream
    - Exceptions
    - Protocol
    - Concurrency and I/O model
    - Event driven and callbacks
    - Facts, costs and limitation
    - Rate limiting & Concurrency Limiting

  • The practical world on Linux OS
    - User mode and kernel mode
    - Memory management
    - Process, Thread and Coroutine
    - Socket and Networking I/O
    - Blocking IO and Non-blocking IO
    - Callbacks, await async vs coroutines

  • Connect with protocols
    - TCP/UDP Protocol
    - HTTP Protocol
    - Websocket Protocol
    - HTTP2 Protocol and GRPC
    - Custom protocol

  • Swoole runtime and internal
    - Swoole PHP extension
    - Variable and states
    - Event loop and asynchronous I/O
    - Swoole PHP Coroutine
    - Multiple execution modes

  • Hands on Swoole PHP
    - Swoole Server
    - Swoole Server Workers
    - Swoole Process
    - Swoole Clients
    - Swoole Table
    - Swoole Timer
    - Swoole Coroutine and Channel

  • Use cases and patterns
    - HTTP services
    - Data processing
    - HTTP and PHP-FPM proxy
    - Sidecar process
    - TCP service
    - WebSocket Server
    - Task Scheduler
    - Producer and Consumer
    - M: N concurrency mapping
    - Connection polling
    - Web spider and scraper
    - PUBSUB system
    - Server-sent events (SSE)
    - Integrate with Linux process
    - Service Governance: RPC and gRPC
  • 購物須知

    外文書商品之書封,為出版社提供之樣本。實際出貨商品,以出版社所提供之現有版本為主。部份書籍,因出版社供應狀況特殊,匯率將依實際狀況做調整。

    無庫存之商品,在您完成訂單程序之後,將以空運的方式為你下單調貨。為了縮短等待的時間,建議您將外文書與其他商品分開下單,以獲得最快的取貨速度,平均調貨時間為1~2個月。

    為了保護您的權益,「三民網路書店」提供會員七日商品鑑賞期(收到商品為起始日)。

    若要辦理退貨,請在商品鑑賞期內寄回,且商品必須是全新狀態與完整包裝(商品、附件、發票、隨貨贈品等)否則恕不接受退貨。

    定價:100 2031
    無庫存,下單後進貨
    (到貨天數約30-45天)

    暢銷榜

    客服中心

    收藏

    會員專區