The whole network goes crazy! The Netty high-level manual that Ali released completely shattered my previous understanding of it (theory + practice + interview + landing project)

Preface

Netty is currently the most popular NIO framework. Netty has been widely used in the Internet field, big data distributed computing field, game industry, communication industry, etc. Netty is used in the well-known Elasticsearch and Dubbo frameworks. With the penetration of the Internet into all walks of life, we can see some popular technologies in the computer field, such as cloud computing, microservices, and the Internet of Things. The core behind them has always been connectivity. In this context, mastering Netty can be regarded as the most important skill for a developer. However, many people have never had a systematic concept in learning Netty, and they don't know how or why they should learn. There are actually very few learning materials about Netty in the market. Today I want to introduce to you Ali's internal Netty advanced manual ( 2 Netty documents + a Netty actual project + interview topic). It is completely possible to take everyone to thoroughly play Netty, whether you are a novice or a developer who has used Netty, I believe you can benefit from this article.

First document

Due to space limitations, only the main content is displayed, the first document focuses on the concept of Netty. I won't do too much space to show, I use the main space to show the practical documents and projects, and the friends who need all the materials can help like the article. Follow me to add an assistant to get it for free.

  • Chapter 1 Java's I/O Evolution
  • Chapter 2 Introduction to NIO

Getting Started Netty NIO Development Guide

  • Chapter 3 Getting Started with Netty
  • Chapter 4 Solutions to TCP Sticking/Unpacking Problems
  • Chapter 5 Application of Separator and Fixed Length Decoder

Intermediate Netty Codec Development Guide

  • Chapter 6 Codec Technology
  • Chapter 7 Java Serialization
  • Chapter 8 Google Protobuf encoding and decoding
  • Chapter 9 JBoss Marshalling Codec

Advanced article Netty multi-protocol development and application

  • Chapter 10 HTTP Protocol Development and Application
  • Chapter 11 WebSocket Protocol Development
  • Chapter 12 UDP Protocol Development
  • Chapter 13 File Transfer
  • Chapter 14 Private Protocol Stack Development

Source code analysis article Netty function introduction and source code analysis

  • Chapter 15 ByteBuf and related auxiliary classes
  • Chapter 16 Channel and Unsafe
  • Chapter 17 ChannelPipeline and ChannelHandler
  • Chapter 18 EventLoop and EventLoopGroup
  • Chapter 19 Future and Promise

Architecture and Industry Applications Netty Advanced Features

  • Chapter 20 Application of Java Multithreaded Programming in Netty
  • Chapter 21 Netty Architecture Analysis
  • Chapter 22 Netty Industry Applications
  • Chapter 23 Netty Future Outlook

Appendix A Netty parameter configuration table

Part:

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

Second document

After reading and learning theoretical knowledge, many people want to use it directly in actual projects, but when it is really combined with specific projects to solve practical problems, they feel more difficult. I don’t know whether the method they use is the best. I hope Be able to learn more knowledge about case practice in order to better use Netty in business. Then the following document can definitely help you.

Chapter 1 Netty server exit unexpectedly

  • Netty server exit unexpectedly
  • Netty graceful exit mechanism

Chapter 2 Netty Client Connection Pool Resource Leakage Case

  • Netty connection pool resource leakage problem
  • Netty client creation mechanism

Chapter 3 Suspected Cases of Netty Memory Pool Leakage

  • Netty memory pool leak problem
  • Netty memory pool working mechanism

Chapter 4 ByteBuf troubleshooting case

  • HTTP protocol stack ByteBuf usage problem
  • Netty ByteBuf implementation mechanism

Chapter 5 Netty Send Queue Backlog Causes Memory Leak Case

  • Netty send queue backlog case
  • Netty message sending working mechanism

Chapter 6 API Gateway High Concurrency Stress Test Performance Fluctuation Case

  • High concurrent stress test performance fluctuation problem
  • Netty message access memory request mechanism

Chapter 7 Netty ChannelHandler Concurrency Safety Case

  • Netty ChannelHandler concurrency security issues
  • Netty ChannelHandler working mechanism

Chapter 8 Cases of Inability to Receive Messages from Vehicle Terminals

  • The car networking server cannot receive the vehicle terminal message problem
  • NioEventLoop thread working mechanism

