first of all, I'd like to talk about my understanding of Synchronize asynchronous blocking nonblocking:
Synchronize asynchronism refers to whether a thread can handle one thing while it is dealing with another, and then give the result of another thing later
blocking nonblocking refers to whether a thread will be blocked while processing something. (NIO in linux means no block io)
which in java and other programming languages, It should be a programming model,
in linux's IO model, this statement is not true, because no matter what IO model is copied from the kernel to the user mode, it is blocking. Even in the Synchronize non-blocking model,
in the linux model, blocking non-blocking means using the system call to see if the user state is ready for this process. For linux multiplexing, the system call select is also blocked, and there is no way to do other tasks. It looks like it should be Synchronize blocking, but it is much better than linux's Synchronize blocking,
because Synchronize blocking model is for one IO, and multiplexing is for multiple IO,
about linuxIO model: https://www.jianshu.com/p/486.
I have struggled with Synchronize non-blocking and asynchronous non-blocking before, but then I thought about it. Take netty as a whole, it belongs to asynchronous non-blocking. The thread of accept processes the request and passes it to the reactor,
then the thread of accept will not process other requests. This will achieve asynchronous non-blocking. But his internal reactor uses the multiplexing model instead of the real asynchronous non-blocking model,
so having said so much, in fact, I still want to express Synchronize async, blocking and non-blocking. It's just a programming idea. You don't have to struggle, and don't be confused by linux's IO model.
and java's NIO means new IO, not noblock io, because in addition to providing selector, it also provides other io features, such as handling large files
.it is recommended that you read the second edition of Netty's authoritative guide, which is very clear
.Previous: React-native acquires objects in state. If there are multiple layers, an error will be reported.
Next: How does vue-cli package txt files under the dist folder and at the same level as index.html?
recently working on flume+kafka+storm, I would like to ask you that you can access kafka-manager and storm ui without a password. Isn t this very insecure? how to configure an access password for these two pages? ...
function: read the contents of files in the specified directory on the remote linux server. known: server IP, port number, user name, password, path, file name. I use ssh2 mode to establish a connection, and then I can only upload or retrieve files. T...
java s web service is deployed on linux. When upgrading a new version of kill-9 XXXX, some unprocessed requests are aborted, especially some operations to write to the database. is there any way to stop service after the current request is successfull...
I recently built a GitLab repository with my own server . Every time I write it locally by clone, then push it to this warehouse, and then clone the contents of this warehouse on the online server (the same server), but I think it s very cumbersome. bu...
1. Yesterday noon server monitoring hint: server xx.xx machine cpu utilization exceeded 20% for 36 times in a row 2. Server basic information: javaweb project, provide query, export and other functions. 3. The monitoring information is as follows: yo...
suppose I deploy the application under test, and the owner and default group of the application are both test,. Why is the owner and default group of the generated path folder created from the application code root? For what reason. drwxrwxr-x 9 test t...
< H1 > A fatal error has been detected by the Java Runtime Environment: < H1 > < H1 > SIGBUS (0x7) at pc=0x00007fa8b1052410, pid=5320, tid=0x00007fa89dbe9700 < H1 > < H1 > JRE version: Java (TM) SE Runtime Environment (8.0_162-b12) (build 1.8.0_162-b...
Aliyun: ubuntu 16.04. springBoot: 1.5.9 declare: I do not have a domain name ~ my attempt: 1 I have applied for an account on it ipv6 etc network interfaces ipv6 netstat -tnlp tcp6 udp6~~ dns ping6 ipv6.baidu.com ping ...
tomcat8 default configuration: ab4001000 tomcat8:catalina.shserver.xml tomcat8nio ab (only some simple parameters are modified here, but they should be the most direct and effective, not even the simple ones, not to mention the advanced parameter...
I have a question about docker file persistence that I d like to ask you guys now I ve created a docker container for host directory mapping when starting container-v, the folders in the home directory in my container will be empty by default. ...
I use NERDTree, in vim and there is a very useful shortcut Ctrl+w+w is used to switch horizontally, but I think it s too troublesome. I want to set another shortcut for this key combination, such as . Ctrl+Alt+Left I don t know how to configure it...
The question is this: for example, if I have built a set of services using docker-compose on machine a, is there any way to quickly use these containers on other machines (b machines)? the way I can think of is: put all the files needed to build on...
problem description: when developing java applications, you need to visit this website. Everything accesses normally on windows, and when deployed to a linux server, access timeout occurs [root@VM_18_115_centos ~]-sharp wget https: wap.zhengzhoubu...
Hello, everyone cpu ...
the search string is highlighted when using the grep command. But sometimes there are too many search results, so if you need to page them, you should use less . grep "find string " file |less the search string is not highlighted in the less results ...
< H1 > what is the main purpose of upnp protocol? Can this requirement be achieved? < H1 > Baidu went to php java to implement upnp, and found that they are all profiles . so I d like to ask a question: if there are multiple routers and multiple nat...