var data = import('./blahblah/data')
app.get('/data', data.getData)
app.listen(3000)
// blahblah/data:
exports.getData = function(req, res) {
setTimeout(function(){
res.send('test')
}, 10000)
};
//code I use to test
for(var i = 0;i<10;i++){
$.ajax({
url: 'http://127.0.0.1:3000/data',
success: function(l){console.log(l);}
});
}
If I send 10 simultaneous requests to this endpoint, then they only receive a reply one at a time 10 seconds apart, with the last request coming 110 seconds after the first request was sent. Aren't nodejs and express supposed to let other requests process when the other requests are running asynchronous code?


getDataused in your express app?