gpt4 book ai didi

spring - Tomcat 7 多上下文

转载 作者:行者123 更新时间:2023-11-28 22:57:44 30 4
gpt4 key购买 nike

我的应用程序“MyApp”在 tomcat 7 上运行并使用 spring 框架并具有以下访问 URL:

1 - https://localhost:8443/MyApp/      for the Application Web
2 - https://localhost:8443/MyApp/Rest for the Application web services

我的应用程序设置在路径上:

...\tomcat\webapps\MyApp\

我需要在不更改应用程序文件夹的情况下更改 URL:

1 - https://localhost:8443/MyApp/Admin       for the Application Web(need to change MyApp to be Admin)
2 - https://localhost:8443/MyApp/Rest for the Application web services

有什么想法吗?

最佳答案

普尔曼的解决方案:

复制tomcat中的ROOT文件夹,重命名为Admin,然后修改index.jsp,在代码中加入这一行:

response.sendRedirect("https://localhost:8443/MyApp/");

关于spring - Tomcat 7 多上下文,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23864917/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com