Alon Bar-Lev has uploaded a new change for review. Change subject: packaging: move api from /api to /ovirt-engine/api ......................................................................
packaging: move api from /api to /ovirt-engine/api part of the effort to make the ovirt-engine application well behaved application we would like to stop abusing root context of the web server. for backward compatibility /api/* will be forwarded into /ovirt-engine/api/* without redirect. the uris that will be returned in the response will reference to the /ovirt-engine/api namespace. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=961677 Change-Id: I2ab8396359db608bb2eaae366f31b92034fa4413 Signed-off-by: Alon Bar-Lev <[email protected]> --- M backend/manager/modules/root/src/main/webapp/WEB-INF/web.xml M ear/pom.xml 2 files changed, 19 insertions(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/86/20786/1 diff --git a/backend/manager/modules/root/src/main/webapp/WEB-INF/web.xml b/backend/manager/modules/root/src/main/webapp/WEB-INF/web.xml index 5239a36..ae56ea0 100644 --- a/backend/manager/modules/root/src/main/webapp/WEB-INF/web.xml +++ b/backend/manager/modules/root/src/main/webapp/WEB-INF/web.xml @@ -100,6 +100,24 @@ <url-pattern>/OvirtEngineWeb/HealthStatus.aspx</url-pattern> </servlet-mapping> + <!-- Legacy api URI --> + <servlet> + <servlet-name>API</servlet-name> + <servlet-class>org.ovirt.engine.core.utils.servlet.ForwardServlet</servlet-class> + <init-param> + <param-name>targetContext</param-name> + <param-value>%{ENGINE_URI}/api/</param-value> + </init-param> + <init-param> + <param-name>uri</param-name> + <param-value>/</param-value> + </init-param> + </servlet> + <servlet-mapping> + <servlet-name>API</servlet-name> + <url-pattern>/api/*</url-pattern> + </servlet-mapping> + <servlet> <servlet-name>index</servlet-name> <servlet-class>org.ovirt.engine.core.utils.servlet.RedirectServlet</servlet-class> diff --git a/ear/pom.xml b/ear/pom.xml index ef67f1e..eab728b 100644 --- a/ear/pom.xml +++ b/ear/pom.xml @@ -200,7 +200,7 @@ <groupId>org.ovirt.engine.api</groupId> <artifactId>restapi-webapp</artifactId> <bundleFileName>restapi.war</bundleFileName> - <contextRoot>/api</contextRoot> + <contextRoot>/ovirt-engine/api</contextRoot> </webModule> <webModule> -- To view, visit http://gerrit.ovirt.org/20786 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I2ab8396359db608bb2eaae366f31b92034fa4413 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Alon Bar-Lev <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
