Moving nodes/actions in Eclipse OEPE by drag-and-drop
This recipe will just present a simple approach for doing refactoring of nodes and actions within a single message flow. It uses the drag-and-drop functionality of the Eclipse OEPE to move around the items on the graphical representation of the message flow.
Getting ready
You can import the OSB project containing the base setup for this recipe into Eclipse OEPE from \chapter2\getting-ready\moving-nodes\actions-by-drag-and-drop
.
How to do it...
If an existing message flow needs to be refactored and some nodes or actions need to be moved around, the Eclipse OEPE provides us with the drag-and-drop functionality, and a simple way to achieve this. For example to move a Pipeline Pair node from one place to another, perform the following actions in Eclipse OEPE:
- Open the CustomerManagement proxy service and navigate to the Message Flow tab.
- Select the node to move, for example, the PipelinePair node in the FindCustomer branch.
- Drag the selected node and immediately Eclipse OEPE will show all the valid contexts, where the node could be dropped by a green circle. In our case, as the next screenshot shows, these are three places:
- Drop it in the StoreCustomer branch, just above the StoreCustomerRoute route node. The circle will change to yellow before the selected node can be dropped.
- The whole PipelinePair including all other items it might contain, Stage in our case, will be moved as well.
We have moved a whole node with all subitems from one place to another. The same can be done on a single-action level as well. To move an action to another place, similarly perform the following steps in Eclipse OEPE:
- Select the Log action inside the Stage nested in the PipelinePair node.
- Drag the Log action to the Routing action of the StoreCustomerRoute and drop it on the Request Action flow. Again the green circles show the places where a drop of the selected item is valid.