I have a set of non-trivial methods and the result of one of these will eventually be requested. I want to run all of the methods in parallel so that the answer from whichever one is chosen will be immediately available.
I know the probability of each method being selected and so I would like to reflect these probabilities in the priorities of the methods as they run in parallel.
The OS I use ignores the priorities I give to threads and so is there a workaround to ensure that the thread running the method with the highest probability will get more CPU resources?