doc: clarify sub-1000ms behavior in socket.setKeepAlive · nodejs/node@b653813 · GitHub
Skip to content

Commit b653813

Browse files
haramjaduh95
authored andcommitted
doc: clarify sub-1000ms behavior in socket.setKeepAlive
The current documentation states that `initialDelay` and `interval` are divided by 1000 and rounded down, but does not explicitly mention that values less than 1000ms will result in 0 seconds. This can lead to confusion when users pass values like 400ms expecting sub-second keepalive delays. Add a concrete example showing that 400ms rounds down to 0 seconds. Refs: #57712 Signed-off-by: haramjeong <04harams77@gmail.com> PR-URL: #65869 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com>
1 parent 146f00f commit b653813

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎doc/api/net.md‎

Lines changed: 3 additions & 1 deletion

0 commit comments

Comments
 (0)