Reputation: 71
I have IBM Websphere 8.5.5.10. and hibernate-jpa-2.0-api-1.0.0.Final.jar is a default jar. However, I want to use a newer version -> hibernate-jpa-2.1-api-1.0.0.Final.jar. I set "Classes loaded with local class loader first (parent last)" and "Single class loader for application". In spite of that, I get the following error:
Caused by: java.lang.NoSuchMethodError: javax/persistence/Table.indexes()[Ljavax/persistence/Index;
...
Delegation Mode: PARENT_FIRST).
at org.hibernate.cfg.annotations.EntityBinder.processComplementaryTableDefinitions(EntityBinder.java:973) ~[hibernate-core-4.3.11.Final.jar:4.3.11.Final]
...
Looks like this error occurs because the old/parent's jar is loaded first. Also. please notice that Delegation Mode is PARENT_FIRST although I defined different. And I checked many times my classloader definition, restarted the application and even the server and always the same:(
Can someone help, please?
Upvotes: 1
Views: 2189