website

Official website download address

Fifth, Netty

An overview of the

1, the introduction

1) Netty is a Java open source framework provided by JBOSS. Netty provides an asynchronous, event-driven network application framework for rapid development of high-performance, highly reliable network IO programs.

2) Netty can help you develop a network application quickly and easily, which is equivalent to simplifying and streamlining NIO’s development process.

3) Netty is currently the most popular NIO framework.

2, strengths,

1) Elegant design.

Uniform API blocking and non-blocking sockets for all transport types; Based on flexible and extensible event models. Clear separation of concerns; Highly customizable threading model - single thread, one or more thread pools.Copy the code

2) Easy to use.

Detailed documentation of Javadoc, user guides, and examplesCopy the code

3) High performance and higher throughput.

Lower latency; Reducing resource consumption; Minimize unnecessary memory replication;Copy the code

4) Security.

Full SSL/TLS and StartTLS support.Copy the code

5) Active and constantly updated community.

Reactor

1. Basic introduction

1) There are three typical implementations based on the number of reactors and the number of threads in the resource pool

Single Reactor Single threadSingle Reactor multithreadingReactor is multithreaded

2) Netty thread mode

Some improvements are made based on the principal and slave Reactor multithreading model, wherein the principal and slave Reator multithreading model has multiple Reators

3) Netty model

Netty model

Netty Quick Start