Github user StephanEwen commented on a diff in the pull request:

    https://github.com/apache/incubator-flink/pull/126#discussion_r18402745
  
    --- Diff: 
flink-runtime/src/main/java/org/apache/flink/runtime/execution/librarycache/BlobLibraryCacheManager.java
 ---
    @@ -0,0 +1,345 @@
    +/*
    --- End diff --
    
    I think the logic with the lock map is dangerous, and most likely even not 
more efficient than a simple lock.
    
    Previous versions of the LibraryCacheManager has errors that the locks were 
not always removed, leading to endless spins. Manual spinning is not required 
any more, the JVM does adaptive spinning that automatically degrades to queued 
waiting, which is better than anything we could hope to implement manually.
    
    Since we do not expect congestion on this class, even the most simple 
global lock might do (and would be lightweight for the JVM). 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to