# | Line 2068 | Line 2068 | public class ThreadPoolExecutor extends | |
---|---|---|
2068 | * public void rejectedExecution(Runnable r, ThreadPoolExecutor e) { | |
2069 | * Future<?> dropped = e.getQueue().poll(); | |
2070 | * if (dropped != null) | |
2071 | < | * dropped.cancel(false); // also consider logging the failure |
2072 | < | * e.execute(r); // retry |
2071 | > | * dropped.cancel(false); // also consider logging the failure |
2072 | > | * e.execute(r); // retry |
2073 | * }}}</pre> | |
2074 | */ | |
2075 | public static class DiscardOldestPolicy implements RejectedExecutionHandler { |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |