Broadway Actor

Actor Overview

A Broadway Actor represents an action that is executed on a Stage of the Broadway flow to get input parameters and return output parameters. For example, reading a file, creating a table, parsing an object or concatenating a string.

Broadway offers a number of built-in Actors that address a wide range of predefined activities that can be added to Broadway flows.

When a flow requires business logic that is not supported by a built-in Actor, a JavaScript Actor can be used for executing the JavaScript code provided in the script Input parameter. Alternatively, you can use the LuFunction Actor to invoke Java functions or build your own Java Actor.

This article describes the following options for working with Actors:

To learn about more complex scenarios, such as creating or editing an Actor, refer to the Actor Editor article.

How Do I Add Actor to Stage?

To add an Actor to a Stage in a Broadway flow:

  1. Click anywhere in the Stage area to open the Add Actors to [Stage Name] window, which displays a list of categories on the left and Actors of each of these categories on the right.
  2. Search for the required Actor and select it.
  3. Click Submit to finish the action and to add the Actor to the Stage.

Note that you can add a call to an inner flow by switching the radio button from Actors to Flows at the top-right of the pop-up window. Select a flow and click Submit. At that point, the InnerFlow Actor, whose aim is to execute the Broadway flow that it encapsulates, is added to the stage. Click for more information about Inner Flows.

image

Broadway Co-pilot

Starting from Fabric V8.2, Broadway includes an AI-based capability to search for required actors using natural language rather than standard key words.

To start using the Co-pilot, make sure an LLM AI interface is defined in the project as it is a prerequisite. Note that prior to an AI interface creation in a project, it is required to install the relevant extension (e.g. OpenAI Connector).

Open the Add Actor window, select the AI icon as shown below and populate the prompt describing what action should be performed by the actors:

image

Upon clicking Enter, the LLM model is invoked. The LLM returns an explanation, stating what actors are needed, and accordingly they are retrieved from the Broadway repository. At this stage, the actors can be added to a flow, and the user should complete the flow creation by adding the links between the actors. When multiple actors are suggested by the Co-pilot, they can be added all at once.

image

How Do I Save a Flow as an Actor?

A flow can be encapsulated and then reused as an inner flow in another flow. For example, an inner flow that handles errors. This is an excellent solution for reusing business logic and for avoiding complex flows that include many steps.

To save a flow as an Actor, click Actions > Save as Actor in the Main menu of the Broadway flow window.

How Do I Export an Actor?

An Actor can be exported to create another Actor that inherits the current Actor’s logic. By doing so, specific business logic can be reused in different places in the flow. Once exported, the new Actor is added to the list of built-in Actors.

To export an Actor, click Export Actor in the Actor's context menu.

Dynamic Logic Actors

Dynamic Logic Actors include dynamic logic as one of their input parameters. Among the most frequently used Actors are:

  • JavaScript Actor, which executes the JavaScript code provided in the script parameter and returns the value of the last expression.
  • DbCommand Actor, which executes the SQL command provided in the sql parameter.

Actor Description and Remarks

The description of the Actor is part of the Actor's file. A remark is a user's comment added during the flow implementation.

When exporting an Actor, the Actor's remarks are copied to the description of the new Actor type.

Click image in the top-right corner of the Actor to open the Actor's context menu and select Description to view the description of the Actor type. The Description window is displayed in a read-only mode.

To add your own remark to an Actor, select Remark in the Actor's context menu.

Once there is a remark, you can view it by clicking the green asterisk . To delete a remark, remove its text and close the remark.

Previous

Broadway Actor

Actor Overview

A Broadway Actor represents an action that is executed on a Stage of the Broadway flow to get input parameters and return output parameters. For example, reading a file, creating a table, parsing an object or concatenating a string.

Broadway offers a number of built-in Actors that address a wide range of predefined activities that can be added to Broadway flows.

When a flow requires business logic that is not supported by a built-in Actor, a JavaScript Actor can be used for executing the JavaScript code provided in the script Input parameter. Alternatively, you can use the LuFunction Actor to invoke Java functions or build your own Java Actor.

This article describes the following options for working with Actors:

To learn about more complex scenarios, such as creating or editing an Actor, refer to the Actor Editor article.

How Do I Add Actor to Stage?

To add an Actor to a Stage in a Broadway flow:

  1. Click anywhere in the Stage area to open the Add Actors to [Stage Name] window, which displays a list of categories on the left and Actors of each of these categories on the right.
  2. Search for the required Actor and select it.
  3. Click Submit to finish the action and to add the Actor to the Stage.

Note that you can add a call to an inner flow by switching the radio button from Actors to Flows at the top-right of the pop-up window. Select a flow and click Submit. At that point, the InnerFlow Actor, whose aim is to execute the Broadway flow that it encapsulates, is added to the stage. Click for more information about Inner Flows.

image

Broadway Co-pilot

Starting from Fabric V8.2, Broadway includes an AI-based capability to search for required actors using natural language rather than standard key words.

To start using the Co-pilot, make sure an LLM AI interface is defined in the project as it is a prerequisite. Note that prior to an AI interface creation in a project, it is required to install the relevant extension (e.g. OpenAI Connector).

Open the Add Actor window, select the AI icon as shown below and populate the prompt describing what action should be performed by the actors:

image

Upon clicking Enter, the LLM model is invoked. The LLM returns an explanation, stating what actors are needed, and accordingly they are retrieved from the Broadway repository. At this stage, the actors can be added to a flow, and the user should complete the flow creation by adding the links between the actors. When multiple actors are suggested by the Co-pilot, they can be added all at once.

image

How Do I Save a Flow as an Actor?

A flow can be encapsulated and then reused as an inner flow in another flow. For example, an inner flow that handles errors. This is an excellent solution for reusing business logic and for avoiding complex flows that include many steps.

To save a flow as an Actor, click Actions > Save as Actor in the Main menu of the Broadway flow window.

How Do I Export an Actor?

An Actor can be exported to create another Actor that inherits the current Actor’s logic. By doing so, specific business logic can be reused in different places in the flow. Once exported, the new Actor is added to the list of built-in Actors.

To export an Actor, click Export Actor in the Actor's context menu.

Dynamic Logic Actors

Dynamic Logic Actors include dynamic logic as one of their input parameters. Among the most frequently used Actors are:

  • JavaScript Actor, which executes the JavaScript code provided in the script parameter and returns the value of the last expression.
  • DbCommand Actor, which executes the SQL command provided in the sql parameter.

Actor Description and Remarks

The description of the Actor is part of the Actor's file. A remark is a user's comment added during the flow implementation.

When exporting an Actor, the Actor's remarks are copied to the description of the new Actor type.

Click image in the top-right corner of the Actor to open the Actor's context menu and select Description to view the description of the Actor type. The Description window is displayed in a read-only mode.

To add your own remark to an Actor, select Remark in the Actor's context menu.

Once there is a remark, you can view it by clicking the green asterisk . To delete a remark, remove its text and close the remark.

Previous