| If it's in the local wiki's uploaded file set, that's used. Otherwise, | the commons file set is checked.
I need to import recent wiki content in diff. languages to my website - presently about 5 MB including images - so to download 26 GBs via the complete DB dump wouldn't be economical.
As I don't have access to the wikipedia filesystem I'd have to do the check above via HTTP request.
I'd do it like this:
1) send a GET request to http://upload.wikimedia.org/somePathToImg 2) wait for result 3) a - use the file in case of response 200 b - else if response 404 fetch the file at http://commons.wikimedia.org/somePathToImg
...which still causes overhead. Isn't there a more elegant solution?
Marek