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

Bug 333822

Summary: EJBHelper has unused variables treated differently with new compiler
Product: [WebTools] WTP EJB Tools Reporter: David Williams <david_williams>
Component: jst.ejbAssignee: David Williams <david_williams>
Status: RESOLVED FIXED QA Contact: Kaloyan Raev <kaloyan>
Severity: normal    
Priority: P3 CC: ccc
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on:    
Bug Blocks: 333678    
Attachments:
Description Flags
patch to remove unused variables none

Description David Williams CLA 2011-01-09 22:58:28 EST
Created attachment 186347 [details]
patch to remove unused variables

related to bug 333678 ... 

EJBHelper in org.eclipse.jst.j2ee.ejb has an unused variable, executionMap, in loadChildren map. Recent changes in JDT compiler now correct detect this case, and remove it from the byte codes. 

Hence, that makes the bundle "different" even though version and qualifier are the same. 

It appears 'executionMap' was used in some code that is now commented out. If it is suspected that commented out code might be restored soon, this might be a case where it'd be more appropriate to re-tag the bundle, so its differences show up correct in versioning. 

However, if the unused variables are commented out for now, then same change could be made in maintenance stream too ... if it is easier to "leave the same" in both streams ... there is apparently no change from 'head' stream and 'maintenance' stream. 

The attached patch has the unused variables commented out, and the bundles manifest service field incremented by +1. (Should probably be +100, if committed only to head).
Comment 1 David Williams CLA 2011-02-26 19:41:44 EST
I've applied the patch and released for M6. 

I noticed the service field had been incremented to 402 already, but the 32 maintenance branch has 401, so 402 would be incorrect ... I think should have been +100 from maintenance. So, I changed to 502. 

Not sure why had been incremented to 402 ... if it was to "fix" this problem, or just to avoid being on versioning report. So, feel free to revert my fix of commenting out the unused variables, if that wasn't desired.
Comment 2 Carl Anderson CLA 2011-05-12 14:00:59 EDT
*** Bug 335075 has been marked as a duplicate of this bug. ***