Community
Participate
Working Groups
Build Identifier: 3.6 When mirroring artifacts locally from/to a SimpleArtiRepo the private "downloadArtifact" method has a minimum run time of 0.1 seconds(on my host), even for very small artifacts with a few bytes to copy. Replacing the "getTransport().download()" call with "FileUtils.copyStream()" speeds that up tremendously, which is why I suggest changing downloadArtifact to do that for "scheme == file" downloads... The transport accepts a monitor so copyStream might need that too so that the UI can report proper progress on the copy stage... Reproducible: Always Steps to Reproduce: 1. Mirror artifacts from a file: URI 2. Check performance of copying each artifact 3. Notice that even very small artifacts seem to have a "copy overhead" of 100+ milli seconds
Could you please provide a patch?
Created attachment 191516 [details] Proposed change to get performance up Hi Pascal :) This is the proposed change, it's very small, a few lines really, but I also tried to create a copy method accepting a progress monitor, not so sure about that one though, reporting every 16k will be a lot of monitor notifications for a bigger file.. HTH, Helmut
Pascal, do you want to apply this, or push it out to 3.8?
I've released the patch. It makes quite a difference !!! Thx for this.
(In reply to comment #4) > I've released the patch. It makes quite a difference !!! Thx for this. Thanks for picking this up, I'm glad it helps! :) Helmut