grails-3.1

Grails 3.1.6 Deploy to JBoss is 404

核能气质少年 提交于 2019-12-12 01:12:55
问题 When I deploy a helloWorld app to JBoss EAP 6.4.0.GA it deploys with warnings and no errors, shows deployed in JBoss web admin console, but the application context returns 404. I have some warnings but no errors in JBoss log file. Process: Grails 3.1.6 JVM 1.8.0_77 Build on Windows 7 Enterprise Deploying to JBoss EAP 6.4.0.GA running on CentOS Linux release 7.1.1503 grails create-app helloWorld grails create-domain-class Person Edit Person.groovy... add String name grails henerate-all *

GORM doesn't handle mapping of associations which have a further association in their composite primary key

半世苍凉 提交于 2019-12-08 20:55:31
I'm trying to map existing tables in a GORM/Grails app. Most of the tables have composite primary keys (not my choice). I'm finding that when I map an association to a class (parent of a child) where the composite key of the parent class contains an association to a class with a composite key also (grandparent), GORM doesn't bother to check the mapping of the grandparent class and subs in a non-composite key. Child class Child implements Serializable { Parent parent String name belongsTo= [parent: Parent] static mapping= { id(composite: ['parent', 'name']) } } Parent class Parent implements

GORM doesn't handle mapping of associations which have a further association in their composite primary key

拜拜、爱过 提交于 2019-12-08 06:35:56
问题 I'm trying to map existing tables in a GORM/Grails app. Most of the tables have composite primary keys (not my choice). I'm finding that when I map an association to a class (parent of a child) where the composite key of the parent class contains an association to a class with a composite key also (grandparent), GORM doesn't bother to check the mapping of the grandparent class and subs in a non-composite key. Child class Child implements Serializable { Parent parent String name belongsTo=

404 when deploying Grails 3.1.10 war to tomcat7 or tomcat8

一曲冷凌霜 提交于 2019-12-08 05:59:44
问题 The closest stackoverflow question that explains my symptoms is here - How can I deploy a Grails 3.0.1 war file in Tomcat7? I am in the process of upgrading a Grails 2.3.4 application to Grails 3.1.10 and everything is working with 'grails run-app'. When i deploy to a war i get nothing but 404's for any url. The war deploys without any error messages in catalina.out. The tomcat access logs show my access attempts. (not linux problem?) I can get to the tomcat manager, and the tomcat manager

Following symbolic link in Grails 3

蓝咒 提交于 2019-12-07 22:01:10
问题 In Grails 2.x, to allow following symbolic links, we can add following in the scripts/_Events.groovy : eventConfigureTomcat = { tomcat -> def ctx = tomcat.host.findChild("") ctx.allowLinking = true // Follow soft links } How can we achieve the same in Grails 3? I've tried creating the same script file in src/main/scripts directory in Grails 3 but didn't help. Edit: I also tried adding following line in Bootstrap.groovy : Holders.getServletContext().allowLinking = true GitHub issue #10045 回答1:

Following symbolic link in Grails 3

放肆的年华 提交于 2019-12-06 05:32:28
In Grails 2.x, to allow following symbolic links, we can add following in the scripts/_Events.groovy : eventConfigureTomcat = { tomcat -> def ctx = tomcat.host.findChild("") ctx.allowLinking = true // Follow soft links } How can we achieve the same in Grails 3? I've tried creating the same script file in src/main/scripts directory in Grails 3 but didn't help. Edit: I also tried adding following line in Bootstrap.groovy : Holders.getServletContext().allowLinking = true GitHub issue #10045 Finally, I've figured out the solution for following symbolic link in Grails 3 with the help of examples

Disable reloading in Grails 3.1 / springloaded

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-04 01:23:53
问题 I'm trying to disable automatic reload/recompiling in Grails 3.1 as I would like to use JRebel instead. I find springloaded rather limited, but more importantly is constantly fails with File /Users/engrun/Development/projects/grailsPoc/grails-app/controllers/grailsPoc/HelloController.groovy changed, recompiling... java.lang.IllegalAccessException: Class org.springsource.loaded.ReloadableType can not access a member of class org.springframework.aop.framework.CglibAopProxy

Configuring Grails 3 for Log4j2

為{幸葍}努か 提交于 2019-12-03 00:19:51
We would like to use Log4j2 as the log binding with grails 3. From what I can figure out so far. We have many subordinate dependencies that use a variety of loggers, so we need to use the SLF4J API. Then, instead of letting grails / groovy / spring re-direct the SLF4J API to the Logback binding, we need to re-direct each to the Log4j2 binding. Since grails 3 uses the Logback binding, I am planning to go through each dependency in the build.gradle, exclude the Logback binding, and include the Log4j2 binding. Will this work? Update: Yes Do we also need to bridge the Log4j2 API to the SLF4j API?

Adding in-place plugin to grails 3 project

血红的双手。 提交于 2019-12-01 05:36:20
In grails 2.x, we were allowed to add an in place plugin by adding following in BuildConfig.groovy grails.plugin.location."my-plugin" = "../my-plugin" My question is, can we add our local plugins similarly in-place in grails3.0 as well or there is some other way to do this in grails. Actual purpose is to test the plugin whether it's working properly or not before pushing it to bintray. Yes, there is. Grails 3 is based on Gradle so multi-project gradle builds solve your issue. Basically you add dependency as: compile project(':../my-custom-plugin') and has to modify settings.gradle to include

Disable reloading in Grails 3.1 / springloaded

China☆狼群 提交于 2019-12-01 04:17:52
I'm trying to disable automatic reload/recompiling in Grails 3.1 as I would like to use JRebel instead. I find springloaded rather limited, but more importantly is constantly fails with File /Users/engrun/Development/projects/grailsPoc/grails-app/controllers/grailsPoc/HelloController.groovy changed, recompiling... java.lang.IllegalAccessException: Class org.springsource.loaded.ReloadableType can not access a member of class org.springframework.aop.framework.CglibAopProxy$ClassLoaderAwareUndeclaredThrowableStrategy with modifiers "public" I have tried all kinds of settings that I have found