Skip to content

Conversation

doddi
Copy link
Contributor

@doddi doddi commented Jun 22, 2025

This PR is a backport of #576 which was an implementation of RFC9457 which adds problem information as a payload. Previously, the reasonPhrase prior to http2 could be used to provide extra information but since http2 this has been dropped.

The backport is required because maven 3.9.x is pinning maven-resolver to 1.9.x
. The previous work was released in 2.0.2.

Slack conversation: https://the-asf.slack.com/archives/C7Q9JB404/p1750487298498529?thread_ts=1750487298.498529&cid=C7Q9JB404
Fixes: #1501

Following this checklist to help us incorporate your
contribution quickly and easily:

  • Your pull request should address just one issue, without pulling in other changes.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Each commit in the pull request should have a meaningful subject line and body.
    Note that commits might be squashed by a maintainer on merge.
  • Write unit tests that match behavioral changes, where the tests fail if the changes to the runtime are not applied.
    This may not always be possible but is a best-practice.
  • Run mvn verify to make sure basic checks pass.
    A more thorough check will be performed on your pull request automatically.
  • You have run the integration tests successfully (mvn -Prun-its verify).

If your pull request is about ~20 lines of code you don't need to sign an
Individual Contributor License Agreement if you are unsure
please ask on the developers list.

To make clear that you license your contribution under
the Apache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.

@slawekjaranowski slawekjaranowski added the enhancement New feature or request label Jun 23, 2025
@slawekjaranowski
Copy link
Member

@doddi I would like to change a title of PR to something more descriptive ... like example: RFC9457 Implementation

it will be used in release notes,

@doddi doddi changed the title Backport of MRESOLVER-600 to 1.9.x release RFC9457 implementation Jun 23, 2025
Copy link
Member

@michael-o michael-o left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Squash and use the original commit summary

@cstamas
Copy link
Member

cstamas commented Jun 23, 2025

No need for squashing, as we do it anyway (on GH UI or locally), no?

@doddi doddi force-pushed the Backport-MRESOLVER-600-to-1.9.x branch from fb1ccfd to 24f8135 Compare June 23, 2025 17:15
@doddi
Copy link
Contributor Author

doddi commented Jun 23, 2025

Easy enough to do anyway 👍

@doddi
Copy link
Contributor Author

doddi commented Jun 23, 2025

What would be the process for getting a maven-resolver release done for this change so that it can go into the next maven 3.9.x release?

@cstamas
Copy link
Member

cstamas commented Jun 23, 2025

It should happen. We plan 3.9.11 soon, and resolver 1.x has some other update prs scheduled as well.

@slawekjaranowski
Copy link
Member

Easy enough to do anyway 👍

We need also change commit message ... so quash on GitHub UI will be the easier

@slawekjaranowski
Copy link
Member

@michael-o the commit subject and message from
92b46ba

will be ok for you?

@michael-o
Copy link
Member

@michael-o the commit subject and message from 92b46ba

will be ok for you?

Exactly

@slawekjaranowski slawekjaranowski self-assigned this Jun 23, 2025
Copy link
Member

@michael-o michael-o left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit summary and message aren't still right

@slawekjaranowski
Copy link
Member

Commit summary and message aren't still right

Will be - after squash in GitHub

@michael-o
Copy link
Member

Commit summary and message aren't still right

Will be - after squash in GitHub

How? GH knows nothing about the commit on master.

backport of change 92b46ba

Added an RFC9457Reporter for HttpTransporter

At the moment, I tried to keep the original exception messages if the error response is not an [RFC9457](https://www.rfc-editor.org/rfc/rfc9457) type. This did create a little more complexity in the implementation than is perhaps necessary.

If the exceptions to be thrown can be consisted throughout the transporters, then this PR could also be simplified considerably. At the moment, I have taken the stance not to make any potential breaking changes in messaging.
@slawekjaranowski slawekjaranowski force-pushed the Backport-MRESOLVER-600-to-1.9.x branch from 24f8135 to d657c80 Compare June 23, 2025 18:48
@slawekjaranowski
Copy link
Member

@michael-o done in PR

@slawekjaranowski slawekjaranowski merged commit 615eab3 into apache:maven-resolver-1.9.x Jun 23, 2025
11 checks passed
@github-actions github-actions bot added this to the 1.9.24 milestone Jun 23, 2025
@slawekjaranowski slawekjaranowski linked an issue Jun 26, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request resolver1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Backport RFC9457 [MRESOLVER-600] to 1.9.x
4 participants