Question: What happens when a new task is submitted to an ExecutorService in which no threads are available? A The executor adds the task to an

What happens when a new task is submitted to an ExecutorService in which no threads are available?
A The executor adds the task to an internal queue and completes when there is an available thread.
B The thread submitting the task waits on the submit call until a thread is available before continuing.
C The executor stops an existing task and starts the newly submitted one.
D The executor throws an exception when the task is submitted.
E The executor discards the task without completing it.
What happens when a new task is submitted to an

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!