Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redix crash by Redis connection closed by unknow reason #19

Closed
zhongwencool opened this issue Dec 24, 2015 · 3 comments
Closed

Redix crash by Redis connection closed by unknow reason #19

zhongwencool opened this issue Dec 24, 2015 · 3 comments

Comments

@zhongwencool
Copy link

19:34:36.241 [error] Disconnected from Redis (11.1.1.11:6379): unknown POSIX error
19:34:36.243 [error] GenServer #PID<0.1963.0> terminating
** (FunctionClauseError) no function clause matching in Redix.Connection.Auth.auth/2
    (redix) lib/redix/connection/auth.ex:32: Redix.Connection.Auth.auth(%{opts: [host: "11.1.1.11", port: 6379, password: :redacted, socket_opts: [], backoff: 2000], receiver: #PID<0.1964.0>, reconnection_attempts: 0, socket: #Port<0.22764>, tail: ""}, :redacted)
    (redix) lib/redix/connection/auth.ex:18: Redix.Connection.Auth.auth_and_select_db/1
    (redix) lib/redix/connection.ex:38: Redix.Connection.connect/2
    (connection) lib/connection.ex:742: Connection.connect/3
    (stdlib) gen_server.erl:615: :gen_server.try_dispatch/4
    (stdlib) gen_server.erl:681: :gen_server.handle_msg/5
    (stdlib) proc_lib.erl:240: :proc_lib.init_p_do_apply/3
Last message: {:timeout, #Reference<0.0.524289.138217>, Connection}
State: %{opts: [host: "11.1.1.11", port: 6379, password: :redacted, socket_opts: [], backoff: 2000], receiver: #PID<0.1964.0>, reconnection_attempts: 0, socket: nil, tail: ""}
@zhongwencool zhongwencool changed the title Redis connection closed by unknow reason cause Redix crash Redix crash by Redis connection closed by unknow reason Dec 24, 2015
@whatyouhide
Copy link
Owner

Whoops, I can spot the problem already :). Sorry for causing this, will fix it tomorrow!

@whatyouhide
Copy link
Owner

Took me a little bit longer because of the holidays, but I pushed a fix and released version 0.3.4 on hex. Please upgrade and let me know if there's anything wrong :) Thanks for the report! ❤️

whatyouhide referenced this issue Dec 27, 2015
Before this commit, the password in the `opts` field of the state of the
connection was replaced with `:redacted` if auth was successful so that
we avoided printing it in case of failures (when GenServers print the
state). This was obviously causing problems when trying to reconnect
with a password, as the original password was now unavailable.

In this commit, I just removed this "feature".
@zhongwencool
Copy link
Author

thanks, it's fixed.:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants