Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 353941

Summary: Provide api for determining web context root providing related ear project
Product: [WebTools] WTP Java EE Tools Reporter: Chuck Bridgham <cbridgha>
Component: jst.j2eeAssignee: Chuck Bridgham <cbridgha>
Status: RESOLVED FIXED QA Contact: Chuck Bridgham <cbridgha>
Severity: enhancement    
Priority: P3 CC: ccc
Version: 3.2.4Flags: ccc: review+
Target Milestone: 3.2.5   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on:    
Bug Blocks: 369017    
Attachments:
Description Flags
patch
none
new patch with junit none

Description Chuck Bridgham CLA 2011-08-04 17:21:18 EDT
No API currently exists on "WebUtilities" class to return the web context root based on either the component property if standalone, or via the Ear module's property.
Comment 1 Chuck Bridgham CLA 2011-08-04 17:23:42 EDT
Created attachment 200945 [details]
patch
Comment 2 Carl Anderson CLA 2011-08-08 11:34:38 EDT
Chuck, in the case of an EAR 5 or EAR 6 where there is no application.xml, the context root of a web module is the module name.  Have you tested that scenario with this API?
Comment 3 Chuck Bridgham CLA 2011-08-30 15:51:58 EDT
I need to make sure... but actually.. because there is a property in the component model for context root... if nothing is defined by the ear...  then the war's property is used.
Comment 4 Chuck Bridgham CLA 2011-09-07 15:27:38 EDT
Created attachment 202929 [details]
new patch with junit
Comment 5 Chuck Bridgham CLA 2011-09-07 15:28:44 EDT
All scenarios check out....    included in ear or now... Ear has DD or not  etc...
Comment 6 Chuck Bridgham CLA 2011-09-19 11:10:41 EDT
Code dropped