1. [Recommended] It is recommended to reduce the time_wait value of the TCP protocol for high concurrency servers.

Note: By default the operating system will close connection in time_wait state after 240 seconds. In high concurrent situation, the server may not be able to establish new connections because there are too many connections in time_wait state, so the value of time_wait needs to be reduced.

Positive example: Modify the default value (Sec) by modifying the _etcsysctl.conf file on Linux servers:
net.ipv4.tcp\_fin\_timeout = 30

2. [Recommended] Increase the maximum number of File Descriptors supported by the server.

Note: Most operating systems are designed to manage TCP/UDP connections as a file, i.e. one connection corresponds to one File Descriptor. The maximum number of File Descriptors supported by the most Linux servers is 1024. It is easy to make an “open too many files” error because of the lack of File Descriptor when the number of concurrent connections is large, which would cause that new connections cannot be established.

3. [Recommended] Set -XX:+HeapDumpOnOutOfMemoryError parameter for JVM, so JVM will output dump information when OOM occurs.

Note: OOM does not occur very often, only once in a few months. The dump information printed when error occurs is very valuable for error checking.

4. [For Reference] Use forward for internal redirection and URL assembly tools for external redirection. Otherwise there will be problems about URL maintaining inconsistency and potential security risks.