Skip to content

Commit 56d6df2

Browse files
committed
chore(upstream): sync Laravel Horizon 5.x
1 parent 9be2843 commit 56d6df2

6 files changed

Lines changed: 45 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
# Release Notes
1+
# Upstream Laravel Horizon Release Notes
2+
3+
This file preserves Laravel Horizon release history imported into HorizonFlow. The versions below are official upstream Laravel Horizon versions, not HorizonFlow releases. HorizonFlow uses independent release numbers; synchronization state is recorded in [UPSTREAM.md](UPSTREAM.md).
24

35
## [Unreleased](https://github.com/laravel/horizon/compare/v5.48.1...5.x)
46

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ composer remove laravel/horizon --no-update
4141
composer require nsumbadze/horizonflow --with-all-dependencies
4242
```
4343

44-
The fork intentionally retains the `Laravel\Horizon` PHP namespace, service providers, Artisan commands, configuration shape, dashboard routes, and Redis data conventions. Composer declares that HorizonFlow replaces `laravel/horizon`, preventing both implementations from being installed together. Review [UPGRADE.md](UPGRADE.md) and test the change in a non-production environment before deployment; HorizonFlow uses its own versioning and does not claim the same version numbers as upstream Horizon.
44+
The fork intentionally retains the `Laravel\Horizon` PHP namespace, service providers, Artisan commands, configuration shape, dashboard routes, and Redis data conventions. Composer declares that HorizonFlow replaces the Laravel Horizon `5.x` line, preventing both implementations from being installed together. Review [UPGRADE.md](UPGRADE.md) and test the change in a non-production environment before deployment; HorizonFlow has its own releases and version numbers and does not claim the same versions as upstream Horizon.
4545

4646
### Compatibility
4747

@@ -200,7 +200,7 @@ php artisan horizonxflow:demo-jobs --clear
200200

201201
HorizonFlow is derived from Laravel Horizon and keeps its existing dashboard, queue supervision, metrics, and worker configuration. Refer to the [Laravel Horizon documentation](https://laravel.com/docs/horizon) for inherited Horizon behaviour.
202202

203-
Laravel Horizon was created by Taylor Otwell and is maintained by Laravel and its contributors. HorizonFlow retains Laravel Horizon's original copyright and license notices. Issues caused by HorizonFlow changes should be reported in this repository; upstream Laravel Horizon has its own issue tracker and release process.
203+
Laravel Horizon was created by Taylor Otwell and is maintained by Laravel and its contributors. HorizonFlow retains Laravel Horizon's original copyright and license notices. Issues caused by HorizonFlow changes should be reported in this repository; bugs that also exist in unmodified Laravel Horizon may belong in the upstream issue tracker. Upstream Laravel Horizon has its own release process.
204204

205205
## Contributing
206206

UPSTREAM.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Upstream Synchronization
2+
3+
HorizonFlow is an independently maintained fork of Laravel Horizon.
4+
5+
- Upstream repository: https://github.com/laravel/horizon
6+
- Upstream branch: `5.x`
7+
- Imported/synchronized baseline: `60e9d1369458762c55be6167bbf31930406ac3c9`
8+
- Latest synchronized upstream commit: `cbb4d2e1e28926e8e8a2a649937eb185415f4b09`
9+
- Synchronization method: reviewed patch range with applicable upstream commits cherry-picked
10+
- Last synchronization date: 2026-08-06
11+
12+
## Checking for updates
13+
14+
```bash
15+
git fetch upstream 5.x
16+
git log --oneline cbb4d2e1e28926e8e8a2a649937eb185415f4b09..upstream/5.x
17+
git diff --stat cbb4d2e1e28926e8e8a2a649937eb185415f4b09..upstream/5.x
18+
```
19+
20+
Upstream changes must be reviewed and combined with HorizonFlow-specific modifications rather than applied blindly.

composer.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,18 @@
66
"homepage": "https://github.com/nsumbadze/horizonflow",
77
"license": "MIT",
88
"authors": [
9+
{
10+
"name": "Nika Sumbadze",
11+
"role": "Maintainer"
12+
},
913
{
1014
"name": "Taylor Otwell",
1115
"role": "Original Author"
1216
}
1317
],
1418
"support": {
1519
"issues": "https://github.com/nsumbadze/horizonflow/issues",
16-
"security": "https://github.com/nsumbadze/horizonflow/security/advisories/new",
20+
"security": "https://github.com/nsumbadze/horizonflow/security/policy",
1721
"source": "https://github.com/nsumbadze/horizonflow"
1822
},
1923
"require": {
@@ -39,7 +43,7 @@
3943
"predis/predis": "^1.1|^2.0|^3.0"
4044
},
4145
"replace": {
42-
"laravel/horizon": "self.version"
46+
"laravel/horizon": "^5.0"
4347
},
4448
"suggest": {
4549
"ext-redis": "Required to use the Redis PHP driver.",

src/RedisQueue.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ protected function createPayloadArray($job, $queue, $data = '')
114114
#[\Override]
115115
public function later($delay, $job, $data = '', $queue = null)
116116
{
117-
$args = version_compare(Application::class, '12.11.0', '>=')
117+
$args = version_compare(Application::VERSION, '12.11.0', '>=')
118118
? [$job, $queue, $data, $delay]
119119
: [$job, $queue, $data];
120120

tests/Feature/QueueProcessingTest.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Laravel\Horizon\Tests\Feature;
44

55
use Carbon\CarbonImmutable;
6+
use Illuminate\Foundation\Application;
67
use Illuminate\Support\Facades\Event;
78
use Illuminate\Support\Facades\Queue;
89
use Illuminate\Support\Facades\Redis;
@@ -41,6 +42,18 @@ public function test_pending_delayed_jobs_are_stored_in_pending_job_database()
4142
$this->assertSame('pending', Redis::connection('horizon')->hget($id, 'status'));
4243
}
4344

45+
public function test_pending_delayed_jobs_store_the_delay_in_their_payload()
46+
{
47+
if (version_compare(Application::VERSION, '12.11.0', '<')) {
48+
$this->markTestSkipped('Delay metadata requires Laravel 12.11 or newer.');
49+
}
50+
51+
$id = Queue::later(5, new Jobs\BasicJob);
52+
$payload = json_decode(Redis::connection('horizon')->hget($id, 'payload'), true);
53+
54+
$this->assertSame(5, $payload['delay']);
55+
}
56+
4457
public function test_pending_jobs_are_stored_with_their_tags()
4558
{
4659
$id = Queue::push(new Jobs\BasicJob);

0 commit comments

Comments
 (0)