首次访问时出现Grails Webflow错误

首次访问时出现Grails Webflow错误,grails,spring-webflow,missingmethodexception,Grails,Spring Webflow,Missingmethodexception,我在Grails中开发了一个简单的webflow(主要是为了试验webflows的使用——在这种情况下有点过分)。在对可序列化对象进行了一些尝试和磨难之后,我让它工作了——有时 问题是——启动应用程序(run app)后,我第一次访问webflow时,遇到以下异常: 2010-06-16 09:11:25,580 [http-8080-3] [ERROR] [org.codehaus.groovy.grails.web.errors.GrailsExceptionResolver] No sig

我在Grails中开发了一个简单的webflow(主要是为了试验webflows的使用——在这种情况下有点过分)。在对可序列化对象进行了一些尝试和磨难之后,我让它工作了——有时

问题是——启动应用程序(run app)后,我第一次访问webflow时,遇到以下异常:

2010-06-16 09:11:25,580 [http-8080-3] [ERROR] [org.codehaus.groovy.grails.web.errors.GrailsExceptionResolver] No signature of method: groovy.lang.MissingMethodException.to() is applicable for argument types: (java.lang.String) values: [validate]
Possible solutions: is(java.lang.Object), any(), use([Ljava.lang.Object;), getAt(java.lang.String), with(groovy.lang.Closure), any(groovy.lang.Closure)
groovy.lang.MissingMethodException: No signature of method: groovy.lang.MissingMethodException.to() is applicable for argument types: (java.lang.String) values: [validate]
Possible solutions: is(java.lang.Object), any(), use([Ljava.lang.Object;), getAt(java.lang.String), with(groovy.lang.Closure), any(groovy.lang.Closure)
        at com.sbs.component.survey.SurveyDefinitionController.invokeMethod(SurveyDefinitionController.groovy)
        at com.sbs.component.survey.SurveyDefinitionController$_closure3.doCall(SurveyDefinitionController.groovy:23)
如果我“触摸”控制器(进行任何编辑,即使只是添加一个空白),然后保存文件,webflow开始工作。。。在控制器至少重新加载一次之前,似乎有些东西没有连接起来。显然,这是一个非启动。。。你知道这是什么原因吗

我在MacOSXJava1.6上使用Grails1.3.1

以下是webflow的框架:

def createSurveyFlow = {
        select {

            }.to("validate")
            on("cancel").to("finish")
        }

        validate {
            on("approve") {

            }.to("finish")
            on("disapprove").to("select")
            on("cancel").to("finish")
        }

        finish {
            action {
                flash.message = "SurveyDefinition created"            
            }
            redirect(controller:"surveyDefinition", action:"index")
        }

    }

我可能已经弄明白了——似乎webflow定义和控制器操作不太像是在同一个控制器上。当我将webflow移动到它自己的控制器时,这个(和其他)问题似乎消失了。至少现在是这样。如果我了解更多情况,我会向你汇报