by ledgerdev · 8y ago · 0 comments
But seriously completely agree with you about the jvm being awesome. However clojure var load times on top of the base jvm and memory use makes it dog slow to start a development repl(30+ seconds is normal.. queue comment about how someone only restarts their repl every couple of days LOL) and unsuitable or unusable for situations where you care about app start times of less than 10 seconds and memory constrained environments such as cli, iot, serverless, android.
$ time clj -e '(System/exit 0)'
clj -e '(System/exit 0)' 1.60s user 0.07s system 198% cpu 0.839 total
It takes about 2 seconds to start for me.In this case I suspect cursive is fast because:
* You have a JVM loaded in the form of IntelliJ * You only need to start Clojure inside that JVM (which is reduced from the time clj takes!)
So 1 second is a reasonable time from IntelliJ=>Clojure. 2 seconds is reasonable for Nothing=>Clojure.
So the actual time was 0.839s.
Which means Clojure 1.9 on your computer boots and shutdowns its repl in under a second.
The (Clojure) "JVM Slow Startup Time" Myth