Page MenuHomePhabricator

thumb.php should work with ForeignAPIRepo
Open, MediumPublic

Description

It would be really nice if thumb.php worked with ForeignAPIRepo.


Version: unspecified
Severity: minor
See also: T114098: Remote file thumb generation blocks serving a page (we now hotlink InstantCommons thumbnails, hence this is not an issue for that use case)

Details

Reference
bz25958

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:23 PM
bzimport set Reference to bz25958.
bzimport added a subscriber: Unknown Object (MLST).

it doesn't ?

I get the following error using MediaWiki 1.16.0:

Error generating thumbnail
The source file for the specified thumbnail does not exist.

TheDJ added a comment.Nov 19 2010, 1:35 AM

I just looked at this. It seems that atm thumb.php only supports the local repository. This is a rather interesting issue. Normally, for foreign repositories, the thumb script will point to the original location of the file, if I understand correctly, for instantcommons, the thumbscript should thus be http://commons.wikimedia.org/w/thumb.php (i'm not sure if it is set at all atm).

Now the issue here is of course that we are locally caching remote thumbnails, so using a "remote" thumb.php is not really useful in this case.

I'm guessing the idea here is that for ForeignAPIrepo, you want to use the local thumb.php script to generate thumbnails on the fly ? That would require some intricate changes to thumb.php.

(In reply to comment #3)

I'm guessing the idea here is that for ForeignAPIrepo, you want to use the
local thumb.php script to generate thumbnails on the fly ? That would require
some intricate changes to thumb.php.

Yes, this.

Reedy added a comment.Sep 17 2013, 2:14 AM
  • Bug 49670 has been marked as a duplicate of this bug. ***
Jdforrester-WMF moved this task from Untriaged to Backlog on the Multimedia board.Sep 4 2015, 6:41 PM
Restricted Application added subscribers: Steinsplitter, Matanya. · View Herald TranscriptSep 4 2015, 6:41 PM

I'm guessing the idea here is that for ForeignAPIrepo, you want to use the local thumb.php script to generate thumbnails on the fly ? That would require some intricate changes to thumb.php.

Shouldn't thumb.php "just" call ForeignAPIrepo::getThumbUrlFromCache() and/or whatever normally downloads the remote thumbs? Generating thumbs locally is a waste of own CPU and remote bandwidth.

Tgr added a comment.Oct 2 2015, 7:03 AM

Local thumbnail generation might produce different results due to using different tools or having different parameters such as sharpening.

Remote generation is more friendly to shared hosting (you don't need to get all the tools installed to get working thumbnails). OTOH if a different revision of the of the media handler is installed locally and remotely, it could break in various ways.

Nemo_bis updated the task description. (Show Details)Dec 12 2015, 9:49 AM
Nemo_bis set Security to None.
Restricted Application added a project: Commons. · View Herald TranscriptDec 12 2015, 9:49 AM
zhuyifei1999 moved this task from Incoming to Backlog on the Commons board.Dec 15 2015, 10:21 AM