What is `-plain.war` in grails 5 `build/libs/`? - grails

I use grails 5 official start to create project:
curl -O https://start.grails.org/restPproject.zip -d profile=rest-api
unzip restPproject.zip
cd restPproject
chmod +x gradlew grailsw
sed -i 's/org.grails.plugins:views-gradle:2.1.0/org.grails.plugins:views-gradle:2.1.1/' build.gradle
./grailsw war
And I find when I use ./grails war will generate 2 war files in build/libs/:
$ ls build/libs/
restPproject-0.1-plain.war restPproject-0.1.war
What is -plain.war ? And how could I build a standalone runnable war and can be deploy to a servlet container like Jetty at one time build?
I find both -plain.war and .war cannot run under Jetty 10:
$ cp build/libs/restPproject-0.1-plain.war webapps/ROOT.war
$ docker run --rm -p 8080:8080 -v `pwd`/webapps:/var/lib/jetty/webapps/ jetty:10-jre11-slim
2021-12-03 10:55:34.467:WARN :oejw.WebAppContext:main: Failed startup of context o.e.j.w.WebAppContext#6150c3ec{ROOT.war,/,file:///tmp/jetty/jetty-0_0_0_0-8080-ROOT_war-_-any-7013661700671242562/webapp/,UNAVAILABLE}{/var/lib/jetty/webapps/ROOT.war}
java.util.ServiceConfigurationError: org.apache.juli.logging.Log: org.eclipse.jetty.apache.jsp.JuliLog not a subtype
at java.base/java.util.ServiceLoader.fail(Unknown Source)
at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(Unknown Source)
at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(Unknown Source)
at java.base/java.util.ServiceLoader$2.hasNext(Unknown Source)
at java.base/java.util.ServiceLoader$3.hasNext(Unknown Source)
at org.apache.juli.logging.LogFactory.<init>(LogFactory.java:94)
at org.apache.juli.logging.LogFactory.<clinit>(LogFactory.java:69)
at org.apache.tomcat.websocket.WsWebSocketContainer.<init>(WsWebSocketContainer.java:92)
at org.apache.tomcat.websocket.server.WsServerContainer.<init>(WsServerContainer.java:83)
at org.apache.tomcat.websocket.server.WsSci.init(WsSci.java:137)
at org.apache.tomcat.websocket.server.WsSci.onStartup(WsSci.java:49)
at org.eclipse.jetty.servlet.ServletContainerInitializerHolder.doStart(ServletContainerInitializerHolder.java:148)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
at org.eclipse.jetty.servlet.ServletContextHandler$ServletContainerInitializerStarter.doStart(ServletContextHandler.java:1660)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:369)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1304)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:895)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:306)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:532)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:40)
at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:183)
at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:516)
at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:151)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:186)
at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:456)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:58)
at org.eclipse.jetty.util.Scanner$DiscreteListener.pathAdded(Scanner.java:282)
at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:836)
at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:802)
at org.eclipse.jetty.util.Scanner.scan(Scanner.java:709)
at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:597)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:158)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:605)
at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:246)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.server.Server.start(Server.java:469)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:89)
at org.eclipse.jetty.server.Server.doStart(Server.java:414)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.xml.XmlConfiguration.lambda$main$4(XmlConfiguration.java:1867)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1810)
2021-12-03 10:55:34.491:INFO :oejs.AbstractConnector:main: Started ServerConnector#77a98a6a{HTTP/1.1, (http/1.1)}{0.0.0.0:8080}
$ cp build/libs/restPproject-0.1.war webapps/ROOT.war
$ docker run --rm -p 8080:8080 -v `pwd`/webapps:/var/lib/jetty/webapps/ jetty:10-jre11-slim
2021-12-03 10:56:21.615:WARN :oejw.WebAppContext:main: Failed startup of context o.e.j.w.WebAppContext#6150c3ec{ROOT.war,/,file:///tmp/jetty/jetty-0_0_0_0-8080-ROOT_war-_-any-15153155136947335580/webapp/,UNAVAILABLE}{/var/lib/jetty/webapps/ROOT.war}
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tomcatServletWebServerFactory' defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/ServletWebServerFactoryConfiguration$EmbeddedTomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory]: Factory method 'tomcatServletWebServerFactory' threw exception; nested exception is java.util.ServiceConfigurationError: org.apache.juli.logging.Log: org.eclipse.jetty.apache.jsp.JuliLog not a subtype
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:658)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:638)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1352)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1195)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:582)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:542)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:754)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:434)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:338)
at grails.boot.GrailsApp.run(GrailsApp.groovy:99)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:175)
at org.grails.boot.context.web.GrailsAppServletInitializer.createRootApplicationContext(GrailsAppServletInitializer.groovy:57)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:97)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
at org.eclipse.jetty.servlet.ServletContainerInitializerHolder.doStart(ServletContainerInitializerHolder.java:148)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
at org.eclipse.jetty.servlet.ServletContextHandler$ServletContainerInitializerStarter.doStart(ServletContextHandler.java:1660)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:369)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1304)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:895)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:306)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:532)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:40)
at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:183)
at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:516)
at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:151)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:186)
at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:456)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:58)
at org.eclipse.jetty.util.Scanner$DiscreteListener.pathAdded(Scanner.java:282)
at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:836)
at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:802)
at org.eclipse.jetty.util.Scanner.scan(Scanner.java:709)
at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:597)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:158)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:605)
at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:246)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.server.Server.start(Server.java:469)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:89)
at org.eclipse.jetty.server.Server.doStart(Server.java:414)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.xml.XmlConfiguration.lambda$main$4(XmlConfiguration.java:1867)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1810)
Caused by:
org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory]: Factory method 'tomcatServletWebServerFactory' threw exception; nested exception is java.util.ServiceConfigurationError: org.apache.juli.logging.Log: org.eclipse.jetty.apache.jsp.JuliLog not a subtype
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:638)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1352)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1195)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:582)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:542)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:754)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:434)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:338)
at grails.boot.GrailsApp.run(GrailsApp.groovy:99)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:175)
at org.grails.boot.context.web.GrailsAppServletInitializer.createRootApplicationContext(GrailsAppServletInitializer.groovy:57)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:97)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
at org.eclipse.jetty.servlet.ServletContainerInitializerHolder.doStart(ServletContainerInitializerHolder.java:148)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
at org.eclipse.jetty.servlet.ServletContextHandler$ServletContainerInitializerStarter.doStart(ServletContextHandler.java:1660)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:369)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1304)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:895)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:306)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:532)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:40)
at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:183)
at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:516)
at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:151)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:186)
at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:456)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:58)
at org.eclipse.jetty.util.Scanner$DiscreteListener.pathAdded(Scanner.java:282)
at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:836)
at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:802)
at org.eclipse.jetty.util.Scanner.scan(Scanner.java:709)
at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:597)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:158)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:605)
at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:246)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.server.Server.start(Server.java:469)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:89)
at org.eclipse.jetty.server.Server.doStart(Server.java:414)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.xml.XmlConfiguration.lambda$main$4(XmlConfiguration.java:1867)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1810)
Caused by:
java.util.ServiceConfigurationError: org.apache.juli.logging.Log: org.eclipse.jetty.apache.jsp.JuliLog not a subtype
at java.base/java.util.ServiceLoader.fail(Unknown Source)
at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(Unknown Source)
at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(Unknown Source)
at java.base/java.util.ServiceLoader$2.hasNext(Unknown Source)
at java.base/java.util.ServiceLoader$3.hasNext(Unknown Source)
at org.apache.juli.logging.LogFactory.<init>(LogFactory.java:94)
at org.apache.juli.logging.LogFactory.<clinit>(LogFactory.java:69)
at org.apache.catalina.core.AprLifecycleListener.<clinit>(AprLifecycleListener.java:46)
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.getDefaultLifecycleListeners(TomcatServletWebServerFactory.java:172)
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.<init>(TomcatServletWebServerFactory.java:120)
at org.springframework.boot.autoconfigure.web.servlet.ServletWebServerFactoryConfiguration$EmbeddedTomcat.tomcatServletWebServerFactory(ServletWebServerFactoryConfiguration.java:76)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:638)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1352)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1195)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:582)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:542)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:754)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:434)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:338)
at grails.boot.GrailsApp.run(GrailsApp.groovy:99)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:175)
at org.grails.boot.context.web.GrailsAppServletInitializer.createRootApplicationContext(GrailsAppServletInitializer.groovy:57)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:97)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
at org.eclipse.jetty.servlet.ServletContainerInitializerHolder.doStart(ServletContainerInitializerHolder.java:148)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
at org.eclipse.jetty.servlet.ServletContextHandler$ServletContainerInitializerStarter.doStart(ServletContextHandler.java:1660)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:369)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1304)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:895)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:306)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:532)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:40)
at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:183)
at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:516)
at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:151)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:186)
at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:456)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:58)
at org.eclipse.jetty.util.Scanner$DiscreteListener.pathAdded(Scanner.java:282)
at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:836)
at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:802)
at org.eclipse.jetty.util.Scanner.scan(Scanner.java:709)
at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:597)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:158)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:605)
at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:246)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:171)
at org.eclipse.jetty.server.Server.start(Server.java:469)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:89)
at org.eclipse.jetty.server.Server.doStart(Server.java:414)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
at org.eclipse.jetty.xml.XmlConfiguration.lambda$main$4(XmlConfiguration.java:1867)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1810)
2021-12-03 10:56:21.658:INFO :oejs.AbstractConnector:main: Started ServerConnector#85b9f9c{HTTP/1.1, (http/1.1)}{0.0.0.0:8080}
Thanks.

