I am trying to use conferencing. My clients’ app (A party) calls B a C and then merges them with REFER and Accepted. But Asterisk after Accepted message, sends 2 NOTIFY immediately like below with “noresource” reason and then sends BYE. Any idea what can make this issue?
Conceptually B sends INVITE C/Replaces C’s leg to A, forwards the replies from C, as NOTIFY, and then sends BYE A.
C sends OK to the INVITE, triggering the above, and BYE to A, to clear the leg being replaced.
I say conceptually, in the normal case, where Asterisk is handling both B and C, the last two paragraphs are handled internally by Asterisk.
If you want a conference, either the phone has to implement the bridge, in which case the only interaction with Asterisk will be to remove the hold on B, or you have to blind transfer B and C, separately to an extension that connects them to the conference, then, when A becomes free, it also dials into the conference.
I checked the pjsip logs again, and as you said, it puts B party into the room but when Asterisk receives second REFER for C party it responds 'Not Found". I checked the ‘Refer-To’ header and information there (Call-ID, to-tag, from-tag) corresponds with the original C party call.
So is there any idea? it might be a bug?
That’s how REFER/Replaces works. A bug like that wouldn’t have lasted for years and years.
If you want to move the parties to a conference on the PABX side, you must issue blind transfers to each individually. Blind transfers don’t have a Replaces parameter, so don’t have a call-id, from tag and to tag.