Logic Apps: Tips and Tricks about the “new” Logic Apps Designer

Posted: April 22, 2016 in Azure App Services, Logic Apps
Tags: , , , , , ,

If you are following Logic Apps since its beginning, you must love the new Logic Apps Designer! That is a little closer to his on premise brother (BizTalk Orchestration Designer). I am saying this because now, finally, the new designer uses a top-down approach instead of a left-right approach that existed in the previous version of Logic Apps.

01-Logic-Apps-Designer-left-right-approach

Besides this big improvement in the Visual Flow (top-down approach instead of a left-right approach), the designer is being constantly improved with a several new capabilities such as:

  • Managed Connectors, search capabilities within the designer
    • Adding API Apps to a logic app is now more intuitive
  • We now also have the ability to collapse and expand the tiles/shapes
  • We have a first class experience with the HTTP + Swagger connector within the designer
  • If-else conditions within the designer itself. No need to open up the code view to look into the conditions box.
  • Call nested Logic Apps within the designer
  • And many more, the list go on and on!

02-Logic-Apps-Designer-top-down-approach

In this post we will provide some tips and tricks in working within the new Logic Apps Designer, in terms of actions that we can make on it, and describe some of its behavior

Adding actions (tiles or shapes) …

Adding actions in the middle of the existing flow is not allowed, at least for now. We are only able to add actions on the bottom of our Logic App flow or at the bottom of each condition branches.

To add an action or condition in the Logic App flow: we need to click on the plus sign, and then choose “Add a condition” or “Add an action

09-Logic-Apps-Designer-add-action-or-condition

To add an action inside condition branches, we need to click in “Add an action” button that is present on the top right corner of the condition branch

10-Logic-Apps-Designer-add-action-condition

  • We can add several actions inside a branch;
  • Nested conditions, at least for now, are not allowed;
  • And we can only add actions on the “If no, do nothing” branch, if we have at least one action in the “If yes” branch;

Deleting actions (tiles or shapes) …

If we take in consideration the flow in the picture above, you will notice 4 actions will have “…” (three dots) option in the tile. This means that we can take an action on them, in this case the “Delete” option:

03-Logic-Apps-Designer-Delete-option-action

However, in this sample the other two tiles/shapes available, “Search tweet” and “Condition” doesn’t have this option and we cannot easily delete this action or step.

The reason is because:

  • Their outputs are being used by other actions
    • In this case the “Search tweet” output is being used as input on the “Condition”, “Create File” and “Send approval email”
  • or they contain child action
    • The “Condition” tile as one “child” action in each branch;

04-Logic-Apps-Designer-Cannot-Delete-action

If we remove the “Search tweet” output being used as input on the “Condition”, “Create File” and “Send approval email” or remove these actions, we will now be able to delete the “Search tweet” action

05-Logic-Apps-Designer-Cannot-Delete-action-fixed

Moving actions (tiles or shapes) …

Noticed that you make a mistake and forgot to add an action between previous ones! Well, adding actions in the middle of the existing flow is not allowed, at least for now. However, we have the possibility to add and action in the end and drag and drop to another position inside your flow (arranging/modifying shape dispositions) … within certain conditions…

Again, if we take in consideration the Logic App that we are working above. We have several shapes, “Condition”, “Create file” and “Send approval email” that is consuming the output of a previous action, the “Search tweet

06-Logic-Apps-Designer-movind-Dependecies

If we try to move the “Condition” shape on top of the “Search tweet” shape:

11-Logic-Apps-Designer-moving-condition

We can’t move because it depends on the “Search tweet” action. However, if we try to do the same for the “Dynamic CRM Online – Create a new record”, that is still to be configured, i.e., it doesn’t have any dependency from previous ones

07-Logic-Apps-Designer-movind-no-Dependecies

We will then be able to drag and drop to any place of our flow

08-Logic-Apps-Designer-movind-no-Dependecies-1

08-Logic-Apps-Designer-movind-no-Dependecies-2

The only exception is that you cannot put on top of the trigger, in this case, the “Recurrence” shape.

In summary, you can move shapes only to:

  • Underneath the Logic Apps trigger;
  • Underneath their dependencies;
Moving actions inside conditions

Yes, we can move actions into the conditions branches, between them or remove them from within the conditions branches… again, within certain conditions regarding mainly the “If yes” branch:

  • If we have only one action inside the “If yes” branch
    • We cannot remove this action to outside the “If yes” branch, if the “If no” branch contains any action;
    • We need to delete or remove the shapes inside the “If no” branch to be able to move/remove the action inside the “If yes”;

The reason that this happens is because, the design doesn’t allow you to add action in the “If no” branch until you have an action inside the “If yes” branch

  • If we have several actions inside the “If yes” branch
    • We cannot remove the first action to outside the “If yes” branch, if the “If no” branch contains any action;
    • We need to delete or remove the shapes inside the “If no” branch to be able to remove the action inside the “If yes”;
    • Or we need to move the first action to another position inside the “If yes” branch and then move it to another position inside your flow (outside the “If yes”);

The reason that this happens is because, the first action inside the “If yes” is the “trigger” that allows you add actions in the “If no” branch… so it will be deep tied to the “If yes” branch and the design will not allow it to be moved

  • If we don’t have any action inside the “If yes” branch
    • We cannot move or add an action to the “If no, do nothing” branch;
    • We need to first add an action in the “If yes” branch;

The reason that this happens is because we need to have at least one action inside the If yes” branch to be able to add or move actions to the “If no, do nothing” branch – this is a default behavior of the design. The first action inside the “If yes” is the “trigger” that allows you add or move actions in the “If no, do nothing” branch.

Comments
  1. Anonymous says:

    Great write up …the only thing which is holding us right now at our side to move couple of applications to logic app is : Feature to stop/Suspend resume messages ( That feature is badly missing here ) .and exception handling related blocks…

  2. sandeep chugh says:

    option of suspend/resume/stop instances is still not available which is a big hurdle for us to move couple of apps we would like to move to logic app…Let me know if you know when that feature is coming …

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s