调整媒体处理的规模概述Scaling Media Processing overview

此页概述了如何以及为何调整媒体处理的规模。This page gives an overview of how and why to scale media processing.

概述Overview

媒体服务帐户与预留单位类型关联,后者决定了编码处理任务的处理速度。A Media Services account is associated with a Reserved Unit Type, which determines the speed with which your media processing tasks are processed. 可以在以下预留单位类型中进行选择:S1S2S3You can pick between the following reserved unit types: S1, S2, or S3. 例如,与 S1 预留单位类型相比,使用 S2 预留单位类型时,同一编码作业运行速度更快。For example, the same encoding job runs faster when you use the S2 reserved unit type compare to the S1 type. 有关详细信息,请参阅预留单位类型For more information, see the Reserved Unit Types.

除了指定预留单位类型,还可以指定通过预留单位来设置帐户。In addition to specifying the reserved unit type, you can specify to provision your account with reserved units. 设置的预留单位数决定了给定帐户中可并发处理的媒体任务数。The number of provisioned reserved units determines the number of media tasks that can be processed concurrently in a given account. 例如,如果帐户具有 5 个预留单位,则只要有任务要处理,就可以同时运行 5 个媒体任务。For example, if your account has five reserved units, then five media tasks will be running concurrently as long as there are tasks to be processed. 其余任务将排队等待,运行的任务完成后才选择它们以按顺序进行处理。The remaining tasks will wait in the queue and will get picked up for processing sequentially when a running task finishes. 如果帐户未设置任何预留单位,则按顺序选择任务进行处理。If an account does not have any reserved units provisioned, then tasks will be picked up sequentially. 在这种情况下,完成一个任务和开始下一个任务之间的等待时间取决于系统中资源的可用性。In this case, the wait time between one task finishing and the next one starting will depend on the availability of resources in the system.

在不同的预留单位类型之间进行选择Choosing between different reserved unit types

下表有助于在不同的编码速度之间进行选择时做出决定。The following table helps you make a decision when choosing between different encoding speeds. 它还提供了几个基准案例,可下载视频来执行自己的测试:It also provides a few benchmark cases on a video that you can download to perform your own tests:

RU 类型RU type 方案Scenario 7 分钟 1080p 视频的示例结果Example results for the 7 min 1080p video
S1S1 单比特率编码。Single bitrate encoding.
具有 SD 或更低分辨率的文件,不具有高时效性,成本低。Files at SD or below resolutions, not time sensitive, low cost.
使用“H264 单比特率 SD 16x9”编码为单比特率 SD 分辨率 MP4 文件大约需要 7 分钟。Encoding to single bitrate SD resolution MP4 file using "H264 Single Bitrate SD 16x9" takes around 7 minutes.
S2S2 单比特率和多比特率编码。Single bitrate and multiple bitrate encoding.
SD 和 HD 编码的正常使用情况。Normal usage for both SD and HD encoding.
预设为“H264 单比特率 720p”的编码大约需要 6 分钟。Encoding with "H264 Single Bitrate 720p" preset takes around 6 minutes.

预设为“H264 多比特率 720p”的编码大约需要 12 分钟。Encoding with "H264 Multiple Bitrate 720p" preset takes around 12 minutes.
S3S3 单比特率和多比特率编码。Single bitrate and multiple bitrate encoding.
全高清和 4K 分辨率视频。Full HD and 4K resolution videos. 对时间敏感,更快的编码周转。Time sensitive, faster turnaround encoding.
预设为“H264 单比特率 1080p”的编码大约需要 3 分钟。Encoding with "H264 Single Bitrate 1080p" preset takes approximately 3 minutes.

预设为“H264 多比特率 1080p”的编码大约需要 8 分钟。Encoding with "H264 Multiple Bitrate 1080p" preset takes approximately 8 minutes.

注意事项Considerations

Important

查看本节中所述的注意事项。Review considerations described in this section.

  • 对于由媒体服务 v3 或视频索引器触发的音频分析和视频分析作业,强烈建议采用 S3 单位类型。For the Audio Analysis and Video Analysis jobs that are triggered by Media Services v3 or Video Indexer, S3 unit type is highly recommended.
  • 如果使用共享的池(即没有任何预留单位),则编码任务将具有与 S1 RU 相同的性能。If using the shared pool, that is, without any reserved units, then your encode tasks have the same performance as with S1 RUs. 但是,任务在排队状态下花费的时间可能没有上限,并且在任何给定的时间内,最多只会运行一项任务。However, there is no upper bound to the time your Tasks can spend in queued state, and at any given time, at most only one Task will be running.

计费Billing

根据在帐户中预配的媒体预留单位的分钟数计费。You are charged based on number of minutes the Media Reserved Units are provisioned in your account. 这与帐户中是否有作业运行无关。This occurs independent of whether there are any Jobs running in your account. 有关详细说明,请参阅媒体服务定价页的“常见问题”部分。For a detailed explanation, see the FAQ section of the Media Services pricing page.

配额和限制Quotas and limitations

有关配额和限制以及如何开具支持票证的信息,请参阅配额和限制For information about quotas and limitations and how to open a support ticket, see Quotas and limitations.

后续步骤Next step

通过以下技术之一完成调整媒体处理的规模任务:Achieve the scaling media processing task with one of these technologies:

Note

若要获取最新版本的 Java SDK 并开始使用 Java 进行开发,请参阅媒体服务的 Java 客户端 SDK 入门To get the latest version of Java SDK and get started developing with Java, see Get started with the Java client SDK for Media Services.
若要下载最新的媒体服务 PHP SDK,请在 Packagist 存储库中查找 0.5.7 版 Microsoft/WindowAzure 包。To download the latest PHP SDK for Media Services, look for version 0.5.7 of the Microsoft/WindowAzure package in the Packagist repository.

媒体服务学习路径Media Services learning paths

媒体服务 v3(最新版本)Media Services v3 (latest)

查看最新版本的 Azure 媒体服务!Check out the latest version of Azure Media Services!

媒体服务 v2(旧版)Media Services v2 (legacy)