Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » Web App Context
Web App Context [message #219205] Tue, 12 August 2008 18:24 Go to next message
Eclipse UserFriend
Originally posted by: nowhere.a.com

In the properties for a project, there is an item named Web Project
Settings which has a single property named Context Root.

My Project name is MYAPP
I set the Context Root to app

Publishing the project produces a directory named:
<webapp>/MYAPP

Should not the directory name for the application follow the context
root name? I was expecting:

<webapp>/app

--
Wojtek :-)
Re: Web App Context [message #219213 is a reply to message #219205] Tue, 12 August 2008 20:01 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry IsaacsFriend
Messages: 1354
Registered: July 2009
Senior Member
Wojtek wrote:
> In the properties for a project, there is an item named Web Project
> Settings which has a single property named Context Root.
>
> My Project name is MYAPP
> I set the Context Root to app
>
> Publishing the project produces a directory named:
> <webapp>/MYAPP
>
> Should not the directory name for the application follow the context
> root name? I was expecting:
>
> <webapp>/app
>

For the Tomcat support, and probably others, the directory name is
determined by the module's deploy-name as specified in the project's
".settings/org.eclipse.wst.common.component" file.

Cheers,
Larry
Re: Web App Context [message #219221 is a reply to message #219213] Tue, 12 August 2008 21:48 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: nowhere.a.com

Larry Isaacs wrote :
> Wojtek wrote:
>> In the properties for a project, there is an item named Web Project
>> Settings which has a single property named Context Root.
>>
>> My Project name is MYAPP
>> I set the Context Root to app
>>
>> Publishing the project produces a directory named:
>> <webapp>/MYAPP
>>
>> Should not the directory name for the application follow the context root
>> name? I was expecting:
>>
>> <webapp>/app
>>
>
> For the Tomcat support, and probably others, the directory name is determined
> by the module's deploy-name as specified in the project's
> ".settings/org.eclipse.wst.common.component" file.

I don't suppose this could be exposed in properties?

--
Wojtek :-)
Re: Web App Context [message #219228 is a reply to message #219213] Tue, 12 August 2008 21:59 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: nowhere.a.com

Larry Isaacs wrote :
> Wojtek wrote:
>> In the properties for a project, there is an item named Web Project
>> Settings which has a single property named Context Root.
>>
>> My Project name is MYAPP
>> I set the Context Root to app
>>
>> Publishing the project produces a directory named:
>> <webapp>/MYAPP
>>
>> Should not the directory name for the application follow the context root
>> name? I was expecting:
>>
>> <webapp>/app
>>
>
> For the Tomcat support, and probably others, the directory name is determined
> by the module's deploy-name as specified in the project's
> ".settings/org.eclipse.wst.common.component" file.
It seemed that the name should in the attribute "deploy-name". However
when I changed it, I could no longer add the project to the server.

So it seems that the "Add/Remove Projects" in the Server matches the
deploy-name with existing project names.

Oh, and when I exited Eclipse with the file open, Ecplise crashed. No
messages, just a pop-up from windows stating that Eclipse abended.

--
Wojtek :-)
Re: Web App Context [message #219252 is a reply to message #219228] Wed, 13 August 2008 12:30 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry IsaacsFriend
Messages: 1354
Registered: July 2009
Senior Member
Wojtek wrote:
> Larry Isaacs wrote :
>> Wojtek wrote:
>>> In the properties for a project, there is an item named Web Project
>>> Settings which has a single property named Context Root.
>>>
>>> My Project name is MYAPP
>>> I set the Context Root to app
>>>
>>> Publishing the project produces a directory named:
>>> <webapp>/MYAPP
>>>
>>> Should not the directory name for the application follow the context
>>> root name? I was expecting:
>>>
>>> <webapp>/app
>>>
>>
>> For the Tomcat support, and probably others, the directory name is
>> determined by the module's deploy-name as specified in the project's
>> ".settings/org.eclipse.wst.common.component" file.
> It seemed that the name should in the attribute "deploy-name". However
> when I changed it, I could no longer add the project to the server.
>
> So it seems that the "Add/Remove Projects" in the Server matches the
> deploy-name with existing project names.

WTP continues to have issues if the project name and the deploy-name do
not match. For example, see:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=202541
https://bugs.eclipse.org/bugs/show_bug.cgi?id=154833

>
> Oh, and when I exited Eclipse with the file open, Ecplise crashed. No
> messages, just a pop-up from windows stating that Eclipse abended.
>

Likely a JVM bug. You can check the "eclipse" directory to see if any
crash file was written there that might provide clues.

Cheers,
Larry
Re: Web App Context [message #219260 is a reply to message #219252] Wed, 13 August 2008 14:10 Go to previous message
Eclipse UserFriend
Originally posted by: nowhere.a.com

Larry Isaacs wrote :
> Wojtek wrote:
>> Larry Isaacs wrote :
>>> Wojtek wrote:
>>>> In the properties for a project, there is an item named Web Project
>>>> Settings which has a single property named Context Root.
>>>>
>>>> My Project name is MYAPP
>>>> I set the Context Root to app
>>>>
>>>> Publishing the project produces a directory named:
>>>> <webapp>/MYAPP
>>>>
>>>> Should not the directory name for the application follow the context root
>>>> name? I was expecting:
>>>>
>>>> <webapp>/app
>>>>
>>>
>>> For the Tomcat support, and probably others, the directory name is
>>> determined by the module's deploy-name as specified in the project's
>>> ".settings/org.eclipse.wst.common.component" file.
>> It seemed that the name should in the attribute "deploy-name". However when
>> I changed it, I could no longer add the project to the server.
>>
>> So it seems that the "Add/Remove Projects" in the Server matches the
>> deploy-name with existing project names.
>
> WTP continues to have issues if the project name and the deploy-name do not
> match. For example, see:
>
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=202541
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=154833
>
>>
>> Oh, and when I exited Eclipse with the file open, Ecplise crashed. No
>> messages, just a pop-up from windows stating that Eclipse abended.
>>
>
> Likely a JVM bug. You can check the "eclipse" directory to see if any crash
> file was written there that might provide clues.

Forgot to look.

I was left with an Eclipse which was "unstable". Every time I tried to
open the project, Project Explorer did not show the project. When I did
a Refresh, two copies of the project were displayed. A deploy only
created MYAPP\WEB-INF\lib. The lib had my external jar files, but the
rest were empty.

It looked like a real mis-match between config files which was not
being cleaned up.

So I ended up deleting Eclipse, then re-installing it. I also created a
new workspace, created a new Web project, then copied in my source.

Thanks for your help.

--
Wojtek :-)
Previous Topic:Getting "error parsing site stream"
Next Topic:Location of validation method for Context Root
Goto Forum:
  


Current Time: Thu Apr 25 07:52:39 GMT 2024

Powered by FUDForum. Page generated in 0.03041 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top