In Grails 5, there 3 ways to package your app: (1) grails package, (2) ./gradlew assemble and (3) grails war. both of them can make 2 files: myapp-0.1.war and myapp-0.1-plain.war. (Grails Docs - 21 Deployment)
the .war file is completely consistent in the 3 ways, and its a Runnable WAR, so you can run it like this: java -jar build/libs/myapp-0.1.war.
the -plain.war is a little different, it is consistent in the way of (1) and (3), but in the way of (2), a micronaut-inject-groovy-*.jar is added in WEB-INF/lib, and it is NOT a Runable WAR, it is used for Servlet container deployment, such as Tomcat.
the difference between .war and -plain.war is that there are used for different purposes. there is a spring-boot-jarmode-layertools-*.jar with configuration file layers.idx in .war for easier Docker Deployment than before (manual unpacking is no longer required), for more details see the spring-boot docs.(1.2. Layering Docker Images)

Related

A job instance already exists and is complete for parameters={-spring.cloud.task.executionid=2}. If you want to run this job again, change the parame

I am working on Spring Cloud Data Flow and Spring Batch by taking a reference from https://github.com/spring-cloud/spring-cloud-task/tree/master/spring-cloud-task-samples.
I'm executing the batch-job and when executed this example two times, on 2nd time I observed the error, however for the first time it worked fine.
I started the spring-cloud-dataflow-server-local server using below commands and it created all metadata for me- highlighted in yellow.
Error:
exitCode=null, taskName='batch-job', startTime=Fri Apr 17 18:21:36 IST 2020, endTime=null, exitMessage='null', externalExecutionId='null', errorMessage='null', arguments=[--spring.cloud.task.executionid=3]}
2020-04-17 18:21:36.312 INFO 4988 --- [ main] com.example.BatchJobApplication : Started BatchJobApplication in 3.661 seconds (JVM running for 4.407)
2020-04-17 18:21:36.312 INFO 4988 --- [ main] o.s.b.a.b.JobLauncherCommandLineRunner : Running default command line with: [--spring.cloud.task.executionid=3]
2020-04-17 18:21:36.396 DEBUG 4988 --- [ main] o.s.c.t.r.support.SimpleTaskRepository : Updating: TaskExecution with executionId=3 with the following {exitCode=1, endTime=Fri Apr 17 18:21:36 IST 2020, exitMessage='null', errorMessage='java.lang.IllegalStateException: Failed to execute CommandLineRunner
at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:787)
at org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:768)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:322)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215)
at com.example.BatchJobApplication.main(BatchJobApplication.java:14)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:51)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52)
Caused by: org.springframework.batch.core.repository.JobInstanceAlreadyCompleteException: A job instance already exists and is complete for parameters={-spring.cloud.task.executionid=3}. If you want to run this job again, change the parameters.
at org.springframework.batch.core.repository.support.SimpleJobRepository.createJobExecution(SimpleJobRepository.java:131)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:366)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:118)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.batch.core.repository.support.AbstractJobRepositoryFactoryBe'}
2020-04-17 18:21:36.404 INFO 4988 --- [ main] ConditionEvaluationReportLoggingListener :
java -jar spring-cloud-dataflow-server-local-1.7.4.RELEASE.jar
On the second time Task Execution, I get the below error.
java.lang.IllegalStateException: Failed to execute CommandLineRunner
at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:787) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:768) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:322) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at com.example.BatchJobApplication.main(BatchJobApplication.java:14) [classes!/:0.0.1-SNAPSHOT]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_151]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_151]
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [batch-job-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [batch-job-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
at org.springframework.boot.loader.Launcher.launch(Launcher.java:51) [batch-job-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52) [batch-job-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
Caused by: org.springframework.batch.core.repository.JobInstanceAlreadyCompleteException: A job instance already exists and is complete for parameters={-spring.cloud.task.executionid=2}. If you want to run this job again, change the parameters.
at org.springframework.batch.core.repository.support.SimpleJobRepository.createJobExecution(SimpleJobRepository.java:131) ~[spring-batch-core-4.2.1.RELEASE.jar!/:4.2.1.RELEASE]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_151]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_151]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:366) ~[spring-tx-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:118) ~[spring-tx-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.batch.core.repository.support.AbstractJobRepositoryFactoryBean$1.invoke(AbstractJobRepositoryFactoryBean.java:181) ~[spring-batch-core-4.2.1.RELEASE.jar!/:4.2.1.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at com.sun.proxy.$Proxy45.createJobExecution(Unknown Source) ~[na:na]
at org.springframework.batch.core.launch.support.SimpleJobLauncher.run(SimpleJobLauncher.java:137) ~[spring-batch-core-4.2.1.RELEASE.jar!/:4.2.1.RELEASE]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_151]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_151]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_151]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.batch.core.configuration.annotation.SimpleBatchConfiguration$PassthruAdvice.invoke(SimpleBatchConfiguration.java:127) ~[spring-batch-core-4.2.1.RELEASE.jar!/:4.2.1.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) ~[spring-aop-5.2.5.RELEASE.jar!/:5.2.5.RELEASE]
at com.sun.proxy.$Proxy51.run(Unknown Source) ~[na:na]
at org.springframework.boot.autoconfigure.batch.JobLauncherCommandLineRunner.execute(JobLauncherCommandLineRunner.java:192) ~[spring-boot-autoconfigure-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.autoconfigure.batch.JobLauncherCommandLineRunner.executeLocalJobs(JobLauncherCommandLineRunner.java:166) ~[spring-boot-autoconfigure-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.autoconfigure.batch.JobLauncherCommandLineRunner.launchJobFromProperties(JobLauncherCommandLineRunner.java:153) ~[spring-boot-autoconfigure-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.autoconfigure.batch.JobLauncherCommandLineRunner.run(JobLauncherCommandLineRunner.java:148) ~[spring-boot-autoconfigure-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:784) [spring-boot-2.2.6.RELEASE.jar!/:2.2.6.RELEASE]
... 13 common frames omitted
2020-04-17 17:35:47.076 INFO 10780 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown initiated...
2020-04-17 17:35:47.091 INFO 10780 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown completed.
BatchJobApplication.java
#EnableTask
#SpringBootApplication
#EnableBatchProcessing
public class BatchJobApplication implements CommandLineRunner{
#Autowired
private JobLauncher jobLauncher;
#Autowired
private Job job;
public static void main(String[] args) {
SpringApplication.run(BatchJobApplication.class, args);
}
#Override
public void run(String... args) throws Exception {
JobParameters jobParameters = new JobParametersBuilder()
.addDate("date", new Date())
.addLong("JobId",System.currentTimeMillis())
.addLong("time",System.currentTimeMillis()).toJobParameters();
JobExecution execution = jobLauncher.run(job, jobParameters);
System.out.println("STATUS :: "+execution.getStatus());
}
}
To resolved this issue, I passed the unique key:value in the Task Argument and I so keeping passing the multiple key:value combinations, then I can run the same Task many times.
However I wanted to do this programmatically. Any quick solution ?
#Configuration
public class JobConfiguration {
private static final Log logger = LogFactory.getLog(JobConfiguration.class);
#Autowired
public JobBuilderFactory jobBuilderFactory;
#Autowired
public StepBuilderFactory stepBuilderFactory;
#Bean
public Job job1() {
return this.jobBuilderFactory.get("job1").start(this.stepBuilderFactory.get("job1step1").tasklet(new Tasklet() {
#Override
public RepeatStatus execute(StepContribution contribution, ChunkContext chunkContext) throws Exception {
logger.info("Job1 was run");
return RepeatStatus.FINISHED;
}
}).build()).build();
}
#Bean
public Job job2() {
return this.jobBuilderFactory.get("job2").start(this.stepBuilderFactory.get("job2step1").tasklet(new Tasklet() {
#Override
public RepeatStatus execute(StepContribution contribution, ChunkContext chunkContext) throws Exception {
logger.info("Job2 was run");
return RepeatStatus.FINISHED;
}
}).build()).build();
}
}
Great Help from #GlennRenfro - Use .incrementer(new RunIdIncrementer()). in each job, now you can execute the same job multiple times.

Unable to install Grails Asynchronous Mail plugin

Grails Version: 3.0.9
Groovy Version: 2.4.5
JVM Version: 1.8.0_60
I'm following the simple instructions to install the Grails Asynchronous Mail plugin but I'm getting the following error message on start up.
http://grails.org/plugins.html#plugin/asynchronous-mail
Can't seem to find a solution to this no matter how much I google and trawl the web.
I'd be very grateful for any insight.
ERROR grails.boot.GrailsApp - Application startup failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'grailsApplicationPostProcessor' defined in mchq.admin.Application: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [grails.boot.config.GrailsApplicationPostProcessor]: Factory method 'grailsApplicationPostProcessor' threw exception; nested exception is grails.plugins.exceptions.PluginException: Failed to initialize class [grails.plugin.asyncmail.AsynchronousMailAttachment] from plugin [asynchronousMail] : grails/gorm/Entity
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:599) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1119) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1014) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:116) ~[spring-context-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:606) ~[spring-context-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:462) ~[spring-context-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) ~[spring-boot-1.2.5.RELEASE.jar:1.2.5.RELEASE]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:686) ~[spring-boot-1.2.5.RELEASE.jar:1.2.5.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:320) ~[spring-boot-1.2.5.RELEASE.jar:1.2.5.RELEASE]
at grails.boot.GrailsApp.run(GrailsApp.groovy:52) [grails-core-3.0.7.jar:3.0.7]
at grails.boot.GrailsApp.run(GrailsApp.groovy:330) [grails-core-3.0.7.jar:3.0.7]
at grails.boot.GrailsApp.run(GrailsApp.groovy:319) [grails-core-3.0.7.jar:3.0.7]
at grails.boot.GrailsApp$run.call(Unknown Source) [grails-core-3.0.7.jar:3.0.7]
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) [groovy-2.4.4.jar:2.4.4]
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) [groovy-2.4.4.jar:2.4.4]
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:133) [groovy-2.4.4.jar:2.4.4]
at mchq.admin.Application.main(Application.groovy:8) [main/:na]
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [grails.boot.config.GrailsApplicationPostProcessor]: Factory method 'grailsApplicationPostProcessor' threw exception; nested exception is grails.plugins.exceptions.PluginException: Failed to initialize class [grails.plugin.asyncmail.AsynchronousMailAttachment] from plugin [asynchronousMail] : grails/gorm/Entity
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
... 22 common frames omitted
Caused by: grails.plugins.exceptions.PluginException: Failed to initialize class [grails.plugin.asyncmail.AsynchronousMailAttachment] from plugin [asynchronousMail] : grails/gorm/Entity
at org.grails.plugins.BinaryGrailsPlugin.initializeProvidedArtefacts(BinaryGrailsPlugin.java:133) ~[grails-core-3.0.7.jar:3.0.7]
at org.grails.plugins.BinaryGrailsPlugin.<init>(BinaryGrailsPlugin.java:66) ~[grails-core-3.0.7.jar:3.0.7]
at grails.plugins.DefaultGrailsPluginManager.createBinaryGrailsPlugin(DefaultGrailsPluginManager.java:390) ~[grails-core-3.0.7.jar:3.0.7]
at grails.plugins.DefaultGrailsPluginManager.findCorePlugins(DefaultGrailsPluginManager.java:377) ~[grails-core-3.0.7.jar:3.0.7]
at grails.plugins.DefaultGrailsPluginManager.attemptLoadPlugins(DefaultGrailsPluginManager.java:329) ~[grails-core-3.0.7.jar:3.0.7]
at grails.plugins.DefaultGrailsPluginManager.loadPlugins(DefaultGrailsPluginManager.java:239) ~[grails-core-3.0.7.jar:3.0.7]
at grails.boot.config.GrailsApplicationPostProcessor.initializeGrailsApplication(GrailsApplicationPostProcessor.groovy:87) ~[grails-core-3.0.7.jar:3.0.7]
at grails.boot.config.GrailsApplicationPostProcessor.<init>(GrailsApplicationPostProcessor.groovy:78) ~[grails-core-3.0.7.jar:3.0.7]
at grails.boot.config.GrailsAutoConfiguration.grailsApplicationPostProcessor(GrailsAutoConfiguration.groovy:59) ~[grails-core-3.0.7.jar:3.0.7]
at mchq.admin.Application.grailsApplicationPostProcessor(Application.groovy) [main/:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_60]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_60]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_60]
at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_60]
at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1426) ~[springloaded-1.2.4.RELEASE.jar:1.2.4.RELEASE]
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162) ~[spring-beans-4.1.7.RELEASE.jar:4.1.7.RELEASE]
... 23 common frames omitted
Caused by: java.lang.NoClassDefFoundError: grails/gorm/Entity
at java.lang.ClassLoader.defineClass1(Native Method) ~[na:1.8.0_60]
at java.lang.ClassLoader.defineClass(ClassLoader.java:760) ~[na:1.8.0_60]
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) ~[na:1.8.0_60]
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) ~[na:1.8.0_60]
at java.net.URLClassLoader.access$100(URLClassLoader.java:73) ~[na:1.8.0_60]
at java.net.URLClassLoader$1.run(URLClassLoader.java:368) ~[na:1.8.0_60]
at java.net.URLClassLoader$1.run(URLClassLoader.java:362) ~[na:1.8.0_60]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.8.0_60]
at java.net.URLClassLoader.findClass(URLClassLoader.java:361) ~[na:1.8.0_60]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[na:1.8.0_60]
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) ~[na:1.8.0_60]
at java.lang.ClassLoader.loadClass(ClassLoader.java:411) ~[na:1.8.0_60]
at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:677) ~[groovy-2.4.4.jar:2.4.4]
at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:787) ~[groovy-2.4.4.jar:2.4.4]
at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:775) ~[groovy-2.4.4.jar:2.4.4]
at org.grails.plugins.BinaryGrailsPlugin.initializeProvidedArtefacts(BinaryGrailsPlugin.java:131) ~[grails-core-3.0.7.jar:3.0.7]
... 38 common frames omitted
Caused by: java.lang.ClassNotFoundException: grails.gorm.Entity
at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[na:1.8.0_60]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[na:1.8.0_60]
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) ~[na:1.8.0_60]
at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[na:1.8.0_60]
... 54 common frames omitted
FAILURE: Build failed with an exception.
Here is a full list of dependencies :
dependencies {
compile "org.springframework.boot:spring-boot-starter-logging"
compile "org.springframework.boot:spring-boot-starter-actuator"
compile "org.springframework.boot:spring-boot-autoconfigure"
provided "org.springframework.boot:spring-boot-starter-tomcat"
compile "org.grails:grails-dependencies"
compile "org.grails:grails-web-boot"
compile "org.grails.plugins:hibernate"
compile "org.grails.plugins:cache"
compile "org.hibernate:hibernate-ehcache"
compile "org.grails.plugins:scaffolding"
compile 'org.grails.plugins:spring-security-core:3.0.0.M1'
compile "org.grails.plugins:mail:2.0.0.RC2"
compile 'org.grails.plugins:asynchronous-mail:2.0.0.RC2'
compile "org.grails.plugins:grails-cloudinary:0.3"
compile 'org.joda:joda-money:0.10.0'
compile "org.grails.plugins:taggable:2.0.0-SNAPSHOT"
compile 'org.grails.plugins:geocode:0.3'
runtime 'mysql:mysql-connector-java:5.1.37'
runtime "org.grails.plugins:asset-pipeline"
testCompile "org.grails:grails-plugin-testing"
testCompile "org.grails.plugins:geb"
runtime 'com.bertramlabs.plugins:less-asset-pipeline:2.6.7'
testRuntime 'org.seleniumhq.selenium:selenium-htmlunit-driver:2.44.0'
console "org.grails:grails-console"
}
There isn't a hibernate plugin for Grails 3.x.x. You have to use hibernate3, hibernate4 or hibernate5. I've just tested with hibernate4. Also in my applications there is grails-core dependency.
compile "org.grails.plugins:hibernate4"
instead of
compile "org.grails.plugins:hibernate"

