Affects Version/s: 2.2.4u2
Fix Version/s: None
Java 7 Update 10 on Windows 7
The attached ZIP contains a Maven project with two test cases.
For this issue, the classes, resources and test case in package com.jaxbtest.java7.bug1 are relevant.
1.) make sure your current test environment is Java 7 Update 10
For Maven 2.2.1 on Windows it means:
a) set the JAVA_HOME variable to your Java 7 Update 10 JDK installation directory.
b) prepend %JAVA_HOME%\bin to your Path.
2.) run the unit tests in the project
For Maven 2.2.1 it means:
a) execute "mvn test" in the project root directory
b) examine test result (look at ./target/surefire-reports/com.jaxbtest.java7.bug1.ReportFieldDefTestCase.txt)
It should fail with a NullPointerException.
You can import the project into Eclipse (m2e required!) for debugging.
It works both with Java 6 Update 35 and JAXB 2.2.6 (may be fixed with
com.jaxbtest.java7.bug1.ReportFieldDefTestCas is the entry point for the test.
ReportFieldDef is the XmlRootElement. It has a list of SimpleTypeField and ComplexTypeField. SimpleTypeField references a TextFormatImpl via interface and @XmlIDREF. TextFormatImpl has an id field with @XmlID.
Unmarshalling an example document succeeds, but marshalling it back to a file fails then.