Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 341193 - intermittent JUnit failures on JSP tests
Summary: intermittent JUnit failures on JSP tests
Status: CLOSED FIXED
Alias: None
Product: MoDisco
Classification: Modeling
Component: Infrastructure (show other bugs)
Version: 0.9.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 0.9.0 M7   Edit
Assignee: Nicolas Bros CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 341596
Blocks:
  Show dependency tree
 
Reported: 2011-03-29 03:44 EDT by Nicolas Bros CLA
Modified: 2011-08-18 08:01 EDT (History)
2 users (show)

See Also:
nicolas.bros: indigo+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas Bros CLA 2011-03-29 03:44:35 EDT
I've seen the following two JSP tests get stuck randomly, causing a build timeout:
org.eclipse.modisco.jee.jsp.discoverer.tests.compatibility.TestHtml.test1
org.eclipse.modisco.jee.jsp.discoverer.tests.compatibility.TestJsp.test1

For TestHtml.test1, this might be due to the fact that the JSP references an external DTD:
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
So, network issues on the build server may cause this.

But for TestJsp.test1, I don't see any external reference in "jspElement.jsp".
Comment 1 Nicolas Bros CLA 2011-04-01 04:46:14 EDT
(In reply to comment #0)
> For TestHtml.test1, this might be due to the fact that the JSP references an
> external DTD:
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
> So, network issues on the build server may cause this.

I have verified on my PC using Fiddler, and launching the JUnit test doesn't seem to cause any network access. But this might be because it's already cached on my PC?
Comment 2 Nicolas Bros CLA 2011-04-01 05:43:15 EDT
With these modifications, the code running at the time of the timeout appears in the log. It appears to be in:

org.eclipse.acceleo.common.utils.CompactLinkedHashSet.deleteIndex(int index)

Where a while loop is running until a condition is met. And apparently this condition is never met, causing an infinite loop.

The call to the Acceleo code seems to be caused by a workspace change notification while deleting a Resource in the test.
Comment 3 Nicolas Bros CLA 2011-04-05 05:29:12 EDT
I haven't seen any JSP test timeouts since I switched to the nightly Acceleo update site, which incorporates a supposed fix.
So, I'm marking this bug as fixed.
Comment 4 Hugo Bruneliere CLA 2011-08-18 08:01:37 EDT
Bug solved.