-
Enhancement
-
Resolution: Done
-
Major
-
jbossws-cxf-7.1.0.Final
-
None
Heavy load in CXF Service.getPort calls from a servlet, will cause performance issue from:
@WebServlet( urlPatterns = {"/WSAccess"}, asyncSupported = true ) public class WSAccessServlet extends HttpServlet { public WSAccessServlet() { } protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { String endPointAddress = "http://localhost:8080/jaxws-retail/ProfileMgmtService/ProfileMgmt"; QName serviceName = new QName("http://org.jboss.ws/samples/retail/profile", "ProfileMgmtService"); try { URL wsdlURL = new URL(endPointAddress + "?wsdl"); Service service = Service.create(wsdlURL, serviceName); ProfileMgmt proxy = (ProfileMgmt)service.getPort(ProfileMgmt.class); Customer customer = new Customer(); customer.setFirstName("Jayé"); customer.setLastName("Boss"); customer.setCreditCardDetails("newbie"); DiscountRequest dRequest = new DiscountRequest(); dRequest.setCustomer(customer); DiscountResponse dResponse = proxy.getCustomerDiscount(dRequest); Customer responseCustomer = dResponse.getCustomer(); System.out.format("%s %s's discount is %.2f%n", responseCustomer.getFirstName(), responseCustomer.getLastName(), dResponse.getDiscount()); } catch (Exception var12) { var12.printStackTrace(); } } }
The first trying load SOAP relevant class with current context loader(deployment classloader) always fail. This takes a lot of CPU time and throws other JDK exception when this is called with high concurrent requests.
- is caused by
-
OPENJDK-3030 jdk.internal.loader.AbstractClassLoaderValue.computeIfAbsent has race condition allowing for CPU spikes
- New
- is cloned by
-
JBEAP-27325 [GSS](7.4.z) JBWS-4424 - Heavy load in CXF Service.getPort calls from a servlet causes performance issue
- Verified
-
JBEAP-27324 [GSS](8.0.z) JBWS-4424 - Heavy load in CXF Service.getPort calls from a servlet causes performance issue
- Ready for QA