svalaskevicius commented on PR #15312:
URL: https://github.com/apache/iceberg/pull/15312#issuecomment-3926778735

   @mxm 
   
   > It works, but it is quite nondeterministic how the shutdown is executed. 
With the current code, the shutdown timeout can be reset multiple times if 
there are multiple calls to shutdownThreadPools().
   
   yeah, but there are no linear types in java, so the best I could do is to 
throw an exception if it's called again. but if the library is used after 
calling it the first time there should be quite a few exceptions anw.
   
   IMO at best, I could update the javadoc to word it somehow more seriously - 
to only call this at the end of the intended usage of the library, and never 
before. Also, it is safe to call it multiple times -- but only AFTER the client 
code is sure that it's not longer using the library 


-- 
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]

Reply via email to