Is it possible to compile and sign grails plug-in? I am thinking about distributing my application logic using grails plug-in architecture and I do not want my client to be able to read that easily .groovy or to modify it. Is it possible to package it somehow or at least distribute only compiled .class?
3 Answers
Yes. you need to think more traditional Java.
Create a JAR with your logic in it and sign the jar. Put the minimum Groovy code in the plugin. You have not stated where the logic is if it's a controller or GORM object so I am not sure what you looking for 100%.
Hope this helps.

- 1,581
- 1
- 17
- 30
It is possible to compile and package groovy/java code into a jar and then use it in a grails app. (as Scott suggests) but these classes can not directly benefit from grails ie. no way to declare grails service, domain class or controller in a separate jar.
There is an issue in grails jira describing the same problem: http://jira.codehaus.org/browse/GRAILS-4956

- 11,077
- 20
- 84
- 119
Since Grails 1.4 M1 there are binary plugins, I assume this is exactly what you need. I'm not sure if signing is supported in any way, but it's at least possible to distribute the plugin without its sources.

- 39,465
- 6
- 87
- 97
-
yep, it seems binary plugin disto is available. I wonder why they didn't update te jira item mentioned in accepted answer. And once you have the jar, you can sign it... – Dan Jun 14 '11 at 19:29