Using context menu to add nodes and actions to message flow
So far we have used the drag-and-drop feature for adding nodes and actions to the message flow of a proxy service. However, there is also a more developer-friendly approach, where we don't have to know where in the palette a given item is and especially which items are allowed in a given context.
Getting ready
You can import the OSB project containing the base setup for this recipe into Eclipse OEPE from \chapter2\getting-ready\using-context-menu-to-add-nodes-actions
.
How to do it...
Navigate to the Message Flow tab and perform the following steps:
- In the message flow, right-click on any element, for example, on the Default branch of the operational branch node.
- In the given context, Insert Into and Insert After are possible.
- Select Insert Into and then the element to be added. In the given context, the Default handler, only a Conditional Branch, an Operational Branch, a Pipeline Pair, or a Route are valid and therefore the context menu only holds these items.
- Select Pipeline Pair to add the unsupported error-handling code as shown in the previous screenshot.
- Right-click on the Request Pipeline of the pipeline pair just added earlier and check the context menu.
- Only Insert Into | Stage is available in this context.
How it works...
The context-sensitive menu helps in choosing the right element at a given place in the message flow. There is an Insert Into and an Insert After menu, the first inserting the element into the element that holds the focus and the second one adding it after the one holding the focus.
This is very helpful, especially for a beginner, because this way we no longer have to exactly know which elements are allowed at a given place in the message flow. If using the drag-and-drop feature, the drop will not be possible for a certain action or node, if it's not allowed in the given context. Only those elements that are valid at the given context can be chosen.
- 網(wǎng)管員典藏書架:網(wǎng)絡(luò)管理與運(yùn)維實戰(zhàn)寶典
- SEO 20日
- GPS/GNSS原理與應(yīng)用(第3版)
- OpenLayers Cookbook
- 物聯(lián)網(wǎng)信息安全
- Mastering JavaFX 10
- Kong網(wǎng)關(guān):入門、實戰(zhàn)與進(jìn)階
- Working with Legacy Systems
- Echo Quick Start Guide
- 人人都該都懂的互聯(lián)網(wǎng)思維
- Dart Cookbook
- LwIP應(yīng)用開發(fā)實戰(zhàn)指南:基于STM32
- Guide to NoSQL with Azure Cosmos DB
- 新媒體交互藝術(shù)
- 5G智慧交通