A running thread is explicitly interrupted by calling interrupt()
while it is in wait
, sleep
, or join
states.
When a normally running thread calls the interrupt()
method, it sets the current thread’s interrupt status to true, but the thread’s execution will not be affected.
You can take action based on the actual situation or check if the business code has been misused.