Bug 58 - better stream connection garbage collection and ulimit management
Summary: better stream connection garbage collection and ulimit management
Status: NEW
Alias: None
Product: resiprocate
Classification: Unclassified
Component: stack (libresip) (show other bugs)
Version: unspecified
Hardware: All All
: P1 normal
Assignee: Owner of all unassigned bugs
Depends on:
Reported: 2014-01-02 09:39 CST by Daniel Pocock
Modified: 2014-01-02 09:39 CST (History)
0 users

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Pocock 2014-01-02 09:39:40 CST
resip/stack/ConnectionManager performs some basic garbage collection on stream connections (TCP, TLS, WS and WSS connections)

A recent change makes it use getrlimit() on UNIX platforms to find out how many connections are possible.  However, this is not very precise and it is not implemented for Windows.

With more users doing WebSocket and federated VoIP over TLS connections, file descriptors will need to be managed much more carefully as more connections will be kept open concurrently and sometimes long after they were really needed.

Some ideas:

- more accurately count the actual number of descriptors in use (currently it just counts the number of stream connections, this ignores the other file descriptors for things like listening sockets and open files)

- similar checks for Windows

- warning about low ulimit at startup