“加载插件管理器时出错:TomcatGrailsPlugin”关于Grails 2.3数据库迁移 [英] "Error loading plugin manager: TomcatGrailsPlugin" on Grails 2.3 Database Migration

查看:138
本文介绍了“加载插件管理器时出错:TomcatGrailsPlugin”关于Grails 2.3数据库迁移的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Grails 2.3和Grails数据库迁移插件(1.3.6)。

当我执行grails dbm-update时,出现以下错误。如何解决这个错误?

 错误错误加载插件管理器:TomcatGrailsPlugin(注意:堆栈跟踪已被过滤使用 - 。详细看到整个跟踪)
抛出java.lang.ClassNotFoundException:TomcatGrailsPlugin
在_GrailsBootstrap_groovy $ _run_closure2.doCall(_GrailsBootstrap_groovy:40)
在org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass。 Java的:133)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)$ b $ org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)$ b在org.codehaus.gant.GantBinding.this $ 4 $ withTargetEvent(GantBinding.groovy)
在org.codehaus。 gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
at org.codehaus.gant.GantBinding $ _initializeGantBinding在_GrailsBootstrap_groovy上
$ _run_closure6.doCall(_GrailsBootstrap_groovy:64)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
at _GrailsBootstrap_groovy $ _run_closure6.doCall .codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
。在org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
。在org.codehaus.gant.GantBinding.this $ 4 $ withTargetEvent(GantBinding。常规)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
在org.codehaus.gant.GantMetaClass.processClosure(GantMetaC lass.java:81)
at org.codehaus.gant.GantMetaClass.processArgument(GantMetaClass.java:95)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:128)
at _DatabaseMigrationCommon_groovy $ _run_closure1.doCall(_DatabaseMigrationCommon_groovy:25)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
at org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall (GantBinding.groovy:185)
。在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
。在org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
在org.codehaus.gant.GantBinding.this $ 4 $ withTargetEvent(GantBinding.groovy)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
at org .codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
在org.codehaus.gant.GantMetaClass.processClosure(GantMetaClass.java:81)
在org.codehaus.gant.GantMetaClass.processArgument(GantMetaClass.java:95)
在org.codehaus.gant .GantMetaClass.invokeMethod(GantMetaClass.java:128)
在DbmUpdate $ _run_closure1.doCall(DbmUpdate:23)
在org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
在org.codehaus。 gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
。在org.codehaus.gant.GantBinding.this $ 4 $ withTargetEvent(GantBinding.groovy)
。在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall (GantBinding.groovy:185)
在org.codehaus.gant.GantBinding $ _initializeGantBinding_closure5_closure16.doCall( GantBinding.groovy)
at gant.Gant $ _dispatch_closure5.doCall(Gant.groovy:381)
at gant.Gant $ _dispatch_closure7.doCall(Gant.groovy:415)
at gant.Gant $ _dispatch_closure7.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:427)
at gant.Gant.this $ 2 $ withBuildListeners(Gant.groovy)
at gant .Gant $ this $ 2 $ withBuildListeners.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:415)
at gant.Gant.this $ 2 $ dispatch(Gant.groovy)
at gant.invokeMethod(Gant.groovy)
at gant.Gant.executeTargets(Gant.groovy:591)
at gant.Gant.executeTargets(Gant.groovy:590)
|错误加载插件管理器错误:TomcatGrailsPlugin


解决方案

em>超级烦人 bug。我的应用程序依赖于使用运行脚本运行脚本,并获得相同的行为。这是我做的一个解决方法:

 插件{
...
// grails 2.3。 2和tomcat 7.0.42会导致脚本无法正常工作:(在脚本中传递-DnoTomcat = true以修复此
if(System.getProperty(noTomcat)== null){
build :tomcat:7.0.42

}

然后当你运行你的脚本:

  grails -DnoTomcat = true运行脚本脚本/ MyScript.groovy 



确实令人讨厌,但至少您可以在等待修复时使用所有其他最新功能。


I use Grails 2.3 and the Grails database migration plugin (1.3.6).

When I do grails dbm-update I get the following error. How can I solve this error?

 Error Error loading plugin manager: TomcatGrailsPlugin (NOTE: Stack trace has been filtered. Use --verbose to see entire trace.)
java.lang.ClassNotFoundException: TomcatGrailsPlugin
    at _GrailsBootstrap_groovy$_run_closure2.doCall(_GrailsBootstrap_groovy:40)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
    at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
    at _GrailsBootstrap_groovy$_run_closure6.doCall(_GrailsBootstrap_groovy:64)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
    at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantMetaClass.processClosure(GantMetaClass.java:81)
    at org.codehaus.gant.GantMetaClass.processArgument(GantMetaClass.java:95)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:128)
    at _DatabaseMigrationCommon_groovy$_run_closure1.doCall(_DatabaseMigrationCommon_groovy:25)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
    at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantMetaClass.processClosure(GantMetaClass.java:81)
    at org.codehaus.gant.GantMetaClass.processArgument(GantMetaClass.java:95)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:128)
    at DbmUpdate$_run_closure1.doCall(DbmUpdate:23)
    at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
    at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
    at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
    at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
    at gant.Gant$_dispatch_closure5.doCall(Gant.groovy:381)
    at gant.Gant$_dispatch_closure7.doCall(Gant.groovy:415)
    at gant.Gant$_dispatch_closure7.doCall(Gant.groovy)
    at gant.Gant.withBuildListeners(Gant.groovy:427)
    at gant.Gant.this$2$withBuildListeners(Gant.groovy)
    at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
    at gant.Gant.dispatch(Gant.groovy:415)
    at gant.Gant.this$2$dispatch(Gant.groovy)
    at gant.Gant.invokeMethod(Gant.groovy)
    at gant.Gant.executeTargets(Gant.groovy:591)
    at gant.Gant.executeTargets(Gant.groovy:590)
| Error Error loading plugin manager: TomcatGrailsPlugin

解决方案

This is a super annoying bug. My application depends on running scripts with run-script and I get the same behavior. Here's what I did as a workaround:

plugins {
    ...
    // grails 2.3.2 and tomcat 7.0.42 cause scripts to not work :( Pass -DnoTomcat=true in the script args to fix this
    if (System.getProperty("noTomcat") == null) {
        build ":tomcat:7.0.42"
    }
}

Then when running your script:

 grails -DnoTomcat=true run-script scripts/MyScript.groovy

Annoying for sure, but at least you can use all the other latest features while awaiting a fix.

这篇关于“加载插件管理器时出错:TomcatGrailsPlugin”关于Grails 2.3数据库迁移的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