method
TLSSocket.reload
): void;
Reset the socket's callbacks. This is useful with bun --hot for hot reloading.
This applies to all sockets from the same Listener. It is per socket only for Bun.connect.
Referenced types
interface SocketOptions<Data = unknown>
- allowHalfOpen?: boolean
Whether to allow half-open connections.
A half-open connection occurs when one end of the connection has called
close()or sent a FIN packet, while the other end remains open. When set totrue:- The socket won't automatically send FIN when the remote side closes its end
- The local side can continue sending data even after the remote side has closed
- The application must explicitly call
end()to fully close the connection
When
false, the socket automatically closes both ends of the connection when either side closes.