Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could io.github.scouter-project:scouter-webapp:2.17.1 drop off redundant dependencies? #869

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Celebrate-future
Copy link

@Celebrate-future Celebrate-future commented May 24, 2022

Hi! I found the pom file of project io.github.scouter-project:scouter-webapp:2.17.1 introduced 88 dependencies. However, among them, 7 libraries (7%) are not used by your project. I list the redundant dependencies below:

Redundant dependencies

org.glassfish.web:javax.el:jar:2.2.4:compile
javax.xml.bind:jaxb-api:jar:2.3.0:compile
javax.activation:activation:jar:1.1.1:compile
javax.annotation:javax.annotation-api:jar:1.2:compile
javax.inject:javax.inject:jar:1:compile
com.sun.xml.bind:jaxb-impl:jar:2.3.0:compile
javax.el:javax.el-api:jar:2.2.4:compile

Outdated dependencies

javax.inject:javax.inject:1 (5037 days without maintenance)
javax.annotation:javax.annotation-api:1.2 (3746 days without maintenance)
javax.activation:activation:1.1.1 (5027 days without maintenance)
com.sun.xml.bind:jaxb-impl:2.3.0 (2188 days without maintenance)


Removing the redundant dependencies can reduce the size of project and prevent potential dependency conflict issues (i.e., multiple versions of the same library). More importantly, one of the redundant dependencies javax.annotation:javax.annotation-api:jar:1.2:compile induced dependency conflict in the dependency graph. As such, I suggest a refactoring operation for io.github.scouter-project:scouter-webapp:2.17.1’s pom file.

The attached PR helps resolve the reported problem. It is safe to remove the unused libraries (we considered Java reflection relations when analyzing the dependencies). These changes have passed io.github.scouter-project:scouter-webapp:2.17.1’s maven tests.

Best regards

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant