laravel-6-noteslisted
Install: claude install-skill hmj1026/dhpk
# Laravel 6 — LTS baseline
Released September 2019. **First Laravel version on strict semver** —
prior majors used a 5.x rolling number that did not signal breaking
changes meaningfully.
> PHP floor: 7.2 (use `php-7.4` module — there is no `php-7.2` module
> shipped). LTS support ran through 2022.
---
## Signature features
### Job middleware
```php
final class ThrottlesByCustomer
{
public function handle($job, callable $next): void
{
Redis::funnel('customer:' . $job->customerId)
->limit(1)
->then(fn () => $next($job), fn () => $job->release(5));
}
}
// In the Job class:
public function middleware(): array
{
return [new ThrottlesByCustomer];
}
```
Wraps `Job::handle()` execution with composable middleware. Replaces
ad-hoc rate-limit / dedup logic that previously had to live inside
`handle()` itself.
### Lazy collections
```php
LazyCollection::make(function () {
$handle = fopen('huge.csv', 'r');
while (($row = fgetcsv($handle)) !== false) {
yield $row;
}
})->filter(fn ($r) => $r[3] === 'active')
->each(fn ($r) => Order::create([...]));
```
Memory-bounded iteration over arbitrarily large datasets. Eloquent
gained `cursor()` and `lazy()` methods that return `LazyCollection`.
Use anywhere a regular `Collection` would `OOM` on a multi-GB
dataset.
### Eloquent subquery selects
```php
$users = User::addSelect(['last_login_at' => Login::select('created_at')
->whereColumn('user_id', 'users.id')
-