Actions
Any automated processes in a workflow are fulfilled by jobs.
For these jobs to run, you must create actions.
For example, to import an asset into the system automatically, you need to create and configure an import action.
You reference this action in your workflow and when the workflow runs an import job is created.
Dalet Flex supports an extensive list of Action Plugin Types that enable you to create many different kinds of actions. To create a simple import workflow, you will use the:
- Import Plugin type to create an Import action
- Extract Plugin type to extract technical data
- Create Proxy type to create a proxy version of the asset that you can preview in FlexMAM and FlexReviewer
There are many settings required to configure actions, some are mandatory and some are not.
You can supply static information that will be used every time the workflow runs, for example a specific storage resource that is always used as the target storage resource.
You can also supply dynamic information using Spring Expressions. The expression will be evaluated at runtime when the workflow starts to retrieve the variables that are required for the workflow to run, for example the name of the file currently being imported.
In other cases, if a setting is not mandatory and you do not supply a value, a default value (if available) may be used instead. In this tutorial, you will learn how to use both static and dynamic values.
Creating an import action
For an import action, you need to supply the location of the Source file being imported and the target storage location together with some additional metadata, such as the type (variant) of asset to create and which metadata schema to attach to the imported asset.
You can use these instructions to create a simple import action that does not rely on additional scripts to supply variables to the workflow.
In Flex Core, go to the New menu and select Action.
In the Create new Action screen, give your action a Name and an optional Description.
Set which accounts and groups have access to the action by setting its Visibility.
Select the Import Plugin Type and the Asset Import Plugin.
Save your changes and then move to the Configuration sub-tab and click Edit to configure your import action.
Start by clicking to display the Source File section and then display the Source Resource Item section. Click on the icon next to the Source Resource field to convert it to a free text field so you can type in this Spring Expression to indicate the storage resource that the imported asset is located in.
#{variables['resource'].id}
Using a dynamic Spring Expression for the Source Resource adds flexibility to the action so that it can be used in different workflows triggered from different storage resources.
When you upload a file to FlexMOVE, the Inbox retrieves the id of the storage resource and injects it into the import action in the workflow.
In the Item Name field add this Spring Expression:
#{variables['externalFileName']}
FlexMOVE retrieves the name of the file that you uploaded and this is used by the import action in the workflow.
The next thing that you need to add are details of the target destination for the file that you are uploading.
First you must display the Move File section by clicking .
From the drop down lists, select the Storage Resource that you created for your imported asset and the Folder Resource that connects to this storage.
Since you are using a static configuration, you know that all assets imported using this action will always be moved to the storage resource that you selected.
The next configuration will be Asset Details. This is information used to set the Title of the asset created in Dalet Flex. In this case, you should use this Spring Expression:
#{variables['externalFileName']}
When you use this Spring Expression, the title of all assets uploaded with FlexMOVE will be the same as the uploaded file name.
In more complex workflows, you can use more complicated expressions to set a different name for your imported assets.
The Asset Origin field is a mandatory field and it indicates how the asset was created.
The available options are hard-coded; for an Import action you select Import from the drop down list. To complete the configuration of your import action, set the Variant (type) of asset to create in Dalet Flex, in this case video and select a Metadata Definition to be associated to the asset.
Once you have completed these configurations, your import action should look like this.
Click Save and Enable.
Creating an extract technical data action
Once you have imported your file, you need to extract technical data from it.
Without the technical data, your asset will display a duration of 00:00:00:00 in FlexMAM and you will not be able to preview the proxy file in the Player.
In Flex Core, go to the New menu and select Action.
In the Create new Action screen, give your action a Name and an optional Description. Set which accounts and groups have access to the action by setting its Visibility and select the Extract Plugin Type and the Extract Technical Metadata Plugin.
Save your changes and in the Configuration sub-tab.
In the Transcode Resource field, select System REST Transcode Resource.
Click Save and Enable your new action.
Creating a "create proxy" Action
To be able to preview your assets in FlexMAM and in Flex Reviewer you must create a proxy version of your file.
You do this with a Create proxy action, providing the transcode resource, the transcode profile and the destination folder to connect to the proxy storage.
You can use these instructions to create a simple "create proxy" action that does not rely on additional scripts to supply variables to the workflow.
In Flex Core, go to the New menu and select Profile.
In the Create new Profile screen, give your action a Name and an optional Description. Set which accounts and groups have access to the action by setting its Visibility.
Save your changes and in the Configuration sub-tab, in the Transcode Engine field, select Flex Stream Processor.
In the Transcoder Profile Name, type in hls.
Click Save and Enable your new profile.
Go to the New menu and select Action.
In the Create new Action screen, give your action a Name and an optional Description. Set which accounts and groups have access to the action by setting its Visibility and select the Create Proxy Plugin Type and the Create Proxy (FSP) Plugin.
Save your changes and in the Configuration sub-tab, in the Transcode Resource field, select System REST Transcode Resource. Choose the profile name that you created previously from the Transcode Profile drop down list and select the destination folder that connects to your proxy storage resource.
Click Save and Enable your new action.
Comments
0 comments
Please sign in to leave a comment.