Quantcast

Returning status 500 when connection pool is full

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Returning status 500 when connection pool is full

Alejandro Pulver
Hello,

I'm using the Grizzly 1.9 branch and would like to return an error status code 500 when the connection thread pool is exhausted instead of failing with an exception or ignoring the request.

For instance, an alternative to ThreadPoolExecutor$AbortPolicy that does this. Do you have any suggestions on how to implement this?

I understand that if the connection pool is exhausted it doesn't make sense to allocate more resources to answer all the requests with 500 but I was thinking of only 1 thread doing that.

Thanks,
Alejandro
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Returning status 500 when connection pool is full

Ryan Lubke-2
Sorry!  This slipped through.  We can continue the discussion on the issue [1] you logged.

[1] https://java.net/jira/browse/GRIZZLY-1871

September 26, 2016 at 12:12
Hello,

I'm using the Grizzly 1.9 branch and would like to return an error status code 500 when the connection thread pool is exhausted instead of failing with an exception or ignoring the request.

For instance, an alternative to ThreadPoolExecutor$AbortPolicy that does this. Do you have any suggestions on how to implement this?

I understand that if the connection pool is exhausted it doesn't make sense to allocate more resources to answer all the requests with 500 but I was thinking of only 1 thread doing that.

Thanks,
Alejandro

Loading...