Never mind, I found the problem.  During testing I had enabled Plumatic
Schema function validation:


    (s/set-fn-validation! true) ; enforce fn schemas
Disabling validation made `lein test` and `lein run` produce comparable
times.
Alan




On Sat, Dec 15, 2018 at 10:41 AM Alan Thompson <clooj...@gmail.com> wrote:

> Hi,
>
> I'm seeing something I never expected with Leiningen, namely that `lein
> test` can take 28x longer to run a task than if it is invoked via `lein
> run`.  Elapsed time measurements (sec):
>
> *   function                                               test
>   run           ratio*
> :add-tree-xml                 0.314    0.188      *1.7x*
> :remove-whitespace-leaves     5.104    0.183     *28x*
> :hid->bush                    0.429    0.009     *48x*
>
> From the table, you can see that the speed ratio varies quite a bit
> depending on the task.  Since the slowest task is 28x, I'm using that as a
> reference point. I have my `:jvm-opts` in project.clj set as follows:
>
>     :jvm-opts ["-Xms500m" "-Xmx2g" "-server"]
>
> It seems to make no difference if I use -Xmx value of 2g or 8g.  Using a
> flat of "-server", "-client" or nothing also makes no significant
> difference.
>
> I have found no information in the lein docs that might explain such huge
> variations.  Any ideas?
>
> Alan
>
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to