"The origin server did not find a current representation for the target resource or is not willing to disclose that one exists" upgrading to 12.7

Seems you have the Java security manager turned on for Tomcat. Maybe see https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/Installation/InstallationWAR/InstallationTomcat/#HPolicyconfiguration and https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/Installation/InstallationWAR/InstallationTomcat/#HJavaSecurityManager