fn prefixes_overlap(a: &[Vec<u8>], b: &[Vec<u8>]) -> boolExpand description
Whether two namespace prefixes overlap.
Section 8.28: “A subscriber cannot make overlapping namespace subscriptions on a single session. Within a session, if a publisher receives a SUBSCRIBE_NAMESPACE with a Track Namespace Prefix that is a prefix of, suffix of, or equal to an active SUBSCRIBE_NAMESPACE, it MUST respond with SUBSCRIBE_NAMESPACE_ERROR, with error code Namespace Prefix Overlap.”
A namespace matches a namespace subscription when the subscription’s prefix is a prefix of it, so two prefixes select overlapping sets of namespaces exactly when one of them is a prefix of the other. Equal prefixes are that case as well, and this draft names them.
“Suffix of” is read as the “or vice versa” drafts 07 through 11 write in the same place. Which suffix a prefix ends with decides nothing about the namespaces it matches, so read at its word the term would forbid pairs that overlap in nothing and permit pairs that overlap entirely.