We've also had to reset the site data cache in TNEW ... when we make changes to settings in different tables maybe. IDK but when it has gone down in the last few weeks as we were getting our site adjustments made it required a lot of going into SITE DATA and pulling down RESET SITE DATA and clicking RESET CACHE. So if you've just made changes in there and get the 504 then that's a good thing to do too.