Live data from Hacker News

Thread Pools in Nginx Boost Performance 9x (2015)

nginx.com

31–40 of 62 posts

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#31
The moral is that threads and asynchronous programming are not mutually exclusive.

No matter how much you can do with a single thread, in a highly parallel environment (such as a web server), on a cpu with multiple cores (the norm), you can (almost always) do more with multiple threads.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#32
post #25

Ok, I understand why you might "offload" read() from disk backed files file descriptors. But why "sendfile"? I thought sendfile is properly async in linux... Unless I'm getting something wrong. "aio_write" -> wasn't the idea of AIO operations to actually be truly async? Maybe it's because it requires XFS. Anyway, I'm confused.

Sendfile isn't async, it just avoids the user space copy, and in some cases the copy from the fd to the socket. Aio doesn't require xfs, just O_DIRECT, which can be tricky to get right and more work than userspace guys want to deal with.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#33
This message should probably be repeated at the bottom of the article:

"The page cache works pretty well and allows NGINX to demonstrate great performance in almost all common use cases...So if you have a reasonable amount of RAM and your working data set isn’t very big, then NGINX already works in the most optimal way without using thread pools"

So using thread pools in NGINX isn't a general recommendation. The article suggests "a heavily loaded NGINX‑based streaming media server" as the type of situation where it makes sense.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#34
post #25

Ok, I understand why you might "offload" read() from disk backed files file descriptors. But why "sendfile"? I thought sendfile is properly async in linux... Unless I'm getting something wrong. "aio_write" -> wasn't the idea of AIO operations to actually be truly async? Maybe it's because it requires XFS. Anyway, I'm confused.

No, sendfile is not necessarily non-blocking (note the difference between async and non-blocking IO), it still blocks the caller if the reading side is a disk device. The advantage of using sendfile is that you need to copy the data from the kernel-space (source) to the user-space (program) and then back to the kernel-space.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#35

The moral is that threads and asynchronous programming are not mutually exclusive. No matter how much you can do with a single thread, in a highly parallel environment (such as a web server), on a cpu with multiple cores (the norm), you can (almost always) do more with multiple threads.

Sure for threads up to cores / 2. Past that it is likely a throughput and latency loss.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#36

The moral is that threads and asynchronous programming are not mutually exclusive. No matter how much you can do with a single thread, in a highly parallel environment (such as a web server), on a cpu with multiple cores (the norm), you can (almost always) do more with multiple threads.

Sure for threads up to cores / 2. Past that it is likely a throughput and latency loss.

Does anyone have numbers to back this claim? Seems like for IO focused software you'll have a lot of dead CPU time. If you have more threads than cores, you can take advantage of that.

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#37
BEWARE OF FAKE HACKERS WHO SCAM:

If Truly you Are In Need Of A PROFESSIONAL HACKER Who Will Get Your Job Done Efficiently With Swift Response, You Have Met the Right Person. ANONYMITY: I don't care who you are. The reason why I am hired is to simply get the job done. I engage in"silent" attacks so the target remains unaware of the hack. MY HACKING CAPABILITIES: No job is too small, no job is too difficult. There are series of people who needs to Hack their target email I.D, social media websites/apps or smartphones, for many reasons such as husband cheating on wife, girlfriend cheating on boyfriend or vice versa. Or important information needed to be dumped from the target email address or for whatsoever reason you want to hack your target email address/social media websites, Or As a parent you might need to monitor what your children are doing on social media and on their personal computers so that they don’t get into trouble. Or if you want to hack a private domain email account(business email), Facebook, Twitter, contact me. Frankly speaking, I always give a 100% guarantee on any job I am been asked to do, because I have always been successful in Almost all my jobs for the past 10years and my clients can testify to that . To hack anything needs time though, but I can provide a swift response to your job depending on how fast and urgent you need. Time also depends on what exactly you want to hack and how serious you are. Enough time with social engineering is required for hacking. So if you want to bind me in a short time, then just don't contact me because I can't hack within one hour,sorry. Basically, time depends on your luck. If its good luck, then it is possible to hack within one hour but, if its in the other way round, it would take few hours. I have seen FAKE HACKERS claiming they can hack in 1hr , but there is no REAL HACKER who can say this (AVOID THEM).

If your target account is Facebook, MySpace, Twitter, sexual accounts or other social accounts etc, or you want to hack into someones smartphone so you can monitor their calls, read their messages, chats, and social account activities without their notice, feel free to contact me and we would have a nice deal! I will explain to you how I am going to get the job done.

HACKING A WEBSITE Perhaps, many people want to hack their target website for their personal reasons. I am enough experienced and skilled in hacking websites and getting access to database and I am providing the web hacking services. It may be for database access, database dump, getting access to a specific information, defacing, you might want me to hack into court database and Erase your criminal records, maybe for political reasons or competitor company etc. I dont care what type of site you will give me to pen test. Is it high profile or low profile or medium profile, I will do my possible best (just be sure that you are not going to make it a real crime otherwise I will ignore you).

PAYMENT: PLEASE, think how much you will be paying for your job and don't waste time offering 100$ or 200$ (because we might require higher than that, depending on what you want to hack and the hack tool we are going to use. I accept various secure payment methods that maintains your anonymity. However, bank direct deposits and/or transfers are not accepted due to federal tracking laws.

You can contact me for any other type of "hijacking and attacks". I do almost everything. Compositehacks@gmail.com

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#38
BEWARE OF FAKE HACKERS WHO SCAM:

