我正在尝试通过 Maven 创建 GAE 项目,但我遇到了持久性库配置的问题。我尝试包含不同的依赖项并指定不同的范围,但我总是遇到一些错误,例如:
java.lang.NoClassDefFoundError: org/datanucleus/ObjectManagerFactoryImpl
.
java.lang.NoClassDefFoundError: javax/persistence/spi/ProviderUtil
.
java.lang.NoClassDefFoundError: org/datanucleus/ClassLoaderResolver
.
Invocation of init method failed; nested exception is javax.persistence.PersistenceException: No persistence providers available for "transactions-optional" after trying the following discovered implementations: org.datanucleus.api.jpa.PersistenceProviderImpl