luoyuan3471 commented on PR #4726: URL: https://github.com/apache/hadoop/pull/4726#issuecomment-1211760018
> @luoyuan3471  you can see this image. this problem will happen when refresh thread is calling PreemptionManager.refreshQueue and schedule thread is calling AbstractCSQueue.getTotalKillableResource.At this time, refresh thread will require csqueue.readLock,but csqueue.readLock will blocked by schedule thread and "other thread"( https://bugs.openjdk.org/browse/JDK-6893626 ).And schedule thread will require PremmptionManager.readLock,but this readLock will blocked by refresh thread held writeLock. so i use tryLock to make refresh thread get csqueue.readLock. Wait for the refresh thread complete PreemptionManager.refreshQueue,the schedule thread will get premmptionManager.readLock, then can allocate new container. ----------------------------------------------- Do you mean readLock.tryLock() will make readLock place first ,though a write lock request is already in the head of waiting queue? @yb12138 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
