Initializerswift-nio 2.74.0NIOCore
init(shouldForwardIOErrorCaught:backoffProvider:)
Create a new instance
ChannelHandlers.swift:50init(shouldForwardIOErrorCaught: Bool, backoffProvider: @escaping (IOError) -> TimeAmount? = AcceptBackoffHandler.defaultBackoffProvider)
Parameters
- shouldForwardIOErrorCaught
A boolean indicating if a caught IOError should be forwarded.
- backoffProvider
returns a
TimeAmount
which will be the amount of time to wait before attempting anotherread
.
Other members in extension
Typealiases
Type members
init(backoffProvider: @escaping (IOError) -> TimeAmount?
) Create a new instance
static func defaultBackoffProvider(error: IOError
) -> TimeAmount? Default implementation used as
backoffProvider
which delays accept by 1 second.