Review main Merged

23464[TASK] FAL-Drivers: Make getFileInfo more versatile and performant

Steffen Ritter CR +2 V +2 Normal +53 −128 updated 10/11/13, 14:45

Commit message

If a storage needs information about a file, it always has
to retrieve all information about the file from the driver.
This can be very expensive - especially if only the modification
timestamp would be relevant, but sha1 content hash as well
as creation time, access time, size, mimetype ... are detected.
This patch extends the interface with a possibility to only
retrieve a subset of these information. As drivers are only
accessible through an ResourceStorage and the new parameters
are optional this patch does not change behaviour or break
backwards compatiblity.

Review

  • Code review CR +2
    • Oliver Hader +2
  • Verified V +2
    • Oliver Hader +2

Issues 1

Files 3

Review log 26

Show 1 earlier messages
  1. Steffen Ritter commented on patch set 1 CR -2 08/29/13, 13:12

    to much files in it
  1. Mr. Jenkins commented on patch set 1 08/29/13, 13:13

  2. Steffen Ritter uploaded patch set 2 08/29/13, 13:16

  3. Mr. Jenkins commented on patch set 2 08/29/13, 13:17

  4. Frans Saris commented on patch set 2 CR -1 08/29/13, 13:23

    LocalDriver.php:237

    extractFileInformation() has not third parameter
  5. Steffen Ritter uploaded patch set 3 08/29/13, 14:00

  6. Mr. Jenkins commented on patch set 3 08/29/13, 14:01

  7. Steffen Ritter uploaded patch set 4 08/29/13, 14:10

  8. Steffen Ritter commented on patch set 4 08/29/13, 14:11

    Sorry, It took me 5 patch sets to finally push the right subset of files without any merge errors.
  9. Mr. Jenkins commented on patch set 4 08/29/13, 14:11

  10. Frans Saris commented on patch set 4 CR -1 08/29/13, 15:37

    general idea looks good.

    AbstractDriver.php:387

    Maybe add some extra description to this parameter about what these properties are for and rename te property to something like $propertiesToExtract

    LocalDriver.php:220

    phpdocs misses new property and rename te property to something like $propertiesToExtract

    LocalDriverTest.php:291

    why did you remove the tests without a replacement?
  11. Steffen Ritter commented on patch set 4 08/29/13, 15:40

    LocalDriverTest.php:291 Reply

    because the function which is tested has been removed
  12. Steffen Ritter uploaded patch set 5 08/30/13, 08:28

  13. Mr. Jenkins commented on patch set 5 08/30/13, 08:29

  14. Steffen Ritter commented on patch set 5 08/30/13, 08:29

    fixed the doc-comment thingies in patchset 5
  15. Sascha Egerer uploaded patch set 6 08/30/13, 14:22

  16. Mr. Jenkins commented on patch set 6 08/30/13, 14:23

  17. Sascha Egerer commented on patch set 4 08/30/13, 14:23

    LocalDriverTest.php:291 Reply

    What about unit tests for getSpecificFileInformation?
  18. Frans Saris commented on patch set 6 V +1 CR +1 10/10/13, 15:26

    Looks good to me. Only question remains is the one from Sascha "What about unit tests for getSpecificFileInformation?" Should we add a test or tests?
  19. Steffen Ritter commented on patch set 6 10/10/13, 15:36

    we cannot mock the mtime functions, unit test there does not make sense IMHO. If we would do a Unit test, it should test if the correct fnction is called. But that is not possible - so it does not make sense.
  20. Oliver Hader commented on patch set 6 V +1 CR +1 10/11/13, 13:11

    AbstractDriver.php:382

    This breaks compatibility in existing implementations (PHP 5.3) - so, if we put that only to 6.2, it's fine...
  21. Oliver Hader updated the commit message in patch set 6 10/11/13, 13:13

  22. Oliver Hader voted on patch set 7 V +2 10/11/13, 13:13

  23. Oliver Hader voted on patch set 7 CR +2 10/11/13, 13:13

  24. Oliver Hader merged patch set 8 10/11/13, 13:13

  25. Mr. Jenkins commented on patch set 7 10/11/13, 14:45