| Summary: | EJB Projects created by web Service Wizards does not add the ejbModule as a source folder | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [WebTools] WTP Webservices | Reporter: | Zina Mostafia <zina> | ||||||||||||||||
| Component: | jst.ws | Assignee: | Zina Mostafia <zina> | ||||||||||||||||
| Status: | RESOLVED FIXED | QA Contact: | Keith Chong <keith.chong.ca> | ||||||||||||||||
| Severity: | major | ||||||||||||||||||
| Priority: | P3 | CC: | ccc, keith.chong.ca, yenlu | ||||||||||||||||
| Version: | 3.0.4 | ||||||||||||||||||
| Target Milestone: | 3.0.5 P | ||||||||||||||||||
| Hardware: | PC | ||||||||||||||||||
| OS: | Windows XP | ||||||||||||||||||
| Whiteboard: | |||||||||||||||||||
| Attachments: |
|
||||||||||||||||||
|
Description
Zina Mostafia
Created attachment 144720 [details]
Patch to fix this problem
This should be re-routed to Web services (jst.ws). I also have a few concerns about the patch:
1) The fixEJBClassPath() method will run for any project created by the Web service wizard - regardless of whether or not it is an EJB project.
2) In fixEJBClassPath() itself, the "test" for whether or not a project is an EJB project is simply checking if there is a folder named "ejbModule" relative to the project root. This is too wide-ranging. You may be able to use a Java EE Tools utility method to check whether or not a project is an EJB project or there may be logic in the current command which gives you this information.
3) In the for loop inside the try-catch block of the fixEJBClassPath() method, there is a comparison of the current entry's path with projectRoot.append("ejbModule"). I think you can and should compute this before the try-catch block and store it in a variable for use in the comparison to improve performance.
Created attachment 144723 [details]
Revised Patch
Created attachment 144732 [details]
Patch with better performance
Created attachment 144862 [details]
Patch only for the 3.0.5 P stream
Thi patch is for the 3.0.5 stream, it is a different structure than the 3.1.x and 3.2. Please ignore the previouse patches , as this bugzilla would be only for the 3.0.5 P stream
Created attachment 144863 [details]
Fixed version number
Created attachment 144869 [details]
removed spaces change
Created attachment 144875 [details]
Updated copyright
Zina, looks good. I just updated the copyright header. Committed to R3_0_5_patches. Please clone this bug for the 3.1.x and 3.2 work. Bugs 286868 and 286874 were opened and fixes were applied to 3.2 and 3.1.x |