略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: Swoole\Channel::__construct

2024-11-12

Swoole\Channel::__construct

(PECL swoole >= 1.9.0)

Swoole\Channel::__constructConstruct a Swoole Channel

说明

public Swoole\Channel::__construct(string $size)

Swoole channel is memory data structure works like Chan in Golang, implemented based on shared memory and mutex locks. It can be used as high performance message queue in memory. Construct a swoole channel with a fixed size. The minimum size of a swoole channel is 64KB. Exceptions will be thrown if there is not enough memory.

参数

size

The size of the Swoole channel.

add a noteadd a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/swoole-channel.construct.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3