Mule Studio 3.4 Preview
Mule Studio 3.4 Preview
Join the DZone community and get the full member experience.Join For Free
We are making this release of Studio available to the Mule community to get valuable feedback on our latest and greatest features. This blog post contains text and video introductions to the freshly-baked features included in this release.
As you read through this post and try the Studio features, please keep in mind that this is a pre-Beta version. Explore, discover and play, but do not use it to develop Mule apps for use in production.
To date, one of the biggest requests from our customers has been for a tool to debug Mule flows in Studio like you debug a Java application in a Java IDE. We are excited to respond to this request with the Visual Flow Debugger. We expect it to significantly simplify the Mule debugging experience.
Visual Flow Debugger allows you to place break points on any element within a flow, then execute your flow in debug mode. Mule stops the thread of execution as soon as it hits a break point. In the Debugger pane, you have visibility into the content and structure of the Mule message payload and properties. The screenshot below illustrates the variety of Debugger’s cool inspection capabilities.
Further, you can use Debugger to:
- dynamically execute Mule expressions
- insert breakpoints in your flow that are conditional on a boolean Mule expression statement
- request that Mule stops flow execution – and start up Debugger – anytime an exception is thrown.
The following short video demonstrates the Visual Flow Debugger in action.
Technical Note: In order to get the debugger working for a particular project, add the snippet below to the very beginning of mule configuration file (right after the <mule> element). This is a temporary work-around that will not be required for the actual product release.
<custom-agent name="debuggerAgent" class="com.mulesoft.mule.debugger.server.DebuggerAgent"/>
Mule developers are already familiar with DataMapper, a Mule feature that greatly simplifies complex data transformations between heterogeneous data sources. In this release of Mule, we have implemented a number of improvements to DataMapper.
The first improvement we added is a tool called FlowRef Lookup. As part of a transformation, DataMapper’s existing lookup table feature allows you to look up data within a CSV file, a database, or other user-defined location. This new FlowRef Lookup tool can look up content by executing a separate flow instead of looking it up within a table. This functionality allows you to make a call to one or more flows within your Mule app, then use the result within your mapping. (For now, this tool is implemented as though it were a Lookup Table, even though it’s technically not a table.)
This feature is quite powerful as it allows you to add multiple sources, backed by Mule flows, to any transformation. So long as you can design a flow to get to it, you can use the data in a DataMapper.
The second improvement we made to DataMapper is support for fixed-width data formats. Fixed-width formatted content is commonly used by mainframe – generally, legacy system – data feeds. Data in fixed-width format is positioned in specified character positions within each line (for example, dCustomerId is always represented by characters 9-21 on a line). Now able to support fixed-width content, DataMapper makes it much easier for you to integrate with mainframe and legacy systems.
Thirdly, DataMapper now includes the ability to auto-generate the input or output data structure of a transformation. To do this, you manually specify the format and structure of either the input or output part of the mapping, then select a data type for the corresponding part. At this point, DataMapper displays a “generate default” option which, if selected, demands that DataMapper auto-generate the data structure. No more labor-intensive work to manually define your data structure target!
Finally, we have improved the model for defining data structures. In previous versions of Studio, and depending on the type of the data, users were able to define the data structure manually, or point to an example file from which DataMapper could extrapolate the data structure. In this early preview release, we have extended these capability.
- Users can now also specify an example file for fixed-width and map formats.
- Users can now also define the data format manually (without the need for an example) for CSV, JSON, XML, and fixed-width data types.
The video below demonstrates some of these new DataMapper capabilities. Keep in mind that this is just a subset of the DataMapper enhancements that we are working on in 3.4. More features and improvements to come!
One of our goals for the 3.4 release of Mule is to make integrating with external endpoints even simpler than it is today. The first step towards this goal is the introduction of a Connections Explorer in Studio. This pane lists all of the endpoints in your flow, displaying a single view of all of your external connections. Best of all, in the Connections Explorer you can change the configuration of any connection and test its connectivity. Is it working? Find out with one quick test.
As part of this early availability release, Mule supports connection testing for database endpoints and Salesforce, Mongo DB, and Twitter Cloud Connectors. Also note that in this preview release you can only test connections of database elements on database nodes, not on data sources directly. In the final version of 3.4, we plan to support many more transports and Cloud Connectors.
Yet another extremely useful feature in this release is the ability to generate HTML documentation for a Mule project. In Studio, use the Export Mule Studio Documentation button (see screenshot below) to generate an HTML document that captures details of your project’s flows.
The generated documentation contains a nicely formatted HTML report that describes the overall flow and provides links to sections with details about each element within the flow. Also if you have entered any text in the Documentation field of your flow’s elements, Mule renders this text within the generated HTML report.
Single Studio Distribution
Last, but not least, is our unification of Studio. Previously, Studio was bundled and able to work with only a single edition (either CE or EE) of a Mule ESB runtime. Starting with this early preview release, you can extend a single Studio installation with different runtimes using the Eclipse install updates function.
With multiple runtimes installed, you can choose which version to use when creating a new Mule project.
For a detailed overview of the rationale and benefits of this single Studio distribution please see this blog post from Ross Mason.
But wait– there’s more!
Beyond the features described above, we have included many more improvements and functionality, such as:
- a Marquee component in Studio to further enhance Studio’s refactoring capability. With the Marquee component you can select multiple processors then rename, wrap, or extract them as a group.
- a Transaction Demarcation scope to create transaction delimitations
- several significant improvements to Studio’s performance with large projects
Stay tuned: we’ll be blogging about these features and more as we approach our final version.
What do you think?
As mentioned in the introduction of this post, the main aim of this early preview release is to get the product into the hands of our users so you can play around with the new features and offer some feedback.
Download the Mule Studio 3.4 Early Preview (See the lower part of the page under ‘Milestone Releases’) and send us your thoughts. We look forward to hearing from you. Enjoy!
Published at DZone with permission of Reza Shafii , DZone MVB. See the original article here.
Opinions expressed by DZone contributors are their own.