grails-plugin

Grails 3.0 adding an inline plugin

让人想犯罪 __ 提交于 2019-12-05 09:00:13
问题 I created simple grails 3.0 applications using commands below: create-app admin --profile=web create-plugin core --profile=plugin Now, I wanted to use core as an inline plugin in admin build, which is a web application. We can easily do that in grails version < 3.0 in buildconfig. Where can I do that in grails 3.0. Every help is worth appreciated. 回答1: Inplace plugins have been replaced by multi project Gradle builds. See the Grails 3 functional test suite for an example https://github.com

Grails Inline Plugins: Cannot Upgrade a plugin that is configured via BuildConfig.groovy

≯℡__Kan透↙ 提交于 2019-12-05 06:39:42
Our app is split into a main application and a few plugins. We're using inline plugins via the BuildConfig.groovy file. When it is time to WAR the whole thing up for production I'm getting the following message: You cannot upgrade a plugin that is configured via BuildConfig.groovy, remove the configuration to continue. And then Grails wants to uninstall the plugin because it can't find it in application.properties. But during development, having it in application.properties causes issues. So when we're ready to create a production WAR, how do we work around this without commenting the plugins

Exclude plugin for specific environment

馋奶兔 提交于 2019-12-05 06:11:08
I'm using grails 2.1. I need to exclude a plugin when building for production. This post mentions adding scopes to the plugins. I believe this requires editing indivudual plugin descriptors? I would like to define plugins to exclude in one location. I have tried adding the following to config.groovy: environments { production { plugin.excludes='grails-melody' } } When I check the war it still contains the melody folder under WEB-INF/plugins. I should add that most of the application plugins are specified in application.properties as follows: plugins.build-test-data=2.0.3 plugins.fixtures=1.1

Using grails datasources in quartz plugin

孤街醉人 提交于 2019-12-05 05:02:38
问题 I want to create quartz jobs that use a JdbcStore as described in the clustering section of the docs, in Burt's example. The example shows how to configure quartz using a quartz.properties file. Now, I'd like my jdbc store to be the same database as my grails application, so that I have less settings to duplicate. So, assuming I manually create the required tables in my database, is it possible to use the default dataSource configured in Datasource.groovy with the quartz plugin ? I'm using

Grails - Failed to read artifact descriptor for org.grails.plugins:tomcat:zip:8.0.33

别说谁变了你拦得住时间么 提交于 2019-12-05 02:55:58
问题 Since this morning I seem to have an issue with grails plugins repo (Using Grails 2.4.4). Getting - Hostname in certificate didn't match: != < .jfrog.io> OR < .jfrog.io> OR . BuildConfig has: build 'org.grails.plugins:tomcat:8.0.33' under plugins Anyone have encountered similar issue or have a solution for it? Resolve error obtaining dependencies: Failed to read artifact descriptor for org.grails.plugins:tomcat:zip:8.0.33 (NOTE: Stack trace has been filtered. Use --verbose to see entire trace

Which Security Framework to use for Grails application?

我与影子孤独终老i 提交于 2019-12-05 02:15:16
问题 I spent a couple of weeks trying to figure out what solution I should bring to this question I posted. Since I couldn't find a full documentation for Shiro-Grails integration, I am looking for some other framework (like Spring) to secure our lightweight web based Grails application. The application is couple of months old and it is not a huge application. Not more 20 persistent classes. However, I believe it will grow up soon. But, security is not implemented yet and I want to make sure that

grails override redirect controller method

耗尽温柔 提交于 2019-12-05 00:30:46
问题 I am trying to override the default controller redirect method and cannot seem to get the following bit of code to work. I have created a plugin and I'm trying to use the "doWithDynamicMethods" to replace the redirect. def doWithDynamicMethods = {ctx -> application.controllerClasses.each() { controllerClass -> replaceRedirectMethod(controllerClass) } } void replaceRedirectMethod(controllerClass) { def oldRedirect = controllerClass.metaClass.pickMethod("redirect", [Map] as Class[])

Grails spring-security - Can I intercept before success action to check required password change?

别等时光非礼了梦想. 提交于 2019-12-04 19:35:01
Upon creating new users in my system, I am sending them a temporary password via email and setting an property of changePasswordNextLogin=true. When they come to log in for the first time, I would like to intercept the flow upon a successful login, check for this this value, and if it is true, redirect them to a change password action. Once the password change has been completed, ideally I would like to send them to their intended destination. I have been pouring through the default settings and am not seeing - or more likely not interpreting properly - any way to make that happen. It seems

Grails database migration plugins

最后都变了- 提交于 2019-12-04 17:41:46
问题 There are at least two Grails plugins that emulate the database migration functionality of Rails: Autobase Liquibase Is there a consensus about which of these is best, or is there another plugin that does database migration better than either of the above? 回答1: There is now a standard Grails database migration plugin available. According to this blog post at least the liquibase plugin will therefore not be maintained past the liquibase 1.9 release anymore. The new database migration plugin

belongsTo multiple Domain

眉间皱痕 提交于 2019-12-04 16:31:36
I have 4 classes, incidents,problems, requests and another is Attachment. Every domain look like......... Class Incidents { // other fields static hasOne = [attachment: Attachment] static constraints = [attachment nullable:true] } Class Problems { // other fields static hasOne = [attachment: Attachment] static constraints = [attachment nullable:true] } Class Requests { // other fields static hasOne = [attachment: Attachment] static constraints = [attachment nullable:true] } Class Attachment { // other fields static belongsTo= [ incident: Incidents, problem: Problems, requests: Requests ]