mvn clean install
mvn exec:java
mvn datanucleus:schema-create
mvn datanucleus:schema-delete
The same code is working with datanucleus version 5.x. Have created a separate branch named workingCase and attached the working screenshot as well
main branch: Java 17
workingCase branch: Java 8