eclipse-ee4j / eclipse-ee4j/jersey

Jersey - CdiComponentProvider.isJaxRsComponentType - Throtelling WeldBoostrap phsae

Open
#3,703 2 comments 0 reactions 0 assignees View on GitHub
cdi weblogic
Dominant language
Java
Stars
730
Forks
382
PR merge metrics
No merged PRs in 30d

Description

Hi,
In weblogic 12.2.1.2, Jersey and the:
CdiComponentProvider.isJaxRsComponentType

Is throttling deployment speed.
We have an application where this annotated beans obverver is responsible for more than 7 seconds of deployment time.

The following sample application with 4999 beans is able to demonstrate, if a Thread Dump is taken every second, that the deployBeans phase is being slowed down by jersey.
https://github.com/99sono/wls-jsf-2-2-12-jersey-weldstartup-bottleneck

On a real productive with higher degree of complexity the situation can be much worse.

This API should be heavily tuned, Jresey should never or rarily be spotted during thread dump sampling of the deployment of an application.

In this case, we are dealing with WeldBoostrap which is a process of much higher complexity than checking if an annotated class is related to JAX-RS, and the code from WeldBoostrap barely registers in the thread dumps, if not for Jersey.

NOTE:
Oracle has been made aware of this issue.

Kindest regards.

Contributor guide

Open the contributing guide

Research direction

Start with CdiComponentProvider.isJaxRsComponentType and reproduce the deployment slowdown using the linked sample application with 4,999 beans. Review thread dumps during the WeldBootstrap deployBeans phase and compare Jersey's contribution. Done means the deployment overhead is reduced and the improvement is demonstrated against the reported scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.