I'm using Lua FASTCGI with Lighttpd. The Lua script is a thin wrapper around our C API which is being exposed to web. The problem is that Ajax calls execute one by one on the server side (instead of running in parallel) and it takes so much time. Some Ajax calls take up to 10 seconds and the browser cannot update any data while those calls are being executed.
I tried increasing the number of sever threads in Lighttpd but it is not recommended by Lighttpd. I don't know how to let multiple Ajax calls be executed at the server side in parallel.
lighttpd can handle many requests in parallel, but your lua fastcgi thing probably can't. So don't increase the number of lighttpd workers - increase the number of lua workers instead, or make your lua backend handle multiple requests (perhaps with coroutines) at the same time.