Team,
Our application is a Root Cause Analysis Computation Engine for Telecom
networks. We have been implementing the logics in java only so far.
We are now planning to write DSLs for each feature and write the logics
using the DSL. We have implemented a framework for plugging in any number
of DS
Hi Adithyan,
How about caching the class instance and reuse it? Here are some
scratch code for your reference:
```
static LRUCache lruCache = new LRUCache(100);
def dslSrc = '''
your DSL source code
'''
def md5 = md5(dslSrc)
def resultClass = lruCache.getAndPut(md5, k -> new GroovyShell
and keep the compiled scripts in a
cache, see the mentioned docs on how to obtain thread-safety with the Binding
object.
From: K Adithyan (tech) [mailto:adi.k@gmail.com]
Sent: Wednesday, February 7, 2018 4:15 PM
To: users@groovy.apache.org
Subject: Executing Groovy DSL scripts concurrently
concurrency issues.
>
>
>
> You could use the GroovyClassLoader directly and keep the compiled scripts
> in a cache, see the mentioned docs on how to obtain thread-safety with the
> Binding object.
>
>
>
> *From:* K Adithyan (tech) [mailto:adi.k@gmail.com]
> *Se
sday, February 13, 2018 3:41 AM
To: users@groovy.apache.org
Subject: Re: Executing Groovy DSL scripts concurrently
That guide to integrating is *very* interesting! I had never seen
GroovyClassLoader before.
I work with a large application that uses GroovyShell a lot. It has thousands
of