search
HomePHP FrameworkWorkermanIs php workerman asynchronous?

Is php workerman asynchronous?

Dec 05, 2019 am 11:57 AM
workerman

Is php workerman asynchronous?

workerman official introduction: Workerman is an open source high-performance asynchronous PHP socket instant messaging framework. It supports high concurrency and ultra-high stability, and is widely used in the development of mobile apps, mobile communications, WeChat applets, mobile game servers, online games, etc. (Recommended learning: workerman tutorial)

Supports TCP long connections, supports Websocket, HTTP and other protocols, and supports custom protocols. It has many high-performance components such as asynchronous Mysql, asynchronous Redis, asynchronous Http, MQTT IoT client, asynchronous message queue, etc.

In fact, Workerman is similar to a PHP version of nginx, and the core is also multi-process Epoll non-blocking IO. Each Workerman process can maintain tens of thousands of concurrent connections. Because it resides in memory, it does not rely on containers such as Apache, nginx, and php-fpm, and has ultra-high performance.

High performance

Based on the high-performance Epoll event network library, a single machine can support millions of concurrent connections, and the long-term connection throughput is as high as 36W/S. Objects such as PHP databases can reside in memory, reducing parsing, compilation and network overhead.

Since the PHP file is read and parsed from the disk once, it will be resident in the memory. The next time it is used, the opcode in the memory will be used directly, which greatly reduces the disk IO and request initialization, creation of execution environment, etc. in PHP. There are many time-consuming processes such as lexical parsing, syntax parsing, compiling opcode, request closing, etc.

And it does not rely on containers such as nginx and apache. It reduces the network overhead of nginx and other containers communicating with PHP. The most important thing is that resources can be maintained permanently without having to initialize database connections every time, so use workererman to develop applications. Program, performance is very high.

High availability

has been confirmed by many companies, including e-commerce companies with a daily turnover of over 100 million, for server backend development, and Well-known online game companies use it for the development of game backends.

Simple development

The interface is simple, and there are already many mature network applications. As long as you know PHP, you can quickly develop based on these applications. Own Socket application service.

The above is the detailed content of Is php workerman asynchronous?. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

SecLists

SecLists

SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.