Commit fac1569
authored
Use GET() and PUT() instead of method() (#740)
But this does not work for `HEAD()` that is 18+.
Moreover, builder `method(String, BodyPublisher)` enforces body publisher as non-null, while the logic to stop emitting `Content-Length: 0` on GET and HEAD expects `null` body publisher.
This fixes:
* GET as it uses dedicated `GET()` method on builder that will use `null` body publisher (and JDK bugfix will work)
* PUT as it uses dedicated `PUT()` method on builder
* but does not fix HEAD (and as I see, it will be still emitted with `Content-Length: 0`, but may be wrong). Fixing HEAD is not possible, as dedicated `HEAD()` method was added in java 18, while the existing `method(String, BodyPublisher)` enforces non-null publisher.
Fixes #7391 parent 145588b commit fac1569
File tree
1 file changed
+2
-2
lines changed- maven-resolver-transport-jdk-parent/maven-resolver-transport-jdk-11/src/main/java/org/eclipse/aether/transport/jdk
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
272 | 272 | | |
273 | 273 | | |
274 | 274 | | |
275 | | - | |
| 275 | + | |
276 | 276 | | |
277 | 277 | | |
278 | 278 | | |
| |||
395 | 395 | | |
396 | 396 | | |
397 | 397 | | |
398 | | - | |
| 398 | + | |
399 | 399 | | |
400 | 400 | | |
401 | 401 | | |
| |||
0 commit comments