Commit Graph

12090 Commits

Author SHA1 Message Date
Guillaume Nodet c813320848
Remove empty dependency scope from the api (#1402) 2024-02-07 14:37:36 +01:00
Tamas Cservenak 76794c0237
[MNG-8043] Dependency properties should be provided by Maven (#1399)
Followup of MRESOLVER-484:
* move off deprecated resolver bits
* introduce non-deprecated replacements
* move existing to code to those new bits

---

https://issues.apache.org/jira/browse/MNG-8043
2024-02-07 10:51:56 +01:00
Guillaume Nodet a37cf3d37f
[MNG-7954] New dependency injection mechanism (#1393) 2024-02-05 10:45:47 +01:00
Tamas Cservenak 3f9fec2307
[MNG-8026] Maven drives regarding scopes (#1391)
Changes:
* new types for build path, path scope, dependency scope, language
* introduce "extensible enum" and provides registries, SPI providers, etc...
---------
Co-authored-by: Guillaume Nodet <gnodet@gmail.com>
2024-02-05 10:42:51 +01:00
huazhongming b3ec995848
[MNG-8013] Integration testing process logs can be output github artifact (#1375)
Signed-off-by: crazyhzm <crazyhzm@apache.org>
2024-02-05 11:02:11 +08:00
Tamas Cservenak 42559937d8
[MNG-7854] Warn if imported dep is ignored (#1370)
The artificial (or "bolted on") scope "import" behaves wildly differently that rest of Maven, causes surprise to our users. For start, we should emit "actionable" warnings about these, ultimate goal is to align this behaviour with "maven way" of working ("closest occurence wins" vs current weird "direct occurrence then first occurence wins" strategy).

Warnings are only created when the dependency is not directly managed. The warning also suggests to add a direct managed dependency to get rid of it, so it's now helpful and actionnable.

---

https://issues.apache.org/jira/browse/MNG-7854
2024-02-01 17:25:04 +01:00
Guillaume Nodet 16fc54da7f
[MNG-8037] Restrict project to the entity being built and make it immutable (#1389)
* Make POM and basedir required on the project
* Remove the API to build projects from artifact coordinate
2024-01-31 00:39:19 +01:00
Guillaume Nodet 0a1117854c
[MNG-8036] [MNG-8017] [MNG-8022] Upgrade JLine to 3.25.1 (#1390) 2024-01-29 16:51:24 +01:00
Tamas Cservenak 2452a6488a
[MNG-8035] Update to Resolver 2.0.0-alpha-7 (#1394)
Update to Resolver 2.0.0-alpha-7, sort out TODO.

This is also one simple change "sneaked in" for RAT, to ignore local `.mvn` that is unrelated to all this, but does not make any harm. In turn, it allows dev local checkout to have various stuff set without
decorating those with headers or fighing RAT plugin.

---

https://issues.apache.org/jira/browse/MNG-8035
2024-01-29 16:27:43 +01:00
Tamas Cservenak 20f7cfc361
[MNG-8026] Maven drives regarding scopes (#1392)
Maven should be fully in control regarding dependency scope definitions and their interpretations (and transformations). 
This PR makes following changes:
* no change in behaviour (all works as before), but
* maven codebase contains now all the code related to scopes
* no resolver code is in use that was deprecated (as it was wrong to have it in resolver), see issue [MRESOLVER-471](https://issues.apache.org/jira/browse/MRESOLVER-471)
* this also stops scope definitions duplication as well, they are now defined in one single project: Maven

---

https://issues.apache.org/jira/browse/MNG-8026
2024-01-25 14:58:24 +01:00
Tamas Cservenak f2595c83d9
[MNG-8023] New method + javadoc on Project (#1387)
Introduce new method that returns POM and project Artifact in sensible manner (so install or deploy and other does not need to figure out anything).

Also, javadoc the class.

---

https://issues.apache.org/jira/browse/MNG-8023
2024-01-23 13:06:56 +01:00
Guillaume Nodet b6a84fcac6
[MNG-8014] Fix multithreaded builder (#1386) 2024-01-22 18:27:48 +01:00
Tamas Cservenak 6afa4770cb
[MNG-8006] [MNG-8021] SPI to contribute properties and more (#1384)
Create _aether internal_ "extenders" components to serve several purposes:
* extender to meddle with exec request, for example to mediate between effective properties SPI (exec request extender)
* extender to meddle with prepped session and related bits, for example to move out deprecated code from session factory (session extender)

This PR implements M4 API SPI for contributing effective properties and exposes method for effective properties on `Session`.
* `Session` should expose properties service "ready" for interpolation, otherwise each interpolating code (plugin, etc) would need to construct the "effective" ones themselves, repeating same steps over and over again.
* SPI can contribute to user properties
* `Session` exposed properties are all immutable (sans effective, that is computed on each call).
* and lastly, a cleanup: all packages within `o.a.m.internal.aether` are now package protected, to tighten internal encapsulation. New core package `o.a.m.resolver` introduced that contains 2 publicly accessible classes.

---

https://issues.apache.org/jira/browse/MNG-8006
https://issues.apache.org/jira/browse/MNG-8021
2024-01-19 12:00:28 +01:00
Tamas Cservenak 3f47580dcc
[MNG-8005] Fix workspace reader drop bug (#1385)
Maven4 seems sets but then drops/overrides some workspace readers. Partially due hazy borders who or what manages them, as role is split between session factory and session factory caller.

Changes:
* session factory does NOTHING re workspace readers, it becomes fully the caller duty
* two spots calling session factory (default maven, extension bootstrap) are now fully in charge to properly setup workspace readers

Co-authored-by: Jonas Rutishauser <jonas.rutishauser@alumni.ethz.ch>

---

https://issues.apache.org/jira/browse/MNG-8005
2024-01-18 12:51:16 +01:00
Guillaume Nodet b44856d0dc
Simplify model builder internal Graph (#1380) 2024-01-15 17:49:26 +01:00
Guillaume Nodet e15170ba0e
[MNG-8014] Workaround for deadlocks in model building (#1376) 2024-01-15 13:14:56 +01:00
Guillaume Nodet 7f70467aa3
[MNG-8016] Simplify ModelCache (#1377)
The `ModelCache` is now bloated and can be simplified a lot.

---

https://issues.apache.org/jira/browse/MNG-8016
2024-01-13 14:02:40 +01:00
Guillaume Nodet 0d046da6f1 [maven-release-plugin] prepare for next development iteration 2024-01-12 10:41:50 +01:00
Guillaume Nodet e627879aed [maven-release-plugin] prepare release maven-4.0.0-alpha-12 2024-01-12 10:41:41 +01:00
Guillaume Nodet 18c0d9aecd [MNG-8003] Fix BOM groupId 2024-01-12 10:40:22 +01:00
Guillaume Nodet 8ce99bdbf2 [maven-release-plugin] prepare for next development iteration 2024-01-12 09:24:56 +01:00
Guillaume Nodet aa7994890b [maven-release-plugin] prepare release maven-4.0.0-alpha-11 2024-01-12 09:24:48 +01:00
Guillaume Nodet 2084b0e499 [MNG-8003] Do not import the BOM within the reactor 2024-01-12 09:09:46 +01:00
Tamas Cservenak a952c9ee10
[MNG-7960] Artifact collection filtering (#1353)
Make Maven more friendly (and tunable) when ranges are being used. There new options are merely affecting range processing, allowing different narrowing strategies. Relies on latest Resolver alpha-6 features.

https://issues.apache.org/jira/browse/MNG-7960
2024-01-11 18:47:28 +01:00
Tamas Cservenak 63a207a0f6
[MNG-8007] Maven TransferListener wrapper (#1371)
A wrapper listener that can receive events even from multiple threads, and passes them to wrapped delegate listener on single thread, keeping delegate implementation simple.

---

https://issues.apache.org/jira/browse/MNG-8007
2024-01-11 18:35:13 +01:00
Tamas Cservenak 5261ba9203
[MNG-7982] Switch to enable transitivity in depMgr used by Maven (#1357)
Resolver 2.0.0-alpha-6 introduced "transitive" switch to dependency Manager, make use of it.

---

https://issues.apache.org/jira/browse/MNG-7982
2024-01-11 17:55:21 +01:00
Guillaume Nodet f1c53cbfdf
[MNG-8003] The Maven BOM should have a cleaner parent (#1374) 2024-01-11 16:12:49 +01:00
huazhongming 6c20e8e85c
[MNG-8000] DefaultArtifact lacks constructors for version and optional (#1368)
Signed-off-by: crazyhzm <crazyhzm@apache.org>
2024-01-11 13:35:01 +01:00
Tamas Cservenak c4ccba7bf9
[MNG-7994] Update to Resolver 2.0.0-alpha-6 (#1373)
Update to alpha-6. Also, move off from deprecated default ctor of def repo session in tests.

---

https://issues.apache.org/jira/browse/MNG-7994
2024-01-11 13:16:51 +01:00
Tamas Cservenak cfa13f5cc7
[MNG-7999] Confine Plexus Container as much as possible (#1367)
This is an ongoing effort to confine Plexus, but also perform a bit of cleanup in Maven Core and around. No logic changes, just replacing Plexus with Lookup (that is a thin wrapper around it), and removing unused members, redundant checks, etc. Module maven-compat omitted on purpose.

---

https://issues.apache.org/jira/browse/MNG-7999
2024-01-10 13:55:54 +01:00
Tamas Cservenak 2c06637fb4
[MNG-8001] Expose CoreRealm internally (#1369)
Expose internally (not for plugin API) CoreRealm.

---

https://issues.apache.org/jira/browse/MNG-8001
2024-01-10 13:53:42 +01:00
Tamas Cservenak 076b346c0c
[MNG-7998] Minor cleanup regarding "tasks" (#1366)
Just a minor cleanup regarding internals of "tasks".

---

https://issues.apache.org/jira/browse/MNG-7998
2024-01-09 21:57:17 +01:00
Guillaume Nodet 33aec13b84
[MNG-7996] Remove experimental flag from build-consumer feature (#1364) 2024-01-09 14:04:57 +01:00
Guillaume Nodet 8460021f02 Remove useless comment which was introduced when wrapper was included 2024-01-09 08:24:07 +01:00
Olivia Lucca Fraser 804cfea8f6
Fixed a copy-paste error in ComparableVersionTest.java (#1363)
Co-authored-by: Olivia Lucca Fraser <lucca@mushussu.local>
2024-01-09 07:39:47 +01:00
Guillaume Nodet 979fc9a5b6
[MNG-7983] Switch to slf4j-api 2 (#1358) 2024-01-09 07:36:58 +01:00
Guillaume Nodet 5baa2f4098
[MNG-7977] Fix reactor reader to not resolve any artifacts from projects being built outside the reactor (#1330) 2024-01-08 11:38:13 +01:00
Guillaume Nodet 782e8679bf
[MNG-7995] Switch to JLine to provide line editing (#1279) 2024-01-08 11:37:09 +01:00
Guillaume Nodet 47fc18faf9
[MNG-7992] Fix windows identified as dos (#1360) 2024-01-08 09:52:00 +01:00
Karl Heinz Marbaise 23d13fb322
[MNG-7989] - Making this build non-interactive, because the environment variable CI equals true. 2023-12-22 19:12:21 +01:00
Tamas Cservenak 437f34f8dc
[MNG-7957] Checksum API (backed by Resolver) (#1359)
Expose checksumming API (backed by Resolver).

---

https://issues.apache.org/jira/browse/MNG-7957
2023-12-21 09:05:10 +01:00
Guillaume Nodet b4e78d7c43
[MNG-7985] Provide project access to modified resources / test-resources and to the executionProject (#1356) 2023-12-21 06:31:27 +01:00
Tamas Cservenak 732e3649e1
[MNG-7980] CLI switch to ignore transitive repositories. (#1354)
If set, Maven will ignore all remote repositories introduced by
transitive dependencies POM.

---

https://issues.apache.org/jira/browse/MNG-7980
2023-12-20 14:03:57 +01:00
Tamas Cservenak 00d243a92e
[MNG-7978] Decouple maven-artifact from maven-resolver-provider (#1352)
As it is actually not needed. This also "pulls in" all of VersionParser into model version parser, so Core implementation now 100% just delegates over there.

---

https://issues.apache.org/jira/browse/MNG-7978
2023-12-20 14:03:35 +01:00
Tamas Cservenak a381970609
[MNG-7969][MNG-7981] Add missing information on Maven 4 version api to fix an exception (#1355)
Co-authored-by: Guillaume Nodet <gnodet@gmail.com>
2023-12-19 20:08:55 +01:00
Guillaume Nodet fe71f7d8aa [maven-release-plugin] prepare for next development iteration 2023-12-18 17:27:24 +01:00
Guillaume Nodet 89d3c0321d [maven-release-plugin] prepare release maven-4.0.0-alpha-10 2023-12-18 17:27:16 +01:00
Guillaume Nodet e6cd7b1ac4 Break dependency cycle 2023-12-18 17:25:17 +01:00
Tamas Cservenak ad5e085ebe
[MNG-7959] User controlled rewrite (#1351)
Extra handling if redirection happens within same GAV.

---

https://issues.apache.org/jira/browse/MNG-7959
2023-12-18 16:31:24 +01:00
Tamas Cservenak 9596255cbf
[MNG-7959] User controlled relocations Addendum (#1350)
Name the things.

---

https://issues.apache.org/jira/browse/MNG-7959
2023-12-18 13:26:49 +01:00