Skip to content

Commit

Permalink
TransformerFactory not "used" with GraalVM for JDK 21 (23.1)
Browse files Browse the repository at this point in the history
javax.xml.transform.TransformerFactory does not appear as used in
GraalVM for JDK 21's reports due to inlining.

Closes quarkusio#35676
  • Loading branch information
zakkak committed Sep 6, 2023
1 parent 69b0e01 commit 1579d17
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ public void verifyJDKXMLParsersAreIncluded() {
report.assertContains(org.postgresql.jdbc.PgSQLXML.class);
report.assertContains(UUIDJdbcType.class);

//And finally verify we included the JDK XML by triggering
//io.quarkus.jdbc.postgresql.runtime.graal.SQLXLMFeature
report.assertContains(javax.xml.transform.TransformerFactory.class);
// And finally verify we included "com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl" which is
// the fallback implementation class name used in javax.xml.transform.TransformerFactory.newInstance()
// whose invocation gets triggered when io.quarkus.jdbc.postgresql.runtime.graal.SQLXLMFeature is enabled
report.assertContains("com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl");
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@ public void verifyJdkXmlParsersHavebeenEcludedFromNative() {
report.assertContains(org.postgresql.jdbc.PgSQLXML.class);
report.assertContains(UUIDJdbcType.class);

//And finally verify we managed to exclude the JDK XML because of having hinted the analysis
//(See io.quarkus.jdbc.postgresql.runtime.graal.SQLXLMFeature )
// And finally verify we exclude "com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl" which is
// the fallback implementation class name used in javax.xml.transform.TransformerFactory.newInstance()
// whose invocation gets triggered when io.quarkus.jdbc.postgresql.runtime.graal.SQLXLMFeature is enabled
report.assertContainsNot(javax.xml.transform.TransformerFactory.class);
report.assertContainsNot("com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl");
}

}

0 comments on commit 1579d17

Please sign in to comment.