As far as I could gather from the documentation the YARG reporting gives you the functionality to use entities (directly or by using JPA or SQL) - but in my instance I have a service that calculates current stock from various entities and I want to use it in a report.
this can be solved using groovy as the report dataset type (see the docs for more info).
Just do a
// my groovy script that loads the data...
// do some stuff
// get access to params via params['xyz']
println params['xyz']
// call services through AppBeans.get()
MyService myService = AppBeans.get(MyService)
def result = myService.myMethod()
// return a map as the data
return [myData: result]
If you don’t want to change it at runtime and add some software engineering practices like unit tests e.g. you can create report using class defined templates.