Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IBX-1694: Rebranded dependency injection container service tags #7

Merged
merged 1 commit into from
Jan 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Example for Linux crontab (`crontab -e`):
Setting up own cron jobs is as simple as tagging services for your existing Symfony Commands.

The tag takes the following arguments:
- `name`: `ezplatform.cron.job`
- `name`: `ibexa.cron.job`
- `schedule`: _Takes any kind of [format supported by cron/cron](https://github.com/Cron/Cron#crontab-syntax), which mimics linux crontab format. E.g. `* * * * *`_
- `category`: _(Optional, by default: `default`) Lets you separate cronjobs that should be run under different logic then default, e.g. infrequent jobs (NOTE: Means end user will need to setup several entries in his crontab to run all categories!)_
- `options`: _(Optional, by default: `''`) Takes custom option/s in string format which are added to the command. (E.g. '--keep=0 --status=draft' for running the cleanup versions command)_
Expand All @@ -37,7 +37,7 @@ The tag takes the following arguments:
class: EzSystems\DateBasedPublisherBundle\Command\PublishScheduledCommand
tags:
- { name: console.command }
- { name: ezplatform.cron.job, schedule: '* * * * *' }
- { name: ibexa.cron.job, schedule: '* * * * *' }
```

## Logging run command
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function process(ContainerBuilder $container)
}

$registry = $container->findDefinition('ezplatform.cron.registry.cronjobs');
$cronJobs = $container->findTaggedServiceIds('ezplatform.cron.job');
$cronJobs = $container->findTaggedServiceIds('ibexa.cron.job');

foreach ($cronJobs as $id => $tags) {
foreach ($tags as $cronJob) {
Expand Down