change MAX_THREADS to 40