Pre-1.0. Not intended for public use yet. The API is subject to undocumented change, and these pages may already be wrong about it.

Skip to content

Live Burst Windows ​

Live combines the same action while activity continues. A quiet gap or a maximum duration closes the row; the next activity starts another burst.

Setting a Verb's Window ​

routes/feed.php
php
use Storyfeed\Facades\Story;

Story::verb('place')->bursts(within: '10 minutes', ceiling: '1 hour');

Orders placed minutes apart share one row:

Erica Sinclair
Erica Sinclair placed 3 orders with Scoops Ahoy
SettingDefaultCloses a Burst When
within'15 minutes'the next activity reaches the quiet gap
ceiling'4 hours'the next activity reaches this duration from the start

The window slides with each activity, up to the ceiling. A burst can cross midnight. A closed burst stays closed when a late activity arrives. Each row contains one action. Aggregation determines which people and things can share it.

Setting Default Windows ​

config/storyfeed.php
php
'grouping' => [
    'bursts' => [
        'within' => '15 minutes',
        'ceiling' => '4 hours',
    ],
],

A verb's bursts() declaration overrides both defaults. An argument it leaves out is 15 minutes for within or 4 hours for ceiling, not the configured value, so pass both when your defaults differ. A type-and-verb declaration takes precedence over a verb-only declaration. Windows must be positive intervals of at least one second.

A closed window is kept for grouping.burst_retention_days, 7 by default, so a late activity such as an import can still join it. Older windows are swept by the scheduledstoryfeed:prune --bursts.

See Custom Axes for calendar-based grouping. Batch windows independently determine when a batch closes; see Batching Activities.

Applying Window Changes ​

Changed windows apply to new activity. To rebuild existing memberships, pause every publisher, queue worker, and publishing schedule for the full rebuild. Maintenance mode alone does not stop queue workers.

bash
php artisan storyfeed:curate --rebuild-bursts --writers-paused

After an interruption, add --resume to continue from the committed cursor; add --restart to discard progress and replay all history. Keep writers paused until the rebuild completes. See Rehashing Groups.

Released under the MIT License.