Use Layers in Anypoint Visualizer
When you associate a node with a layer, you create a visual representation of the applications in your network. Use one of the default layers provided by Anypoint Visualizer, or create a custom layer.
|The application will appear in its assigned layer in every view in which it is included.|
Map a node to a layer in the application’s properties file, or use the Anypoint Visualizer UI.
To automate the classification of nodes into layers, configure the property
anypoint.platform.visualizer.layer=<name> in the application’s properties file.
|This is an application property, not a server property.|
When this property is used, nodes automatically appear in the specified layer. If the layer doesn’t exist it is created.
For applications deployed to standalone Mule runtime engines, layer names set using runtime properties can contain only alphanumeric characters. Unsupported characters are replaced with an underscore.
You cannot reassign a node layer using the Anypoint Visualizer UI if you assign it using application property file.
If a node was not assigned to a layer at deployment time using the Runtime Manager UI or API, by default, the node is not assigned to a layer in Anypoint Visualizer. Use the Anypoint Visualizer UI to:
Assign a node to an existing layer or, if the node does not have a layer set via properties, change the assigned layer.
Create a new layer.
Select the application node to add to a layer.
You can hold the shift key to select multiple nodes to apply layers to all the selected nodes at once.
Result: The Customization section for the node appears in the Details tab of the node’s card as shown in the following image:
In the Customization section, expand the drop-down list next to Layer as shown in the following image:
Select the layer you want from the drop-down list.
Result: The node you selected appears within the layer as shown in the following image:
In addition to the default layers provided by Anypoint Visualizer, you can create new layers to customize the view of your application network.
Select the node to add to a new layer.
From the drop-down list in the Customization section, select New Layer.
Enter a name for your layer in the dialog box, then click Create Layer.
Result: The node appears in the new layer. You can add additional nodes to the new layer as necessary.
If a layer has no services assigned to it, Anypoint Visualizer deletes the layer automatically:
If the layer is a default layer, it disappears from the canvas but is still available in the dropdown.
If the layer is a custom layer, it disappears from the canvas and the dropdown.
Anypoint Visualizer also automatically adjusts the network display.
In the Visualizer display, use the arrows on the right side of the layer to move it up or down relative to the other layers.