MUnit for Java Programmers: Test Assertions

February 20 2020


At the heart of unit tests are assertions which provide a mechanism for comparing expected outcomes with actual outcomes. JUnit provides a large selection of overloaded convenience methods that perform predefined logical assertions, such as testing for equality, negations, and conditions specified by a matcher. MUnit also provides a similar set of assertion capabilities such as to assert two values as equals, validate a logical condition, and a variety of other custom assertions that replicate familiar JUnit assertions.

An introduction to MUnit for Java programmers

February 13 2020


Unit tests are an integral part of the software development lifecycle. However, for most it is a task that must be endured and compounded by what seem like arbitrary test coverage targets.

In this blog, I will introduce MUnit by making reference to concepts already familiar to Java developers, thereby making the transition to MuleSoft developer and architect smoother.

DataWeave function chaining for Java programmers

In this article, you will learn how to use method chaining in DataWeave with reference to Java 8 lambda expressions and how to convert from Java Streams into DataWeave chaining. 

Java 8 introduced the Stream API, which is used to process a stream of objects. Various methods can be chained together such as filter, limit, map, and reduce,

DataWeave lambdas for Java programmers

dataweave howto

In Mule 4, DataWeave is everywhere: every listener and processor can be configured with it. Because most Mule users already know Java well, this article will help Java developers to easily use DataWeave by rewriting their lambdas expressions.

DataWeave performance demystified


I have been asked so many times about DataWeave Performance during my time in the field. This is because developers try to find arguments to not use it when they realize that a new and proprietary programming language is introduced. Most of the time they have the same “natural response” of resolving the problem by going to the known and comfortable zone called “Java.”

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.  

Need 77% performance boost? No problem with Mule 3.7 using Kryo

Currently, Mule relies on plain old java serialization in order to store objects to files or to replicate them through a Mule cluster. That imposes limitations on:

JMS Queue: When Size Does Matter


Anypoint Platform is fast. The legacy systems that it often connects to? Not so much.

Therefore, in real world use cases, the requirements often call for limiting the message throughput to protect the endpoint systems from being overwhelmed by traffic. Architectural designs that support message throttling commonly incorporate some elements of message queues to stage and hold messages in-flight, so that the endpoints can process them at a steadier pace.

Give your old school API some love


If you’re an assiduous reader of this blog, then you probably already heard about our vision around APIs, our Anypoint API Manager solution and all our RAML based stories. Those are our recommended way of approaching REST APIs and if you haven’t already, we all highly recommend you to take a look at them. However, we’re about connecting everything, everywhere. Thus we recognize that there are a lot of APIs out there built in plain old Java code and a migration process is not something you can do overnight.

API Manager – Simple JAVA Client Access Example


I recently had a customer wanting to build a simple UI to maintain additional filtering data associated to a defined “Contract” contained within API Manager. This code would have to run outside of the MuleSoft eco-system, as a service, within a JAVA Data Layer container environment.

My goal was to develop a very simple JAVA API Manager Client Access Example, whose concept prototype could be used as a basis to construct a necessary Mashup of API Manager Resources and Custom Client oriented resources.