Skip to content

Should shutdownAndAwaitTermination and awaitUninterruptibly be @CheckReturnValue? #3655

Open

Description

(For that matter, ExecutorService.awaitTermination itself -- though that change would ideally be made in Error Prone itself, rather than in our subclass ListeningExecutorService.)

I just had a bug in my test because I was thinking that shutdownAndAwaitTermination would throw an exception if the executor didn't terminate in time. I'm not sure that's what all callers would want, but it does seem weird to specifically wait around for termination but wait only so long. We could prompt users to think about this by adding @CheckReturnValue (or really "by removing @CanIgnoreReturnValue").

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions