I wrote a program that automatically grades programming assignments submitted from students. Reflection is used to load classes and instantiate objects. Unintentional infinite loops are a common mistake in student assignments. A thread is assigned to each student submission. A monitor keeps track of the threads' running time and uses the stop()
method to terminate threads that exceed the maximum time allowed. My program is working as intended, but the stop()
method in java.lang.Thread
is deprecated. I would greatly appreciate advice on a cleaner solution.
Thank you.