larawelders/scheduler-event-logger 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

larawelders/scheduler-event-logger

Composer 安装命令:

composer require larawelders/scheduler-event-logger

包简介

Log Laravel scheduler lifecycle events.

README 文档

README

Log Laravel scheduler lifecycle events to a dedicated schedule log channel.

Support Matrix

Package PHP Laravel
1.x 8.2+ 12.x / 13.x

Notes:

  • Laravel 12 supports PHP 8.2 through 8.5.
  • Laravel 13 requires PHP 8.3+, so PHP 8.2 is only valid with Laravel 12.

What it logs

  • ScheduledTaskStarting at info
  • ScheduledTaskFinished at info
  • ScheduledTaskFailed at error
  • ScheduledTaskSkipped at info
  • ScheduledBackgroundTaskFinished at info
  • SchedulePaused at info
  • ScheduleResumed at info

Installation

composer require larawelders/scheduler-event-logger

The package uses Laravel package discovery, so no manual provider registration is required.

The package registers a default schedule log channel at runtime if your application does not already define one. By default, it uses a daily channel that writes to date-named files under storage/logs/schedule.log.

If you want to customize the channel name or logger configuration, publish the package config:

php artisan vendor:publish --tag=scheduler-event-logger-config

The published config lets you change both the channel name and the underlying channel definition:

'channel' => 'schedule',

'channel_config' => [
    'driver' => 'daily',
    'path' => storage_path('logs/schedule.log'),
    'level' => 'debug',
],

If your application already defines a channel with the configured name in config/logging.php, the application definition takes precedence:

'channels' => [
    'schedule' => [
        'driver' => 'single',
        'path' => storage_path('logs/app-schedule.log'),
        'level' => 'info',
    ],
],

Example Output

[framework/schedule-9f57b5c9...] Starting task "daily-report" on timezone UTC
[framework/schedule-9f57b5c9...] Finished task "daily-report" on timezone UTC with exit code 0 in 0.125s
[framework/schedule-a1b3f70e...] Failed task `php artisan sync:vendors` after RuntimeException: API timeout
[framework/schedule-a1b3f70e...] Skipped task `php artisan sync:vendors`
[framework/schedule-70c74e7f...] Background task finished `php artisan imports:run` in background with exit code 0
[schedule] Paused
[schedule] Resumed

Development

composer install
composer run analyse

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 7
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-05-07

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固