From defe088fedd90a96891ef7f53bb265b22fbeefdc Mon Sep 17 00:00:00 2001 From: Fernanda Date: Tue, 14 Apr 2026 09:03:51 -0300 Subject: [PATCH 1/3] Update int-configure-components.adoc --- .../ROOT/pages/int-configure-components.adoc | 66 +++++++++++++++++++ 1 file changed, 66 insertions(+) diff --git a/modules/ROOT/pages/int-configure-components.adoc b/modules/ROOT/pages/int-configure-components.adoc index 31c7cc0a5..c3dbf6056 100644 --- a/modules/ROOT/pages/int-configure-components.adoc +++ b/modules/ROOT/pages/int-configure-components.adoc @@ -41,6 +41,72 @@ To set custom metadata for a component, add or open the component in the canvas image::int-set-component-custom-metadata.png["Set Custom Metadata for a component"] +[[canvas-actions]] +== Refactor Flows Using Canvas Actions + +Canvas actions enable you to reorganize and refactor your flows directly from the canvas. You can move, copy, and extract components without manually updating the underlying XML. + +These actions help you reduce rework, maintain clean flow structures, and safely evolve your implementations as complexity grows. + +You can use canvas actions to: + +* Move components within a flow or across files +* Copy and reuse components in the same or different projects +* Extract components into a new flow or subflow + +When you perform these actions, Anypoint Code Builder automatically updates references, connections, and configurations to prevent broken flows. + +[NOTE] +Some components can't be extracted or moved. If a selection includes unsupported components, the available actions are limited to prevent invalid configurations. + +=== Extract Components to a Flow + +You can extract one or more components into a new flow or subflow. This is useful for simplifying large flows or reusing logic. + +To extract components: + +. Select one or more components in the canvas. +. Right-click the selection and select *Extract to Flow*. +. Enter a name for the new flow. +. Select the target Mule configuration file. +. Configure metadata preferences if needed. +. Click *Extract*. + +Anypoint Code Builder creates the new flow and replaces the selected components with a Flow Reference in the original flow. + +By default, the current file is selected as the target configuration file. + +[NOTE] +The *Extract to Flow* option is available only for supported components. If the selected components can't be extracted, the option isn't displayed. + +=== Metadata Preferences + +When extracting components, you can define metadata preferences for the new flow. + +You can configure: + +* Payload metadata +* Attributes metadata +* Variables metadata + +These settings help ensure that the extracted flow has the correct input structure. + +=== Multi-Selection Behavior + +You can select multiple components by holding Shift and clicking components in the canvas. + +=== Validation and Safeguards + +Canvas actions include built-in validation to prevent invalid operations. + +For example: + +* Extraction is blocked until required metadata is loaded +* Unsupported components can't be extracted +* Actions are disabled while the canvas is loading + +These safeguards help ensure that your flows remain valid and executable after refactoring. + [[copy-components]] == Copy Components From 3bcd91de20184c7008f05445b8fd0b0d1eac4640 Mon Sep 17 00:00:00 2001 From: Fernanda Ailup <105381467+failup@users.noreply.github.com> Date: Tue, 14 Apr 2026 11:12:25 -0300 Subject: [PATCH 2/3] Apply suggestions from code review Co-authored-by: Cristian Pose <101070178+Crispy-Salesforce@users.noreply.github.com> --- modules/ROOT/pages/int-configure-components.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/ROOT/pages/int-configure-components.adoc b/modules/ROOT/pages/int-configure-components.adoc index c3dbf6056..449f53e2f 100644 --- a/modules/ROOT/pages/int-configure-components.adoc +++ b/modules/ROOT/pages/int-configure-components.adoc @@ -44,7 +44,7 @@ image::int-set-component-custom-metadata.png["Set Custom Metadata for a componen [[canvas-actions]] == Refactor Flows Using Canvas Actions -Canvas actions enable you to reorganize and refactor your flows directly from the canvas. You can move, copy, and extract components without manually updating the underlying XML. +Reorganize and refactor your flows directly from the canvas. Move, copy, and extract components without manually updating the underlying XML. These actions help you reduce rework, maintain clean flow structures, and safely evolve your implementations as complexity grows. @@ -61,7 +61,7 @@ Some components can't be extracted or moved. If a selection includes unsupported === Extract Components to a Flow -You can extract one or more components into a new flow or subflow. This is useful for simplifying large flows or reusing logic. +Extract one or more components into a new flow or subflow. This is useful for simplifying large flows or reusing logic. To extract components: From 7093011aaaa40b943787a5575f04b9213c587a0a Mon Sep 17 00:00:00 2001 From: Fernanda Date: Thu, 16 Apr 2026 09:05:09 -0300 Subject: [PATCH 3/3] Update int-configure-components.adoc --- modules/ROOT/pages/int-configure-components.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/ROOT/pages/int-configure-components.adoc b/modules/ROOT/pages/int-configure-components.adoc index c3dbf6056..97e43dbe7 100644 --- a/modules/ROOT/pages/int-configure-components.adoc +++ b/modules/ROOT/pages/int-configure-components.adoc @@ -57,7 +57,7 @@ You can use canvas actions to: When you perform these actions, Anypoint Code Builder automatically updates references, connections, and configurations to prevent broken flows. [NOTE] -Some components can't be extracted or moved. If a selection includes unsupported components, the available actions are limited to prevent invalid configurations. +Some components can't be extracted or moved. If a selection includes unsupported components, the available actions are limited to prevent invalid configurations. In some cases, the *Extract to Flow* option is displayed but no extraction is performed, for example when extraction across scopes isn't supported. === Extract Components to a Flow @@ -77,7 +77,7 @@ Anypoint Code Builder creates the new flow and replaces the selected components By default, the current file is selected as the target configuration file. [NOTE] -The *Extract to Flow* option is available only for supported components. If the selected components can't be extracted, the option isn't displayed. +Some components can't be extracted or moved. If a selection includes unsupported components, the available actions are limited to prevent invalid configurations. In some cases, the *Extract to Flow* option is displayed but no extraction is performed, for example when extraction across scopes isn't supported. === Metadata Preferences