Helmut Wolf wrote: > Hi Benny, > > My application serve multiple Clients to another server. I have a mapping > table in which every client is stored. When a new client connects to my > application the client must be stored in this mapping table. When the client > is down (connection closed) then I have to remove the client from the > mapping table. In the case that a client connection is closed unexpected the > application must inform the server. I see. AFAIK TCP connection between client and server is not permanent, so I'm not sure if it's wise to monitor it as an indication that the client is reachable. This should be done by REGISTER. So because of this, pjsip does not provide an API to notify applications about closure of TCP connection. But there is a hack to do this. Once you have the pjsip_transport instance, you can always alter the "do_shutdown" method to point to your own function, so that you'll get notified when the transport is closing. > By the way, I want to serve many clients (15000-20000) but it seems that > pjsip supports max. 256 tcp connections. Can I realize this only by > increasing the value of PJ_IOQUEUE_MAX_HANDLES? Do I need multiple threads? Apart from PJ_IOQUEUE_MAX_HANDLES, you'll also need to increase PJSIP_MAX_TSX_COUNT and PJSIP_MAX_DIALOG_COUNT. And maybe PJSIP_TPMGR_HTABLE_SIZE if you plan to use large number of TCP connections. Have a look at config_site_sample.h for configurations that have been tuned for performance. > I don't know why you get my mails three times but I will checking it. From > this mailing list I get my mail once only. Two times it happened that I > sended my mails over an mail address which isn't registered in pjsip mailing > list so I sended it again using the right address. It didn't happen again for some reason. :) cheers, -benny > Best regards, > Helmut