migration is ok again (remains probleme of ram consuming > 4Go for users
This commit is contained in:
@@ -9,9 +9,10 @@ migration_tags:
|
||||
- Content
|
||||
- Materio
|
||||
- Files
|
||||
|
||||
|
||||
source:
|
||||
plugin: d7_pubic_file
|
||||
batch_size: 5000
|
||||
scheme: public
|
||||
constants:
|
||||
# The tool configuring this migration must set source_base_path. It
|
||||
|
@@ -10,6 +10,7 @@ migration_tags:
|
||||
source:
|
||||
plugin: d7_node_materiau
|
||||
node_type: materiau
|
||||
batch_size: 500
|
||||
high_water_property:
|
||||
name: changed
|
||||
alias: n
|
||||
@@ -51,6 +52,10 @@ process:
|
||||
plugin: default_value
|
||||
source: workflow
|
||||
default_value: 2
|
||||
# -
|
||||
# plugin: debug
|
||||
# source: workflow
|
||||
# label: workflow_debug
|
||||
-
|
||||
plugin: static_map
|
||||
default_value: 2
|
||||
|
@@ -62,7 +62,8 @@ process:
|
||||
4: "workflow_imported"
|
||||
5: "workflow_edited"
|
||||
|
||||
simplenews_issue:
|
||||
# https://www.drupal.org/project/simplenews/issues/3037694
|
||||
simplenews_issue/target_id:
|
||||
-
|
||||
plugin: extract
|
||||
source: field_simplenews_term
|
||||
@@ -76,8 +77,15 @@ process:
|
||||
6374: "ze_daily_materio_"
|
||||
6274: "materio_newsletter"
|
||||
7881: "companies"
|
||||
|
||||
# Sent status
|
||||
simplenews_issue/sent_count: snn_sent_subscriber_count
|
||||
simplenews_issue/status: snn_status
|
||||
simplenews_issue/error_count:
|
||||
plugin: default_value
|
||||
default_value: 0
|
||||
simplenews_issue/subscribers: snn_sent_subscriber_count
|
||||
simplenews_issue/handler:
|
||||
plugin: default_value
|
||||
default_value: simplenews_all
|
||||
|
||||
migration_dependencies:
|
||||
required:
|
||||
|
@@ -9,6 +9,7 @@ migration_tags:
|
||||
|
||||
source:
|
||||
plugin: d7_user_profile
|
||||
batch_size: 1000
|
||||
high_water_property:
|
||||
name: changed
|
||||
alias: p
|
||||
|
@@ -9,6 +9,7 @@ migration_tags:
|
||||
|
||||
source:
|
||||
plugin: d7_users
|
||||
batch_size: 1000
|
||||
|
||||
destination:
|
||||
plugin: entity:user
|
||||
|
@@ -12,12 +12,24 @@ dependencies:
|
||||
- migrate_tools:migrate_tools
|
||||
# - drupal:field_group_migrate
|
||||
- telephone_validation
|
||||
|
||||
# config_devel:
|
||||
# install:
|
||||
# - migrate_plus.migration_group.d7_materio
|
||||
# - migrate_plus.migration.d7_taxonomy_term_thesaurus
|
||||
# - migrate_plus.migration.d7_taxonomy_term_tags
|
||||
# - migrate_plus.migration.d7_taxonomy_term_showroom
|
||||
# - migrate_plus.migration.d7_taxonomy_term_company
|
||||
# - migrate_plus.migration.d7_node_entity_translation_materiau
|
||||
|
||||
# https://www.liip.ch/en/blog/using-the-new-drupal-8-migration-api-module
|
||||
config_devel:
|
||||
install:
|
||||
- migrate_plus.migration.d7_users
|
||||
- migrate_plus.migration.d7_allpublicfiles
|
||||
- migrate_plus.migration.d7_taxonomy_term_company
|
||||
- migrate_plus.migration.d7_uc_roles_license
|
||||
- migrate_plus.migration.d7_simplenews_subscribers
|
||||
- migrate_plus.migration.d7_node_article
|
||||
- migrate_plus.migration.d7_simplenews_nodes
|
||||
- migrate_plus.migration.d7_node_materiau
|
||||
- migrate_plus.migration.d7_node_materiau_i18n
|
||||
- migrate_plus.migration.d7_node_article_i18n
|
||||
- migrate_plus.migration.d7_user_profile
|
||||
- migrate_plus.migration_group.d7_materio
|
||||
- migrate_plus.migration.d7_taxonomy_term_showroom
|
||||
- migrate_plus.migration.d7_taxonomy_term_tags_i18n
|
||||
- migrate_plus.migration.d7_taxonomy_term_tags
|
||||
- migrate_plus.migration.d7_taxonomy_term_thesaurus_i18n
|
||||
- migrate_plus.migration.d7_taxonomy_term_thesaurus
|
||||
|
@@ -178,7 +178,7 @@ class D7NodeMateriau extends FieldableEntity {
|
||||
drush_print('WARNING: no workflow');
|
||||
}
|
||||
$row->setSourceProperty('workflow', $results);
|
||||
|
||||
// drush_print('workflow: '.$results);
|
||||
|
||||
// record migration errors in field_memo
|
||||
if(isset($memo)){
|
||||
@@ -186,7 +186,6 @@ class D7NodeMateriau extends FieldableEntity {
|
||||
$field_memo[0]['value'] .= "\n".$memo;
|
||||
$row->setSourceProperty('field_memo', $field_memo);
|
||||
}
|
||||
|
||||
return parent::prepareRow($row);
|
||||
}
|
||||
|
||||
|
@@ -84,9 +84,13 @@ class D7SimplenewsNodes extends FieldableEntity {
|
||||
])
|
||||
->orderBy('changed');
|
||||
|
||||
$query->innerJoin('node', 'n', static::JOIN);
|
||||
$query->addField('n', 'uid', 'node_uid');
|
||||
$query->addField('nr', 'uid', 'revision_uid');
|
||||
$query->innerJoin('node', 'n', static::JOIN);
|
||||
|
||||
$query->innerJoin('simplenews_newsletter', 'snn', 'snn.nid = n.nid');
|
||||
$query->addField('snn', 'status', 'snn_status');
|
||||
$query->addField('snn', 'sent_subscriber_count', 'snn_sent_subscriber_count');
|
||||
|
||||
if (isset($this->configuration['node_type'])) {
|
||||
$query->condition('n.type', $this->configuration['node_type']);
|
||||
|
@@ -149,6 +149,8 @@ class D7TaxonomyTermCompany extends FieldableEntity implements ContainerFactoryP
|
||||
// drush_print('tode_nid: ');
|
||||
// print_r($tode_nid);
|
||||
// drush_print(' ');
|
||||
// TODO: [error] Drupal\Core\Entity\EntityStorageException: Route "entity.workflow_state.canonical" does not exist. in Drupal\Core\Entity\Sql\SqlContentEntityStorage->save() (line 846 of /var/www/html/d8.materio.com/public_html/web/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php).
|
||||
|
||||
if($tode_nid){
|
||||
// get the tode fields
|
||||
foreach ($this->getFields('node', 'company') as $field_name => $field) {
|
||||
|
@@ -127,7 +127,7 @@ class D7UcRolesLicense extends DrupalSqlBase {
|
||||
'created',
|
||||
'modified',
|
||||
]);
|
||||
$query->orderBy('created', DESC);
|
||||
$query->orderBy('created', 'DESC');
|
||||
$orders = $query->execute()->fetchAll();
|
||||
// print_r($orders);
|
||||
|
||||
|
@@ -21,7 +21,7 @@ class D7Users extends FieldableEntity {
|
||||
public function query() {
|
||||
return $this->select('users', 'u')
|
||||
->fields('u')
|
||||
->condition('u.uid', 0, '>');
|
||||
->condition('u.uid', 1, '>');
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user