O'Reilly logo

Alfresco CMIS by Martin Bergljung

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using CMIS in Groovy scripts

Using OpenCMIS to talk to a CMIS server via Java is quite easy compared to using basic protocol bindings such as the AtomPub binding. But by using the OpenCMIS API via the Groovy scripting language, we can also do the following:

  • Get less code, making the application more readable
  • Run the code without the need to compile it, making a round trip from code change to test quicker
  • Script content updates so we can easily run checks or updates, such as cron jobs
  • Use any Java library as Groovy runs on the JVM

Install Groovy using the following command:

$ sudo apt-get install groovy

If you are not familiar with Groovy, I recommend that you spend 1 to 2 hours reading a tutorial about it before coding anything in this section at ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required