Hello,
Infrastructure:
Java 1.7
Eclipselink 2.4
JPA 2.0.1
Tomcat 7
Problem:
Activated Static weaving in my Application with Maven:
<build>
<plugins>
<plugin>
<artifactId>eclipselink-staticweave-maven-plugin</artifactId>
<groupId>au.com.alderaan</groupId>
<version>1.0.4</version>
<executions>
<execution>
<goals>
<goal>weave</goal>
</goals>
<phase>install</phase>
<configuration>
<logLevel>ALL</logLevel>
<includeProjectClasspath>true</includeProjectClasspath>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>eclipselink</artifactId>
<version>2.4.0</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
Superclass:
@MappedSuperclass
abstract
public
class DbObject
{
…
/** indicates if the object is valid (e.g. successfully loaded from database) or not **/
@Transient
private
boolean
valid =
true;
…
}
Class:
@Entity
public
class Category
extends DbObject
{
…
}
In My Manmged bean i’ve the following output with and without weaving:
1.
weaving
inactive
is Category valid?:true
2.
weaving
active
is Category valid?:false
the valid variable is never been touched!
What I the cause for the change of the valid varible when weaving is activated???
Thanks and regards steffen