คู่มืออัปเกรด 2.1

ฟีเจอร์และการเปลี่ยนแปลง

  • ต้องใช้ PHP>=8.1

  • อิง workerman/workerman:^5.1 รองรับ coroutine ดู webman Coroutine

  • เพิ่ม connection pool สำหรับ webman/redis:^2.1 webman/cache:^2.1 webman/database:^2.1 webman/think-orm:^2.1 webman/think-cache:^2.1 รองรับทั้งสภาพแวดล้อม coroutine และไม่ใช้ coroutine โดยอัตโนมัติ

กรุณาสำรองข้อมูลก่อนอัปเกรด แล้วรันคำสั่งด้านล่าง

composer config -g --unset repos.packagist
composer require -W workerman/workerman:~5.1 workerman/webman-framework:~2.1

อัปเกรดฐานข้อมูล

หากใช้คอมโพเนนต์ต่อไปนี้ รันคำสั่งที่ตรงกัน:

  • illuminate/database ของ Laravel

    composer require -W webman/database:~2.1
  • illuminate/redis ของ Laravel

    composer require -W webman/redis:~2.1
  • illuminate/cache ของ Laravel

    composer require -W webman/cache:~2.1
  • topthink/think-orm ของ ThinkPHP

    composer require -W webman/think-orm:~2.1
  • topthink/think-cache ของ ThinkPHP

    composer require -W webman/think-cache:~2.1
  • webman/redis-queue

    composer require -W webman/redis-queue:~2.1
  • webman/log

    composer require -W webman/log:~2.1