Grails - ReloadException: Unexpected exception occuring while running grails application

I am getting this unexpected exception while running application on grails. I have done clean, compile and run-app many times but nothing happens. It cleans and compiled successfully but when I do run-app this exception occurs:
java.lang.RuntimeException: Reloading agent exited via exception, please raise a jira
at org.springsource.loaded.agent.ClassPreProcessorAgentAdapter.transform(ClassPreProcessorAgentAdapter.java:110)
at sun.instrument.TransformerManager.transform(TransformerManager.java:188)
at sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:428)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at org.apache.logging.log4j.core.config.plugins.util.ResolverUtil.addIfMatching(ResolverUtil.java:390)
at org.apache.logging.log4j.core.config.plugins.util.ResolverUtil.loadImplementationsInDirectory(ResolverUtil.java:292)
at org.apache.logging.log4j.core.config.plugins.util.ResolverUtil.loadImplementationsInDirectory(ResolverUtil.java:290)
at org.apache.logging.log4j.core.config.plugins.util.ResolverUtil.loadImplementationsInDirectory(ResolverUtil.java:290)
at org.apache.logging.log4j.core.config.plugins.util.ResolverUtil.findInPackage(ResolverUtil.java:204)
at org.apache.logging.log4j.core.config.plugins.util.PluginRegistry.loadFromPackage(PluginRegistry.java:222)
at org.apache.logging.log4j.core.config.plugins.util.PluginManager.collectPlugins(PluginManager.java:152)
at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:144)
at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:361)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:426)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:442)
at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:138)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:147)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:41)
at org.apache.logging.log4j.LogManager.getContext(LogManager.java:175)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:426)
at com.asklytics.provisioning.TenantProvisioningManagerService.<clinit>(TenantProvisioningManagerService.java:35)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at org.springsource.loaded.ri.ReflectiveInterceptor.jlrConstructorNewInstance(ReflectiveInterceptor.java:1075)
at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
at org.grails.spring.beans.factory.OptimizedAutowireCapableBeanFactory$1.instantiate(OptimizedAutowireCapableBeanFactory.java:89)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1098)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1050)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:510)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByName(AbstractAutowireCapableBeanFactory.java:1244)
at org.grails.spring.beans.factory.OptimizedAutowireCapableBeanFactory.autowireByName(OptimizedAutowireCapableBeanFactory.java:160)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1194)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:543)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByName(AbstractAutowireCapableBeanFactory.java:1244)
at org.grails.spring.beans.factory.OptimizedAutowireCapableBeanFactory.autowireByName(OptimizedAutowireCapableBeanFactory.java:160)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1194)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:543)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:772)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:839)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:538)
at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:766)
at org.springframework.boot.SpringApplication.createAndRefreshContext(SpringApplication.java:361)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:307)
at grails.boot.GrailsApp.run(GrailsApp.groovy:51)
at grails.boot.GrailsApp.run(GrailsApp.groovy:335)
at grails.boot.GrailsApp.run(GrailsApp.groovy:324)
at grails.boot.GrailsApp$run.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:133)
at analyticsapplication.Application.main(Application.groovy:8)
Caused by: org.springsource.loaded.ReloadException: Problem defining class com..analytic.services.ELBService$_stub_closure1__I
at org.springsource.loaded.TypeRegistry.defineClass(TypeRegistry.java:1306)
at org.springsource.loaded.ReloadableType.rewriteCallSitesAndDefine(ReloadableType.java:939)
at org.springsource.loaded.ReloadableType.<init>(ReloadableType.java:173)
at org.springsource.loaded.TypeRegistry.addType(TypeRegistry.java:1104)
at org.springsource.loaded.agent.SpringLoadedPreProcessor.preProcess(SpringLoadedPreProcessor.java:335)
at org.springsource.loaded.agent.ClassPreProcessorAgentAdapter.transform(ClassPreProcessorAgentAdapter.java:107)
... 79 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor50.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springsource.loaded.TypeRegistry.defineClass(TypeRegistry.java:1298)
... 84 more
Caused by: java.lang.NoClassDefFoundError: com//analytic/services/ELBService$_stub_closure1__I (wrong name: com/analytic/services/ELBService$_stub_closure1__I)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
at java.lang.ClassLoader.defineClass(ClassLoader.java:642)
... 88 more
I am not sure why the name of class is ending with $_stub_clouser1__I? Any one please help me out.
Hmm, looks like you might have a bad package declaration in your file:
check the "package" line in the file ELBService.groovy
it might have an extra period in there: com..analytic.services
Problem probably is connected with TenantProvisioningManagerService.java line 35. Please check it out.
Moreover did you try to update Grails for example to 3.0.16? Did you check also package naming in tests files with injected service?

