slachiewicz opened a new pull request, #13826:
URL: https://github.com/apache/maven/pull/13826

   Backports two settings features from maven-3.10.x, keeping their authors and 
adding `(cherry picked from …)`. maven-3.9.x already binds server credentials 
to repository origins (aeb0a05540); with these commits a server can also 
declare its origins itself, as on 3.10.0.
   
   1. **MNG-5913, server `<aliases>`** (713b643b19 on maven-3.10.x). It bumps 
the settings model to 1.3.0, which `<repositoryOrigins>` belongs to, so it 
comes first.
   2. **#13265, `<server><repositoryOrigins>`** (ae59501ad8 on maven-3.10.x). A 
server can list the origins its credentials may be used with. They are added to 
the origins Maven derives from repositories and mirrors with the same id, 
validated (an unparsable value is an error, a full URL a warning naming the 
origin used), and named in the warnings of the origin binding.
   
   Adapted for 3.9.x, nothing else: the 3.10.x hunk that also brought Resolver 
2 version-filter lines into `DefaultRepositorySystemSessionFactory` is left 
out; the new `DefaultRepositorySystemSessionFactoryTest` injects 
`DefaultRepositorySystemSessionFactory` and calls `newRepositorySession()`, as 
3.9.x has no `RepositorySystemSessionFactory` interface; 
`DefaultSettingsBuilderFactoryTest` gains the `assertEquals` import 3.10.x 
already had.
   
   **Settings compatibility.** The model goes from 1.2.0 to 1.3.0, as in 
3.10.0. Settings with the 1.2.0 namespace or none keep loading; 1.3.0 settings 
with `<aliases>` and `<repositoryOrigins>` are accepted. No other element 
changes.
   
   Verified: `DefaultSettingsBuilderFactoryTest`, 
`DefaultSettingsValidatorTest`, `DefaultRepositorySystemSessionFactoryTest`, 
`OriginBoundAuthenticationSelectorTest` → 5, 18, 5 and 7 tests pass; spotless 
and RAT pass.
   
   Not included: a core IT. On 3.9.x the core ITs live in 
apache/maven-integration-testing; one would be a separate PR there, gated to 
`[3.9.17,)`.
   
   ---
   
   Following this checklist to help us incorporate your
   contribution quickly and easily:
   
   - [x] Your pull request should address just one issue, without pulling in 
other changes.
   - [x] Write a pull request description that is detailed enough to understand 
what the pull request does, how, and why.
   - [x] 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.
   - [x] 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.
   - [x] 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 [Core IT][core-its] successfully.
   
   To make clear that you license your contribution under
   the [Apache License Version 2.0, January 
2004](http://www.apache.org/licenses/LICENSE-2.0)
   you have to acknowledge this by using the following check-box.
   
   - [x] I hereby declare this contribution to be licenced under the [Apache 
License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
   - [ ] In any other case, please file an [Apache Individual Contributor 
License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   [core-its]: https://maven.apache.org/core-its/core-it-suite/
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to