This document describes the Streaming Tasks, provided as custom tasks that must be installed with PureLoad/PureTest for each installation using these tasks. The tasks support simulation of clients receiving streaming data using the protocols RTSP, RTP and RTMP. See References for more information about these protocols.
Before you use the tasks, read more about installing and how to load and use custom tasks .
The list of provided tasks are grouped by RTSP, RTP and RTMP
tasks.
However, RTSP and RTP tasks are normally used and mixed together
(also with other tasks, such as with standard HTTP tasks):
Description of each task package follows.
All RTSP tasks that send a request will include the following parameters:
URL | RTSP URL to requested resource. |
---|---|
Status Code | Comma separated list of valid status codes. Empty value means accept all response codes less than 400. |
Headers | RTSP Headers for generated RTSP request where Key is the name of the header and Value is the value of the header. |
Task used oo initiate common parameters used by other RTSP tasks.
RTSP Request Timeout | Number of milliseconds allowed between an RTSP request and the corresponding reply |
---|---|
Local Host | Local RTSP host or IP Address. |
Local Port | Local RTSP port. Any to use any available port. |
Proxy Host | RTSP Proxy host or IP Adress. None for no proxy. |
Proxy Port | RTSP Proxy port. |
Keep Alive | Number of seconds before keep-alive (OPTIONS) requests are sent. |
Task used to Send a DESCRIBE request. The DESCRIBE method retrieves the description of a presentation or media object identified by the request URL from a server.
The response will be parsed and saved so that it can be used to extract required information in subsequent tasks. Information extracted includes number of media tracks and media urls to be used by SETUP request(s) later in the scenario.
Task used to Send SETUP request(s). The SETUP request for an URL specifies the transport mechanism to be used for the streamed media.
One setup request will be sent for each media track specified. Track id will be added to the URL parameter, using information parsed from previous RtspDescibeTask. Transport header will be added automatically, based of the specified local port parameters.
Returned session identifiers in the response will be parsed and used by subsequent RTSP requests within the scenario.
No of Tracks | Number of media tracks. 1 or 2. |
---|---|
Local Port, track 1 | Local port for track 1 (Any to allocate port automatically). |
Local Port, track 2 | Local port for track 2 (Any to allocate port automatically). |
The port numbers must start with an event port (used for RTP) and the next port number will be used for RTCP. I.e if you specify port 9002, this will be used for RTP and 9003 will be used for RTCP.
The recommended usage is to not specify any port numbers (i.e use "Any") and let the runtime environment allocate ports.
Task used to Send a RTSP PLAY request. The PLAY method tells the server to start sending data via the mechanism specified in SETUP.
If no Range header is specified the server starts playing a stream from the beginning unless the stream has been paused. If a stream has been paused via PAUSE, stream delivery resumes at the pause point.
Task used to Send a RTSP PAUSE request. The PAUSE request causes the stream delivery to be interrupted (halted) temporarily. If the request URL names a stream, only playback and recording of that stream is halted.
Task used to Send a RTSP OPTIONS request. The OPTIONS request is used to inquire about methods supported by the server.
Task used to Send a RTSP GET_PARAMETER request. The GET_PARAMETER request is used to inquire about methods supported by the server.
The GET_PARAMETER request retrieves the value of a parameter of a presentation or stream specified in the URI. The content of the reply and response is left to the implementation. GET_PARAMETER with no entity body may be used to test client or server liveness ("ping").
Content-Type | Optional Content-Type header value. |
---|---|
Content | Optional Content (entity body). |
Task used to Send a RTSP SET_PARAMETER request. The SET_PARAMETER request is used to set the value of a parameter for a presentation or stream specified by the URI.
Content-Type | Optional Content-Type header value. |
---|---|
Content | Optional Content (entity body). |
Task used to Send a RTSP TEARDOWN request. The TEARDOWN request stops the stream delivery for the given URL, freeing the resources associated with it.
Task used to close RTSP usage and release all resources used.
One difference between the RTP tasks and other task, including
the RTSP tasks is that RTP transport will execute continuously in
the background while, possibly other tasks is executed. This means
that metrics can not be calculated the same way as for other tasks
where the execution time per task is measured. To retrieve metrics
a separate task, RtpCollectStatsTask,
must be used instead.
Initiates RTP tracks. The task will initiate receive of RTP and RTCP packets using background threads.
Local Host | Local host or IP Address. |
---|---|
No of Tracks | Number of media tracks. 1 or 2. |
Local Port, track 1 | Local port for track 1 (Any to allocate port automatically). |
Local Port, track 2 | Local port for track 2 (Any to allocate port automatically). |
SSRC | RTP Server Synchronization Source. Select "Use RTSP Value" to use value retreived by RTSP. |
Clock Rate | RTP Clock Rate. Select "Use RTSP Value" to use value retreived by RTSP. |
Fake Loss | Percentage fake loss: 0 for no packets lost, 100 all packets lost |
Bitrate | Set a bit rate in bits/second to other than "no constraint" to simulate a constrained bandwidth. |
Collect RTP statistics. If wait flag selected the task will wait until stream completed as specified by RTSP session (information returned by server). If "Max Time" specified the task will wait for the mininum of "Max Time" and session information (if known).
Wait | Wait until stream completed as specified by session or Max Time parameter |
---|---|
Max Time | Max time (seconds) to wait for stream completed. |
Collect lost RTP/RTCP packets since the last time RtpCollectLostTask was executed. Due to limitations in how metrics are handled in PureLoad, the lost packets are reported as "Transactions" by this task.
Close and release RTP streams.
Tasks used to handle an RTMP-stream. There are tasks to start,
play, pause, seek and close the stream. The RtmpPlayTask will
execute continuously in the background, while possibly other tasks
are executed. To correctly calculate RTMP-metrics (like execution
time) non-RTMP tasks must have their "Report Result" parameter set
to false.
NOTE! Remember to disable results from all SleepTasks in a RTMP
scenario.
Initiates a RMTP stream. The task will create a connection with an RTMP server.
Server Host | Hostname or IP Address of the RTMP Media Server. |
---|---|
Server Port |
The number of the port used by the RTMP Media Server.
Default is 1935. |
Local Host | Local host name or IP address to be used. Leave empty for default host. |
Application | The RTMP application. Default is "vod" (video on demand). |
Stream Name |
The name of the media (file) to stream. This entry takes
the form format:filename. Example mp4:sample.mp4. Note! if a faulty filename is given a "NetStream.Play.StreamNotFound" message should be sent by the server to identify the cause of the problem. Example: Wowza Server will send this message,Adobe Media Server will. |
Use RTMPE |
Encryption. Set to true ( = check) to enable encrypted RTMP. |
Use RTMPT |
HTTP Tunneling. Set to true (=check) to enable HTTP Tunneling of the RTMP stream. Http Tunneling will use the Server Port set in this task. RTMPT can be used in conjuction with RTMPE ( = RTMPTE). |
Abort on insufficient bandwidth |
Set to true ( = check) to have subsequent tasks fail if
there is not enough bandwidth. Default is false. This
functionality is depending on the Media Server to send a
"NetStream.Play.InsufficientBW" message. Adobe Media Server
will send the message, Wowza Server will not. |
Starts the RTMP stream. Collect RTP statistics. If wait flag
selected the task will wait until stream completed as specified by
RTSP session (information returned by server). If "Max Time"
specified the task will wait for the mininum of "Max Time" and
session information (if known).
The task can be run in two ways:
When starting the stream as a background process the RtmpPlayTask
must be combined with, for instance, a SleepTask in order to
actually be running the stream for a while.
When a SleepTask is used the "Report Result" option MUST be set to
false. Otherwise the stream execution time will be doubled.
NOTE! Remember to disable results from all SleepTasks in a RTMP scenario.
Play to End Of File |
Set to true to have this stream run until the media file
has reached its end OR the "Max wait for EOF
millisecs" limit has been reached. When set to false this
task will return immediately and the stream will continue to
run in the background. Default is false. |
---|---|
Max wait for EOF millisecs | The maximum time to wait for the stream to reach its end.
After this time (milliseconds) the task will fail (timeout)
and the stream will be closed. |
Pauses the RTMP-stream. The task also stops the RTMP-stream
execution time measurement. If this task is followed by a non-RTMP
taks, like for instance a SleepTask, the "Report Result"-parameter
must be set to false in the SleepTask.
NOTE! Remember to disable results from all SleepTasks in a RTMP scenario.
Seeks a position on the stream. The position is given as a time
offset from the start of the stream. The offset is given in
milliseconds.
To obtain the total playing time (the duration) of the stream, run a scenario in debug mode and look for the information about the duration of the stream.
Note that the duration is given in seconds but the seek offset
should be given in milliseconds!
Seek offset time millisecs |
The position in time, counted from the start of the
media, where this stream shall continue to play. The time is
given in milliseconds. Default is 0. |
---|
Closes the RTMP-stream, reports results and releases resources.