Build a High‑Performance Queue System with Webman and GatewayWorker

This guide explains how to create a scalable PHP queue and ticket‑calling system using the high‑performance Webman framework and GatewayWorker, covering the system’s purpose, core components, step‑by‑step installation, configuration, startup commands, and sample log output.

Open Source Tech Hub
Open Source Tech Hub
Open Source Tech Hub
Build a High‑Performance Queue System with Webman and GatewayWorker

Overview

The project implements a simple queue and ticket‑calling system with ultra‑high performance and scalability, built on the Webman HTTP framework and the GatewayWorker TCP long‑connection framework. Such systems are widely used in banks, hospitals, government service centers, restaurants, airports, and similar venues to improve service efficiency, enhance customer experience, and streamline workflow by automating the queuing process.

Webman is a high‑performance HTTP service framework based on Workerman, intended to replace the traditional php‑fpm architecture. It can be used to develop websites, HTTP APIs, or micro‑services.
GatewayWorker, also built on Workerman, provides a rapid development framework for TCP long‑connection applications such as push‑notification servers, instant messaging back‑ends, game servers, IoT, and smart‑home services.

Installation

1. Clone the repository

git clone https://github.com/zx2020-07/queue.git

2. Install dependencies

cd queue

composer install

3. Import the SQL file

import sql/queue.sql

4. Configure environment variables

cp .env.example .env

5. Start Webman

php start.php start

After starting, open http://localhost:8787 in a browser to access the application.

Sample Log Output

[2024-12-28 18:03:35] default.INFO: 172.18.0.1 GET 127.0.0.1:8204 [360.955ms] [webman/log]
[SQL]   [connection:default] select count(*) as aggregate from `queue_numbers` where `status` in (4, 0, 2) and date(`created_at`) = '2024-12-28' [41.53 ms]
[SQL]   [connection:default] select * from `windows` where `status` = 1 order by `id` asc [1.4 ms]
... (additional log entries omitted for brevity) ...

Preview

Preview 1
Preview 1
Preview 2
Preview 2
Preview 3
Preview 3
Preview 4
Preview 4
Preview 5
Preview 5
Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

BackendPHPInstallationWebmanGatewayWorkerQueue System
Open Source Tech Hub
Written by

Open Source Tech Hub

Sharing cutting-edge internet technologies and practical AI resources.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.