我应该为 Symfony 6.4 使用哪个 cron?我已经尝试了一切,但版本不起作用

问题描述 投票:0回答:1

Symphony 6.4 应该使用哪个 cron? 我已经尝试了一切,但版本不起作用

composer.json

{
    "type": "project",
    "license": "proprietary",
    "minimum-stability": "stable",
    "prefer-stable": true,
    "require": {
        "php": ">=8.3",
        "ext-ctype": "*",
        "ext-iconv": "*",
        "ext-simplexml": "*",
        "doctrine/dbal": "^3",
        "doctrine/doctrine-bundle": "^2.12",
        "doctrine/doctrine-migrations-bundle": "^3.3",
        "doctrine/orm": "^3.1",
        "mybuilder/cronos": "^4.0",
        "phpdocumentor/reflection-docblock": "^5.3",
        "phpstan/phpdoc-parser": "^1.28",
        "shapecode/cron-bundle": "^7.0",
        "symfony/apache-pack": "^1.0",
        "symfony/asset": "6.4.*",
        "symfony/asset-mapper": "6.4.*",
        "symfony/console": "6.4.*",
        "symfony/doctrine-messenger": "6.4.*",
        "symfony/dotenv": "6.4.*",
        "symfony/expression-language": "6.4.*",
        "symfony/flex": "^2.4",
        "symfony/form": "6.4.*",
        "symfony/framework-bundle": "6.4.*",
        "symfony/http-client": "6.4.*",
        "symfony/intl": "6.4.*",
        "symfony/mailer": "6.4.*",
        "symfony/mime": "6.4.*",
        "symfony/monolog-bundle": "^3.0",
        "symfony/notifier": "6.4.*",
        "symfony/process": "6.4.*",
        "symfony/property-access": "6.4.*",
        "symfony/property-info": "6.4.*",
        "symfony/runtime": "6.4.*",
        "symfony/security-bundle": "6.4.*",
        "symfony/serializer": "6.4.*",
        "symfony/stimulus-bundle": "^2.16",
        "symfony/string": "6.4.*",
        "symfony/translation": "6.4.*",
        "symfony/twig-bundle": "6.4.*",
        "symfony/ux-turbo": "^2.16",
        "symfony/validator": "6.4.*",
        "symfony/web-link": "6.4.*",
        "symfony/yaml": "6.4.*",
        "twig/extra-bundle": "^2.12|^3.0",
        "twig/twig": "^2.12|^3.0",
        "ext-curl": "*"
    },
    "config": {
        "allow-plugins": {
            "php-http/discovery": true,
            "symfony/flex": true,
            "symfony/runtime": true
        },
        "sort-packages": true
    },
    "autoload": {
        "psr-4": {
            "App\\": "src/"
        }
    },
    "autoload-dev": {
        "psr-4": {
            "App\\Tests\\": "tests/"
        }
    },
    "replace": {
        "symfony/polyfill-ctype": "*",
        "symfony/polyfill-iconv": "*",
        "symfony/polyfill-php72": "*",
        "symfony/polyfill-php73": "*",
        "symfony/polyfill-php74": "*",
        "symfony/polyfill-php80": "*",
        "symfony/polyfill-php81": "*"
    },
    "scripts": {
        "auto-scripts": {
            "cache:clear": "symfony-cmd",
            "assets:install %PUBLIC_DIR%": "symfony-cmd",
            "importmap:install": "symfony-cmd"
        },
        "post-install-cmd": [
            "@auto-scripts"
        ],
        "post-update-cmd": [
            "@auto-scripts"
        ]
    },
    "conflict": {
        "symfony/symfony": "*"
    },
    "extra": {
        "symfony": {
            "allow-contrib": false,
            "require": "6.4.*"
        }
    },
    "require-dev": {
        "phpunit/phpunit": "^9.5",
        "symfony/browser-kit": "6.4.*",
        "symfony/css-selector": "6.4.*",
        "symfony/debug-bundle": "6.4.*",
        "symfony/maker-bundle": "^1.57",
        "symfony/phpunit-bridge": "^7.0",
        "symfony/stopwatch": "6.4.*",
        "symfony/web-profiler-bundle": "6.4.*"
    }
}
symfony cron bundle
1个回答
0
投票

考虑阅读本文https://symfony.com/doc/6.4/scheduler.html

这应该是 Symfony 6.3 及更高版本处理周期性任务的方法。

© www.soinside.com 2019 - 2024. All rights reserved.