Page MenuHomePhabricator

Thumbnails failing to be created (400 error) due to metadata caching problem
Open, LowPublic

Event Timeline

Josve05a raised the priority of this task from to Needs Triage.
Josve05a updated the task description. (Show Details)
Josve05a subscribed.

That's weird. I tried to reproduce manually but couldn't:

tgr@terbium:~$ mwscript eval.php --wiki=commonswiki
> $img = wfLocalFile( 'Voroshilov,_Molotov,_Stalin,_with_Nikolai_Yezhov.jpg' );
> $params = array( 'width' => 800 );
> $thumbName = $img->thumbName( $params );
> $thumbPath = $img->getThumbPath( $thumbName );
> $mto = $img->transform( $params, File::RENDER_NOW );
> echo $mto->isError();
> echo $mto->hasFile();
1
> echo $mto->fileIsSource();

Both images were reuploaded a few hours age and the previous version was smaller than 800px, so this is some sort of metadata caching problem.

That's what I assumed (as the uploader). But it's strange, surely uploading larger versions is very much routine? Why would it break in this case but not usually?

Jdforrester-WMF renamed this task from Failed to load resource: the server responded with a status of 400 (Bad Request) to Thumbnails failing to be created (400 error) due to metadata caching problem.Sep 29 2015, 4:11 PM
Jdforrester-WMF triaged this task as Low priority.
Jdforrester-WMF set Security to None.
Jdforrester-WMF moved this task from Untriaged to Backlog on the Multimedia board.

Interestingly these specific files seem to be fixed now. I don't know how that happened, was it one of you?

The width/height cache for file metadata has an expiry date of 7 days. So its been long enough that the cache entry became expired.

Of course, the cache entry is supposed to be explicitly deleted upon a new version being uploaded. So the underlying cause may still be there

Given recent efforts to move to different levels of caches (e.g. WAN cache vs non-WAN cache), maybe there's something setting to one cache and reading from another. Or something like that. However grepping around there isn't really anything that sticks out.