slawekjaranowski commented on code in PR #1790:
URL: https://github.com/apache/maven-resolver/pull/1790#discussion_r2790028722


##########
maven-resolver-transport-http/src/main/java/org/eclipse/aether/transport/http/HttpTransporter.java:
##########
@@ -358,6 +363,18 @@ final class HttpTransporter extends AbstractTransporter {
             
builder.setConnectionReuseStrategy(NoConnectionReuseStrategy.INSTANCE);
         }
 
+        if (session.getCache() != null) {
+            String authCacheKey = getClass().getSimpleName() + "-" + 
repository.getId() + "-"
+                    + StringDigestUtil.sha1(repository.toString());
+            AuthCache cache = (AuthCache) session.getCache().get(session, 
authCacheKey);
+            if (cache == null) {
+                cache = new BasicAuthCache();
+                session.getCache().put(session, authCacheKey, cache);
+            }

Review Comment:
   should we synchronize such operation



-- 
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