Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
We should remove usages of Drupal\migrate\Plugin\migrate\process\Iterator and replace with Drupal\migrate\Plugin\migrate\process\SubProcess.
Proposed resolution
Replace all the usages of Drupal\migrate\Plugin\migrate\process\Iterator with Drupal\migrate\Plugin\migrate\process\SubProcess.
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#18 | 2969757-18.patch | 3.37 KB | marcel66 |
#18 | interdiff-18.txt | 570 bytes | marcel66 |
#16 | interdiff-16.txt | 1.18 KB | marcel66 |
#16 | 2969757-16.patch | 3.1 KB | marcel66 |
#14 | interdiff-14.txt | 1.04 KB | marcel66 |
Comments
Comment #2
marcel66 CreditAttribution: marcel66 as a volunteer commentedA simple patch replacing Drupal\migrate\Plugin\migrate\process\Iterator with Drupal\migrate\Plugin\migrate\process\SubProcess.
Comment #4
marcel66 CreditAttribution: marcel66 as a volunteer commentedUnchanges to IteratorTest.php.
Comment #6
marcel66 CreditAttribution: marcel66 as a volunteer commentedFixed IteratorText.php
Comment #7
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedNice work!
Comment #8
alexpottThis is actually a
Drupal\migrate\Plugin\migrate\process\Iterator
- it is currently incorrect and the patch change is still not right. This is a legacy test - we should be adding an @expectedDeprecation annotation to the test and fixing this to point to the deprecated class.The other changes look good.
Comment #9
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedCleaning up tags.
Comment #10
marcel66 CreditAttribution: marcel66 as a volunteer commentedAdded back deprecation message for Iterator which should remain.
Comment #11
marcel66 CreditAttribution: marcel66 as a volunteer commentedThanks for support.
Comment #12
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedLooks great now :)
Comment #14
marcel66 CreditAttribution: marcel66 as a volunteer commentedThank you all to allow me make mistakes and correct them. I'm still learning.
Comment #15
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedThe
@expectedDeprecation
annotation needs to be placed in the documentation block of a test method. In this case, it needs to be in thetestIterator()
method of this test class.You can find an example of how this works in the
\Drupal\Tests\link\Unit\Plugin\migrate\cckfield\LinkCckTest
test class, and thetestProcessCckFieldValues()
test method.Comment #16
marcel66 CreditAttribution: marcel66 as a volunteer commentedThank you
Comment #17
marcel66 CreditAttribution: marcel66 as a volunteer commentedI have seen a mistake
Comment #18
marcel66 CreditAttribution: marcel66 as a volunteer commentedThanks.
Comment #19
marcel66 CreditAttribution: marcel66 as a volunteer commentedComment #20
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedLooks great now :)
Comment #21
alexpottCommitted and pushed 282eb36c14 to 8.6.x and 5781652137 to 8.5.x. Thanks!
Backported to 8.5.x since all the changes are either docs or tests.