apache / apache/grails-core

Do NOT include compilation dependencies in production jar

Open
#13,745 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
Groovy
Stars
2.9k
Forks
975
Avg merge
1d 22h
Merged PRs (30d)
92

Description

Amongst other things, javax.servlet is being bundled in the production jar/war. This is supposed to be provided by the container and adds an extra 30MB++ dependency to the final distribution. `api` is **NOT** a replacement for `provided`

Numerous dependencies should *not* be part of the final build:
```
95505 10-10-2024 05:33 BOOT-INF/lib/javax.servlet-api-4.0.1.jar
141302 10-09-2024 06:27 BOOT-INF/lib/ant-junit-1.10.14.jar
384581 10-09-2024 06:16 BOOT-INF/lib/junit-4.13.2.jar
78743 10-11-2024 06:28 BOOT-INF/lib/javax.el-api-3.0.1-b06.jar
237335 10-10-2024 05:33 BOOT-INF/lib/javax.el-3.0.1-b12.jar
792399 10-10-2024 05:33 BOOT-INF/lib/spring-test-5.3.39.jar
15071 10-10-2024 05:33 BOOT-INF/lib/jta-1.1.jar
82803 10-10-2024 05:31 BOOT-INF/lib/groovy-ant-3.0.21.jar
2303167 10-09-2024 06:27 BOOT-INF/lib/ant-1.10.14.jar
18871 10-09-2024 06:27 BOOT-INF/lib/ant-launcher-1.10.14.jar
```

Contributor guide

Open the contributing guide

Research direction

Start from the build configuration that assembles the production jar/war and compare the dependency scopes for the packages listed in the issue, especially the distinction between `api` and `provided`. Verify the resulting archive contents; done means container-provided and test or compilation-only dependencies listed here are absent from the production distribution.

Written by the indexing model from the issue text.

Assessment

Tech stack
groovy
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.