<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Enabled
    |--------------------------------------------------------------------------
    |
    | Master switch for cron execution logging. When disabled, the listeners
    | short-circuit and write nothing. Defaults to off during automated tests
    | (see phpunit.xml) so command runs don't pollute assertions.
    |
    */

    'enabled' => (bool) env('CRON_LOGS_ENABLED', true),

    /*
    |--------------------------------------------------------------------------
    | Ignored commands
    |--------------------------------------------------------------------------
    |
    | Command names that should never be logged - long-running daemons (whose
    | "finished" never fires) and interactive tooling. Supports "*" wildcards
    | (matched with Str::is against the command name).
    |
    */

    'ignore' => [
        'schedule:run',
        'schedule:work',
        'schedule:finish',
        'schedule:interrupt',
        'queue:work',
        'queue:listen',
        'queue:restart',
        'horizon',
        'horizon:*',
        'octane:*',
        'tinker',
    ],

    /*
    |--------------------------------------------------------------------------
    | Retention - rows kept per task
    |--------------------------------------------------------------------------
    |
    | cron-logs:prune keeps the latest N rows per (command, tenant_id) group.
    | Count-based (rather than time-based) so infrequent daily/weekly tasks
    | keep their recent history instead of being trimmed by a time window.
    |
    */

    'keep_per_task' => (int) env('CRON_LOGS_KEEP_PER_TASK', 10),

];
