A subscriber issues a SUBSCRIBE_UPDATE to a publisher to request a change to an existing subscription. Subscriptions can only become more narrow, not wider, because an attempt to widen a subscription could fail. If Objects before the start or after the end of the current subscription are needed, a fetch might be able to retrieve objects before the start. The start Object MUST NOT decrease and when it increases, there is no guarantee that a publisher will not have already sent Objects before the new start Object. The end Group MUST NOT increase and when it decreases, there is no guarantee that a publisher will not have already sent Objects after the new end Object. A publisher SHOULD close the Session as a 'Protocol Violation' if the SUBSCRIBE_UPDATE violates either rule or if the subscriber specifies a Request ID that has not existed within the Session.
There is no control message in response to a SUBSCRIBE_UPDATE, because it is expected that it will always succeed and the worst outcome is that it is not processed promptly and some extra objects from the existing subscription are delivered.
Unlike a new subscription, SUBSCRIBE_UPDATE can not cause an Object to be
delivered multiple times. Like SUBSCRIBE, End Group MUST be greater than or
equal to the Group specified in Start.
If a parameter included in SUBSCRIBE is not present in
SUBSCRIBE_UPDATE, its value remains unchanged. There is no mechanism to
remove a parameter from a subscription.
The format of SUBSCRIBE_UPDATE is as follows:
SUBSCRIBE_UPDATE Message {
Type (i) = 0x2,
Length (i),
Request ID (i),
Start Location (Location),
End Group (i),
Subscriber Priority (8),
Forward (8),
Number of Parameters (i),
Subscribe Parameters (..) ...
}
-
Request ID: The Request ID of the SUBSCRIBE (Section 8.7) this message is updating. This MUST match an existing Request ID.
-
Start Location : The starting location.
-
End Group: The end Group ID, plus 1. A value of 0 means the subscription is open-ended.
-
Subscriber Priority: Specifies the priority of a subscription relative to other subscriptions in the same session. Lower numbers get higher priority. See Section 6.
-
Forward: If 1, Objects matching the subscription are forwarded to the subscriber. If 0, Objects are not forwarded to the subscriber. Any other value is a protocol error and MUST terminate the session with a Protocol Violation (Section 3.4).
-
Subscribe Parameters: The parameters are defined in Section 8.2.1.