Permalink
Browse files

Fixed issue #28: The sub socket was incorrectly set to resulting in t…

…he socket sending more messages than wanted. At large volumes of messages, we get into a situation where we can no longer handle the messages fast enough. Thanks to pmembrey for reporting.
  • Loading branch information...
1 parent 06ce724 commit 4d35fccef3b04a83ebd636bbc4f229c840f52559 @knutin knutin committed May 31, 2012
Showing with 9 additions and 3 deletions.
  1. +8 −1 CHANGELOG.md
  2. +1 −1 src/eredis.app.src
  3. +0 −1 src/eredis_sub_client.erl
View
9 CHANGELOG.md
@@ -1,5 +1,12 @@
# CHANGELOG
+## v1.0.2
+
+* Fixed bug in eredis_sub where the socket was incorrectly set to
+ `{active, once}` twice. At large volumes of messages, this resulted
+ in too many messages from the socket and we would be unable to keep
+ up.
+
## v1.0
* Support added for pubsub thanks to Dave Peticolas
@@ -28,4 +35,4 @@
* Configurable reconnect sleep time, by Valentino Volonghi (dialtone)
* Support for using eredis as a poolboy worker, by Valentino Volonghi
- (dialtone)
+ (dialtone)
View
2 src/eredis.app.src
@@ -1,6 +1,6 @@
{application, eredis, [
{description, "Erlang Redis Client"},
- {vsn, "1.0.1"},
+ {vsn, "1.0.2"},
{modules, []},
{registered, []},
{applications, [kernel, stdlib]}
View
1 src/eredis_sub_client.erl
@@ -229,7 +229,6 @@ handle_response(Data, #state{parser_state = ParserState} = State) ->
handle_response(Rest, NewState);
{continue, NewParserState} ->
- inet:setopts(State#state.socket, [{active, once}]),
State#state{parser_state = NewParserState}
end.

0 comments on commit 4d35fcc

Please sign in to comment.