Jenkins Cannot deploy to artifactory (database constraint error)

I am using Artifactory OSS v4.5.1, Jenkins v1.648, Gradle v2.9, on Ubuntu 14.04
I am using artifactory plugin for jenkins v2.4.7 to deploy an artifact generated by gradle build script
When I run gradle artifactoryPublish by hand, everything is ok, but when i try to deploy from jenkins, the jar file deploys fine, but the build info cause an error
here is jenkins console output:
Jenkins Artifactory Plugin version: 2.4.7
Jenkins Artifactory Plugin version: 2.4.7
[Gradle] - Launching build.
[workspace] $ gradle jar artifactoryPublish
[buildinfo] Properties file found at '/tmp/buildInfo1752901429055581915.properties'
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:jar UP-TO-DATE
:generatePomFileForMavenJavaPublication
:artifactoryPublish
Deploying artifact: http://localhost:8081/artifactory/gradle-local/org/commerceforge/estore/0.0.1/estore-0.0.1.jar
Deploying build descriptor to: http://localhost:8081/artifactory/api/build
Build successfully deployed. Browse it in Artifactory under http://localhost:8081/artifactory/webapp/builds/Tradenity/21
BUILD SUCCESSFUL
Total time: 11.237 secs
This build could be faster, please consider using the Gradle Daemon: https://docs.gradle.org/2.9/userguide/gradle_daemon.html
Build step 'Invoke Gradle script' changed build result to SUCCESS
Deploying build info to: http://localhost:8081/artifactory/api/build
ERROR: Could not publish build-info: Failed to send build descriptor : HTTP response code: 500. HTTP response message: Internal Server Error
java.io.IOException: Could not publish build-info: Failed to send build descriptor : HTTP response code: 500. HTTP response message: Internal Server Error
at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.sendBuildInfo(ArtifactoryBuildInfoClient.java:244)
at org.jfrog.hudson.generic.GenericBuildInfoDeployer.deploy(GenericBuildInfoDeployer.java:62)
at org.jfrog.hudson.generic.ArtifactoryGenericConfigurator$1.tearDown(ArtifactoryGenericConfigurator.java:344)
at hudson.model.Build$BuildExecution.doRun(Build.java:173)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
at hudson.model.Run.execute(Run.java:1738)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:410)
Finished: FAILURE
when i refer to artifactory log, it seems like a database eror:
2016-03-01 12:05:22,150 [http-nio-8081-exec-3] [INFO ] (o.a.e.UploadServiceImpl:453) - Deploy to 'gradle-local:org/commerceforge/estore/0.0.1/estore-0.0.1.jar' Content-Length: 0
2016-03-01 12:05:24,120 [http-nio-8081-exec-1] [INFO ] (o.a.r.r.c.BuildResource:296) - Adding build 'Tradenity #22'
2016-03-01 12:05:24,302 [http-nio-8081-exec-1] [INFO ] (o.a.r.r.c.BuildResource:313) - Added build 'Tradenity #22'
2016-03-01 12:05:24,686 [http-nio-8081-exec-2] [INFO ] (o.a.r.r.c.BuildResource:296) - Adding build 'Tradenity #22'
2016-03-01 12:05:24,749 [http-nio-8081-exec-2] [ERROR] (o.a.r.c.e.GlobalExceptionMapper:46) - Could not insert build Build{version='1.0.1', name='Tradenity', number='22', type=GENERIC, buildAgent=Generic/Generic, agent=hudson/1.648, started='2016-03-01T12:05:06.642+0200', durationMillis=18018, principal='anonymous', artifactoryPrincipal='admin', artifactoryPluginVersion='2.4.7', url='http://localhost:8088/job/Tradenity/22/', parentName='null', parentNumber='null', vcsRevision='7fdaa715b604d2a27eed956af5560a06a1d6ebe8', vcsUrl='null', parentBuildId='null', licenseControl=org.jfrog.build.api.LicenseControl#399632b2, buildRetention=org.jfrog.build.api.BuildRetention#26e7505f, runParameters=null, modules=[org.jfrog.build.api.Module#39c3f4dc], statuses=null, buildDependencies=[], issues=null, governance=org.jfrog.build.api.Governance#533a0edd}
org.artifactory.storage.StorageException: Could not insert build Build{version='1.0.1', name='Tradenity', number='22', type=GENERIC, buildAgent=Generic/Generic, agent=hudson/1.648, started='2016-03-01T12:05:06.642+0200', durationMillis=18018, principal='anonymous', artifactoryPrincipal='admin', artifactoryPluginVersion='2.4.7', url='http://localhost:8088/job/Tradenity/22/', parentName='null', parentNumber='null', vcsRevision='7fdaa715b604d2a27eed956af5560a06a1d6ebe8', vcsUrl='null', parentBuildId='null', licenseControl=org.jfrog.build.api.LicenseControl#399632b2, buildRetention=org.jfrog.build.api.BuildRetention#26e7505f, runParameters=null, modules=[org.jfrog.build.api.Module#39c3f4dc], statuses=null, buildDependencies=[], issues=null, governance=org.jfrog.build.api.Governance#533a0edd}
at org.artifactory.storage.db.build.service.BuildStoreServiceImpl.addBuild(BuildStoreServiceImpl.java:122) ~[artifactory-storage-db-4.5.1.jar:na]
at org.artifactory.build.BuildServiceImpl.addBuild(BuildServiceImpl.java:193) ~[artifactory-core-4.5.1.jar:na]
at sun.reflect.GeneratedMethodAccessor375.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_66]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.artifactory.storage.fs.lock.aop.LockingAdvice.invoke(LockingAdvice.java:76) ~[artifactory-storage-common-4.5.1.jar:na]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at com.sun.proxy.$Proxy98.addBuild(Unknown Source) ~[na:na]
at org.artifactory.build.BuildServiceImpl.addBuild(BuildServiceImpl.java:172) ~[artifactory-core-4.5.1.jar:na]
at sun.reflect.GeneratedMethodAccessor374.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_66]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99) ~[spring-tx-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281) ~[spring-tx-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) ~[spring-tx-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.artifactory.storage.fs.lock.aop.LockingAdvice.invoke(LockingAdvice.java:74) ~[artifactory-storage-common-4.5.1.jar:na]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207) ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]
at com.sun.proxy.$Proxy98.addBuild(Unknown Source) ~[na:na]
at org.artifactory.rest.resource.ci.BuildResource.addBuild(BuildResource.java:305) ~[artifactory-rest-4.5.1.jar:na]
at sun.reflect.GeneratedMethodAccessor373.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_66]
at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$VoidOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:167) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84) ~[jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542) [jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473) [jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419) [jersey-server-1.19.jar:1.19]
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409) [jersey-server-1.19.jar:1.19]
at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409) [jersey-servlet-1.19.jar:1.19]
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:558) [jersey-servlet-1.19.jar:1.19]
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:733) [jersey-servlet-1.19.jar:1.19]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) [servlet-api.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291) [catalina.jar:8.0.22]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:8.0.22]
at org.artifactory.webapp.servlet.RepoFilter.execute(RepoFilter.java:198) [artifactory-web-application-4.5.1.jar:na]
at org.artifactory.webapp.servlet.RepoFilter.doFilter(RepoFilter.java:89) [artifactory-web-application-4.5.1.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) [catalina.jar:8.0.22]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:8.0.22]
at org.artifactory.webapp.servlet.AccessFilter.useAuthentication(AccessFilter.java:334) [artifactory-web-application-4.5.1.jar:na]
at org.artifactory.webapp.servlet.AccessFilter.authenticateAndExecute(AccessFilter.java:234) [artifactory-web-application-4.5.1.jar:na]
at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:190) [artifactory-web-application-4.5.1.jar:na]
at org.artifactory.webapp.servlet.AccessFilter.doFilter(AccessFilter.java:156) [artifactory-web-application-4.5.1.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) [catalina.jar:8.0.22]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:8.0.22]
at org.artifactory.webapp.servlet.RequestFilter.doFilter(RequestFilter.java:65) [artifactory-web-application-4.5.1.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) [catalina.jar:8.0.22]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:8.0.22]
at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:109) [artifactory-web-application-4.5.1.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) [catalina.jar:8.0.22]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:8.0.22]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219) [catalina.jar:8.0.22]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106) [catalina.jar:8.0.22]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:142) [catalina.jar:8.0.22]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) [catalina.jar:8.0.22]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88) [catalina.jar:8.0.22]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:518) [catalina.jar:8.0.22]
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1091) [tomcat-coyote.jar:8.0.22]
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:668) [tomcat-coyote.jar:8.0.22]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1521) [tomcat-coyote.jar:8.0.22]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1478) [tomcat-coyote.jar:8.0.22]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_66]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_66]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:8.0.22]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66]
Caused by: java.sql.SQLIntegrityConstraintViolationException: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'BUILDS_NAME_NUMBER_DATE_IDX' defined on 'BUILDS'.
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeLargeUpdate(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeUpdate(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.artifactory.storage.db.util.JdbcHelper.executeUpdate(JdbcHelper.java:160) ~[artifactory-storage-db-4.5.1.jar:na]
at org.artifactory.storage.db.build.dao.BuildsDao.createBuild(BuildsDao.java:65) ~[artifactory-storage-db-4.5.1.jar:na]
at org.artifactory.storage.db.build.service.BuildStoreServiceImpl.addBuild(BuildStoreServiceImpl.java:119) ~[artifactory-storage-db-4.5.1.jar:na]
... 76 common frames omitted
Caused by: org.apache.derby.iapi.error.StandardException: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'BUILDS_NAME_NUMBER_DATE_IDX' defined on 'BUILDS'.
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.IndexChanger.insertAndCheckDups(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.IndexChanger.doInsert(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.IndexChanger.insert(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.IndexSetChanger.insert(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.RowChangerImpl.insertRow(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.InsertResultSet.normalInsertCore(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(Unknown Source) ~[derby-10.11.1.1.jar:na]
at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown Source) ~[derby-10.11.1.1.jar:na]
... 83 common frames omitted

Error executing <g:render /> Grails 3.0.5

I am using Grails 3.0.5
I get this error when trying to deploy using java -Dgrails.env=prod -jar
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Grails application running at http://localhost:8080 in environment: production
ERROR StackTrace - Full Stack Trace:
org.grails.taglib.GrailsTagException: [views/layouts/secure0.gsp:142] Error executing tag <g:render>: PermGen space
at org.grails.gsp.GroovyPage.throwRootCause(GroovyPage.java:445) ~[grails-gsp-3.0.5.jar!/:3.0.5]
at org.grails.gsp.GroovyPage.invokeTag(GroovyPage.java:388) ~[grails-gsp-3.0.5.jar!/:3.0.5]
at sun.reflect.GeneratedMethodAccessor263.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.7.0_79]
at java.lang.reflect.Method.invoke(Method.java:606) ~[na:1.7.0_79]
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93) ~[groovy-2.4.4.jar!/:2.4.4]
at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325) ~[groovy-2.4.4.jar!/:2.4.4]
at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:384) ~[groovy-2.4.4.jar!/:2.4.4]
at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1019) ~[groovy-2.4.4.jar!/:2.4.4]
at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.callCurrent(PogoMetaClassSite.java:69) ~[groovy-2.4.4.jar!/:2.4.4]
Before deployment, I test in localhost, and it runs without any error.
But after deployment I get this error.
What's wrong with my code?
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Grails application running at http://localhost:80 in environment: production
ERROR org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/].[grailsDis patcherServlet] - Servlet.service() for servlet [grailsDispatcherServlet] in con text with path [] threw exception [Handler processing failed; nested exception i s java.lang.OutOfMemoryError: PermGen space] with root cause
java.lang.OutOfMemoryError: PermGen space
at java.lang.ClassLoader.defineClass1(Native Method) ~[na:1.7.0_79]
at java.lang.ClassLoader.defineClass(ClassLoader.java:800) ~[na:1.7.0_79 ]
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:14 2) ~[na:1.7.0_79]
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449) ~[na:1.7 .0_79]
at java.net.URLClassLoader.access$100(URLClassLoader.java:71) ~[na:1.7.0 _79]
at java.net.URLClassLoader$1.run(URLClassLoader.java:361) ~[na:1.7.0_79]
at java.net.URLClassLoader$1.run(URLClassLoader.java:355) ~[na:1.7.0_79]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0 _79]
at java.net.URLClassLoader.findClass(URLClassLoader.java:354) ~[na:1.7.0 _79]
at org.springframework.boot.loader.LaunchedURLClassLoader.doLoadClass(La unchedURLClassLoader.java:163) ~[ChatV3-0.1.jar!/:na]
at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(Laun chedURLClassLoader.java:136) ~[ChatV3-0.1.jar!/:na]
at java.lang.ClassLoader.loadClass(ClassLoader.java:358) ~[na:1.7.0_79]
at org.grails.buffer.StreamCharBuffer$MultipartCharBufferChunk.asStringC hunk(StreamCharBuffer.java:1864) ~[grails-encoder-3.0.5.jar!/:3.0.5]
at org.grails.buffer.StreamCharBuffer.readToSingleStringChunk(StreamChar Buffer.java:720) ~[grails-encoder-3.0.5.jar!/:3.0.5]
at org.grails.buffer.StreamCharBuffer.toString(StreamCharBuffer.java:700 ) ~[grails-encoder-3.0.5.jar!/:3.0.5]
at org.grails.buffer.FastStringWriter.getValue(FastStringWriter.java:63) ~[grails-encoder-3.0.5.jar!/:3.0.5]
at org.grails.buffer.FastStringWriter.toString(FastStringWriter.java:59) ~[grails-encoder-3.0.5.jar!/:3.0.5]
at org.grails.web.pages.GroovyPagesUriSupport.getAbsoluteViewURIInternal (GroovyPagesUriSupport.java:225) ~[grails-web-common-3.0.5.jar!/:3.0.5]
at org.grails.web.pages.GroovyPagesUriSupport.getAbsoluteViewURI(GroovyP agesUriSupport.java:161) ~[grails-web-common-3.0.5.jar!/:3.0.5]
at org.grails.web.gsp.io.GrailsConventionGroovyPageLocator.findViewByPat h(GrailsConventionGroovyPageLocator.java:68) ~[grails-web-gsp-3.0.5.jar!/:3.0.5]
at org.grails.web.servlet.view.GroovyPageViewResolver.createGrailsView(G roovyPageViewResolver.java:186) ~[grails-web-gsp-3.0.5.jar!/:3.0.5]
at org.grails.web.servlet.view.GroovyPageViewResolver$1.call(GroovyPageV iewResolver.java:113) ~[grails-web-gsp-3.0.5.jar!/:3.0.5]
at org.grails.web.servlet.view.GroovyPageViewResolver$1.call(GroovyPageV iewResolver.java:110) ~[grails-web-gsp-3.0.5.jar!/:3.0.5]
at grails.util.CacheEntry.updateValue(CacheEntry.java:170) ~[grails-core -3.0.5.jar!/:3.0.5]
at grails.util.CacheEntry.getValue(CacheEntry.java:144) ~[grails-core-3. 0.5.jar!/:3.0.5]
at grails.util.CacheEntry.getValue(CacheEntry.java:84) ~[grails-core-3.0 .5.jar!/:3.0.5]
at grails.util.CacheEntry.getValue(CacheEntry.java:102) ~[grails-core-3. 0.5.jar!/:3.0.5]
at org.grails.web.servlet.view.GroovyPageViewResolver.loadView(GroovyPag eViewResolver.java:124) ~[grails-web-gsp-3.0.5.jar!/:3.0.5]
at grails.plugin.scaffolding.ScaffoldingViewResolver.loadView(Scaffoldin gViewResolver.groovy:36) ~[scaffolding-3.1.1.jar!/:na]
at org.springframework.web.servlet.view.AbstractCachingViewResolver.crea teView(AbstractCachingViewResolver.java:244) ~[spring-webmvc-4.1.7.RELEASE.jar!/ :4.1.7.RELEASE]
at org.springframework.web.servlet.view.UrlBasedViewResolver.createView( UrlBasedViewResolver.java:446) ~[spring-webmvc-4.1.7.RELEASE.jar!/:4.1.7.RELEASE ]
at org.springframework.web.servlet.view.AbstractCachingViewResolver.reso lveViewName(AbstractCachingViewResolver.java:146) ~[spring-webmvc-4.1.7.RELEASE. jar!/:4.1.7.RELEASE]
ERROR StackTrace - Full Stack Trace:
org.grails.taglib.GrailsTagException: [views/layouts/main.gsp:8] Error executing tag <asset:stylesheet>: PermGen space
at org.grails.gsp.GroovyPage.throwRootCause(GroovyPage.java:445) ~[grail s-gsp-3.0.5.jar!/:3.0.5]
at org.grails.gsp.GroovyPage.invokeTag(GroovyPage.java:388) ~[grails-gsp -3.0.5.jar!/:3.0.5]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7. 0_79]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:57) ~[na:1.7.0_79]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:43) ~[na:1.7.0_79]
at java.lang.reflect.Method.invoke(Method.java:606) ~[na:1.7.0_79]
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java: 93) ~[groovy-2.4.4.jar!/:2.4.4]
at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325) ~[groovy-2
ERROR org.apache.catalina.core.ContainerBase - Unexpected death of background thread ContainerBackgroundProcessor[StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]]
java.lang.OutOfMemoryError: PermGen space
Exception in thread "ContainerBackgroundProcessor[StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]]"
Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "ContainerBackgroundProcessor[StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]]"
This is what I try to do..
[root#server chat]# export GRAILS_OPTS="-server -d64 -XX:MaxPermSize=1024 -Xmx1024m"
[root#server chat]# java -Dgrails.env=prod -jar ChatV3-0.1.jar
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Grails application running at http://localhost:80 in environment: production
ERROR asset.pipeline.AssetSpecLoader - Error loading asset specification asset.pipeline.CssAssetFile: PermGen space
java.lang.OutOfMemoryError: PermGen space
at java.lang.ClassLoader.defineClass1(Native Method) ~[na:1.7.0_79]
at java.lang.ClassLoader.defineClass(ClassLoader.java:800) ~[na:1.7.0_79]
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) ~[na:1.7.0_79]
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449) ~[na:1.7.0_79]
at java.net.URLClassLoader.access$100(URLClassLoader.java:71) ~[na:1.7.0_79]
at java.net.URLClassLoader$1.run(URLClassLoader.java:361) ~[na:1.7.0_79]
at java.net.URLClassLoader$1.run(URLClassLoader.java:355) ~[na:1.7.0_79]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_79]
at java.net.URLClassLoader.findClass(URLClassLoader.java:354) ~[na:1.7.0_79]
at org.springframework.boot.loader.LaunchedURLClassLoader.doLoadClass(LaunchedURLClassLoader.java:163) ~[ChatV3-0.1.jar!/:na]
at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:136) ~[ChatV3-0.1.jar!/:na]
When I tried to get Java
[root#server chat]# ps -ax | grep java
3700 ? Sl 1:27 /usr/java/jdk1.7.0_79/bin/java -Xms1G -Xmx1G -Djava.util.logging.config.file=logging.properties -Djava.security.auth.login.config=/root/apache-activemq/conf/login.config -Dcom.sun.management.jmxremote -Djava.awt.headless=true -Djava.io.tmpdir=/root/apache-activemq/tmp -Dactivemq.classpath=/root/apache-activemq/conf; -Dactivemq.home=/root/apache-activemq -Dactivemq.base=/root/apache-activemq -Dactivemq.conf=/root/apache-activemq/conf -Dactivemq.data=/root/apache-activemq/data -jar /root/apache-activemq/bin/activemq.jar start
11544 pts/0 S+ 0:00 grep --color=auto java
You got a PermGen error.
Try using somethink like:
$ export GRAILS_OPTS="-XX:MaxPermSize=1024m -Xmx1024M -server"
$ java -Dgrails.env=prod -jar
Take a look on this questions/answers, they will help you:
Grails and PermGen issue with g:link and g:render
Grails PermGem error
I resolve my problem with
java -XX:MaxPermSize:1024m -Dgrails.env=prod -jar hellowWorld.jar

Resources