anyone advise how/what generates this?
# social
c
Perfect timing with @skttl 😂
c
been scanning the source code... could not find squat.. lol
s
just curious? why do you need to know? It's only needed when creating the media, once it has been created the path is just saved to the db, and could be anything
c
because the paths have been indexed...
so if I yeet them with a new build.. then all those media links will 404
c
Won't they just be re-indexed based on the db stored values?
c
uh sorry.. by indexed.. I mean by Google
c
Oooh, but still, if you were to maintain your database/content/media when migrating/upgrading, won't the guids & paths for existing media stay the same?
c
we're.. not maintaining the database :/
we're moving from v8, which has been built with a bunch of proprietary components that we (as the new developers) don't have access to
so needing to clean-slate the db.
s
it sounds like you are in for a lot of work, for very little gains. Google will quickly find the new urls. If you have a lot of inbound links directly to the media items, you could also just add redirects for those?
c
yeah am just trying to determine how much pain we're in for atm.
c
Not to mention that, unless you have a bunch of files like PDFs stored as media which may be of interest, I don't think having your images indexed is really something google would care about to begin with
c
(we do have a lot of PDFs)
It may be that 'it's just too hard...
c
I think I'm with @skttl on this one. Very little gains, but a lot of work for what you're getting out of it, and adding redirects may be the more suitable solution for important/heavy traficked files
c
I have to port the media regardless, maybe if I make them with the same ID then they will automatically just light up with the same URLs 😄
s
It's a combination of the media items guid, and the propertytype containing the uploads guid. So you also need to set the propertyTypes guid to match the previous one. You probably need database access to figure that one out 🙂 And you need to make them have the same id when you upload, you can't just change it afterwards.
c
And I also need to hope that the mechanism to alter these hasn't changed since v8...
s
I remember at one point, it would just generate a guid, check if it was already in use, and if necessary generate another. This proved costly when working with external media (blob storage etc), so was changed at one point.
c
^ not to mention the odds of you of winning the lottery 10 times over is larger than generating 2 of the same GUIDs, so I'm sure that's why they've chosen for this setup 🙂
c
Thinking now that redirects will be much easier to do
if we are in /media and we 404, can search for a media with the same last part of the path and redirect