All Products
Document Center

FAQs about workflow

Last Updated: Dec 04, 2018

How do you upload files?

Use the MPS console or upload SDK tools for Web, iOS or Android to upload files. Multipart upload, resumable data transfer and batch uploads are supported. You can also use the ossbrowser, which is a graphical management tool developed by Alibaba Cloud to upload files.

Are audio or video files transcoded automatically after they are uploaded?

If the extension of the file to upload matches a defined format, the media workflow will be triggered automatically after the file is uploaded.

When you create a media workflow, you must specify the path of input files. When you upload audio or video files with the following extensions to that path, the media workflow will be triggered automatically, and all predefined operations in the workflow will be performed on those input files.

If the file extension of the input file matches one of the formats below, the media workflow will be triggered automatically:

  • Videos:

    3gp, asf, avi, dat, dv, flv, f4v, gif, m2t, m3u8, m4v, mj2, mjpeg, mkv, mov, mp4, mpe, mpg, mpeg, mts, ogg, qt, rm, rmvb, swf, ts, vob, wmv, webm

  • Audios:

    aac, ac3, acm, amr, ape, caf, flac, m4a, mp3, ra, wav, wma, and aiff

Matching rules for workflow triggering:

If the upload path contains the input file path specified in the workflow, the workflow will be triggered, for example:

Note: If the input file path for Workflow A is the directory AA/BB in Bucket A, the workflow will be triggered when you upload AA/BB/a.mp4 and AA/BB/CC/b.flv to Bucket A.

If the workflow is disabled, it will not be triggered automatically.

When I use the OSS tool to upload videos to the input file path of a media workflow, will they be transcoded automatically?

Yes. The media workflow service is triggered whenever matching files are uploaded to the defined input file path in the workflow, regardless of how you upload them, through the console, API, SDK or OSS client tools. However, if the workflow is disabled, it will not be triggered automatically. For instructions about how to upload files and what tools are available for upload, see FAQs - How do you upload files?.

Which operations are supported by media workflows?

The supported operations for media workflows include taking snapshots, transcoding, analysis task, and release management.

How do we name the output files from media workflow transcoding operations?

Media workflows make it possible to process input files in batches, but with it comes the naming issue for the output files. You can use the following variables to name output files:

  • {RunId}: Media workflow execution ID;
  • {ObjectPrefix}: Path of the source file without bucket information;
  • {FileName}: Source file name without the extension;
  • {ExtName}: Source file name extension;

Example: When the input file is ““, the three variables that relate to the source file are:

  • {ObjectPrefix}: news/video/
  • {FileName}: foooo
  • {ExtName}: .mp4

You can configure the variables for the output file as follows: “vod/{ObjectPrefix}{FileName}_HD.flv”After transcoding, the output file: “vod/news/video/foooo_HD.flv” would be created.

In addition, a special variable is added for the operation of taking snapshots:

  • {SnapshotTime}: Snapshot time in milliseconds

Which messaging methods are supported in media workflows?

Media workflows support Message Service’s queue and notification functions. You can configure these features for the input node. When a media workflow is triggered, messages are sent at the start and end of execution according to the preset queue or notification topic.

After a video is transcoded, where can I find the playback URL?

You can manage videos from the “Console” - “Media Repository” page. Use the “Manage” link for each video to open the video details page. You can view the OSS address and CDN address for each video (if CDN is configured for that OSS Bucket); You can also get the information through SDK and programming. For more information, see Media details.

When a media workflow is executed, are queue or notification mechanisms bound to the transcoding pipeline activated?

Currently, when media workflows are executed, message mechanisms that are bound to the transcoding pipeline are ignored.

Why can’t I play a preview of a transcoded file when I open its CDN address on the console?

This can occur if no CNAME record is added to your CDN domain name. You can use the following command to look up the CNAME configurations for your domain name:

  1. nslookup -type=cname [your domain name]

For more information about CNAME configuration, see Domain name management.

After I transcode a file into M3U8 format, why can’t I play a preview on the console?

First of all, ensure that the permissions for the output media bucket are set to public read.

Next, place a file called “crossdomain.xml” in the root directory of the bucket that contains the M3U8 file. This XML file should contain the domain name for the Alibaba Cloud Flash player that the console uses to preview media files.

In order to play a preview on the console, place a file called “crossdomain.xml” in the root directory of the bucket that contains the M3U8 file. The XML file should contain the following content:

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <cross-domain-policy xmlns:xsi="" xsi:noNamespaceSchemaLocation="">
  3. <allow-access-from domain="*"/>
  4. </cross-domain-policy>” is the domain name for the Flash player used by the console. If you want to use another Flash player, add a new allow-access-from domain* record that includes the domain name for the new player.