I'm working with a JavaEE 8 application that has one rest Endpoint shown as below.
I use Jboss EAP 7.2 as Application Server that has thread-pool count 1000 and bounded-queue-thread-pool count 900.
This rest request has some validation businesses in someBusiness.sendResponse(message04);
and also calls another soup request and wait for it to response then response back result.
Sometime this soup request takes too much time , and the problem is that when i have heavy request on this endpoint like 40000 per sec this will make more than that pools i've been set in jboss.and i lose some of requests.i cant make those soup endpoints to do faster their works and cant set my jboss thread more than 1000 cause of some businesses.
What is solutions for situations like this in large companies?what you suggest(technologies or framework)? i can freely use any technologies i want like mq kafka or anything but i want best practices that large companies do.
@Stateless
@Path("/")
public class PaymentIDInquiryImpl {
@EJB
SomeBusiness someBusiness;
@Produces(MediaType.APPLICATION_XML)
@Consumes(MediaType.APPLICATION_XML)
@Path("/SomeInquiry")
@POST
public Message04 getPaymentIDInquiry(Message01 message01) {
return someBusiness.sendResponse(message04);
}
}