aboutsummaryrefslogtreecommitdiffstats
path: root/src/cowboy_listener.erl
AgeCommit message (Collapse)Author
2012-05-23Update version to 0.6.00.6.0Loïc Hoguin
Also update the CHANGELOG and copyright years.
2012-02-20Check for upgrades on accept timeoutLoïc Hoguin
Otherwise acceptors will not be upgraded properly until after the next request comes in. Thanks to DeadZen for pointing it out.
2012-02-01Fix a typo that prevented protocol options upgradesLoïc Hoguin
2012-01-31Remove call to queue:len/1Paul Oliver
queue:len/1 is O(len(Q)) queue:out/1 is O(1) amortized, O(len(Q)) worst case Replace with a pattern match
2012-01-31Use queue() for managing wait queues in cowboy_listenerLoïc Hoguin
The previous solution was retrieving the last put connection and wasn't a real queue, so this solution should improve the overall latency under load.
2012-01-31Refactor cowboy_listener for more consistencyLoïc Hoguin
2012-01-31Add cowboy:get_protocol_options/1 and cowboy_set_protocol_options/2Loïc Hoguin
This allows any application to upgrade the protocol options without having to restart the listener. This is most useful to update the dispatch list of HTTP servers, for example. The upgrade is done at the acceptor level, meaning only new connections receive the new protocol options.
2012-01-30Move max_connections check directly inside cowboy_listenerLoïc Hoguin
This is a big change in the internal cowboy API. This should not have any impact on existing applications as only the acceptor is expected to use these API calls. The function cowboy_listener:wait/3 has been removed. max_connections checking now occurs directly in cowboy_listener:add_connection/3. If the pool is full and the acceptor has to wait, then it doesn't return, waiting for a free space to be available. To accomodate these changes, it is now cowboy_listener that will inform the new connection that it is ready by sending {shoot, self()}. This should be a great improvement to the latency of responses as there is one less message to wait for before the request process can do its work. Overall the performance under heavy load should also be improved as we greatly reduce the number of messages sent between the acceptor and the listener process.
2011-11-01Set the cowboy_listener process priority to highLoïc Hoguin
See comment added with it for more information.
2011-08-10Give the ListenerPid to the protocol on startupLoïc Hoguin
Also sends a message 'shoot' that can be received by the protocol to make sure Cowboy has had enough time to fully initialize the socket. This message should be received before any socket-related operations are performed. WebSocket request connections are now moved from the pool 'default' to the pool 'websocket', meaning we can have a lot of running WebSockets despite having a low 'max_connections' setting.
2011-08-10Introduce cowboy_listener for managing a listenerLoïc Hoguin
Currently only supports limiting the maximum number of connections by managing connection pools.