Review main Merged

25621[CLEANUP] Enhance TCA - FAL migration for tt_content

Benni Mack CR +2 V +2 Hard +214 −116 updated 03/04/14, 17:28

Commit message

The upgrade wizard to migrate the fields like e.g.
tt_content->image and pages->media fetches all records
of each table and loops over them. This is basic, and not
very clever, especially when the max_execution_time is
less than the upgrade wizards needs to process all fields
or if the memory_limit is reached because ALL of the
records are fetched.

Thus, the patch modifies the behavior in the following ways:
* As all TCA value are switched from text to integer
 (the value itself, not the DB field yet) the SQL is done to
only fetch records that are not empty, not integer
(and not deleted). This reduces the memory footprint
massively.
* The check for a record is now done for each table and
then for each field of the table (as the SQL has been changed).
* The field is only marked as "done" if no more records were
found in the migration run.
* Also, the redudant myfile_05.jpg are not moved if the
first file with that name (myfile.jpg) was moved already.

The migration wizard can now be run multiple times
(and the counter shows how many records are left).

Furthermore the wizard hides itself now once all migrations
are done.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 2

Files 1