You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2022/04/14 19:45:29 UTC

[GitHub] [maven] cstamas opened a new pull request, #720: [MNG-7454] Include resolver-transport-http in Maven

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

   Addendum:
   * fix property name to align with existing ones
   * fix logging configuration as no more shaded httpClient


-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] cstamas commented on a diff in pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
cstamas commented on code in PR #720:
URL: https://github.com/apache/maven/pull/720#discussion_r851411531


##########
maven-core/src/main/java/org/apache/maven/internal/aether/DefaultRepositorySystemSessionFactory.java:
##########
@@ -261,23 +261,24 @@ else if ( request.isUpdateSnapshots() )
         }
         session.setAuthenticationSelector( authSelector );
 
-        String transport = request.getUserProperties().getProperty( MAVEN_TRANSPORT_KEY, MAVEN_TRANSPORT_WAGON );
-        if ( MAVEN_TRANSPORT_RESOLVER.equals( transport ) )
+        String transport = request.getUserProperties()
+                .getProperty( MAVEN_RESOLVER_TRANSPORT_KEY, MAVEN_RESOLVER_TRANSPORT_WAGON );
+        if ( MAVEN_RESOLVER_TRANSPORT_NATIVE.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that resolver native is selected
-            configProps.put( RESOLVER_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
-            configProps.put( RESOLVER_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( MAVEN_TRANSPORT_WAGON.equals( transport ) )
+        else if ( MAVEN_RESOLVER_TRANSPORT_WAGON.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that wagon is selected
-            configProps.put( WAGON_TRANSPORTER_KEY_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( WAGON_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( !MAVEN_TRANSPORT_AUTO.equals( transport ) )
+        else if ( !MAVEN_RESOLVER_TRANSPORT_AUTO.equals( transport ) )
         {
             throw new IllegalArgumentException( "Unknown maven.transport=" + transport

Review Comment:
   fixed



-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #720:
URL: https://github.com/apache/maven/pull/720#discussion_r851413825


##########
maven-core/src/main/java/org/apache/maven/internal/aether/DefaultRepositorySystemSessionFactory.java:
##########
@@ -261,23 +261,24 @@ else if ( request.isUpdateSnapshots() )
         }
         session.setAuthenticationSelector( authSelector );
 
-        String transport = request.getUserProperties().getProperty( MAVEN_TRANSPORT_KEY, MAVEN_TRANSPORT_WAGON );
-        if ( MAVEN_TRANSPORT_RESOLVER.equals( transport ) )
+        String transport = request.getUserProperties()
+                .getProperty( MAVEN_RESOLVER_TRANSPORT_KEY, MAVEN_RESOLVER_TRANSPORT_WAGON );
+        if ( MAVEN_RESOLVER_TRANSPORT_NATIVE.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that resolver native is selected
-            configProps.put( RESOLVER_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
-            configProps.put( RESOLVER_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( MAVEN_TRANSPORT_WAGON.equals( transport ) )
+        else if ( MAVEN_RESOLVER_TRANSPORT_WAGON.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that wagon is selected
-            configProps.put( WAGON_TRANSPORTER_KEY_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( WAGON_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( !MAVEN_TRANSPORT_AUTO.equals( transport ) )
+        else if ( !MAVEN_RESOLVER_TRANSPORT_AUTO.equals( transport ) )
         {
-            throw new IllegalArgumentException( "Unknown maven.transport=" + transport
-                    + ". Supported ones are: " + MAVEN_TRANSPORT_WAGON + ", "
-                    + MAVEN_TRANSPORT_RESOLVER + " and " + MAVEN_TRANSPORT_AUTO );
+            throw new IllegalArgumentException( "Unknown " + MAVEN_RESOLVER_TRANSPORT_KEY + "=" + transport

Review Comment:
   This differs from this approach: https://github.com/apache/maven-resolver/pull/168/files#diff-a386807ca89d73dd92c1f453de3af43cee6044c2118d8952ee67ed0e8ba103d6R122-R124
   
   Personally, I like the path from Resolver: Not using the key, but text.



-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] Aylinee-RH-Arletee commented on pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
Aylinee-RH-Arletee commented on PR #720:
URL: https://github.com/apache/maven/pull/720#issuecomment-1100612599

   d826b7c78ccf3edcb9ea365480c2cfff2332c335


-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] cstamas commented on a diff in pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
cstamas commented on code in PR #720:
URL: https://github.com/apache/maven/pull/720#discussion_r851418779


##########
maven-core/src/main/java/org/apache/maven/internal/aether/DefaultRepositorySystemSessionFactory.java:
##########
@@ -261,23 +261,24 @@ else if ( request.isUpdateSnapshots() )
         }
         session.setAuthenticationSelector( authSelector );
 
-        String transport = request.getUserProperties().getProperty( MAVEN_TRANSPORT_KEY, MAVEN_TRANSPORT_WAGON );
-        if ( MAVEN_TRANSPORT_RESOLVER.equals( transport ) )
+        String transport = request.getUserProperties()
+                .getProperty( MAVEN_RESOLVER_TRANSPORT_KEY, MAVEN_RESOLVER_TRANSPORT_WAGON );
+        if ( MAVEN_RESOLVER_TRANSPORT_NATIVE.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that resolver native is selected
-            configProps.put( RESOLVER_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
-            configProps.put( RESOLVER_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( MAVEN_TRANSPORT_WAGON.equals( transport ) )
+        else if ( MAVEN_RESOLVER_TRANSPORT_WAGON.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that wagon is selected
-            configProps.put( WAGON_TRANSPORTER_KEY_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( WAGON_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( !MAVEN_TRANSPORT_AUTO.equals( transport ) )
+        else if ( !MAVEN_RESOLVER_TRANSPORT_AUTO.equals( transport ) )
         {
-            throw new IllegalArgumentException( "Unknown maven.transport=" + transport
-                    + ". Supported ones are: " + MAVEN_TRANSPORT_WAGON + ", "
-                    + MAVEN_TRANSPORT_RESOLVER + " and " + MAVEN_TRANSPORT_AUTO );
+            throw new IllegalArgumentException( "Unknown " + MAVEN_RESOLVER_TRANSPORT_KEY + "=" + transport

Review Comment:
   Done



-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] cstamas merged pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
cstamas merged PR #720:
URL: https://github.com/apache/maven/pull/720


-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #720: [MNG-7454] Include resolver-transport-http in Maven

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #720:
URL: https://github.com/apache/maven/pull/720#discussion_r850788885


##########
maven-core/src/main/java/org/apache/maven/internal/aether/DefaultRepositorySystemSessionFactory.java:
##########
@@ -261,23 +261,24 @@ else if ( request.isUpdateSnapshots() )
         }
         session.setAuthenticationSelector( authSelector );
 
-        String transport = request.getUserProperties().getProperty( MAVEN_TRANSPORT_KEY, MAVEN_TRANSPORT_WAGON );
-        if ( MAVEN_TRANSPORT_RESOLVER.equals( transport ) )
+        String transport = request.getUserProperties()
+                .getProperty( MAVEN_RESOLVER_TRANSPORT_KEY, MAVEN_RESOLVER_TRANSPORT_WAGON );
+        if ( MAVEN_RESOLVER_TRANSPORT_NATIVE.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that resolver native is selected
-            configProps.put( RESOLVER_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
-            configProps.put( RESOLVER_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( NATIVE_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( MAVEN_TRANSPORT_WAGON.equals( transport ) )
+        else if ( MAVEN_RESOLVER_TRANSPORT_WAGON.equals( transport ) )
         {
             // Make sure (whatever extra priority is set) that wagon is selected
-            configProps.put( WAGON_TRANSPORTER_KEY_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
+            configProps.put( WAGON_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY );
         }
-        else if ( !MAVEN_TRANSPORT_AUTO.equals( transport ) )
+        else if ( !MAVEN_RESOLVER_TRANSPORT_AUTO.equals( transport ) )
         {
             throw new IllegalArgumentException( "Unknown maven.transport=" + transport

Review Comment:
   Either do `Unknown " + KEY + "=" + value` or `Uknown Maven Resolver transport 'value'".
   Remember the pattern we used in Resolver for named lock factories.



-- 
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: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org