java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider org.hibernate.spatial.integration.SpatialIntegrator could not be instantiated

Stack Overflow | akash93 | 2 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Hibernate spatial ServiceConfigurationError - www.scriptscoop.net

    scriptscoop.net | 1 year ago
    java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider org.hibernate.spatial.integration.SpatialIntegrator could not be instantiated
  2. 0

    Hibernate spatial ServiceConfigurationError

    Stack Overflow | 2 years ago | akash93
    java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider org.hibernate.spatial.integration.SpatialIntegrator could not be instantiated
  3. 0

    Hi, I am using Hibernate 4.3.7 + Struts 2 + tomcat 7. I want to use EventListener Feature of Hibernate 4.3.7 For this I have tested the configuration with 2 project one is normal java project & other is dynamic web project. For Normal java project I created following struture: project src resources META-INF Services org.hibernate.integrator.spi.Integrator & in my [code] org.hibernate.integrator.spi.Integrator [/code] it contains Implementation class for EventListener Now for dynamic web project I created following Structure:- project src resources META-INF Services org.hibernate.integrator.spi.Integrator Web Content WEB-INF & I am initializing my Hibernate session factory from ServletContextListener one of them which I created for initializing resources. Now when start my tomcat server It gives me following error for Hibernate Session Factory Initialization [code]Error while initializing Hibernate Session factory,Reason : org.hibernate.integrator.spi.Integrator: Provider com.elitecore.nvsmx.policydesigner.listeners.PreInsertListeners could not be instantiated: java.lang.ClassCastException at com.elitecore.nvsmx.policydesigner.model.HibernateSessionFactory.buildSessionFactory(HibernateSessionFactory.java:74) at com.elitecore.nvsmx.policydesigner.listeners.NVSMXContextInitializer.contextInitialized(NVSMXContextInitializer.java:68) at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4887) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5381) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) Caused by: java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider com.elitecore.nvsmx.policydesigner.listeners.PreInsertListeners could not be instantiated: java.lang.ClassCastException at java.util.ServiceLoader.fail(ServiceLoader.java:207) at java.util.ServiceLoader.access$100(ServiceLoader.java:164) at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:353) at java.util.ServiceLoader$1.next(ServiceLoader.java:421) at org.hibernate.boot.registry.classloading.internal.ClassLoaderServiceImpl.loadJavaServices(ClassLoaderServiceImpl.java:339) at org.hibernate.integrator.internal.IntegratorServiceImpl.<init>(IntegratorServiceImpl.java:57) at org.hibernate.boot.registry.BootstrapServiceRegistryBuilder.build(BootstrapServiceRegistryBuilder.java:247) at org.hibernate.boot.registry.StandardServiceRegistryBuilder.<init>(StandardServiceRegistryBuilder.java:73) at com.elitecore.nvsmx.policydesigner.model.HibernateSessionFactory.buildSessionFactory(HibernateSessionFactory.java:59) ... 11 more Caused by: java.lang.ClassCastException at java.lang.Class.cast(Class.java:2990) at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:345) ... 17 more[/code] My question is :- (1). Whether my placement for [code]org.hibernate.integrator.spi.Integrator[/code] file is wrong. (2). Some configuration issue because My normal java project is working fine Thanks in Advance.....

    Hibernate JIRA | 2 years ago | aditya shrivastava
    java.lang.ClassCastException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Hibernate throws servlet service default exception when configuration instance is created

    Stack Overflow | 1 year ago | G.Srinivas Kishan
    java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider org.hibernate.search.hcore.impl.HibernateSearchIntegrator not found
  6. 0

    Hibernate auditing problem with 5.3.1

    openxava | 2 years ago | shankarcs1967
    java.util.ServiceConfigurationError: org.hibernate.integrator.spi.Integrator: Provider org.hibernate.envers.event.spi.EnversIntegrator not a subtype
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.ClassNotFoundException

    org.hibernate.service.spi.BasicServiceInitiator

    at java.net.URLClassLoader$1.run()
  2. Java RT
    ServiceLoader$1.next
    1. java.net.URLClassLoader$1.run(URLClassLoader.java:366)
    2. java.net.URLClassLoader$1.run(URLClassLoader.java:355)
    3. java.security.AccessController.doPrivileged(Native Method)
    4. java.net.URLClassLoader.findClass(URLClassLoader.java:354)
    5. java.lang.ClassLoader.loadClass(ClassLoader.java:425)
    6. sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
    7. java.lang.ClassLoader.loadClass(ClassLoader.java:358)
    8. java.lang.Class.getDeclaredConstructors0(Native Method)
    9. java.lang.Class.privateGetDeclaredConstructors(Class.java:2585)
    10. java.lang.Class.getConstructor0(Class.java:2885)
    11. java.lang.Class.newInstance(Class.java:350)
    12. java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:373)
    13. java.util.ServiceLoader$1.next(ServiceLoader.java:445)
    13 frames
  3. org.hibernate.boot
    ClassLoaderServiceImpl.loadJavaServices
    1. org.hibernate.boot.registry.classloading.internal.ClassLoaderServiceImpl.loadJavaServices(ClassLoaderServiceImpl.java:339)
    1 frame
  4. Hibernate
    IntegratorServiceImpl.<init>
    1. org.hibernate.integrator.internal.IntegratorServiceImpl.<init>(IntegratorServiceImpl.java:57)
    1 frame
  5. org.hibernate.boot
    StandardServiceRegistryBuilder.<init>
    1. org.hibernate.boot.registry.BootstrapServiceRegistryBuilder.build(BootstrapServiceRegistryBuilder.java:247)
    2. org.hibernate.boot.registry.StandardServiceRegistryBuilder.<init>(StandardServiceRegistryBuilder.java:73)
    2 frames
  6. com.handyhome.service
    App.main
    1. com.handyhome.service.database.HibernateUtil.buildSessionFactory(HibernateUtil.java:24)
    2. com.handyhome.service.database.HibernateUtil.getSessionFactory(HibernateUtil.java:39)
    3. com.handyhome.service.database.App.main(App.java:30)
    3 frames
  7. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    4. java.lang.reflect.Method.invoke(Method.java:606)
    4 frames
  8. IDEA
    AppMain.main
    1. com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)
    1 frame