Link to pics on Factorio.com

Discussions related to the forums itself. Call for moderators. Trash Posts area.
Post Reply
User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Link to pics on Factorio.com

Post by ssilk »

Well, this is in my eyes a very minor bug (perhaps) and does not depend the game. So "not important". And perhaps there is an existing workaround to this (which makes a lot of sense), but then I don't know. :)

In the factorio-forum I made many articles, that include pics from factorio.com. Most pictures on factorio.com are outsourced to some amazon-cloud. This is useful, cause this spares a lot of traffic.

So the urls to those pics look like so:
http://eu2.factorio.com/assets/img/blog ... eboard.jpg (taken from https://www.factorio.com/blog/post/fff-74 )
Image

You see the "eu2". That is the problem, cause this can change with time!
This make this URL break when they add, remove, change some amazon-cloud. And my pic is gone: Looks like so:

http://eu5.factorio.com/assets/img/blog ... eboard.jpg
Image

Universal resource locators should not change over space and time. They are somehow "static".

So, normally this problem that you link resources to a server, that can change it's name is solved either by some kind of service, which know the current "true" URL of that resource and forwards the browser to this target. So the URL can keep static but it needs always to be forwarded. The added advantage of this is, that you have an about count of how often that resource is called without looking into the cloud-servers and you keep at every time the control to resource.
Also a useful technique: An X-unclouded-source-url:-Header (I just invented that, maybe, there are better names) in the header of the above linked pic that provides such a "real" URL.

And there are of course many other techniques, the point is: you need to do something. :)

PS: So, without going deeper into this and into how amazon-cloud works: Does anybody already know what I need to write instead, to have a permanent URL to this resource (the pic)?
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

User avatar
TruePikachu
Filter Inserter
Filter Inserter
Posts: 978
Joined: Sat Apr 09, 2016 8:39 pm
Contact:

Re: Link to pics on Factorio.com

Post by TruePikachu »

From what I can tell, the eu5 link broke because the specific instance (as of this moment) is timing out on all requests.

I do believe there at least should be a URL which auto-selects an instance to serve from, but I don't know what it is. I'm trying to do research on it right now, though.

EDIT: Maybe Route 53?

User avatar
HanziQ
Former Staff
Former Staff
Posts: 630
Joined: Fri Mar 27, 2015 7:07 am
Contact:

Re: Link to pics on Factorio.com

Post by HanziQ »


Zeblote
Filter Inserter
Filter Inserter
Posts: 973
Joined: Fri Oct 31, 2014 11:55 am
Contact:

Re: Link to pics on Factorio.com

Post by Zeblote »

HanziQ wrote:1) nothing to do with amazon
2) you should be using https://factorio.com/get-asset/<path> (https://factorio.com/get-asset/img/blog ... und-03.png)
Can you make these links open in browser like normal instead of ask where to save it? Seems the browser doesn't understand these are image files.

User avatar
HanziQ
Former Staff
Former Staff
Posts: 630
Joined: Fri Mar 27, 2015 7:07 am
Contact:

Re: Link to pics on Factorio.com

Post by HanziQ »

Fixed

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Link to pics on Factorio.com

Post by ssilk »

Nice, thanks, I move this from Bugs to This Forum, where I think it is more useful.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

Post Reply

Return to “This Forum”