You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2024/08/02 13:56:00 UTC
[jira] [Commented] (MRESOLVER-588) Incomplete system properties in SessionBuilderSupplier
[ https://issues.apache.org/jira/browse/MRESOLVER-588?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17870525#comment-17870525 ]
ASF GitHub Bot commented on MRESOLVER-588:
------------------------------------------
cstamas commented on PR #539:
URL: https://github.com/apache/maven-resolver/pull/539#issuecomment-2265456429
Personally, I'd skip doing this altogether and here is why:
* as i see in Maven4 supplier (plus Maven side of bits) this is not happening at all
* the goal of supplier is to provide "baseline" only, and nothing in Resolver uses ENV variables
* the idea is that _user_ who needs env or whatever, just _customize supplier by overriding required method_
> Incomplete system properties in SessionBuilderSupplier
> ------------------------------------------------------
>
> Key: MRESOLVER-588
> URL: https://issues.apache.org/jira/browse/MRESOLVER-588
> Project: Maven Resolver
> Issue Type: Bug
> Components: Resolver
> Affects Versions: 2.0.0
> Reporter: Hannes Wellmann
> Priority: Major
>
> The {{SessionBuilderSupplier}} provided for Maven3 sets the java System.properties as systemProperties of the Session to be build.
> [https://github.com/apache/maven-resolver/blob/d13019ce5fa38c0951ca0fb0c62a3f5f1254cffc/maven-resolver-supplier-mvn3/src/main/java/org/eclipse/aether/supplier/SessionBuilderSupplier.java#L72]
> But it does not add environment variables with their key prefixed with {{env.}} like it is for example done in Maven or MIMA:
> [https://github.com/maveniverse/mima/blob/e851dee08706024929f1004e18e3dbd7b3522b36/runtime/standalone-shared/src/main/java/eu/maveniverse/maven/mima/runtime/shared/StandaloneRuntimeSupport.java#L519-L530]
>
> From looking at the code of the SessionBuilderSupplier for Maven 4, which relys heavily on {{org.apache.maven.repository.internal.MavenSessionBuilderSupplier }}system properties are not set at all.
> My suggestion is to extend the Maven3 SessionBuilderSupplier in Maven-Resolver and in maven4 {{MavenSessionBuilderSupplier to have system-properties and environment variables fully set by default.}}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)