Using Groovy to implement a Service Interface

As groovy is the language of my choice, i would be interested, if it is possible to use Groovy for doing an Implementation of a Service like:

class MyServiceBean implements MyService {
    String myMethod() {
        println "hello World" 

Trying to do this, did not seem to work when executing. It says the following:

IllegalArgumentException: Service app-core/test_MyService is not registered in LocalServiceDirectory

In the Controller Layer a Groovy File works as expected. Can anybody give me a hint? That would be great.

Mario, thanks for your question. You need to configure groovy for your core module in build.gradle file, which is located in root directory of the project. In the section configure(coreModule) add:

apply (plugin: "groovy") 
sourceSets { 
  main { groovy { srcDirs = ["src"] } } 
  test { groovy { srcDirs = ["test"] } } 

thx, that did the trick!