Support for storing files under SHA-1 names
authorAaron Schulz <aschulz@wikimedia.org>
Tue, 10 Mar 2015 13:26:14 +0000 (14:26 +0100)
committerGilles Dubuc <gdubuc@wikimedia.org>
Tue, 21 Jul 2015 14:19:22 +0000 (16:19 +0200)
commitf1e1313a164ab06b19ce90e112e00145b8b4afa7
treeb9c1575d32ada873c1ce9a9d1ce19623d0fd1aed
parente77a09ccdbf367c78ebbdc0f846f8698d021c070
Support for storing files under SHA-1 names

* Added a "storageLayout" flag to LocalRepo config (supports "sha1")
* Added a simple migration script to copy files the SHA1 paths
* Currently works with img_auth.php + thumb_handler.php for URLs
* Added visibility to some LocalFile methods
* Simple tests for the wrapper class.

Co-Authored-By: Gilles Dubuc <gdubuc@wikimedia.org>
Change-Id: Iad46ad669c8ae3c02d10da10c3f7a16fe161663f
Bug: T1210
autoload.php
includes/filerepo/FileBackendDBRepoWrapper.php [new file with mode: 0644]
includes/filerepo/FileRepo.php
includes/filerepo/ForeignDBRepo.php
includes/filerepo/ForeignDBViaLBRepo.php
includes/filerepo/LocalRepo.php
includes/filerepo/file/LocalFile.php
maintenance/migrateFileRepoLayout.php [new file with mode: 0644]
tests/phpunit/includes/filerepo/FileBackendDBRepoWrapperTest.php [new file with mode: 0644]
tests/phpunit/includes/filerepo/MigrateFileRepoLayoutTest.php [new file with mode: 0644]