So we are about to go into production with our new site in xp which previously resided under cms.
Since we have a bunch of services which depend upon content in the old cms site, which does not exist, and probably never will, in the new xp site, we cannot simply take the old cms site offline.
So we have made another dns entry for the old site prefixed “retro”.
And when we go live, we will simply update the dns so the xp site lives on the same url the cms site did.
Since we do not know everywhere the old urls are used, we need to have redirects for a while.
We could invent a redirect content type, and make “endpoints” in Content Studio with it, but that would clutter up content studio, and also not catch unknown endpoints.
So we need to be able to use regexes.
I can do this in the error handler, but I’d rather do it in a programmable router.
Not really sure what you want to do?
Do you want to route some specific traffic hitting the xp installation to the retro site? If so, i propose one of the following (in preferred order):
Use rewrites in apache
Add handle404 error.js with a list of regex to redirect
Add separate app with explicit mappings, and add it to the site - so you can release it frequently, and avoid cluttering your main app (available in 6.7)
Using apache for redirects sounds good in theory, but requires involving external OPS people, and possibly ITIL regime, which does not handle rapid changes… Also maintaining apache redirect on multiple cluster nodes sound like pain.
I’m gonna implement it in content studio and error handler for now.
Keeping my fond wishes for a programmable router for later