We are very excited to announce the GA release of Mule 4 and Studio 7, a major evolution of the core runtime behind Anypoint Platform. Mule 4 enhances application development velocity with up to 50% fewer steps and concepts to learn, including: a simplified language for connectivity, clear access to data, automatic tuning, and smoother upgrade processes.
The Mule 4 release is particularly unique to MuleSoft because it involved a massive public beta program. Over the past several months, Mule 4 has been tried and tested again and again by developers all over the world. We’ve been excited to hear from developers where Mule 4 represents a simpler learning experience to get their developers successful in connecting their business.
Mule has evolved a lot since the last major release of Mule 3.0 in 2010, growing to solve legacy modernization projects, power secure SaaS integrations, and provide full API lifecycle management. Mule 4 represents the next generation of tools and capabilities for MuleSoft and our developer community; read on to learn more about the evolution of Mule and the new features in Mule 4.
Mule 4: The engine for building today’s APIs and integrations
Mule has grown tremendously since the early days of Mule 3. We built Mule to make it possible for our customers and developers to connect quickly and innovate faster than they had ever before. Early on, our users were Java and .NET specialists trying to integrate and optimize for accountability for time and resources, system reliability, and information security. As Mule grew, so did the number of data and information sources across mobile, SaaS, IoT, and big data systems; this magnified the importance of connecting to these sources of data and the pressure our developers faced to ship projects faster.
Today, Java developers, data analysts, Salesforce administrators, and other systems specialists work symbiotically to build out application and integration projects to meet the demands of the business. Mule’s natural next progression is to empower these people to cycle through projects with speed and velocity.
Mule 4 not only allows project stakeholders to create, contribute, and control integration and application development, but also makes it easier to cope with the massive amount of systems, devices, and sources of data to connect and integrate with. Mule 4 simplifies how to create applications, operates at scale, and prioritizes developer productivity and velocity. This focus dramatically reduces common integration tasks––allowing IT to deliver on projects faster.
Mule 4: Boost developer velocity
A simplified, highly performant expression language
Mule 4 introduces DataWeave 2.0 as the default expression language. DataWeave simplifies many company tasks, making it possible to query and transform data anywhere in your flow:
- Access data without transformations: Users no longer need to convert data into a set of objects to access it; instead, they can write expressions to access the data stored in CSV, JSON, XML or other forms directly.
- Simplified syntax: All operators are now functions, making DataWeave easier to learn.
- New advanced capabilities: Call Java functions directly, use multi-line comments, and define function types and variable types with type inference.
Design time error handling and new try scope
Mule 4 introduces a new ‘error’ construct and ‘try’ scope feature built directly into Mule so that users do not need to deal with Java exceptions directly. The ‘error’ concept works in conjunction with Studio to show a complete list of errors that each component can potentially raise. The ‘try block’ allows users to handle each error easily at design time, and eliminates the need to create specific flows to catch errors. With state-of-the-art error handling and clearer error messages, debugging is quicker than ever before.
Jumpstart flows with new connector triggers
Anypoint Connectors now include new “triggers” for Mule flows. Rather than needing to configure logic to perform scheduled queries against target systems, the connector itself contains built-in logic to listen for data changes, such as when a new database row is created, a Salesforce lead is changed, or a file is created. Also, the File and FTP connectors have also been significantly enhanced, providing users with the ability to append files, and create directories, and perform other operations.
The Mule SDK is the successor to the Anypoint Connector DevKit that enables developers to easily extend Mule and create new Anypoint connectors which can be shared in Anypoint Exchange. The Mule SDK retains the simple, annotation-based programming model of DevKit, but offers many improvements, such as enhanced forward compatibility with Mule versions, transactions support, and the ability to create routers.
An updated Message model
Mule 4 also introduces a simplified Message model which makes it easier to access content and metadata. You no longer need to think about transport barriers because there is only one scope of properties.
Repeatable data streaming
Mule 4 manages streaming automatically. Users no longer need to add logic into applications to access data streams repeatedly. Mule will automatically handle content caching, larger than memory payloads, and closing of streams for the user. Users can stream and access data concurrently in order to process and transform information at scale.
Improved Studio productivity
Studio 7 features a new Mule Palette to provide one-click access to your favorite integration components. Use shortcuts to switch between viewing the configuration in the visual interface or XML format. Use the universal toolbar in Studio to switch between users, organizations, or accounts within any project.
Mule 4: Improve operational efficiency
A new execution engine
Mule 4 ships with a new reactive, non-blocking execution engine. This engine makes it possible to achieve optimal performance without having to do manual tuning steps, such as declaring exchange patterns, processing strategies or threading configuration.
Simplified upgrade experience
With the new classloader isolation between your Mule application, the runtime, and Anypoint connectors, any library changes that occur internally do not affect the application itself. Connectors are distributed outside the runtime as well, making it possible to get connector enhancements and fixes without having to upgrade your runtime or vice versa.
We hope that these new features, and the overall evolution of Mule, excite you as much as they excite us. Thank you to the hundreds of developers that have been a part of the Mule 4 and Studio 7 beta journey over the past 6 months. This release would not be possible without you!
We also think you’ll also find the following documentation resources helpful as you get started: