view xml/en/docs/stream/stream_processing.xml @ 2600:2fd28cd4f2f8

Added set module for stream.
author Yaroslav Zhuravlev <yar@nginx.com>
date Tue, 29 Sep 2020 16:10:13 +0100
parents 59d1f512c3a0
children 4959250ba429
line wrap: on
line source

<!--
  Copyright (C) Nginx, Inc.
  -->

<!DOCTYPE article SYSTEM "../../../../dtd/article.dtd">

<article name="How nginx processes a TCP/UDP session"
         link="/en/docs/stream/stream_processing.html"
         lang="en"
         rev="3">

<section>

<para>
A TCP/UDP session from a client is processed
in successive steps called <b>phases</b>:

<list type="tag">

<tag-name id="postaccept_phase">
<literal>Post-accept</literal>
</tag-name>
<tag-desc>
The first phase after accepting a client connection.
The <link doc="ngx_stream_realip_module.xml">ngx_stream_realip_module</link>
module is invoked at this phase.
</tag-desc>

<tag-name id="preaccess_phase">
<literal>Pre-access</literal>
</tag-name>
<tag-desc>
Preliminary check for access.
The
<link doc="ngx_stream_limit_conn_module.xml">ngx_stream_limit_conn_module</link>
and
<link doc="ngx_stream_set_module.xml">ngx_stream_set_module</link>
modules are invoked at this phase.
</tag-desc>

<tag-name id="access_phase">
<literal>Access</literal>
</tag-name>
<tag-desc>
Client access limitation before actual data processing.
The <link doc="ngx_stream_access_module.xml">ngx_stream_access_module</link>
module is invoked at this phase.
</tag-desc>

<tag-name id="ssl_phase">
<literal>SSL</literal>
</tag-name>
<tag-desc>
TLS/SSL termination.
The <link doc="ngx_stream_ssl_module.xml">ngx_stream_ssl_module</link>
module is invoked at this phase.
</tag-desc>

<tag-name id="preread_phase">
<literal>Preread</literal>
</tag-name>
<tag-desc>
Reading initial bytes of data into the
<link doc="ngx_stream_core_module.xml" id="preread_buffer_size">preread buffer</link>
to allow modules such as
<link doc="ngx_stream_ssl_preread_module.xml">ngx_stream_ssl_preread_module</link>
analyze the data before its processing.
</tag-desc>

<tag-name id="content_phase">
<literal>Content</literal>
</tag-name>
<tag-desc>
Mandatory phase where data is actually processed, usually
<link doc="ngx_stream_proxy_module.xml">proxied</link> to
<link doc="ngx_stream_upstream_module.xml">upstream</link> servers,
or a specified value
is <link doc="ngx_stream_return_module.xml">returned</link> to a client.
</tag-desc>

<tag-name id="log_phase">
<literal>Log</literal>
</tag-name>
<tag-desc>
The final phase
where the result of a client session processing is recorded.
The <link doc="ngx_stream_log_module.xml">ngx_stream_log_module</link>
module is invoked at this phase.
</tag-desc>
</list>

</para>

</section>

</article>