Use a struct with all the params for threading