Skip to content

Add documentation for new 'backlog' config option #166

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

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion source/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,21 @@ Available listener options:
defines SSL/TLS
:ref:`settings <configuration-listeners-ssl>`.

* - **backlog**
- Integer;
controls the 'backlog' parameter to the listen(2) system-call.
This essentially limits the number of pending connections waiting
to be accepted.

The default varies by system. On Linux, FreeBSD, OpenBSD and macOS
we default (-1) to the OS's default. E.g. on Linux since 5.4 this is
4096, on FreeBSD it's 128.

On other systems we default to 511.

NOTE: Whatever limit you set here will be limited by the OS's
system-wide sysctl, e.g. on Linux net.core.somaxconn and on BSD
kern.ipc.somaxconn

Here, a local listener accepts requests at port 8300
and passes them to the **blogs** app
Expand Down Expand Up @@ -5662,4 +5677,4 @@ Example with njs and the use of a template literal:
"if": "`${uri == '/health' ? false : true}`",
"path": "..."
}
}
}