cancel
Showing results for 
Search instead for 
Did you mean: 

CF - Java Application Fails With UnsupportedClassVersionError

former_member788992
Discoverer
0 Kudos

Hello Guys,

I am facing an issue in a JPA project which uses eclipse persistence. To give the background, this is an application which was developed in Neo, now currently getting migrated to Cloud Foundry.

When we try to run the application, we are getting the error as mentioned at the bottom of this question.

I have tried to specify the version in manifest.yml in the environment variables JBP_CONFIG_OPEN_JDK_JRE to 1.8 and 11 also without any luck. Have also tried degrading the version of eclipselink and javax.persistence in the POM as well. Any help/lead is highly appreciated.

Exception Message:

org/eclipse/persistence/jpa/PersistenceProvider has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0 (unable to load class [org.eclipse.persistence.jpa.PersistenceProvider])

Stack Trace:

java.lang.UnsupportedClassVersionError: org/eclipse/persistence/jpa/PersistenceProvider has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0 (unable to load class [org.eclipse.persistence.jpa.PersistenceProvider])","\tat org.apache.catalina.loader.WebappClassLoaderBase.findClassInternal(WebappClassLoaderBase.java:2341)","\tat org.apache.catalina.loader.WebappClassLoaderBase.findClass(WebappClassLoaderBase.java:810)","\tat org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1293)","\tat org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1141)","\tat java.lang.Class.forName0(Native Method)","\tat java.lang.Class.forNameFW(Class.java:362)","\tat java.lang.Class.forName(Class.java:355)","\tat java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:370)","\tat java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)","\tat java.util.ServiceLoader$1.next(ServiceLoader.java:480)","\tat javax.persistence.spi.PersistenceProviderResolverHolder$DefaultPersistenceProviderResolver.getPersistenceProviders(PersistenceProviderResolverHolder.java:111)","\tat javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:76)","\tat com.arteriatech.finessart.subscription.Material.init(Material.java:64)","\tat javax.servlet.GenericServlet.init(GenericServlet.java:143)","\tat org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1106)","\tat org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1063)","\tat org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:747)","\tat org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:116)","\tat org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:90)","\tat org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:481)","\tat com.sap.xs.security.container.XSSecurityAuthenticator.invoke(XSSecurityAuthenticator.java:62)","\tat org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:130)","\tat com.sap.xs.java.valves.ErrorReportValve.invoke(ErrorReportValve.java:68)","\tat ch.qos.logback.access.tomcat.LogbackValve.invoke(LogbackValve.java:256)","\tat org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)","\tat com.sap.xs.security.TenantIdValve.invoke(TenantIdValve.java:33)","\tat com.sap.xs.security.UserInfoValve.invoke(UserInfoValve.java:18)","\tat com.sap.xs.statistics.tomcat.valve.RequestTracingValve.invoke(RequestTracingValve.java:43)","\tat com.sap.xs.logging.catalina.RuntimeInfoValve.invoke(RuntimeInfoValve.java:42)","\tat org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:765)","\tat org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)","\tat org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:390)","\tat org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:63)","\tat org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:928)","\tat org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1794)","\tat org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)","\tat org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)","\tat org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)","\tat org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)","\tat java.lang.Thread.run(Thread.java:838)

Thanks,

Sujai Kaarthik B

Accepted Solutions (0)

Answers (0)