You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Example that reproduces the problem uploaded to Github
Full description of the issue provided (see below)
Steps to Reproduce
Create a grails app
Install spring security core plugin compile 'org.grails.plugins:spring-security-core:4.0.0'
Add "tablePerHierarchy false" to User class
Extend another class from User
Expected Behaviour
It should create a separate table for the extended class.
Actual Behaviour
Application doesn't start and throws:
Disconnected from the target VM, address: '127.0.0.1:39131', transport: 'socket' 2020-05-08 19:15:10.534 ERROR --- [ restartedMain] o.s.b.web.embedded.tomcat.TomcatStarter : Error starting Tomcat context. Exception: org.springframework.beans.factory.BeanCreationException. Message: Error creating bean with name 'authenticationProcessingFilterDeregistrationBean': Cannot resolve reference to bean 'authenticationProcessingFilter' while setting bean property 'filter'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationProcessingFilter': Cannot resolve reference to bean 'authenticationManager' while setting bean property 'authenticationManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationManager': Cannot resolve reference to bean 'daoAuthenticationProvider' while setting constructor argument with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'daoAuthenticationProvider': Cannot resolve reference to bean 'userDetailsService' while setting bean property 'userDetailsService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'userDetailsService': Unsatisfied dependency expressed through method 'setTargetDatastore' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateDatastore': Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.grails.orm.hibernate.HibernateDatastore]: Constructor threw exception; nested exception is java.lang.NullPointerException 2020-05-08 19:15:10.584 ERROR --- [ restartedMain] o.s.boot.SpringApplication : Application run failed
Steps to Reproduce
compile 'org.grails.plugins:spring-security-core:4.0.0'
Expected Behaviour
It should create a separate table for the extended class.
Actual Behaviour
Application doesn't start and throws:
Disconnected from the target VM, address: '127.0.0.1:39131', transport: 'socket' 2020-05-08 19:15:10.534 ERROR --- [ restartedMain] o.s.b.web.embedded.tomcat.TomcatStarter : Error starting Tomcat context. Exception: org.springframework.beans.factory.BeanCreationException. Message: Error creating bean with name 'authenticationProcessingFilterDeregistrationBean': Cannot resolve reference to bean 'authenticationProcessingFilter' while setting bean property 'filter'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationProcessingFilter': Cannot resolve reference to bean 'authenticationManager' while setting bean property 'authenticationManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationManager': Cannot resolve reference to bean 'daoAuthenticationProvider' while setting constructor argument with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'daoAuthenticationProvider': Cannot resolve reference to bean 'userDetailsService' while setting bean property 'userDetailsService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'userDetailsService': Unsatisfied dependency expressed through method 'setTargetDatastore' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateDatastore': Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.grails.orm.hibernate.HibernateDatastore]: Constructor threw exception; nested exception is java.lang.NullPointerException 2020-05-08 19:15:10.584 ERROR --- [ restartedMain] o.s.boot.SpringApplication : Application run failed
Complete stacktrace
The problem occurs only when trying to extend from the User class, it works ok with any other class.
Environment Information
Example Application
Github repository with example that reproduces the issue:
https://github.com/richardvil/spring-security-core-user-hierarchy-error
The text was updated successfully, but these errors were encountered: