The problem only occurs when deploying the application as WAR (e.g. 'grails run-war'), not when running with 'grails run-app'. I get the same error when creating a minimal spring-security-core and spring-security-ui application for testing the issue, so it would seem that other parts of the application are not to blame.

The cause obviously seems to be that the RegistrationCode is not mapped as a domain class (checking this with DomainClassArtefactHandler.isDomainClass() seems to confirm it). However, when trying to create an explicit RegistrationCode domain class, a DuplicateMappingException is thrown. A workaround would probably be to create the class with another name and edit RegistrationController to use that, which I haven't yet tried, but will probably have to.

derek
added a comment - 11/Dec/10 10:13 PM - edited Same problem here with version 0.1.2 and grails 1.3.5
Maybe we are doing something wrong
Domain class is not mapped from the plugin. The table is also not created in the DB.
Might try explicitly creating a hibernate mapping for it and see what happens

Finn Johnsen
added a comment - 23/Dec/10 8:25 AM I got this when submitting the forgot password dialog. My users were not created using register, they were manually created all of them.
spring-security-ui 0.1.2
I got this in my production environment, as I was misled by my testing it using 'grails run-app'. (Turns out I've been naive)
Any suggested work-around?
org.codehaus.groovy.grails.web.errors.GrailsExceptionResolver - No signature of method: org.codehaus.groovy.grails.plugins.springsecurity.ui.RegistrationCode.save() is app
licable for argument types: () values: []
Possible solutions: wait(), any(), wait(long), any(groovy.lang.Closure), each(groovy.lang.Closure), use([Ljava.lang.Object
groovy.lang.MissingMethodException: No signature of method: org.codehaus.groovy.grails.plugins.springsecurity.ui.RegistrationCode.save() is applicable for argument types: () values: []
Possible solutions: wait(), any(), wait(long), any(groovy.lang.Closure), each(groovy.lang.Closure), use([Ljava.lang.Object
at RegisterController.RegisterController$_closure4.doCall(RegisterController.groovy:118)

This is probably the problem of grails, not SpringSecurity UI - domain class of plugin is not "visible" in run-war (or war) instead od run-app. (No DB table was created also, when using war or run-war).

The simplest workaround I used was creating own domain class - RegistrationCode2 and RegisterController extending grails.plugins.springsecurity.ui.RegisterController
and overriding methods register, forgotPassword, resetPassword and verifyRegistration to use RegistrationCode2
instead of RegistrationCode.

Michal Pavlasek
added a comment - 08/Mar/11 8:21 AM This is probably the problem of grails, not SpringSecurity UI - domain class of plugin is not "visible" in run-war (or war) instead od run-app. (No DB table was created also, when using war or run-war).
The simplest workaround I used was creating own domain class - RegistrationCode2 and RegisterController extending grails.plugins.springsecurity.ui.RegisterController
and overriding methods register, forgotPassword, resetPassword and verifyRegistration to use RegistrationCode2
instead of RegistrationCode.
Stupid workaround, but it works