If Truly you Are In Need Of A PROFESSIONAL HACKER Who Will Get Your Job Done Efficiently With Swift Response, You Have Met the Right Person. ANONYMITY: I don't care who you are. The reason why I am hired is to simply get the job done. I engage in"silent" attacks so the target remains unaware of the hack. MY HACKING CAPABILITIES: No job is too small, no job is too difficult. There are series of people who needs to Hack their target email I.D, social media websites/apps or smartphones, for many reasons such as husband cheating on wife, girlfriend cheating on boyfriend or vice versa. Or important information needed to be dumped from the target email address or for whatsoever reason you want to hack your target email address/social media websites, Or As a parent you might need to monitor what your children are doing on social media and on their personal computers so that they don’t get into trouble. Or if you want to hack a private domain email account(business email), Facebook, Twitter, contact me. Frankly speaking, I always give a 100% guarantee on any job I am been asked to do, because I have always been successful in Almost all my jobs for the past 10years and my clients can testify to that . To hack anything needs time though, but I can provide a swift response to your job depending on how fast and urgent you need. Time also depends on what exactly you want to hack and how serious you are. Enough time with social engineering is required for hacking. So if you want to bind me in a short time, then just don't contact me because I can't hack within one hour,sorry. Basically, time depends on your luck. If its good luck, then it is possible to hack within one hour but, if its in the other way round, it would take few hours. I have seen FAKE HACKERS claiming they can hack in 1hr , but there is no REAL HACKER who can say this (AVOID THEM).

If your target account is Facebook, MySpace, Twitter, sexual accounts or other social accounts etc, or you want to hack into someones smartphone so you can monitor their calls, read their messages, chats, and social account activities without their notice, feel free to contact me and we would have a nice deal! I will explain to you how I am going to get the job done.

HACKING A WEBSITE Perhaps, many people want to hack their target website for their personal reasons. I am enough experienced and skilled in hacking websites and getting access to database and I am providing the web hacking services. It may be for database access, database dump, getting access to a specific information, defacing, you might want me to hack into court database and Erase your criminal records, maybe for political reasons or competitor company etc. I dont care what type of site you will give me to pen test. Is it high profile or low profile or medium profile, I will do my possible best (just be sure that you are not going to make it a real crime otherwise I will ignore you).

PAYMENT: PLEASE, think how much you will be paying for your job and don't waste time offering 100$ or 200$ (because we might require higher than that, depending on what you want to hack and the hack tool we are going to use. I accept various secure payment methods that maintains your anonymity. However, bank direct deposits and/or transfers are not accepted due to federal tracking laws.

You can contact me for any other type of "hijacking and attacks". I do almost everything. Compositehacks@gmail.com

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#39
BEWARE OF FAKE HACKERS WHO SCAM:

If Truly you Are In Need Of A PROFESSIONAL HACKER Who Will Get Your Job Done Efficiently With Swift Response, You Have Met the Right Person. ANONYMITY: I don't care who you are. The reason why I am hired is to simply get the job done. I engage in"silent" attacks so the target remains unaware of the hack. MY HACKING CAPABILITIES: No job is too small, no job is too difficult. There are series of people who needs to Hack their target email I.D, social media websites/apps or smartphones, for many reasons such as husband cheating on wife, girlfriend cheating on boyfriend or vice versa. Or important information needed to be dumped from the target email address or for whatsoever reason you want to hack your target email address/social media websites, Or As a parent you might need to monitor what your children are doing on social media and on their personal computers so that they don’t get into trouble. Or if you want to hack a private domain email account(business email), Facebook, Twitter, contact me. Frankly speaking, I always give a 100% guarantee on any job I am been asked to do, because I have always been successful in Almost all my jobs for the past 10years and my clients can testify to that . To hack anything needs time though, but I can provide a swift response to your job depending on how fast and urgent you need. Time also depends on what exactly you want to hack and how serious you are. Enough time with social engineering is required for hacking. So if you want to bind me in a short time, then just don't contact me because I can't hack within one hour,sorry. Basically, time depends on your luck. If its good luck, then it is possible to hack within one hour but, if its in the other way round, it would take few hours. I have seen FAKE HACKERS claiming they can hack in 1hr , but there is no REAL HACKER who can say this (AVOID THEM).

If your target account is Facebook, MySpace, Twitter, sexual accounts or other social accounts etc, or you want to hack into someones smartphone so you can monitor their calls, read their messages, chats, and social account activities without their notice, feel free to contact me and we would have a nice deal! I will explain to you how I am going to get the job done.

HACKING A WEBSITE Perhaps, many people want to hack their target website for their personal reasons. I am enough experienced and skilled in hacking websites and getting access to database and I am providing the web hacking services. It may be for database access, database dump, getting access to a specific information, defacing, you might want me to hack into court database and Erase your criminal records, maybe for political reasons or competitor company etc. I dont care what type of site you will give me to pen test. Is it high profile or low profile or medium profile, I will do my possible best (just be sure that you are not going to make it a real crime otherwise I will ignore you).

PAYMENT: PLEASE, think how much you will be paying for your job and don't waste time offering 100$ or 200$ (because we might require higher than that, depending on what you want to hack and the hack tool we are going to use. I accept various secure payment methods that maintains your anonymity. However, bank direct deposits and/or transfers are not accepted due to federal tracking laws.

You can contact me for any other type of "hijacking and attacks". I do almost everything. Compositehacks@gmail.com

Re: Thread Pools in Nginx Boost Performance 9x (2015)

#40

Earlier quoted context omitted.

Sure for threads up to cores / 2. Past that it is likely a throughput and latency loss.

Does anyone have numbers to back this claim? Seems like for IO focused software you'll have a lot of dead CPU time. If you have more threads than cores, you can take advantage of that.

Asynchronous programming is also solving that problem by using an event loop.
Post reply on HN