Github user tillrohrmann commented on the issue:

    https://github.com/apache/flink/pull/5740
  
    I agree that having a single shut down hook for cleaning up the temp 
directory is the best solution. I think that the `TaskManager` does not 
properly do it like you've described. The `TaskExecutorLocalStateStoresManager` 
registers its own shut down hooks and most of the `TaskManager` components like 
`BlobCache`, `FileCache` and `IOManager` do so likewise.
    
    The upload directory is a good point. With my changes it will always be 
deleted. If this is not the intended behaviour, then I will adapt it 
accordingly.
    
    In order to not widen the scope of this task too much I would suggest the 
following: 
    1. Addressing the general problem of reducing the number of shut down hooks 
in a separate issue
    2. Creating a a sub directory in `WebOptions#TMP_DIR` which is set up and 
cleaned up by the `ClusterEntrypoint` and its shut down hook
    
    What do you think @StephanEwen.


---

Reply via email to