@alexmiller The uberjar task is taking a long time, so I had a time to profile it and found that the JarOutputStream is created without buffer. Decorating with BufferedOutputStream can make it significantly faster (in our case 38s -> 15s), so unless you're intentionally not using it, do you want me to send a patch for it?
Uberjar task: https://github.com/clojure/tools.build/blob/973eaf53ddd44bca2194f6ea3cf266b39be08d6a/src/main/clojure/clojure/tools/build/tasks/uber.clj#L300 Jar task: https://github.com/clojure/tools.build/blob/973eaf53ddd44bca2194f6ea3cf266b39be08d6a/src/main/clojure/clojure/tools/build/tasks/jar.clj#L34
sure!
looks like you already have a CA and jira access I filed a jira at that you can attach a patch to: https://clojure.atlassian.net/browse/TBUILD-42 (see https://clojure.org/dev/developing_patches if needed)
actually I'll get it, I found at least one other place missing it and I want to consolidate the buffer sizing
tools.build v0.10.4 31388ff is now available, thanks for the report!
Oh, great!
We’ve been running into this too
will report the speed difference here
How’d it go?
FYI: Our uberjar task execution time goes down from 1:51 to 1:25. Once compile-clj support skipping copy-contents by https://clojure.atlassian.net/jira/software/c/projects/TBUILD/issues/TBUILD-31?jql=project%20%3D%20%22TBUILD%22%20AND%20status%20%3D%20Open%20ORDER%20BY%20created%20DESC, another 5-10s can be saved.
This is a very wild guess, but is it possible to parallelize jar explode? It wouldn't be easy because of conflict resolution, but we're already ignoring all meaningful conflicts.
we only saw marginal improvement, maybe 10-20s
that ticket would be relevant to our build as well