Commit Graph
25 Commits
Author SHA1 Message Date
Junggi KimandClaude Opus 5 a0f0cf00b3 Avoid scanning the whole layer index for every entry
IndexedLayers.getLayer() walked every entry of layers.idx for each jar
entry being extracted, making extraction O(entries x index size). The
dependency entries are listed first while the application classes are
covered by a single directory entry near the end, so the most numerous
entries consistently scanned the longest.

Index the candidates once when the index file is read, keeping the
directory candidates in a separate map that preserves index order. A
file name is then resolved with a single map lookup and only the
handful of directory candidates has to be scanned.

For a jar with 24,823 entries and 700 dependencies this reduces the
number of string comparisons from 17,179,582 to 72,946 (106.9ms to
2.5ms). With 4,173 entries it goes from 1,019,857 to 11,896 (5.4ms to
0.1ms) and with 903 entries from 70,612 to 2,426 (0.8ms to 0.1ms).

Lookups resolve to the same layer as before. LayersIndex only writes a
name once its whole subtree belongs to a single layer, so no indexed
name is a prefix of another and at most one candidate can match, which
makes the order the two kinds of candidate are consulted in immaterial.

See gh-51653

Signed-off-by: Junggi Kim <kimjg2477@gmail.com>

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-10 16:23:11 +02:00
Andy Wilkinson 85535ce81f Merge branch '4.1.x'
Closes gh-51607
2026-09-07 12:20:42 +01:00
Andy Wilkinson 50350d0c83 Merge branch '4.0.x' into 4.1.x
Closes gh-51606
2026-09-07 12:20:30 +01:00
Hyunwoo Jung 528c8bd1ea Fix typos
Signed-off-by: Hyunwoo Jung <hyunwoojung@kakao.com>

See gh-51590
2026-09-07 11:53:30 +01:00
Andy Wilkinson 57b44b0594 Merge branch '4.1.x'
Closes gh-51600
2026-09-07 08:27:14 +01:00
Andy Wilkinson ea613dc511 Merge branch '4.0.x' into 4.1.x
Closes gh-51599
2026-09-07 08:26:42 +01:00
Manu Sridharan 25a3f8feb9 Remove unnecessary NullAway suppressions
Signed-off-by: Manu Sridharan <msridhar@gmail.com>

See gh-51591
2026-09-07 08:18:11 +01:00
Moritz Halbritter e5a24bafc7 Polish "Add jarmode tools command to print the SBOM"
See gh-51505
2026-09-02 16:34:49 +02:00
Hyeongjun Cho 962ca36126 Add jarmode tools command to print the SBOM
Add an 'sbom' command to the tools jar mode which prints the SBOM
packaged in an uber jar or war. The SBOM is located using the
Sbom-Location manifest attribute and its bytes are copied verbatim to
the console, or to the file given by --destination.

See gh-51505

Signed-off-by: Hyeongjun Cho <ryuu.public@gmail.com>
2026-09-02 16:26:35 +02:00
Moritz Halbritter 07e3850143 Merge branch '4.0.x' into 4.1.x
Closes gh-51547
2026-09-02 16:23:27 +02:00
Hyeongjun Cho d92a75c66b Print a simple error message when a jarmode tools command fails
See gh-51540

Signed-off-by: Hyeongjun Cho <ryuu.public@gmail.com>
2026-09-02 16:17:49 +02:00
Moritz Halbritter 8afd978548 Merge branch '4.0.x'
Closes gh-50510
2026-05-27 10:47:58 +02:00
Moritz Halbritter 5f0d0ad265 Merge branch '3.5.x' into 4.0.x
Closes gh-50509
2026-05-27 10:47:47 +02:00
Andy Wilkinson 6a74bb85a3 Merge branch '4.0.x'
Closes gh-50440
2026-05-14 15:03:44 +01:00
Andy Wilkinson add52b6ccd Merge branch '3.5.x' into 4.0.x
Closes gh-50439
2026-05-14 15:02:24 +01:00
Andy Wilkinson dcf0b4ccab Merge branch '4.0.x'
Closes gh-50132
2026-04-20 10:09:21 +01:00
Andy Wilkinson b43d3d439d Merge branch '3.5.x' into 4.0.x
Closes gh-50131
2026-04-20 10:05:26 +01:00
Phillip Webb a6e4a93cda Merge branch '4.0.x'
Closes gh-48679
2026-01-05 14:34:20 -08:00
Phillip Webb eef6a6a5e2 Merge branch '3.5.x' into 4.0.x
Closes gh-48678
2026-01-05 14:33:39 -08:00
Stéphane Nicoll da56bfea6e Remove support for the deprecated layertools jar mode
Closes gh-48568
2025-12-22 08:36:52 +01:00
Moritz Halbritter 6f94129c85 Add nullability annotations to tests in loader/spring-boot-jarmode-tools
See gh-47263
2025-10-16 14:07:16 +02:00
Andy Wilkinson 44099d3d21 Build with Gradle 9.1.0 2025-10-06 18:30:48 +01:00
Moritz Halbritter f5be18587c Improve null-safety of loader/spring-boot-jarmode-tools
See gh-46926
2025-08-26 14:22:54 +02:00
Moritz Halbritter d1d35d03c8 Add nullability annotations to loader/spring-boot-jarmode-tools
See gh-46587
2025-08-11 15:50:49 +02:00
Phillip Webb decc32dde3 Restructure project directories to better fit Gradle
Closes gh-46358
2025-07-10 17:54:08 -07:00