java.lang.IllegalStateException: Either class [org.softwood.Author] is not a domain class or GORM has not been initialized correctly or has already been shutdown. Ensure GORM is loaded and configured correctly before calling any methods on a GORM entity.

tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    HibernateTestMixin exception with multiple dataSources (simple key value datastore works)

    GitHub | 1 year ago | zyro23
    java.lang.IllegalStateException: Either class [multidstest2.FooTwo] is not a domain class or GORM has not been initialized correctly or has already been shutdown. If you are unit testing your entities using the mocking APIs
  2. 0

    Spring Security Role Domain class not recognized by Grails

    Stack Overflow | 6 months ago | Vamsi Emani
    java.lang.IllegalStateException: Either class [com.documentstore.domain.Role] is not a domain class or GORM has not been initialized correctly or has already been shutdown. If you are unit testing your entities using the mocking APIs
  3. 0

    No longer able to configure alternative ID type (e.g. UUID) globally in Grails 3

    GitHub | 1 year ago | mjcmatrix
    java.lang.IllegalStateException: Either class [co.example.domain.User] is not a domain class or GORM has not been initialized correctly or has already been shutdown. If you are unit testing your entities using the mocking APIs
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Cannot run grails plugin after creation. Get ERROR o.s.boot.SpringApplication Application startup failed

    Stack Overflow | 3 weeks ago | Diego Sch
    java.lang.IllegalStateException: Either class [cscie56.ps5.User] is not a domain class or GORM has not been initialized correctly or has already been shutdown. Ensure GORM is loaded and configured correctly before calling any methods on a GORM entity.
  6. 0

    Grails 3 Geb functional tests with MongoDB

    GitHub | 1 year ago | Eylen
    java.lang.IllegalStateException: Either class [net.ds.gamileku.domain.Company] is not a domain class or GORM has not been initialized correctly or has already been shutdown. If you are unit testing your entities using the mocking APIs

    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.IllegalStateException

      Either class [org.softwood.Author] is not a domain class or GORM has not been initialized correctly or has already been shutdown. Ensure GORM is loaded and configured correctly before calling any methods on a GORM entity.

      at org.grails.datastore.gorm.GormEnhancer.stateException()
    2. Grails GORM
      GormEntity$Trait$Helper$save.call
      1. org.grails.datastore.gorm.GormEnhancer.stateException(GormEnhancer.groovy:387)
      2. org.grails.datastore.gorm.GormEnhancer.findInstanceApi(GormEnhancer.groovy:273)
      3. org.grails.datastore.gorm.GormEnhancer.findInstanceApi(GormEnhancer.groovy:270)
      4. org.grails.datastore.gorm.GormEntity$Trait$Helper.currentGormInstanceApi(GormEntity.groovy:1326)
      5. org.grails.datastore.gorm.GormEntity$Trait$Helper.save(GormEntity.groovy:151)
      6. org.grails.datastore.gorm.GormEntity$Trait$Helper$save.call(Unknown Source)
      6 frames
    3. Groovy
      AbstractCallSite.call
      1. org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
      2. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
      3. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:133)
      3 frames
    4. org.softwood
      Author.save
      1. org.softwood.Author.save(Author.groovy)
      2. org.softwood.Author.save(Author.groovy)
      2 frames
    5. Grails GORM
      GormEntity$save.call
      1. org.grails.datastore.gorm.GormEntity$save.call(Unknown Source)
      1 frame
    6. Groovy
      AbstractCallSite.call
      1. org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
      2. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
      3. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:125)
      3 frames
    7. test
      BootStrap.createDevData
      1. test.BootStrap.createDevData(BootStrap.groovy:21)
      1 frame
    8. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    9. Groovy
      AbstractCallSite.callCurrent
      1. org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)
      2. groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
      3. org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:384)
      4. groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1024)
      5. org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.callCurrent(PogoMetaClassSite.java:69)
      6. org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52)
      7. org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154)
      8. org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:158)
      8 frames
    10. test
      BootStrap$_closure1$_closure3$_closure4.doCall
      1. test.BootStrap$_closure1$_closure3$_closure4.doCall(BootStrap.groovy:10)
      2. test.BootStrap$_closure1$_closure3$_closure4.doCall(BootStrap.groovy)
      2 frames
    11. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    12. Groovy
      Closure.call
      1. org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)
      2. groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
      3. org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:294)
      4. groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1024)
      5. groovy.lang.Closure.call(Closure.java:414)
      6. groovy.lang.Closure.call(Closure.java:408)
      6 frames
    13. Grails
      Environment.executeForCurrentEnvironment
      1. grails.util.Environment$EnvironmentBlockEvaluator.execute(Environment.java:529)
      2. grails.util.Environment.executeForEnvironment(Environment.java:510)
      3. grails.util.Environment.executeForCurrentEnvironment(Environment.java:485)
      3 frames
    14. org.grails.web
      GrailsConfigUtils.executeGrailsBootstraps
      1. org.grails.web.servlet.boostrap.DefaultGrailsBootstrapClass.callInit(DefaultGrailsBootstrapClass.java:62)
      2. org.grails.web.servlet.context.GrailsConfigUtils.executeGrailsBootstraps(GrailsConfigUtils.java:65)
      2 frames
    15. org.grails.plugins
      BootStrapClassRunner.onStartup
      1. org.grails.plugins.web.servlet.context.BootStrapClassRunner.onStartup(BootStrapClassRunner.groovy:53)
      1 frame
    16. Grails
      GrailsApplicationPostProcessor.onApplicationEvent
      1. grails.boot.config.GrailsApplicationPostProcessor.onApplicationEvent(GrailsApplicationPostProcessor.groovy:256)
      2. grails.boot.config.GrailsApplicationPostProcessor.onApplicationEvent(GrailsApplicationPostProcessor.groovy)
      2 frames
    17. Spring Context
      AbstractApplicationContext.finishRefresh
      1. org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:167)
      2. org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139)
      3. org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:383)
      4. org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:337)
      5. org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:882)
      5 frames
    18. Spring Boot
      EmbeddedWebApplicationContext.finishRefresh
      1. org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:144)
      1 frame
    19. Spring Context
      AbstractApplicationContext.refresh
      1. org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:545)
      1 frame
    20. Spring Boot
      SpringApplication.run
      1. org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)
      2. org.springframework.boot.SpringApplication.refresh(SpringApplication.java:762)
      3. org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:372)
      4. org.springframework.boot.SpringApplication.run(SpringApplication.java:316)
      4 frames
    21. Grails
      GrailsApp$run.call
      1. grails.boot.GrailsApp.run(GrailsApp.groovy:83)
      2. grails.boot.GrailsApp.run(GrailsApp.groovy:388)
      3. grails.boot.GrailsApp.run(GrailsApp.groovy:375)
      4. grails.boot.GrailsApp$run.call(Unknown Source)
      4 frames
    22. Groovy
      AbstractCallSite.call
      1. org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
      2. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
      3. org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:133)
      3 frames
    23. test
      Application.main
      1. test.Application.main(Application.groovy:8)
      1 frame
    24. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    25. IDEA
      AppMain.main
      1. com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)
      1 frame