Sources of SimpleTimeLimiter looks perfectly thread safe for me. There are actually no place there to break thread safety, while executor you are passing is thread safe.
Threadsafety of SimpleTimeLimiter
-
18-06-2023 - |
Question
I want to use com.google.common.util.concurrent.SimpleTimeLimiter from guava in my server applications.
Can I create a singleton instance of SimpleTimeLimiter for the use in several classes?
Is the call of its method callWithTimeout() thread safe?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow