eloquage/filament-horizon 问题修复 & 功能扩展

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

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

eloquage/filament-horizon

Composer 安装命令:

composer require eloquage/filament-horizon

包简介

This is my package filament-horizon

README 文档

README

Filament Horizon Banner

Latest Version PHP Version Total Downloads Tests License

Filament Horizon

The most beautiful way to monitor Laravel Horizon in your Filament admin panel.

A seamless integration of Laravel Horizon into Filament v4, providing a stunning real-time dashboard to monitor your Redis queues, jobs, batches, and workers — all without leaving your admin panel.

✨ Features

📊 Real-time Dashboard

  • Live status indicators (running/paused/inactive)
  • Jobs per minute throughput
  • Process count & queue overview
  • Max wait time monitoring

🔄 Job Management

  • View pending, completed & silenced jobs
  • Failed job inspection with stack traces
  • One-click job retry functionality
  • Tag-based job filtering

📦 Batch Operations

  • Complete batch overview
  • Progress tracking
  • Failed job details per batch
  • Batch retry capabilities

📈 Advanced Metrics

  • Job throughput statistics
  • Runtime performance data
  • Queue-level analytics
  • Historical snapshots

🏷️ Tag Monitoring

  • Monitor specific tags in real-time
  • Start/stop monitoring on demand
  • Job counts per tag
  • Failed jobs by tag

👷 Worker Insights

  • Master supervisor status
  • Per-supervisor breakdown
  • Process allocation details
  • Queue assignments

📋 Requirements

Requirement Version
PHP ^8.1
Laravel ^11.0 | ^12.0
Filament ^4.0
Laravel Horizon ^5.0

🚀 Installation

Install the package via Composer:

composer require eloquage/filament-horizon

Register the plugin in your Filament panel provider:

use Eloquage\FilamentHorizon\FilamentHorizonPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        // ...
        ->plugins([
            FilamentHorizonPlugin::make(),
        ]);
}

That's it! Navigate to your Filament panel and you'll see the Horizon cluster in the navigation.

⚙️ Configuration

Publishing Config

Publish the configuration file to customize the package behavior:

php artisan vendor:publish --tag="filament-horizon-config"

Publishing Views

Want to customize the look? Publish the views:

php artisan vendor:publish --tag="filament-horizon-views"

Publishing Translations

Publish translations for localization:

php artisan vendor:publish --tag="filament-horizon-translations"

🔐 Authorization

By default, Filament Horizon allows access in local environments. For production, it uses Laravel's viewHorizon gate.

Using Laravel's Gate

Define the gate in your AuthServiceProvider or a service provider:

use Illuminate\Support\Facades\Gate;

Gate::define('viewHorizon', function ($user) {
    return in_array($user->email, [
        'admin@example.com',
    ]);
});

Disabling Authorization

For development or trusted environments, you can disable authorization entirely:

FilamentHorizonPlugin::make()
    ->authorization(false),

🖥️ Available Pages

Dashboard

The main overview page showing:

  • Status Banner — Real-time Horizon status with visual indicators
  • Stats Grid — Jobs processed, failed jobs, max wait time, total queues
  • Current Workload — Per-queue job counts, processes, and wait times
  • Workers Panel — Active supervisors with their configuration

Recent Jobs

Browse through your queue history:

  • Pending — Jobs waiting to be processed
  • Completed — Successfully processed jobs
  • Silenced — Jobs marked as silenced
  • Filter by tags with the search functionality

Failed Jobs

Manage problematic jobs:

  • View exception details and stack traces
  • See retry history and status
  • One-click retry with instant feedback
  • Filter failed jobs by tag

Batches

Monitor your job batches:

  • View batch progress percentage
  • See pending and failed job counts
  • Inspect failed jobs within batches
  • Retry entire batches

Monitoring

Tag-based monitoring system:

  • Start monitoring specific tags
  • View job counts per monitored tag
  • Stop monitoring when no longer needed
  • Quick access to tagged jobs

Metrics

Performance analytics:

  • Jobs Tab — Per-job throughput and runtime statistics
  • Queues Tab — Per-queue performance metrics
  • Visual representation of your queue performance

🎨 Widgets

The package includes reusable Filament widgets you can use in your own dashboards:

use Eloquage\FilamentHorizon\Widgets\StatsOverview;
use Eloquage\FilamentHorizon\Widgets\WorkloadWidget;
use Eloquage\FilamentHorizon\Widgets\WorkersWidget;

StatsOverview Widget

Displays key Horizon statistics:

  • Jobs per minute
  • Recent jobs count
  • Failed jobs count
  • Current status
  • Total processes
  • Max wait time
  • Max runtime queue
  • Max throughput queue

🌐 Translations

Full localization support with the following keys:

// Navigation
__('filament-horizon::horizon.navigation.label')

// Status indicators
__('filament-horizon::horizon.status.running')
__('filament-horizon::horizon.status.paused')
__('filament-horizon::horizon.status.inactive')

// And many more...

Currently available in:

  • 🇺🇸 English

PRs for additional languages are welcome!

🔄 Real-time Updates

All pages feature automatic polling to keep data fresh:

Component Polling Interval
Dashboard 5 seconds
Stats Widget 5 seconds
Job Lists On demand

🧪 Testing

Run the test suite:

composer test

Run tests with coverage:

composer test-coverage

📸 Screenshots

Click to view screenshots

Dashboard

Dashboard

Failed Jobs

Failed Jobs

Metrics

Metrics

Batches

Batches

🤝 Contributing

Contributions are welcome! Please see CONTRIBUTING for details.

Development Setup

  1. Clone the repository
  2. Install dependencies: composer install
  3. Run tests: composer test
  4. Format code: composer format

🔒 Security

If you discover a security vulnerability, please send an email to carlos.miguel.enes@gmail.com. All security vulnerabilities will be promptly addressed.

📝 Changelog

Please see CHANGELOG for more information on what has changed recently.

💖 Credits

📄 License

The MIT License (MIT). Please see License File for more information.

Built with ❤️ for the Laravel & Filament community

⭐ Star us on GitHub  ·  🐛 Report Bug  ·  💡 Request Feature

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-09