The JAR for this plugin includes the classes for the test domain classes (saml.TestRole, saml.TestSamlUser and saml.TestUserRole). And the META-INF/grails-plugin.xml then includes these as resources. This results in the creation of matching tables. I've confirmed this quickly by chaning the datasource in my test app to be a file based H2 database, and then inspecting the schema.
I came across this in my efforts to convert an internal plugin which also has the above three domain classes for testing. In trying to fix it I've been attempting to follow the documentation as per Customizing Plugin Contents. But at best this results in a broken plugin, as the references still remain in grails-plugin.xml, and then at start up it can't find those classes.
This plugin (saml) also has setup exclusions for domain classes in SpringSecuritySamlGrailsPlugin.groovy but unfortunately to no effect.
Ahhh, well while writing this I fixed my other plugin thanks to this:
Plugin version: 3.3.0 Grails version: 3.3.3
The JAR for this plugin includes the classes for the test domain classes (
saml.TestRole
,saml.TestSamlUser
andsaml.TestUserRole
). And theMETA-INF/grails-plugin.xml
then includes these as resources. This results in the creation of matching tables. I've confirmed this quickly by chaning the datasource in my test app to be a file based H2 database, and then inspecting the schema.I came across this in my efforts to convert an internal plugin which also has the above three domain classes for testing. In trying to fix it I've been attempting to follow the documentation as per Customizing Plugin Contents. But at best this results in a broken plugin, as the references still remain in
grails-plugin.xml
, and then at start up it can't find those classes.This plugin (saml) also has setup exclusions for domain classes in
SpringSecuritySamlGrailsPlugin.groovy
but unfortunately to no effect.Ahhh, well while writing this I fixed my other plugin thanks to this:
It looks as though the syntax has changed for
pluginExcludes
- no package specific. So we need to:pluginExcludes
; andjar
block inbuild.gradle
with anexclude
P.S. I observed this is not new in 3.3.0, as I inspected the 3.1.2 JAR and its got the same.