GPars has been designed as a concurrency library for the Groovy programming language. This naturally implies GPars is very friendly to Grails and Griffon frameworks and offers applications, which build on top of these frameworks, the ability to:
- Run expensive computations in the background
- Parallelize access to remote services or databases and so limit the effect of latency of these services
- Leverage the high-level concurrency concepts like actors, agents, parallel collections, dataflow and others
To enable GPars in your Grails application, alter the BuildConfig.groovy file as follows:
In Griffon, use the following:
Once the dependency has been specified, you can start using GPars in your project. You may now want to check out the Groovy Fast Track to do your first GPars experiments. Alternatively go directly to the User Guide and have fun!