8000 ErrorMessage read: connection reset by peer (ECONNRESET) · Issue #105 · wookay/Bukdu.jl · GitHub
[go: up one dir, main page]

Skip to content

ErrorMessage read: connection reset by peer (ECONNRESET) #105

Closed

Description

@ueliwechsler

Sorry to bother you again 🙈. But I am nearly done with my application.

Theapplication is now running in a test environment without interruptions but from time to time I get the
read: connection reset by peer (ECONNRESET)", -4077 error message (see below). This does not "break" the server, but I still think that something might not be set up correctly. So far I could not reproduce the error consistently.

Do you have any idea what could cause this error? I already set the kwarg enable_remote_ip=true. If it helps I could create a MVP and provide it to you.

(Base.IOError("read: connection reset by peer (ECONNRESET)", -4077), 
Base.StackTraces.StackFrame[wait_readnb(::Sockets.TCPSocket, ::Int64) at stream.jl:350, eof at stream.jl:48 [inlined], 
read_to_buffer(::HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, ::Int64) at ConnectionPool.jl:253, 
readuntil(::HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, ::Function, ::Int64) at ConnectionPool.jl:273, readuntil at ConnectionPool.jl:271
 [inlined], readheaders(::HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, ::HTTP.Messages.Request) at Messages.jl:471, 
startread(::HTTP.Streams.Stream{HTTP.Messages.Request,HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}}) at Streams.jl:155, 
handle_transaction(::typeof(Bukdu.handle_stream_with_remote_ip), ::HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, ::HTTP.Servers.Server{Nothing,Sockets.TCPServer}; final_transaction::Bool) at Servers.jl:343, 
(::HTTP.Servers.var"#handle_transaction##kw")(::NamedTuple{(:final_transaction,),Tuple{Bool}}, ::typeof(HTTP.Servers.handle_transaction), ::Function, ::HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, ::HTTP.Servers.Server{Nothing,Sockets.TCPServer}) at Servers.jl:338, handle_connection(::Function, ::HTTP.ConnectionPool.Connection{Sockets.TCPSocket}, ::HTTP.Servers.Server{Nothing,Sockets.TCPServer}, ::Int64, ::Int64) at Servers.jl:299, 
(::HTTP.Servers.var"#8#9"typeof(Bukdu.handle_stream_with_remote_ip),HTTP.Servers.Server{Nothing,Sockets.TCPServer},Base.RefValue{Int64},Int64,Int64,Bool,HTTP.ConnectionPool.Connection{Sockets.TCPSocket}})() at task.jl:358])
└ @ HTTP.Servers D:\Libraries\Julia\v1.x\packages\HTTP\BOJmV\src\Servers.jl:264

Activity

  1. wookay commented on Jun 19, 2020

    @wookay
    Owner

    that error's thrown from HTTP.jl/src/Servers.jl
    https://github.com/JuliaWeb/HTTP.jl/blob/v0.8.15/src/Servers.jl#L261

                    if e isa Base.IOError && e.code == -54
                        verbose && @warn "connection reset by peer (ECONNRESET)"
                    else
                        @error exception=(e, stacktrace(catch_backtrace()))
                    end

    to just stop the error message for now,

    1. get the dev HTTP.jl
    julia> using Pkg; Pkg.develop("HTTP")
    1. edit the line as
     if e isa Base.IOError && e.code in (-54, -4077)

    or to make an issue for it on HTTP.jl .

  2. ueliwechsler commented on Jun 19, 2020

    @ueliwechsler
    ContributorAuthor

    Thanks for the information. I will consider opening an Issue on HTTP.jl.

    Actually I don't mind the error message itself, I wanted to figure out how to avoid this error.
    But is it safe to deploy the server in production if this error message occurs from time to time? Or should I consider refactoring my code?

  3. wookay commented on Jun 19, 2020

    @wookay
    Owner

    I found an answer on discourse.
    ECONNRESET error with HTTP.jl https://discourse.julialang.org/t/econnreset-error-with-http-jl/11228/2

  4. ueliwechsler commented on Jun 23, 2020

    @ueliwechsler
    ContributorAuthor

    Thanks, but I still do not understand the scope of the problem fully, so I posted also an issue on HTTP.jl.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0