Chapter 9 Netty 3.X version upgrade case

  • Netty 3.X version upgrade background
  • The problem of data being revised after the version upgrade
  • Context loss problem after upgrade
  • The application suffers from performance degradation after the upgrade
  • Netty threading model change analysis

Chapter 10 Netty Concurrency Failure Causes Performance Degradation Cases

  • Business ChannelHandler cannot execute concurrently
  • Netty DefaultEventExecutor working mechanism

Chapter 11 Performance Tuning Case of Lot Million Long Connection

  • Challenges faced by massive long connection access
  • Smart home memory leak problem
  • Operating system parameter tuning
  • Netty performance tuning
  • JVM related performance optimization

Chapter 12 Performance Degradation Cases Caused by Improper Static Inspection and Modification

  • Edge Service performance is severely degraded
  • Clone and shallow copy

Chapter 13 Netty Performance Statistics Misunderstanding Cases

  • Latency glitch troubleshooting related issues

Chapter 14 Netty HTTP/2 Practice Cases of gRPC

  • Getting started with gRPC basics
  • gRPC Netty HTTP/2 server working mechanism
  • Working mechanism of gRPC Netty HTTP/2 client
  • gRPC message serialization mechanism
  • gRPC threading model

Chapter 15 Cases of Improper Use of Netty Event Triggering Strategy

  • The channelReadComplete method is called multiple times
  • Summary of some misunderstandings used by ChannelHandler

Chapter 16 Netty Traffic Shaping Application Case

  • Netty traffic shaping function
  • Netty traffic shaping application
  • Netty traffic shaping working mechanism

Chapter 17 Netty SSL Application Case

  • Introduction to Netty SSL
  • Netty client SSL handshake timeout issue
  • SSL handshake performance issues
  • SSL event monitoring mechanism

Chapter 18 Netty HTTPS Server High Concurrency Downtime Case

  • Netty HTTPS server down issue
  • Reliability optimization at the functional level
  • Reliability optimization at the architectural level

Chapter 19 MQTT service access timeout case

  • MQTT service access timeout problem
  • Netty-based reliability design

Chapter 20 Netty Practice Summary

  • Netty learning strategy
  • Netty fault location skills

Part:

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

Friends who need information only need to comment + forward, follow me private message [666] to get it for free!

Landing project

The game is a European and American cartoon style MMORPG game. It is currently under development and will be released on Google Play in 2020 to enter the European and American markets. The game's technical framework is based on the well-known domestic web game "Return to the Three Kingdoms", "Return to the Three Kingdoms" was launched on the Tencent Application Center, and set an impressive record of 20 million monthly sales.

Project Overview

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

Prerequisite skills

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

Project architecture diagram

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

Interview topic: (for everyone to check and fill vacancies, it won’t be okay, with answers)

The whole network goes crazy!  The Netty high-end manual that Ali dumped completely shattered my previous cognition

 

  • 1. What is the difference between BIO, NIO and AIO?
  • 2. What is the composition of NIO?
  • 3. What are the characteristics of Netty?
  • 4. Netty's threading model?
  • 5. The reasons and solutions for TCP sticking/unpacking?
  • 6. What kind of serialization protocols do you know?
  • 7. How to choose serialization protocol?
  • 8. What is Netty's zero-copy implementation?
  • 9. What are the high performance of Netty?
  • 10. NIOEventLoopGroup source code?

Write at the end

The characteristic of Netty is that it is relatively easy to get started, but it is very difficult to really master and master it, mainly for the following reasons:

  • More knowledge involved
  • Difficult to debug
  • The class inheritance level is relatively deep, and some codes are very obscure (such as memory pool)
  • Huge code size
  • Fragmented information, lack of practical cases

The above set of Ali’s internal Netty advanced manuals is guided by problem cases. By analyzing the cases, explaining the principles behind the problems, and combining with Netty source code analysis, everyone can truly master Netty and make fewer mistakes in actual work. In the process of case analysis, Netty's problem location ideas, methods, techniques, and related tools used to solve the problem were also interspersed with explanations. “Teaching people to fish is worse than teaching people to fish”. Only by mastering these can you improve in the project. Use Netty with confidence.

If a friend encounters many problems in learning Netty and does not know how to solve it, then this set of Netty advanced manual will definitely be of great help to you. Friends in need only need to help like the article, follow me to add a small assistant vx: bjmsb2020 Get it for free!

Guess you like

Origin blog.csdn.net/weixin_50205273/article/details/108799520