OpenSwoole Server getMasterPid()

25.x is outdated, please check the latest version 26.x


Latest version: pecl install openswoole-26.2.0

Declaration

<?php OpenSwoole\Server->getMasterPid(): int

Parameters

none

Return

masterPid

Return the master thread process ID.

Description

Get the master process thread ID.

Available since > v4.5.0

Last updated on February 28, 2026