Skip to content

Query and ref are lost from jar: URLs that are processed by fat jar loader's handler #14011

@TristanDupontICE

Description

@TristanDupontICE

When a ref is used in a java.net.URL, org.springframework.boot.loader.jar.Handler.parseURL() lose the information.

Code to reproduce:

URL url = new URL("jar:file:/archive.jar!/file.txt#some-ref");
System.out.println(url);

Actual output:

jar:file:/archive.jar!/file.txt

Expected output:

jar:file:/archive.jar!/file.txt#some-ref

This bug occurs only when the application is started with spring-boot-loader. Some frameworks need reference to work properly, this information cannot be lost.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions