Documentation Index
Fetch the complete documentation index at: https://mintlify.com/moqtail/moqtail/llms.txt
Use this file to discover all available pages before exploring further.
Overview
TheTrackStatus class represents a MOQT TrackStatus control message. It allows clients to query the availability and current status of a track before subscribing, enabling smart prefetching and backfill strategies.
Class Definition
Properties
Unique identifier for this track status request.
Alias identifier for the track, used to correlate responses and optimize message size.
The fully qualified track name consisting of a namespace tuple and track name.
Priority value (0-255) for potential future subscription.
Specifies the desired order for group delivery:
GroupOrder.Original(0x0): Original orderGroupOrder.Ascending(0x1): Ascending orderGroupOrder.Descending(0x2): Descending order
If
true, objects would be delivered forward. If false, in reverse.Filter type for the potential subscription:
FilterType.NextGroupStart(0x1): Next available groupFilterType.LatestObject(0x2): Latest objectFilterType.AbsoluteStart(0x3): From absolute locationFilterType.AbsoluteRange(0x4): Specific group range
Starting location for
AbsoluteStart and AbsoluteRange filter types.Ending group for
AbsoluteRange filter type.Parameters that would be used in a subsequent subscription.
Static Factory Methods
newNextGroupStart
Creates a track status request for the next available group.TrackStatus instance with FilterType.NextGroupStart
newLatestObject
Creates a track status request for the latest available object.TrackStatus instance with FilterType.LatestObject
newAbsoluteStart
Creates a track status request from a specific location.The group and object location to query from
TrackStatus instance with FilterType.AbsoluteStart
newAbsoluteRange
Creates a track status request for a specific range of groups.The group and object location to start from
The last group to query (inclusive)
TrackStatus instance with FilterType.AbsoluteRange
Throws: Error if endGroup < startLocation.group
Methods
serialize
Serializes the TrackStatus message to a frozen byte buffer for transmission.FrozenByteBuffer containing the serialized message
Throws:
ErrorifstartLocationis missing forAbsoluteStartorAbsoluteRangeErrorifendGroupis missing forAbsoluteRange
parsePayload
Deserializes a TrackStatus message from a byte buffer.Buffer containing the serialized TrackStatus message payload
TrackStatus instance
Throws: Error if the buffer contains invalid or incomplete data
Status Response Codes
The server responds with aTrackStatusOk message containing one of these status codes:
Track is actively being published and available for subscription
Track does not exist or has never existed
Track is scheduled to exist but has not started yet
Track has completed and no more objects will be published
Relay cannot provide status information for this track
Usage Examples
Query Track Availability
Check Historical Range
Parse TrackStatus Response
Use Cases
Backfill Strategy
Query track status to determine the available historical data before subscribing:Smart Prefetching
Check if upcoming segments are available before a player needs them:Related Types
- FullTrackName - Track identifier
- Location - Group and object position
- FilterType - Filter options
- GroupOrder - Group delivery order
- TrackStatusCode - Status response codes