-
Notifications
You must be signed in to change notification settings - Fork 3
Multiple headers with the same name should be allowed #35
Comments
Adding my comment from #42: In section 6.2.1 as well as other places, we allow setting arbitrary headers. What if the underlying telephony protocol allows multiple headers with the same name? I think the specification should address this in a couple of places:
From RFC 3261 [H4.2] also specifies that multiple header fields of the same field
allows for combining header fields of the same name into a comma- and The relative order of header fields with different field names is not |
@loopingrage Any thoughts on how subsequently delivered values should be specified (replacement vs extra element in a collection)? |
I feel pretty strongly that we need to support multiple headers with the same key/name and ensure that order is respected when handing it to the backend for processing. On the client (Adhearsion) side we should consider the comma-delimited format recommended by the RFC, but both styles are considered valid by my reading. |
@bklang I want to stay away from the comma delimited thing, simply because it's SIP specific, but we do not specify the format of header values anyway so it's perfectly permissible. I also agree that we should support multiple headers of the same name. The only question is what it means in the example in the OP. Thoughts? |
I'm not sure how Rayo deals with headers now. Two possible scenarios:
I strongly prefer 1 since 2 seems confusing and error-prone. |
Yea, option #1 for sure. I'm pretty sure that the RFC requires that we support both the comma separated approach AND the duplicate name approach. I don't think the server support duplicates since we're using a Map to store the headers. This is a bug and should be fixed in Rayo Server. |
Tagging @bklang, @jsgoecke
The tricky point here is how we deal with headers on subsequent events.
eg:
Should this be considered as an additional value, or a replacement?
The text was updated successfully, but these errors were encountered: