The publisher sends the PUBLISH control message to initiate a subscription to a track. The receiver verifies the publisher is authorized to publish this track.
PUBLISH Message {
Type (i) = 0x1D,
Length (i),
Request ID (i),
Track Namespace (tuple),
Track Name Length (i),
Track Name (..),
Track Alias (i),
Group Order (8),
Content Exists (8),
[Largest Location (Location),]
Forward (8),
Number of Parameters (i),
Parameters (..) ...,
}
-
Request ID: See Section 9.1.
-
Track Namespace: Identifies a track's namespace as defined in (Section 2.4.1)
-
Track Name: Identifies the track name as defined in (Section 2.4.1).
-
Track Alias: The identifer used for this track in Subgroups or Datagrams (see Section 10.1). The same Track Alias MUST NOT be used to refer to two different Tracks simultaneously. If a subscriber receives a PUBLISH that uses the same Track Alias as a different track with an active subscription, it MUST close the session with error
DUPLICATE_TRACK_ALIAS. -
Group Order: Indicates the subscription will be delivered in Ascending (0x1) or Descending (0x2) order by group. See Section 7. Values of 0x0 and those larger than 0x2 are a protocol error.
-
Content Exists: 1 if an object has been published on this track, 0 if not. If 0, then the Largest Group ID and Largest Object ID fields will not be present. Any other value is a protocol error and MUST terminate the session with a
PROTOCOL_VIOLATION(Section 3.4). -
Largest Location: The location of the largest object available for this track.
-
Forward: The forward mode for this subscription. Any value other than 0 or 1 is a
PROTOCOL_VIOLATION. 0 indicates the publisher will not transmit any objects until the subscriber sets the Forward State to 1. 1 indicates the publisher will start transmitting objects immediately, even before PUBLISH_OK. -
Parameters: The parameters are defined in Section 9.2.1.
A subscriber receiving a PUBLISH for a Track it does not wish to receive SHOULD
send PUBLISH_ERROR with error code UNINTERESTED, and abandon reading any
publisher initiated streams associated with that subscription using a
STOP_SENDING frame.