HowTo – Invoke Java/Groovy logic in DataWeave

December 20 2017

1 comment.
dataweave howto

When building DataWeave transformations for your Mule application, you will run into situations in which you will need to invoke external logic that may be encapsulated in a Java POJO, Groovy, Python, Ruby script, or really any lookup that uses a CSV file or database table as part of the transformation.  

Continuous Integration with Mule and Gradle

motif

gradlegradle

We use automated build systems not only because they make our lives easier by taking care of building our apps, but because they can run our automated tests and deploy what we build to the target platform. One of our options for building applications (especially Mule applications) is Gradle. The Gradle plugin for Mule apps provides a variety of ways to deploy Mule apps and that’s what we’ll be covering in this post!

Library upgrades in Mule ESB 3.6

motif

If you have read the Mule ESB 3.6 release notes then you already know what I’m about to say, but just to recap, here we go…

A lot of effort was put in 3.6 to upgrade our libraries stack. Even though we try to stay innovative, it doesn’t make sense to reinvent the wheel all the time, so we use a lot of third-party libraries. However, keeping those up-to-date while maintaining our strict backwards compatibility policy is something that’s really difficult to do.

Polyglot programming in Mule: Scripting pack now part of the distribution

motif

Sometimes when transforming complex data structures or applying business rules to your integration, you may face the need to add some custom code. We make our best effort to try to productize and solve every common use case we come across, but sometimes it’s just not enough. When that happens, you probably turn to the programming language you love the most for help. If you’re a Java guy, you can build your own custom components and/or transformers inside Mule.

Fake and Stub objects creation using Groovy

motif

Automated testing using XUnit style frameworks can be achieved using several techniques. You can test a particular class, group of classes, or all your system at once. This selection will conform your SUT (system under test). You must define which technique or mix of techniques to use depending on your system and what best suits it.

In case you are trying to isolate your SUT form other components, such as collaborators, then you will need to create a “double”

Take a ride in the CLI with Mule Jockey

motif

How many web sites/web services have you wished you could just interact with over the command line? Sometimes, you just want to type commands in your shell. I can name at least 3 of our products which I’ve wished I could do that with: iON, MMC, and Tcat.

There are some challenges though. Bash/BAT file scripts don’t provide facilities to interact with web services. Then, if you go with a cross platform language,