diff --git a/core/modules/block/src/Plugin/migrate/destination/EntityBlock.php b/core/modules/block/src/Plugin/migrate/destination/EntityBlock.php index 537b160..2a2a4fb 100644 --- a/core/modules/block/src/Plugin/migrate/destination/EntityBlock.php +++ b/core/modules/block/src/Plugin/migrate/destination/EntityBlock.php @@ -7,7 +7,8 @@ /** * @MigrateDestination( - * id = "entity:block" + * id = "entity:block", + * destination_module = "block", * ) */ class EntityBlock extends EntityConfigBase { diff --git a/core/modules/book/src/Plugin/migrate/destination/Book.php b/core/modules/book/src/Plugin/migrate/destination/Book.php index 3659b34..cd5383e 100644 --- a/core/modules/book/src/Plugin/migrate/destination/Book.php +++ b/core/modules/book/src/Plugin/migrate/destination/Book.php @@ -9,7 +9,8 @@ /** * @MigrateDestination( * id = "book", - * provider = "book" + * provider = "book", + * destination_module = "book", * ) */ class Book extends EntityContentBase { diff --git a/core/modules/comment/src/Plugin/migrate/destination/EntityComment.php b/core/modules/comment/src/Plugin/migrate/destination/EntityComment.php index efce666..9e140ba 100644 --- a/core/modules/comment/src/Plugin/migrate/destination/EntityComment.php +++ b/core/modules/comment/src/Plugin/migrate/destination/EntityComment.php @@ -13,7 +13,8 @@ /** * @MigrateDestination( - * id = "entity:comment" + * id = "entity:comment", + * destination_module = "comment", * ) */ class EntityComment extends EntityContentBase { diff --git a/core/modules/comment/src/Plugin/migrate/destination/EntityCommentType.php b/core/modules/comment/src/Plugin/migrate/destination/EntityCommentType.php index 9bee87a..23a649e 100644 --- a/core/modules/comment/src/Plugin/migrate/destination/EntityCommentType.php +++ b/core/modules/comment/src/Plugin/migrate/destination/EntityCommentType.php @@ -7,7 +7,8 @@ /** * @MigrateDestination( - * id = "entity:comment_type" + * id = "entity:comment_type", + * destination_module = "comment", * ) */ class EntityCommentType extends EntityConfigBase { diff --git a/core/modules/file/src/Plugin/migrate/destination/EntityFile.php b/core/modules/file/src/Plugin/migrate/destination/EntityFile.php index d0a1cca..16ea381 100644 --- a/core/modules/file/src/Plugin/migrate/destination/EntityFile.php +++ b/core/modules/file/src/Plugin/migrate/destination/EntityFile.php @@ -10,7 +10,8 @@ /** * @MigrateDestination( - * id = "entity:file" + * id = "entity:file", + * destination_module = "file", * ) */ class EntityFile extends EntityContentBase { diff --git a/core/modules/image/src/Plugin/migrate/destination/EntityImageStyle.php b/core/modules/image/src/Plugin/migrate/destination/EntityImageStyle.php index 3fc1e7f..12daa7b 100644 --- a/core/modules/image/src/Plugin/migrate/destination/EntityImageStyle.php +++ b/core/modules/image/src/Plugin/migrate/destination/EntityImageStyle.php @@ -12,7 +12,8 @@ * dependency on the d6_file migration to ensure it runs first. * * @MigrateDestination( - * id = "entity:image_style" + * id = "entity:image_style", + * destination_module = "image", * ) */ class EntityImageStyle extends EntityConfigBase { diff --git a/core/modules/migrate/src/Plugin/Derivative/MigrateEntity.php b/core/modules/migrate/src/Plugin/Derivative/MigrateEntity.php index 0babe2f..641d46f 100644 --- a/core/modules/migrate/src/Plugin/Derivative/MigrateEntity.php +++ b/core/modules/migrate/src/Plugin/Derivative/MigrateEntity.php @@ -64,6 +64,7 @@ public function getDerivativeDefinitions($base_plugin_definition) { 'class' => $class, 'requirements_met' => 1, 'provider' => $entity_info->getProvider(), + 'destination_module' => $entity_info->getProvider(), ]; } return $this->derivatives; diff --git a/core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php b/core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php index cee3b39..34632b3 100644 --- a/core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php +++ b/core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php @@ -62,6 +62,7 @@ public function getDerivativeDefinitions($base_plugin_definition) { 'class' => 'Drupal\migrate\Plugin\migrate\destination\EntityRevision', 'requirements_met' => 1, 'provider' => $entity_info->getProvider(), + 'destination_module' => $entity_info->getProvider(), ]; } } diff --git a/core/modules/migrate/src/Plugin/MigrateDestinationPluginManager.php b/core/modules/migrate/src/Plugin/MigrateDestinationPluginManager.php index 3750ca1..0350cec 100644 --- a/core/modules/migrate/src/Plugin/MigrateDestinationPluginManager.php +++ b/core/modules/migrate/src/Plugin/MigrateDestinationPluginManager.php @@ -70,7 +70,7 @@ public function processDefinition(&$definition, $plugin_id) { foreach (['destination_module'] as $required_property) { if (empty($definition[$required_property])) { - throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $plugin_id, $required_property)); + throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $definition['class'], $required_property)); } } } diff --git a/core/modules/migrate/src/Plugin/MigratePluginManager.php b/core/modules/migrate/src/Plugin/MigratePluginManager.php index 7903e42..b46686f 100644 --- a/core/modules/migrate/src/Plugin/MigratePluginManager.php +++ b/core/modules/migrate/src/Plugin/MigratePluginManager.php @@ -71,7 +71,7 @@ public function processDefinition(&$definition, $plugin_id) { foreach (['id'] as $required_property) { if (empty($definition['id'])) { - throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $plugin_id, $required_property)); + throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $definition['class'], $required_property)); } } } diff --git a/core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php b/core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php index 11883e5..0da3886 100644 --- a/core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php +++ b/core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php @@ -59,6 +59,8 @@ protected function getDiscovery() { * @todo This is a temporary solution to the fact that migration source * plugins have more than one provider. This functionality will be moved to * core in https://www.drupal.org/node/2786355. + * + * @throws \Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException */ protected function findDefinitions() { $definitions = $this->getDiscovery()->getDefinitions(); @@ -79,7 +81,7 @@ public function processDefinition(&$definition, $plugin_id) { foreach (['source_module'] as $required_property) { if (empty($definition[$required_property])) { - throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $plugin_id, $required_property)); + throw new InvalidPluginDefinitionException($plugin_id, sprintf('The %s plugin should define the %s property.', $definition['class'], $required_property)); } } } diff --git a/core/modules/migrate/src/Plugin/migrate/destination/Config.php b/core/modules/migrate/src/Plugin/migrate/destination/Config.php index 18d78a3..3d5b29c 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/Config.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/Config.php @@ -66,7 +66,8 @@ * @see \Drupal\migrate_drupal\Plugin\migrate\source\d6\i18nVariable * * @MigrateDestination( - * id = "config" + * id = "config", + * destination_module = "system", * ) */ class Config extends DestinationBase implements ContainerFactoryPluginInterface, DependentPluginInterface { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityBaseFieldOverride.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityBaseFieldOverride.php index 7523249..de20635 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityBaseFieldOverride.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityBaseFieldOverride.php @@ -8,7 +8,8 @@ * Provides entity base field override plugin. * * @MigrateDestination( - * id = "entity:base_field_override" + * id = "entity:base_field_override", + * destination_module = "system", * ) */ class EntityBaseFieldOverride extends EntityConfigBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php index a431c49..d85baba 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php @@ -6,7 +6,8 @@ * Provides entity field instance plugin. * * @MigrateDestination( - * id = "entity:field_config" + * id = "entity:field_config", + * destination_module = "field", * ) */ class EntityFieldInstance extends EntityConfigBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldStorageConfig.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldStorageConfig.php index 9b781a3..04608c0 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldStorageConfig.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldStorageConfig.php @@ -6,7 +6,8 @@ * Provides entity field storage configuration plugin. * * @MigrateDestination( - * id = "entity:field_storage_config" + * id = "entity:field_storage_config", + * destination_module = "field", * ) */ class EntityFieldStorageConfig extends EntityConfigBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php index b0db476..e243552 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php @@ -11,6 +11,7 @@ * * @MigrateDestination( * id = "entity_revision", + * destination_module = "system", * deriver = "Drupal\migrate\Plugin\Derivative\MigrateEntityRevision" * ) */ diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityViewMode.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityViewMode.php index b2c25a4..309b6b0 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityViewMode.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityViewMode.php @@ -25,7 +25,8 @@ * "targetEntityType") to an "entity_view_mode" entity. * * @MigrateDestination( - * id = "entity:entity_view_mode" + * id = "entity:entity_view_mode", + * destination_module = "system", * ) */ class EntityViewMode extends EntityConfigBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/NullDestination.php b/core/modules/migrate/src/Plugin/migrate/destination/NullDestination.php index cfe47ea..7f0a41b 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/NullDestination.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/NullDestination.php @@ -10,7 +10,8 @@ * * @MigrateDestination( * id = "null", - * requirements_met = false + * requirements_met = false, + * destination_module = "null", * ) */ class NullDestination extends DestinationBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityDisplay.php b/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityDisplay.php index 3b9a982..254b389 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityDisplay.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityDisplay.php @@ -45,7 +45,8 @@ * "options" constant, for example the label will be hidden. * * @MigrateDestination( - * id = "component_entity_display" + * id = "component_entity_display", + * destination_module = "system", * ) */ class PerComponentEntityDisplay extends ComponentEntityDisplayBase { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityFormDisplay.php b/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityFormDisplay.php index bd837f0..f8e10dd 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityFormDisplay.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/PerComponentEntityFormDisplay.php @@ -38,7 +38,8 @@ * entity type with options defined by the "options" constant. * * @MigrateDestination( - * id = "component_entity_form_display" + * id = "component_entity_form_display", + * destination_module = "system", * ) */ class PerComponentEntityFormDisplay extends ComponentEntityDisplayBase { diff --git a/core/modules/migrate_drupal/src/Plugin/migrate/destination/EntityFieldStorageConfig.php b/core/modules/migrate_drupal/src/Plugin/migrate/destination/EntityFieldStorageConfig.php index c5e631a..a076e24 100644 --- a/core/modules/migrate_drupal/src/Plugin/migrate/destination/EntityFieldStorageConfig.php +++ b/core/modules/migrate_drupal/src/Plugin/migrate/destination/EntityFieldStorageConfig.php @@ -14,7 +14,8 @@ * Deprecated. Destination with Drupal specific config dependencies. * * @MigrateDestination( - * id = "md_entity:field_storage_config" + * id = "md_entity:field_storage_config", + * destination_module = "field", * ) * * @deprecated in Drupal 8.2.x and will be removed in Drupal 9.0.x. Use diff --git a/core/modules/node/src/Plugin/migrate/destination/EntityNodeType.php b/core/modules/node/src/Plugin/migrate/destination/EntityNodeType.php index c26f3b9..c836232 100644 --- a/core/modules/node/src/Plugin/migrate/destination/EntityNodeType.php +++ b/core/modules/node/src/Plugin/migrate/destination/EntityNodeType.php @@ -7,7 +7,8 @@ /** * @MigrateDestination( - * id = "entity:node_type" + * id = "entity:node_type", + * destination_module = "node", * ) */ class EntityNodeType extends EntityConfigBase { diff --git a/core/modules/search/src/Plugin/migrate/destination/EntitySearchPage.php b/core/modules/search/src/Plugin/migrate/destination/EntitySearchPage.php index ddd8da7..03f109a 100644 --- a/core/modules/search/src/Plugin/migrate/destination/EntitySearchPage.php +++ b/core/modules/search/src/Plugin/migrate/destination/EntitySearchPage.php @@ -8,7 +8,8 @@ /** * @MigrateDestination( - * id = "entity:search_page" + * id = "entity:search_page", + * destination_module = "search", * ) */ class EntitySearchPage extends EntityConfigBase { diff --git a/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php b/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php index fddf08a..4c794ba 100644 --- a/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php +++ b/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php @@ -7,7 +7,8 @@ /** * @MigrateDestination( - * id = "entity:shortcut_set" + * id = "entity:shortcut_set", + * destination_module = "shortcut", * ) */ class EntityShortcutSet extends EntityConfigBase { diff --git a/core/modules/system/src/Plugin/migrate/destination/EntityDateFormat.php b/core/modules/system/src/Plugin/migrate/destination/EntityDateFormat.php index 42ba166..acdffae 100644 --- a/core/modules/system/src/Plugin/migrate/destination/EntityDateFormat.php +++ b/core/modules/system/src/Plugin/migrate/destination/EntityDateFormat.php @@ -7,7 +7,8 @@ /** * @MigrateDestination( - * id = "entity:date_format" + * id = "entity:date_format", + * destination_module = "system", * ) */ class EntityDateFormat extends EntityConfigBase { diff --git a/core/modules/system/src/Plugin/migrate/destination/d7/ThemeSettings.php b/core/modules/system/src/Plugin/migrate/destination/d7/ThemeSettings.php index 55ac721..b7f935c 100644 --- a/core/modules/system/src/Plugin/migrate/destination/d7/ThemeSettings.php +++ b/core/modules/system/src/Plugin/migrate/destination/d7/ThemeSettings.php @@ -13,7 +13,8 @@ * Persist theme settings to the config system. * * @MigrateDestination( - * id = "d7_theme_settings" + * id = "d7_theme_settings", + * destination_module = "system", * ) */ class ThemeSettings extends DestinationBase implements ContainerFactoryPluginInterface { diff --git a/core/modules/user/src/Plugin/migrate/destination/EntityUser.php b/core/modules/user/src/Plugin/migrate/destination/EntityUser.php index 7c2c81a..f5fb9ea 100644 --- a/core/modules/user/src/Plugin/migrate/destination/EntityUser.php +++ b/core/modules/user/src/Plugin/migrate/destination/EntityUser.php @@ -16,7 +16,8 @@ /** * @MigrateDestination( - * id = "entity:user" + * id = "entity:user", + * destination_module = "user", * ) */ class EntityUser extends EntityContentBase { diff --git a/core/modules/user/src/Plugin/migrate/destination/UserData.php b/core/modules/user/src/Plugin/migrate/destination/UserData.php index 7c48f93..8843deb 100644 --- a/core/modules/user/src/Plugin/migrate/destination/UserData.php +++ b/core/modules/user/src/Plugin/migrate/destination/UserData.php @@ -11,7 +11,8 @@ /** * @MigrateDestination( - * id = "user_data" + * id = "user_data", + * destination_module = "user", * ) */ class UserData extends DestinationBase implements ContainerFactoryPluginInterface {