-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Deployment] Changing of context root
value doesn't affect on direct web module deployment
#589
Comments
See WTP Bug. See the |
I left a comment at https://bugs.eclipse.org/bugs/show_bug.cgi?id=133746#c10 It is possible I can come up with a solution for JBT / jboss / wildfly / eap, but I'm not certain that I can. I will investigate it. |
The file .settings/org.eclipse.wst.common.component has two areas with conflicting details. Here is an example of the contents of that file:
You'll note that there's a deploy-name and a context-root. If the deploy-name is left blank, I can probably use the context-root to decide how to name the output war. However, if the deploy-name is NOT blank, and it conflicts with the context-root, then the only solution is to publish as MyWeb8934.war but add a jboss-web.xml with contextRoot = TestRob. But we don't like doing that... adding random files in the project. It's bad practice, especially on-the-fly during a publish. I don't see any UI that exposes the deploy-name part of the module and allows users to change it. It's possible an enhancement to that preference page to allow setting the deploy-name in addition to the context-root might be useful for people. |
Yes, You are right. What i am thinking is, by default the AFAIK for many server in Only MyEclipse has the UI to customize the One important use case is, I think, it should be Actually, this issue was filed for above usecase. |
It should be, but, unfortunately, these are two different data fields in the file. In my opinion the best way to fix this is to update the preference page to display both context-root and deploy-name. Some server adapters may ignore the context-root option (rather than modify or add a jboss-web.xml on the fly) so giving the user the option to change the deploy-name is pretty important I feel. I'll work on an upstream patch for this. |
STEPS
1.Create a web module
web-test
with default options .2. Create
index.jsp
file with simple textHello Wildfly
2.Change the
context root
toweb-test-change
( Right click on project Properties > Web Project Settings )
3. Now deploy/publish the module to Wildfly server.
4.After successful deployment the module can be accessed with the context root
http://localhost:8080/web-test
I think, it should be
http://localhost:8080/web-test-change
Note: the context root value is working as expected for EAR modules
The text was updated successfully, but these errors were encountered: