Files
ezmigrationbundle/Resources/config/services.yml

852 lines
40 KiB
YAML

parameters:
# Set to false to disable completely the debug output of executed migration steps in verbose mode
ez_migration_bundle.enable_debug_output: true
# The directory (inside each bundle) where to look for migrations definitions
# NB: this parameter will be renamed in the future
# NB: supports per-siteaccess configuration as an override of global configuration. For that, just define parameters:
# kaliop_bundle_migration.<siteaccess_group>.version_directory
kaliop_bundle_migration.version_directory: 'MigrationVersions'
# The database tables used to store migration information. Will be created automatically
# NB: supports per-siteaccess configuration as an override of global configuration. For that, just define parameters:
# ez_migration_bundle.<siteaccess_group>.table_name
ez_migration_bundle.table_name: 'kaliop_migrations'
# NB: supports per-siteaccess configuration as an override of global configuration. For that, just define parameters:
# ez_migration_bundle.<siteaccess_group>.context_table_name
ez_migration_bundle.context_table_name: 'kaliop_migrations_contexts'
# Used to discriminate valid migration definitions
ez_migration_bundle.valid_databases:
# names have to correspond to doctrine 'platform', short of version numbers and lowercase
# NB: this does NOT mean that eZPublish supports all of them :-)
- 'mysql'
- 'postgresql'
- 'oracle'
- 'sqlite'
- 'drizzle'
- 'sqlserver'
- 'sqlanywhere'
# This is by default the max value for a 16-bit integer, which is what SOLR accepts as maximum nuber-of-results
# limitation for its queries.
# However, in multi-core configurations, you have to divide this most likely by the number of cores, or you will get
# an 'java.lang.NegativeArraySizeException' error
ez_migration_bundle.query_limit: 2147483647
# Deprecated parameter. Left in for the v1-to-v2 migration to work.
kaliop_bundle_migration.table_name: 'kaliop_versions'
ez_migration_bundle.migration_service.class: Kaliop\eZMigrationBundle\Core\MigrationService
ez_migration_bundle.loader.filesystem.class: Kaliop\eZMigrationBundle\Core\Loader\Filesystem
ez_migration_bundle.loader.filesystem_recursive.class: Kaliop\eZMigrationBundle\Core\Loader\FilesystemRecursive
ez_migration_bundle.definition_parser.yaml.class: Kaliop\eZMigrationBundle\Core\DefinitionParser\YamlDefinitionParser
ez_migration_bundle.definition_parser.json.class: Kaliop\eZMigrationBundle\Core\DefinitionParser\JsonDefinitionParser
ez_migration_bundle.definition_parser.sql.class: Kaliop\eZMigrationBundle\Core\DefinitionParser\SQLDefinitionParser
ez_migration_bundle.definition_parser.php.class: Kaliop\eZMigrationBundle\Core\DefinitionParser\PHPDefinitionParser
ez_migration_bundle.context_handler.class: Kaliop\eZMigrationBundle\Core\ContextHandler
ez_migration_bundle.storage_handler.database.class: Kaliop\eZMigrationBundle\Core\StorageHandler\Database\Migration
ez_migration_bundle.context_storage_handler.database.class: Kaliop\eZMigrationBundle\Core\StorageHandler\Database\Context
ez_migration_bundle.executor.file.class: Kaliop\eZMigrationBundle\Core\Executor\FileExecutor
ez_migration_bundle.executor.http.class: Kaliop\eZMigrationBundle\Core\Executor\HTTPExecutor
ez_migration_bundle.executor.loop.class: Kaliop\eZMigrationBundle\Core\Executor\LoopExecutor
ez_migration_bundle.executor.mail.class: Kaliop\eZMigrationBundle\Core\Executor\MailExecutor
ez_migration_bundle.executor.migration.class: Kaliop\eZMigrationBundle\Core\Executor\MigrationExecutor
ez_migration_bundle.executor.migration_definition.class: Kaliop\eZMigrationBundle\Core\Executor\MigrationDefinitionExecutor
ez_migration_bundle.executor.php.class: Kaliop\eZMigrationBundle\Core\Executor\PHPExecutor
ez_migration_bundle.executor.process.class: Kaliop\eZMigrationBundle\Core\Executor\ProcessExecutor
ez_migration_bundle.executor.service.class: Kaliop\eZMigrationBundle\Core\Executor\ServiceExecutor
ez_migration_bundle.executor.sql.class: Kaliop\eZMigrationBundle\Core\Executor\SQLExecutor
ez_migration_bundle.executor.reference.class: Kaliop\eZMigrationBundle\Core\Executor\ReferenceExecutor
ez_migration_bundle.executor.repository.class: Kaliop\eZMigrationBundle\Core\Executor\RepositoryExecutor
ez_migration_bundle.executor.content_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ContentManager
ez_migration_bundle.executor.content_version_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ContentVersionManager
ez_migration_bundle.executor.content_type_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ContentTypeManager
ez_migration_bundle.executor.content_type_group_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ContentTypeGroupManager
ez_migration_bundle.executor.language_manager.class: Kaliop\eZMigrationBundle\Core\Executor\LanguageManager
ez_migration_bundle.executor.location_manager.class: Kaliop\eZMigrationBundle\Core\Executor\LocationManager
ez_migration_bundle.executor.object_state_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ObjectStateManager
ez_migration_bundle.executor.object_state_group_manager.class: Kaliop\eZMigrationBundle\Core\Executor\ObjectStateGroupManager
ez_migration_bundle.executor.role_manager.class: Kaliop\eZMigrationBundle\Core\Executor\RoleManager
ez_migration_bundle.executor.section_manager.class: Kaliop\eZMigrationBundle\Core\Executor\SectionManager
ez_migration_bundle.executor.tag_manager.class: Kaliop\eZMigrationBundle\Core\Executor\TagManager
ez_migration_bundle.executor.trash_manager.class: Kaliop\eZMigrationBundle\Core\Executor\TrashManager
ez_migration_bundle.executor.user_manager.class: Kaliop\eZMigrationBundle\Core\Executor\UserManager
ez_migration_bundle.executor.user_group_manager.class: Kaliop\eZMigrationBundle\Core\Executor\UserGroupManager
ez_migration_bundle.content_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ContentMatcherDirectLoad
ez_migration_bundle.content_type_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ContentTypeMatcher
ez_migration_bundle.content_type_group_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ContentTypeGroupMatcher
ez_migration_bundle.content_version_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ContentVersionMatcher
ez_migration_bundle.language_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\LanguageMatcher
ez_migration_bundle.location_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\LocationMatcherDirectLoad
ez_migration_bundle.object_state_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ObjectStateMatcher
ez_migration_bundle.object_state_group_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ObjectStateGroupMatcher
ez_migration_bundle.reference_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\ReferenceMatcher
ez_migration_bundle.role_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\RoleMatcher
ez_migration_bundle.section_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\SectionMatcher
ez_migration_bundle.tag_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\TagMatcher
ez_migration_bundle.trash_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\TrashMatcher
ez_migration_bundle.user_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\UserMatcher
ez_migration_bundle.user_group_matcher.class: Kaliop\eZMigrationBundle\Core\Matcher\UserGroupMatcher
ez_migration_bundle.complex_field_manager.class: Kaliop\eZMigrationBundle\Core\FieldHandlerManager
ez_migration_bundle.complex_field.ezauthor.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzAuthor
ez_migration_bundle.complex_field.ezbinaryfile.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzBinaryFile
ez_migration_bundle.complex_field.ezboolean.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzBoolean
ez_migration_bundle.complex_field.ezdate.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzDate
ez_migration_bundle.complex_field.ezdatetime.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzDateAndTime
ez_migration_bundle.complex_field.ezimage.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzImage
ez_migration_bundle.complex_field.ezmedia.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzMedia
ez_migration_bundle.complex_field.ezrelation.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzRelation
ez_migration_bundle.complex_field.ezrelationlist.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzRelationList
ez_migration_bundle.complex_field.ezrichtext.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzRichText
ez_migration_bundle.complex_field.ezselection.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzSelection
ez_migration_bundle.complex_field.ezxmltext.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzXmlText
ez_migration_bundle.complex_field.eztags.class: Kaliop\eZMigrationBundle\Core\FieldHandler\EzTags
ez_migration_bundle.reference_resolver.chain.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\ChainResolver
ez_migration_bundle.reference_resolver.chain_prefix.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\ChainPrefixResolver
ez_migration_bundle.reference_resolver.customreference.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\CustomReferenceResolver
ez_migration_bundle.reference_resolver.content.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\ContentResolver
ez_migration_bundle.reference_resolver.location.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\LocationResolver
ez_migration_bundle.reference_resolver.loop.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\LoopResolver
ez_migration_bundle.reference_resolver.tag.class: Kaliop\eZMigrationBundle\Core\ReferenceResolver\TagResolver
ez_migration_bundle.helper.limitation_converter.class: Kaliop\eZMigrationBundle\Core\Helper\LimitationConverter
ez_migration_bundle.helper.sort_converter.class: Kaliop\eZMigrationBundle\Core\Helper\SortConverter
ez_migration_bundle.helper.console_io.class: Kaliop\eZMigrationBundle\Core\Helper\ConsoleIO
ez_migration_bundle.helper.config.resolver: Kaliop\eZMigrationBundle\Core\Helper\ConfigResolver
ez_migration_bundle.step_executed_listener.tracing.class: Kaliop\eZMigrationBundle\Core\EventListener\TracingStepExecutedListener
services:
ez_migration_bundle.migration_service:
public: true
class: '%ez_migration_bundle.migration_service.class%'
arguments:
- '@ez_migration_bundle.loader'
- '@ez_migration_bundle.storage_handler'
- '@ezpublish.api.repository'
- '@event_dispatcher'
- '@ez_migration_bundle.context_handler'
tags:
- { name: ez_migration_bundle.context_provider, label: migration_service }
calls:
- ['setPermissionResolver', ['@eZ\Publish\API\Repository\PermissionResolver']]
- ['setUserService', ['@eZ\Publish\API\Repository\UserService']]
### loaders
ez_migration_bundle.loader:
alias: ez_migration_bundle.loader.filesystem
ez_migration_bundle.loader.filesystem:
class: '%ez_migration_bundle.loader.filesystem.class%'
arguments:
- '@kernel'
- 'kaliop_bundle_migration.version_directory'
- '@ez_migration_bundle.helper.config.resolver'
ez_migration_bundle.loader.filesystem_recursive:
class: '%ez_migration_bundle.loader.filesystem_recursive.class%'
arguments:
- '@kernel'
- 'kaliop_bundle_migration.version_directory'
- '@ez_migration_bundle.helper.config.resolver'
### parsers
ez_migration_bundle.definition_parser.yaml:
class: '%ez_migration_bundle.definition_parser.yaml.class%'
arguments: []
tags:
- { name: ez_migration_bundle.definition_parser }
ez_migration_bundle.definition_parser.json:
class: '%ez_migration_bundle.definition_parser.json.class%'
arguments: []
tags:
- { name: ez_migration_bundle.definition_parser }
ez_migration_bundle.definition_parser.sql:
class: '%ez_migration_bundle.definition_parser.sql.class%'
arguments:
- '%ez_migration_bundle.valid_databases%'
tags:
- { name: ez_migration_bundle.definition_parser }
ez_migration_bundle.definition_parser.php:
class: '%ez_migration_bundle.definition_parser.php.class%'
arguments: []
tags:
- { name: ez_migration_bundle.definition_parser }
### storage handlers
ez_migration_bundle.storage_handler:
alias: ez_migration_bundle.storage_handler.database
ez_migration_bundle.storage_handler.database:
class: '%ez_migration_bundle.storage_handler.database.class%'
arguments:
- "@ezpublish.api.storage_engine.legacy.connection"
- 'ez_migration_bundle.table_name'
- '@ez_migration_bundle.helper.config.resolver'
ez_migration_bundle.context_storage_handler:
alias: ez_migration_bundle.context_storage_handler.database
ez_migration_bundle.context_storage_handler.database:
class: '%ez_migration_bundle.context_storage_handler.database.class%'
arguments:
- "@ezpublish.api.storage_engine.legacy.connection"
- 'ez_migration_bundle.context_table_name'
- '@ez_migration_bundle.helper.config.resolver'
### executors
ez_migration_bundle.executor.file:
class: '%ez_migration_bundle.executor.file.class%'
arguments:
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.http:
class: '%ez_migration_bundle.executor.http.class%'
arguments:
- '@service_container'
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.loop:
class: '%ez_migration_bundle.executor.loop.class%'
arguments:
- '@ez_migration_bundle.migration_service'
- '@ez_migration_bundle.reference_resolver.loop'
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
# avoid 'ServiceCircularReferenceException' errors by making this lazy
lazy: true
ez_migration_bundle.executor.mail:
class: '%ez_migration_bundle.executor.mail.class%'
arguments:
- '@mailer'
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.migration:
class: '%ez_migration_bundle.executor.migration.class%'
arguments:
- '@ez_migration_bundle.reference_matcher'
- '@ez_migration_bundle.reference_resolver.customreference'
- '@ez_migration_bundle.executor.content_manager'
- '@ez_migration_bundle.executor.location_manager'
- '@ez_migration_bundle.executor.content_type_manager'
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.migration_definition:
class: '%ez_migration_bundle.executor.migration_definition.class%'
arguments:
- '@ez_migration_bundle.migration_service'
- '@ez_migration_bundle.reference_resolver.customreference'
# avoid 'ServiceCircularReferenceException' errors when this service is injected into a migration service
# that is related to the event dispatcher by making it lazy
lazy: true
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.php:
class: '%ez_migration_bundle.executor.php.class%'
arguments:
- '@service_container'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.process:
class: '%ez_migration_bundle.executor.process.class%'
arguments:
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.reference:
class: '%ez_migration_bundle.executor.reference.class%'
arguments:
- '@service_container'
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.service:
class: '%ez_migration_bundle.executor.service.class%'
arguments:
- '@service_container'
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.sql:
class: '%ez_migration_bundle.executor.sql.class%'
arguments:
- "@ezpublish.api.storage_engine.legacy.connection"
- '@ez_migration_bundle.reference_resolver.customreference'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.repository:
abstract: true
class: '%ez_migration_bundle.executor.repository.class%'
calls:
- ['setRepository', ['@ezpublish.api.repository']]
- ['setReferenceResolver', ['@ez_migration_bundle.reference_resolver.customreference']]
- ['setConfigResolver', ['@ezpublish.config.resolver']]
# SF bug? this method is not called for child srevices as it belongs to a trait instead of teh base class...
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
- ['setPermissionResolver', ['@eZ\Publish\API\Repository\PermissionResolver']]
- ['setUserService', ['@eZ\Publish\API\Repository\UserService']]
ez_migration_bundle.executor.content_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.content_manager.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.user_matcher'
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.object_state_group_matcher'
- '@ez_migration_bundle.complex_field_manager'
- '@ez_migration_bundle.executor.location_manager'
- '@ez_migration_bundle.helper.sort_converter'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.content_version_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.content_version_manager.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.user_matcher'
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.object_state_group_matcher'
- '@ez_migration_bundle.complex_field_manager'
- '@ez_migration_bundle.executor.location_manager'
- '@ez_migration_bundle.helper.sort_converter'
- '@ez_migration_bundle.content_version_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.content_type_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.content_type_manager.class%'
arguments:
- '@ez_migration_bundle.content_type_matcher'
- '@ez_migration_bundle.content_type_group_matcher'
- '@ez_migration_bundle.reference_resolver'
- '@ez_migration_bundle.complex_field_manager'
- '@ez_migration_bundle.helper.sort_converter'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.content_type_group_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.content_type_group_manager.class%'
arguments:
- '@ez_migration_bundle.content_type_group_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.language_manager:
class: '%ez_migration_bundle.executor.language_manager.class%'
parent: ez_migration_bundle.executor.repository
arguments:
- '@ez_migration_bundle.language_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.location_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.location_manager.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
- '@ez_migration_bundle.location_matcher'
- '@ez_migration_bundle.helper.sort_converter'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.object_state_manager:
class: '%ez_migration_bundle.executor.object_state_manager.class%'
parent: ez_migration_bundle.executor.repository
arguments:
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.object_state_group_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.object_state_group_manager:
class: '%ez_migration_bundle.executor.object_state_group_manager.class%'
parent: ez_migration_bundle.executor.repository
arguments:
- '@ez_migration_bundle.object_state_group_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.role_manager:
class: '%ez_migration_bundle.executor.role_manager.class%'
parent: ez_migration_bundle.executor.repository
arguments:
- '@ez_migration_bundle.role_matcher'
- '@ez_migration_bundle.helper.limitation_converter'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.section_manager:
class: '%ez_migration_bundle.executor.section_manager.class%'
parent: ez_migration_bundle.executor.repository
arguments:
- '@ez_migration_bundle.section_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.tag_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.tag_manager.class%'
arguments:
- '@ez_migration_bundle.tag_matcher'
- '@?ezpublish.api.service.tags'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.trash_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.trash_manager.class%'
arguments:
- '@ez_migration_bundle.trash_matcher'
- '@ez_migration_bundle.helper.sort_converter'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.user_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.user_manager.class%'
arguments:
- '@ez_migration_bundle.user_matcher'
- '@ez_migration_bundle.user_group_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
ez_migration_bundle.executor.user_group_manager:
parent: ez_migration_bundle.executor.repository
class: '%ez_migration_bundle.executor.user_group_manager.class%'
arguments:
- '@ez_migration_bundle.user_group_matcher'
- '@ez_migration_bundle.role_matcher'
- '@ez_migration_bundle.section_matcher'
calls:
- ['setReferenceMatcher', ['@ez_migration_bundle.reference_matcher']]
tags:
- { name: ez_migration_bundle.executor }
### matchers
ez_migration_bundle.content_matcher:
class: '%ez_migration_bundle.content_matcher.class%'
arguments:
- '@ezpublish.api.repository'
- '@ez_migration_bundle.user_group_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.user_matcher'
- '%ez_migration_bundle.query_limit%'
ez_migration_bundle.content_type_matcher:
class: '%ez_migration_bundle.content_type_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.content_type_group_matcher:
class: '%ez_migration_bundle.content_type_group_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.content_version_matcher:
class: '%ez_migration_bundle.content_version_matcher.class%'
arguments:
- '@ezpublish.api.repository'
- '@ez_migration_bundle.content_matcher'
ez_migration_bundle.language_matcher:
class: '%ez_migration_bundle.language_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.location_matcher:
class: '%ez_migration_bundle.location_matcher.class%'
arguments:
- '@ezpublish.api.repository'
- '@ez_migration_bundle.user_group_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.user_matcher'
- '%ez_migration_bundle.query_limit%'
ez_migration_bundle.object_state_matcher:
class: '%ez_migration_bundle.object_state_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.object_state_group_matcher:
class: '%ez_migration_bundle.object_state_group_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.reference_matcher:
class: '%ez_migration_bundle.reference_matcher.class%'
arguments:
- '@ez_migration_bundle.reference_resolver.customreference'
- '@validator'
ez_migration_bundle.role_matcher:
class: '%ez_migration_bundle.role_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.section_matcher:
class: '%ez_migration_bundle.section_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.tag_matcher:
class: '%ez_migration_bundle.tag_matcher.class%'
arguments:
- '@ezpublish.translation_helper'
- '@?ezpublish.api.service.tags'
ez_migration_bundle.trash_matcher:
class: '%ez_migration_bundle.trash_matcher.class%'
arguments:
- '@ezpublish.api.repository'
- '@ez_migration_bundle.user_group_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.object_state_matcher'
- '@ez_migration_bundle.user_matcher'
- '%ez_migration_bundle.query_limit%'
ez_migration_bundle.user_matcher:
class: '%ez_migration_bundle.user_matcher.class%'
arguments:
- '@ezpublish.api.repository'
ez_migration_bundle.user_group_matcher:
class: '%ez_migration_bundle.user_group_matcher.class%'
arguments:
- '@ezpublish.api.repository'
### field handlers
ez_migration_bundle.complex_field_manager:
class: '%ez_migration_bundle.complex_field_manager.class%'
arguments:
- '@ezpublish.api.service.field_type'
ez_migration_bundle.complex_field:
abstract: true
calls:
- ['setReferenceResolver', ['@ez_migration_bundle.reference_resolver.customreference']]
# NB: you can register handlers for either a field type, using the 'fieldtype' attribute, or for the
# field type of a specific content type by using both 'fieldtype' and 'contenttype' in the tag definition
ez_migration_bundle.complex_field.ezauthor:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezauthor.class%'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezauthor, priority: 0 }
ez_migration_bundle.complex_field.ezbinaryfile:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezbinaryfile.class%'
arguments:
- "$io.root_dir$"
- "@?ezpublish.core.io.prefix_url_decorator"
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezbinaryfile, priority: 0 }
ez_migration_bundle.complex_field.ezboolean:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezboolean.class%'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezboolean, priority: 0 }
ez_migration_bundle.complex_field.ezdate:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezdate.class%'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezdate, priority: 0 }
ez_migration_bundle.complex_field.ezdatetime:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezdatetime.class%'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezdatetime, priority: 0 }
ez_migration_bundle.complex_field.ezimage:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezimage.class%'
arguments:
- "$io.root_dir$"
- "@?ezpublish.core.io.prefix_url_decorator"
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezimage, priority: 0 }
ez_migration_bundle.complex_field.ezmedia:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezmedia.class%'
arguments:
- "$io.root_dir$"
- "@?ezpublish.core.io.prefix_url_decorator"
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezmedia, priority: 0 }
ez_migration_bundle.complex_field.ezrelation:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezrelation.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezobjectrelation, priority: 0 }
ez_migration_bundle.complex_field.ezrelationlist:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezrelationlist.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezobjectrelationlist, priority: 0 }
ez_migration_bundle.complex_field.ezrichtext:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezrichtext.class%'
arguments:
# if you want to replace custom references in rich text fields, you can replace this with a new service
# built f.e. using the ChainPrefixResolver class
- '@ez_migration_bundle.reference_resolver.customreference'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezrichtext, priority: 0 }
ez_migration_bundle.complex_field.ezselection:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezselection.class%'
arguments:
- '@ezpublish.api.repository'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezselection, priority: 0 }
ez_migration_bundle.complex_field.ezxmltext:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.ezxmltext.class%'
arguments:
# if you want to replace custom references in rich text fields, you can replace this with a new service
# built f.e. using the ChainPrefixResolver class
- '@ez_migration_bundle.reference_resolver.customreference'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: ezxmltext, priority: 0 }
ez_migration_bundle.complex_field.eztags:
parent: ez_migration_bundle.complex_field
class: '%ez_migration_bundle.complex_field.eztags.class%'
arguments:
- '@ez_migration_bundle.tag_matcher'
tags:
- { name: ez_migration_bundle.complex_field, fieldtype: eztags, priority: 0 }
### reference resolvers
# A service that will resolve *any* possible reference. To be used with care
# At the moment is is only used to resolve references in definitions of FieldType settings, and even then, only
# for backwards compatibility
ez_migration_bundle.reference_resolver:
alias: ez_migration_bundle.reference_resolver.chain
ez_migration_bundle.reference_resolver.chain:
class: '%ez_migration_bundle.reference_resolver.chain.class%'
arguments:
-
- '@ez_migration_bundle.reference_resolver.customreference'
- '@ez_migration_bundle.reference_resolver.location'
# not enabled by default for v3, as it might break v1 migrations that don't expect it to be present
#- '@ez_migration_bundle.reference_resolver.content'
- '@ez_migration_bundle.reference_resolver.tag'
# @deprecated
ez_migration_bundle.reference_resolver.content:
class: '%ez_migration_bundle.reference_resolver.content.class%'
arguments:
- '@ez_migration_bundle.content_matcher'
ez_migration_bundle.reference_resolver.location:
class: '%ez_migration_bundle.reference_resolver.location.class%'
arguments:
- '@ez_migration_bundle.location_matcher'
ez_migration_bundle.reference_resolver.loop:
class: '%ez_migration_bundle.reference_resolver.loop.class%'
ez_migration_bundle.reference_resolver.tag:
class: '%ez_migration_bundle.reference_resolver.tag.class%'
arguments:
- '@ez_migration_bundle.tag_matcher'
# A service which resolves *only* custom references. As such, it is used in most places
ez_migration_bundle.reference_resolver.customreference:
alias: ez_migration_bundle.reference_resolver.customreference.flexible
ez_migration_bundle.reference_resolver.customreference.base:
class: '%ez_migration_bundle.reference_resolver.customreference.class%'
arguments: []
tags:
- { name: ez_migration_bundle.context_provider, label: reference_resolver_customreference }
# NB: This service will see added to the chain any service tagged as 'ez_migration_bundle.reference_resolver.customreference'
ez_migration_bundle.reference_resolver.customreference.flexible:
class: '%ez_migration_bundle.reference_resolver.chain_prefix.class%'
arguments:
- [ '@ez_migration_bundle.reference_resolver.customreference.base', '@ez_migration_bundle.reference_resolver.loop' ]
### misc
ez_migration_bundle.context_handler:
class: '%ez_migration_bundle.context_handler.class%'
arguments:
- '@ez_migration_bundle.context_storage_handler'
lazy: true
# This service is used for the verbose mode when executing migrations on the command line
ez_migration_bundle.step_executed_listener.tracing:
public: true
class: '%ez_migration_bundle.step_executed_listener.tracing.class%'
arguments:
- '%ez_migration_bundle.enable_debug_output%'
tags:
- { name: kernel.event_listener, event: ez_migration.step_executed, method: onStepExecuted }
- { name: kernel.event_listener, event: ez_migration.migration_aborted, method: onMigrationAborted }
- { name: kernel.event_listener, event: ez_migration.migration_suspended, method: onMigrationSuspended }
ez_migration_bundle.helper.limitation_converter:
class: '%ez_migration_bundle.helper.limitation_converter.class%'
arguments:
- '%ezpublish.siteaccess.list%'
- '@ez_migration_bundle.location_matcher'
- '@ez_migration_bundle.section_matcher'
- '@ez_migration_bundle.content_type_matcher'
ez_migration_bundle.helper.sort_converter:
class: '%ez_migration_bundle.helper.sort_converter.class%'
ez_migration_bundle.helper.console_io:
class: '%ez_migration_bundle.helper.console_io.class%'
tags:
- { name: kernel.event_listener, event: console.command }
ez_migration_bundle.helper.config.resolver:
class: '%ez_migration_bundle.helper.config.resolver%'
public: true
arguments:
- '@ezpublish.config.resolver'
- '@service_container'
Kaliop\eZMigrationBundle\Command\AbstractCommand: ~
Kaliop\eZMigrationBundle\Command\GenerateCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:generate' }
Kaliop\eZMigrationBundle\Command\MassMigrateCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:mass_migrate' }
Kaliop\eZMigrationBundle\Command\MigrateCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:migrate' }
Kaliop\eZMigrationBundle\Command\MigrationCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:migration' }
Kaliop\eZMigrationBundle\Command\ResumeCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:resume' }
Kaliop\eZMigrationBundle\Command\StatusCommand:
arguments:
- '@service_container'
tags:
- { name: 'console.command', command: 'kaliop:migration:status' }