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

   In the mean time turns out we have two important "implementation details" to 
obey, and behave correctly:
   
   * we need ONE transport to happen (go thru pipe fully) before we can pour 
the rest onto transport
   
   The HTTP transporter is equipped with "shared" caches for auth that is 
heavily used by HttpClient to make decisions (ie. about re-attempting request). 
Current code is quite complicated, but auth sharing happens when one transfer 
task is done, and that step "inseminates" the cache to be used by others (and 
skip the auth dance from that point onwards). Similar step happens by transfer 
by issuing OPTIONS to remote to discover does it deals with WebDAV server or 
not (is MKCOL dance needed or not). All these states are once task is done 
shared and remembered for the lifetime of session (per remote repository). 
Hence, to obey these rules, simple fix is applied: FIRST transfer is sent thru 
pipe alone fully, and once is done, the REST is pushed in parallel, as at that 
point, all the auth caches and DAV state of remote repositry are already 
discovered by first one. This simple "trick" should not introduce big 
performance loss for parallel vs sequential deploy.
   
   * we must ensure proper ordering, that was not ensured by origina 
implementation
   
   Clients when going for metadata are getting them as G -> A -> V (the longest 
chain in case of snapshot maven plugin). Hence, we must ensure we deploy the 
opposite order, and we start deploying next group ONLY when we are fully done 
with previous group. Not ensuring this would leave a window of opportunity of 
failed build, where for example A level md is present, but V level not yet.
   
   ---
   
   https://issues.apache.org/jira/browse/MRESOLVER-319


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