Review main Merged

23470[TASK] FAL ResourceStorage must not access sys_file table directly

Steffen Ritter CR +2 V +2 Easy +9 −5 updated 09/11/13, 15:48

Commit message

The ResourceStorage accesses the index table sys_file directly via
a call to the $GLOBALS[TYPO3_DB]. The interaction with the sys_file
index table should be managed only by an according repository to
allow changes within that mechanism.

This patch rearranges the factory method to use the according
call within the FileRepository and adapts it, as the FileRepository
will return a file Object instead of an array.

This serves as a preparation for further indexing optimisations,
which need IndexRecords to be handled centrally.

Review

  • Code review CR +2
    • Stefan Neufeind +2
  • Verified V +2
    • Stefan Neufeind +2

Issues 1

Files 1

Review log 18

  1. Mr. Jenkins commented on patch set 1 08/29/13, 13:54

  2. Frans Saris voted on patch set 1 CR +1 08/29/13, 15:30

  3. Susi Moog commented on patch set 1 08/29/13, 16:54

    ResourceFactory.php:342

    is it ok to remove the intval?
  4. Steffen Ritter commented on patch set 1 08/30/13, 08:32

    ResourceFactory.php:342 Reply

    the repository needs to verify that anyhow itself before it hands it over to the database
  5. Philipp Gampe voted on patch set 1 CR +1 08/31/13, 16:48

  6. Philipp Gampe commented on patch set 1 V -1 CR -1 08/31/13, 16:51

    ResourceFactory.php:343

    I meant fileObject here?!?
  7. Philipp Gampe uploaded patch set 2 08/31/13, 16:53

  8. Mr. Jenkins commented on patch set 2 08/31/13, 16:54

  9. Philipp Gampe commented on patch set 2 V +1 CR -1 08/31/13, 16:54

    Fixed the comment ... please test your changes before push. This change misses a unit test (should be easy to test).
  10. Steffen Ritter commented on patch set 2 09/01/13, 07:54

    what is your -1 based on? A unit test would not make sense now :) It's wasted time - there is a bigger patch set already prepared this one is a split, making patch sets smaller... The following patch set will change the function again. Then a new unit test may make sense.
  11. Philipp Gampe commented on patch set 2 CR +1 09/01/13, 09:06

    not sure ... I guess I put -1 because of a missing test and the fact that the original patch did not work at all (fatal error). Because this is not the first time you push a change that results always in a fatal error, I kindly ask you to test your code before you push it to gerrit.
  12. Wouter Wolters voted on patch set 2 CR +1 09/09/13, 20:33

  13. Stefan Neufeind uploaded patch set 3 09/11/13, 15:47

  14. Stefan Neufeind commented on patch set 3 V +2 CR +2 09/11/13, 15:48

    just rebased. still counting: 1x reviewed from Wouter, 1x reviewed/verified from Philipp
  15. Stefan Neufeind merged patch set 4 09/11/13, 15:48

  16. Mr. Jenkins commented on patch set 3 09/11/13, 15:48

  17. Stefan Neufeind commented on patch set 4 09/11/13, 15:48

    Cherry Picked This patchset was cherry picked to change: I5aa2d212b936b218db1808ea3d0384b8292287a9
  18. Stefan Neufeind commented on patch set 4 09/11/13, 15:48

    Cherry Picked This patchset was cherry picked to change: I5aa2d212b936b218db1808ea3d0384b8292287a9