| Summary: | The execution of an AGR test suite will hang if the plug-in contains many dependencies | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | amehrega | ||||||
| Component: | TPTP | Assignee: | Joe Toomey <jptoomey> | ||||||
| Status: | CLOSED FIXED | QA Contact: | |||||||
| Severity: | major | ||||||||
| Priority: | P1 | CC: | cbmcgee, dmorris, lizdancy, paulslau | ||||||
| Version: | unspecified | Keywords: | plan | ||||||
| Target Milestone: | --- | Flags: | paulslau:
review+
|
||||||
| Hardware: | PC | ||||||||
| OS: | Windows XP | ||||||||
| Whiteboard: | |||||||||
| Bug Depends on: | |||||||||
| Bug Blocks: | 188290 | ||||||||
| Attachments: |
|
||||||||
|
Description
amehrega
Since Joe is out of office today, deferring to 4.4 and increasing the priority to P1. This defect is #2 on my priority list (behind https://bugs.eclipse.org/bugs/show_bug.cgi?id=145115 ), so it will definitely get in for 4.4. Unable to contain in i1, need to push to i2. The priority of this defect has not changed, but it is being deferred to i3 to allow for other work with UI changes that need to be complete in i2. This defect is a candidate for deferral from the 4.4 release. If the originator has opposition, please provide an argument against this deferral. Since I boldly announced in comment #2 that this would definitely get in for 4.4, I am reassigning this defect back to myself. Targetting 4.4 DuWayne investigated this defect in i3, and with some help from Samson, determined that the failure was caused by the classpath variable becoming to long, resulting in an error launching the process (from the windows API.) That will remain an issue for non-plugin based test types, but in the case of AGR (and also JUnit Plugin), the dependant plugins that are not part of the workspace don't need to be put on the classpath at all -- they will be loaded by the eclipse classloader from the target workbench location. For that same reason, these plugins also need not be deployed. I debugged into the deployment code and found that there was already special code added to handle this case for JUnit plugin tests (in the ArtifactUtil class). A simple fix to also handle AGR tests in the same manner fixes this problem, though it's somewhat inelegant. A more elegant solution would be to slightly refactor the JavaExecutionDeployment adapter, and then extend it with a WorkbenchDeploymentAdapater (that would then be regsietered as the deployment adapter for both JUnit plugin and AGR test types.) The simple fix I am attaching here is very low risk, and will address the problem for 4.4. I will file a separate defect to refactor the deployment adapters in 4.5. Created attachment 68011 [details]
Patch to exclude plugins from classpath and deployment consideration for AGR tests
Created attachment 68012 [details]
mylar/context/zip
(In reply to comment #7) > I will > file a separate defect to refactor the deployment adapters in 4.5. https://bugs.eclipse.org/bugs/show_bug.cgi?id=188290 (In reply to comment #8) > Created an attachment (id=68011) [details] > Patch to exclude plugins from classpath and deployment consideration for AGR > tests > Question: Would this fix also apply for the other test types as well? Answer: No -- the fix is to prevent us from deploying, or including on the classpath, jar files from workbench plugins. If you consider two different types of java based tests, those that execute within a workbench and those that don't, only for the former can we get away with not deploying and putting on the classpath. This is b/c the jar files are already in the target workbench, and they'll be loaded by the eclipse classloaders (meaning our classpath changes were ignored anyway.) For non-workbench based test types (like normal JUnit), we still need to deploy those jars and put them on the classpath. The code already had this exclusion for JUnit plugin test type. I just added code to make the same change for AGR. Patch reviewed. Please make a request to the Test Project mailing list for this defect. Once the fix is integrated, please add a comment to this defect containing the build ID of the driver used to verify the fix before marking the defect as fixed. Fix delivered. Will validate and close with next build. Adding hours worked for DuWayne and I Validated in TPTP-4.4.0-200705250100 |