"Reedy" changed the status of MediaWiki.r107980 to "fixme" and commented it.
URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/107980#c30098
Old Status: ok
> New Status: fixme
Commit summary for MediaWiki.r107980:
* Added supported for container sharding via existing FileRepo-style hash
paths. For sharded containers, all paths used to store files must be hashed
appropriately (or the path will be rejected as invalid).
* Tweaked FileBackend::isValidContainerName() length check to give some head
room for shard and segment container names.
* Updated FSFileBackend to use new resolveStoragePathReal() function for file
paths.
* Removed useless cache invalidation in FileBackend::concatenateInternal().
Reedy's comment:
Marking this as fixme, although, it's not exactly to blame.
Line 1147/1148 (the return new)
<pre>
/**
+ * @see FileBackendBase::getFileList()
+ */
+ final public function getFileList( array $params ) {
+ list( $fullCont, $dir, $shard ) = $this->resolveStoragePath(
$params['dir'] );
+ if ( $dir === null ) { // invalid storage path
+ return null;
+ }
+ if ( $shard !== null ) {
+ // File listing is confined to a single container/shard
+ return $this->getFileListInternal( $fullCont, $dir,
$params );
+ } else {
+ wfDebug( __METHOD__ . ": iterating over all container
shards.\n" );
+ // File listing spans multiple containers/shards
+ list( $b, $shortCont, $r ) = self::splitStoragePath(
$params['dir'] );
+ return new ContainerShardListIterator( $this,
+ $fullCont, $this->getContainerSuffixes(
$shortCont ), $params );
+ }
+ }
</pre>
_______________________________________________
MediaWiki-CodeReview mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview