Bug 395151 - EclipseLink static weaving triggers occurring too frequently
Summary: EclipseLink static weaving triggers occurring too frequently
Status: NEW
Alias: None
Product: Dali JPA Tools
Classification: WebTools
Component: JPA (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Neil Hauge CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2012-11-27 06:33 EST by Prashant Deva CLA
Modified: 2013-04-15 23:39 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Prashant Deva CLA 2012-11-27 06:33:21 EST
If I enable Dali's EclipseLink Static Weaving feature 'Weave classes on Build', it seems to be triggered almost every 2 seconds.
The triggering itself wouldnt be that much of an issue, but it seems that the way it does it is by launching an external jvm process which occupies the 'Console' view of Eclipse.
Thus if I am running tomcat or any other process, I cannot see the Console output, since the static weaver constantly keeps interrupting it, to the point where the other process's console output cannot be viewed at all.
Comment 1 Neil Hauge CLA 2012-11-28 17:55:41 EST
This does sound like a problem.  Perhaps we could direct this output to a separate console view, or perhaps set the logging such that only errors are logged to the console.

Possible candidate for Juno SR2.
Comment 2 Prashant Deva CLA 2012-11-28 17:57:41 EST
A much better solution IMHO would be to run the weaver only when the sources are actually changed, instead of constantly running at a fixed interval, kinda like how the eclipse incremental compiler works.
Comment 3 Neil Hauge CLA 2012-11-28 18:11:52 EST
The Static Weaver is actually a Builder, just like the Java Builder (incremental compiler), and should not run any more frequently than the incremental compile is running.  It certainly should not be running on a fixed interval.  There may be a bug where something is triggering it over and over.  A simple test on my end shows it running only when a resource change is committed to disk.

I will do some additional testing with Tomcat running.
Comment 4 Prashant Deva CLA 2012-11-28 20:38:42 EST
Neil,
 I can submit a Chronon recording of the regular, frequent build issue on my machine so you dont have to reproduce it on yours.
(http://chrononsystems.com/)

Please tell me the namespace of the code I need to record for this.
(eg. - org.eclipse.dali.**) ???
Comment 5 Neil Hauge CLA 2012-11-29 11:14:18 EST
(In reply to comment #4)
> Neil,
>  I can submit a Chronon recording of the regular, frequent build issue on my
> machine so you dont have to reproduce it on yours.
> (http://chrononsystems.com/)
> 
> Please tell me the namespace of the code I need to record for this.
> (eg. - org.eclipse.dali.**) ???

Not sure how fine grained of a namespace you are looking for, but org.eclipse.jpt.jpa.* would be a good but general start.

The Builder itself (which extends IncrementalProjectBuilder) is located in org.eclipse.jpt.jpa.eclipselink.core.builder.
Comment 6 Neil Hauge CLA 2013-01-04 17:04:52 EST
A workaround recommendation for this issue is to change the logging level in the Static Weaving preferences.  It can be set to OFF.