-
-
Notifications
You must be signed in to change notification settings - Fork 970
Closed as not planned
Description
Expected Behavior
It should see demo
When add @ComponentScan to Application, it run success.
Grails support grails.spring.bean.packages, but I think this config for external packages, Grails App should auto scan package where Application belong.
import org.springframework.context.annotation.ComponentScan
@CompileStatic
@ComponentScan
class Application extends GrailsAutoConfiguration {
static void main(String[] args) {
GrailsApp.run(Application, args)
}
}
Actual Behaviour
Class: java.lang.NullPointerException
Message: null
Caused by: Cannot get property 'name' on null object
Steps To Reproduce
grails create-app com.rainboyan.demo.app-component-auto-scan-issue
grails run-app
open http://localhost:8080/demo/index
When render demo, it's OK!
Environment Information
Grails Version: 5.1.2
JVM Version: 11.0.14
OS: MacOS 11.6.4 M1
Example Application
https://github.com/rainboyan/grails-app-component-auto-scan-issue
Version
5.1.2
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels