Repository navigation
#48 - Give a code to the tasks, class name as service id - #49
Merged
Merged
Conversation
Give a code to the tasks (cleverage/process-bundle#91), prefixed by the bridge name: doctrine_database_reader, doctrine_database_updater, doctrine_clear_entity_manager, doctrine_batch_writer, doctrine_cleaner, doctrine_detacher, doctrine_reader, doctrine_refresher, doctrine_remover and doctrine_writer (cleverage.task tag, task: <code> with cleverage/process-bundle 5.4 or later). The tasks have their class name as service id (public, non-shared, arguments and monolog.logger tag unchanged) with the container.private tag: fetching them directly from the service container is deprecated since 3.3, they will be private in 4.0. The former ids cleverage_doctrine_process.task.* are private deprecated aliases of the class names (since 3.3, removed in 4.0). Update the extension tests (class name id, code tag, container.private tag, deprecated aliases, every task and alias tested), the documentation (code on each reference page and the template, examples switched to task: <code>, index) and the CHANGELOG. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #48: propagate cleverage/process-bundle#91 (PR cleverage/process-bundle#294) to this bridge. Deprecations introduced in 3.3, removal in 4.0.
Changes
Codes:
cleverage.tasktag on each task, prefixed by the bridge name, so that the tasks are referenced withtask: <code>(process-bundle 5.4 or later, where referencing a task by itsserviceis deprecated):DatabaseReaderTaskdoctrine_database_readerDatabaseUpdaterTaskdoctrine_database_updaterClearEntityManagerTaskdoctrine_clear_entity_managerDoctrineBatchWriterTaskdoctrine_batch_writerDoctrineCleanerTaskdoctrine_cleanerDoctrineDetacherTaskdoctrine_detacherDoctrineReaderTaskdoctrine_readerDoctrineRefresherTaskdoctrine_refresherDoctrineRemoverTaskdoctrine_removerDoctrineWriterTaskdoctrine_writerService ids: the class names, as in process-bundle (definitions non-shared, arguments and
monolog.loggertag unchanged). They stay public, but fetching them directly from the service container is deprecated since 3.3 ({ name: container.private, package: cleverage/doctrine-process-bundle, version: '3.3' }):Accessing the "…" service directly from the container is deprecated, use dependency injection instead.; private in 4.0. The references of the container (process-bundle task locator) use the private service, without deprecation.Former ids
cleverage_doctrine_process.task.*(released since 2.0, private): deprecated aliases of the class names since 3.3 (The "cleverage_doctrine_process.task.doctrine_reader" service alias is deprecated, use the "doctrine_reader" task code or the class name of the task instead. It will be removed in 4.0.), removed in 4.0. They stay private, as before. No other service definition of the bundle referenced them.Docs: the code on the reference page of each task (and in the template), all the examples use the codes (doctrine tasks and process-bundle tasks, 43 references in the reference pages and cookbooks, plus the template);
index.md(codes, service ids, deprecations).Tests:
CleverAgeDoctrineProcessExtensionTestadapted;testEveryTaskIsTestednow checks the class-name definitions, the uniqueness and thedoctrine_prefix of the codes and that every former id is a tested alias.CHANGELOG (Latest).
Requirement not changed yet:
cleverage/process-bundlestays^5.0, because 5.4 is not released (Composer could not resolve^5.4, the CI would fail). The change is harmless with process-bundle ≤ 5.3 (thecleverage.tasktag is ignored there;container.privateand deprecated aliases are Symfony features). To raise to^5.4before releasing 3.3 (thetask:key of the documentation requires it).Checks
ContainerBuilder: the 10 definitions (class name id, non-shared, public, arguments unchanged,cleverage.task/monolog.logger/container.privatetags) and the 10 private deprecated aliases with their message.CleverAgeDoctrineProcessExtensionTest(class name as id, non-shared, logger channel, code, public +container.private, former ids private deprecated aliases with their message, every task tested). Aftercomposer update: 81 tests OK, PHPStan, PHP-CS-Fixer, Rector OK,composer validate --strictOK.Requirements
Breaking changes
None: the former ids and the public access are only deprecated (3.3), removed in 4.0.
🤖 Generated with Claude Code