Google Coder Web Development uses a Raspberry Pi as the web server, and development environment.
npm install -g autocannon npm install -g clinicAutocannon generates sample requests. e.g. autocannon -c100 url will generate 100 concurrent random requests. Clinic clinic doctor --on-port='autocannon -c100 url' -- node index.js opens an HTML file with all sorts of profile data. clinic flame --on-port='autocannon -c100 url' -- node index.js generates a flame graph, which you can drill down into in order to find the slow parts of a script.+
Note that this does NOT mean NodeJS can't take advantage of multiple processors or multi-threaded work:
Use cluster when you want to parallelize the SAME flow of execution and server listening.
Use child_process when you want DIFFERENT flows of execution working together
and take advantage of built in Inter-Process Communication to pass objects between the processes.
|file: /Techref/language/java/SCRIPT/server.htm, 5KB, , updated: 2019/4/1 11:30, local time: 2022/7/4 21:12,
|©2022 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?|
|Did you find what you needed?|
Welcome to sxlist.com!
& kind contributors
just like you!
Please don't rip/copy
Copies of the site on CD
are available at minimal cost.
Welcome to www.sxlist.com!