Gin source code reading - how do http requests flow into gin?

This article is the second in the gin source code analysis series. In this article, we mainly clarify a problem: how does a request return to gin to process logic after receiving the request through the net/http socket? We still start with the example of net/http func main() {     http.HandleFunc("/", func(w http.ResponseWriter, r *http.Reque ...

Posted on Fri, 24 Sep 2021 11:10:03 -0400 by zimmo

❤ Detailed explanation of TCP communication transmission protocol ❤ ️

Review of the previous tutorial ServerSocket --Monitor the connection of the client. Its main function is to establish a connection -ServerSocket -Establish a connection and get one Socket -Telnet 127.0.0.1 8888- Client use Telnet Access the server to establish a connection -The server can get one Socket Object of -Gets the input / output st ...

Posted on Tue, 21 Sep 2021 04:46:44 -0400 by soak

Spring boot establishes restful interface

restful introduction Introduction to restful architecture: RESTful architecture is an architecture formed after the improvement of MVC architecture, which is connected with different services by using pre-defined interfaces. In the RESTful architecture, the browser uses POST, DELETE, PUT and GET to add, DELETE, modify and query the specifi ...

Posted on Mon, 20 Sep 2021 17:01:36 -0400 by zhaohongli

Spring MVC series (14) - file upload and download

Media Type When uploading files, you need to specify the media type. There are the following two types. multipart/form-data In HTML, the enctype attribute in the form specifies how the form data should be encoded before being sent to the server. By default, the form data is encoded as "application/x-www-form-urlencoded". That is, ...

Posted on Sun, 19 Sep 2021 05:25:46 -0400 by littlehelp

Computer network programming - learning notes

The purpose of network programming: data exchange, network communication. Elements of network communication Address of both parties: ·ip ·Port number Rules: network communication protocol TCP/IP UDP  IP ip address: InetAddress ·Uniquely locate a network computer ·127.0.0.1 local localhost ·Class ...

Posted on Fri, 17 Sep 2021 15:43:30 -0400 by ChrisBoden

Java Web cookies and sessions

Conversation introduction Session: multiple requests and responses between browser and serverIn order to realize some functions, multiple requests and responses may be generated between the browser and the server, from the browser accessing the server to the end of accessing the server (closing the browser and expiration time). The multiple re ...

Posted on Sun, 12 Sep 2021 21:56:56 -0400 by Snake PHP

RxHttp, network wide Http cache optimal solution, final battle

READ_CACHE_FAILED_REQUEST_NETWORK In this mode, the cache is read first. After reading successfully, it returns directly; Otherwise, the network will be requested (if the request is successful, write to the cache) REQUEST_NETWORK_FAILED_READ_CACHE In this mode, the network is requested first, the request is successful, the cache is written an ...

Posted on Mon, 06 Sep 2021 22:53:07 -0400 by patricklcam

JAVA WEB Part 1 - initial JAVA WEB

JAVA WEB Part 1 - initial JAVA WEB JavaWeb mainly refers to the general term of dynamic Web resource development technology using Java language. It is the sum of technologies to solve the related Web and Internet fields 1. Http protocol HTTP protocol (HyperText Transfer Protocol) is an application layer protocol developed by W3C (World Wide ...

Posted on Mon, 06 Sep 2021 19:08:21 -0400 by eyaly