2017-02-26 21:06 GMT+01:00 Thomas Heller <[email protected]>:

> Ideally you would run your program without lein, probably as an uberjar.
>

​I have to dive into that. A good excuse to start with Clojure again. ;-)
​



> But if you insist on lein you can do "lein trampoline run -m your.main/fn"
> which will allow the lein process to exit after setting up your program
> leaving you with only one JVM.
>

​I do not insist on it, but that is what I know right now. I have to find
out how to do this also, because it did not work at the moment.

​

> To control the memory you can add :jvm-opts ["-Xmx512m"] to your
> project.clj. It will set the max memory of the JVM to 512mb which should be
> enough for your program.
>

​Did not work either, but at the moment I use:
    export JVM_OPTS=-Xmx512m

For the moment that does the trick.


Need to free some time to dive in these things.

​


> On Saturday, February 25, 2017 at 11:41:03 AM UTC+1, Cecil Westerhof wrote:
>
>> 2017-02-24 15:07 GMT+01:00 Timothy Baldridge <[email protected]>:
>>
>>> What are the JVM memory settings set at? And how much physical memory
>>> does the box have?
>>>
>>
>> ​My system has 16 GB of memory.
>>
>> I use ‘lein  run’ and this results in the following process:
>>     java-Xbootclasspath/a:/home/cecil/.lein/self-installs/leinin
>> gen-2.6.1-standalone.jar-Dfile.encoding=UTF-8-Dmaven.
>> wagon.http.ssl.easy=false-Dmaven.wagon.rto=10000-XX:+
>> TieredCompilation-XX:TieredStopAtLevel=1-Dleiningen.
>> original.pwd=/home/cecil/Clojure/Quotes-Dleiningen.
>> script=/home/cecil/bin/lein-classpath.:/home/cecil/scala:/
>> var/lib/h2/jars/h2-current.jar:/home/cecil/Java/jars/
>> sqlite-jdbc.jar:/home/cecil/Java/jars/javax.mail.jar:/
>> home/cecil/Java/qtjambi-linux64-4.7.4-beta-4/qtjambi-
>> 4.7.4-beta-4.jar:/home/cecil/Java/qtjambi-linux64-4.7.4-
>> beta-4/qtjambi-examples-4.7.4-beta-4.jar:/home/cecil/Java/
>> qtjambi-linux64-4.7.4-beta-4/qtjambi-native-linux64-gcc-4.
>> 7.4-beta-4:/home/cecil/Java/ghost4j/ghost4j-0.5.0.jar:/
>> home/cecil/.lein/self-installs/leiningen-2.6.1-
>> standalone.jarclojure.main-mleiningen.core.mainrun
>>
>> The program itself is:
>>     java-classpath/home/cecil/Clojure/Quotes/test:/home/cecil/
>> Clojure/Quotes/src:/home/cecil/Clojure/Quotes/dev-resou
>> rces:/home/cecil/Clojure/Quotes/resources:/home/cecil/Clojur
>> e/Quotes/target/classes:/home/cecil/.m2/repository/org/
>> clojure/clojure/1.8.0/clojure-1.8.0.jar:/home/cecil/.m2/
>> repository/com/miglayout/miglayout/3.7.4/miglayout-3.7.4.
>> jar:/home/cecil/.m2/repository/org/clojure/tools.nrepl/0.2.
>> 12/tools.nrepl-0.2.12.jar:/home/cecil/.m2/repository/
>> clojure-complete/clojure-complete/0.2.4/clojure-complete-0.2.4.jar:/home/
>> cecil/.m2/repository/org/clojure/java.jdbc/0.5.8/java.jdbc-
>> 0.5.8.jar:/home/cecil/.m2/repository/org/clojure/math.
>> numeric-tower/0.0.4/math.numeric-tower-0.0.4.jar:/home/cecil
>> /.m2/repository/com/fifesoft/rsyntaxtextarea/2.5.6/
>> rsyntaxtextarea-2.5.6.jar:/home/cecil/.m2/repository/org/swi
>> nglabs/swingx/swingx-autocomplete/1.6.3/swingx-autocomplete-
>> 1.6.3.jar:/home/cecil/.m2/repository/j18n/j18n/1.0.2/
>> j18n-1.0.2.jar:/home/cecil/.m2/repository/clj-time/clj-
>> time/0.12.0/clj-time-0.12.0.jar:/home/cecil/.m2/repository
>> /org/swinglabs/swingx/swingx-plaf/1.6.3/swingx-plaf-1.6.3.
>> jar:/home/cecil/.m2/repository/org/swinglabs/
>> swingx/swingx-painters/1.6.3/swingx-painters-1.6.3.jar:/
>> home/cecil/.m2/repository/com/jgoodies/forms/1.2.1/forms-1.2
>> .1.jar:/home/cecil/.m2/repository/joda-time/joda-time/2.9.3/
>> joda-time-2.9.3.jar:/home/cecil/.m2/repository/com/
>> h2database/h2/1.3.176/h2-1.3.176.jar:/home/cecil/.m2/
>> repository/seesaw/seesaw/1.4.5/seesaw-1.4.5.jar:/home/
>> cecil/.m2/repository/org/swinglabs/swingx/swingx-common
>> /1.6.3/swingx-common-1.6.3.jar:/home/cecil/.m2/repository
>> /org/swinglabs/swingx/swingx-core/1.6.3/swingx-core-1.6.3.
>> jar:/home/cecil/.m2/repository/instaparse/instaparse/1.4.2/instaparse-1.
>> 4.2.jar:/home/cecil/.m2/repository/org/swinglabs/
>> swingx/swingx-action/1.6.3/swingx-action-1.6.3.jar:/home/
>> cecil/.m2/repository/yesql/yesql/0.5.3/yesql-0.5.3.jar-
>> Dfile.encoding=UTF-8-Xmx4096M-Dclojure.compile.path=/home/ce
>> cil/Clojure/Quotes/target/classes-Dquotes.version=0.0.1-Dclo
>> jure.debug=falseclojure.main-i/tmp/form-init417092364626579473.clj
>>
>> ​So maximum memory is set to 4 GB. That could probably be a lot less.​
>> Where can I change that?
>> And can I set the maximum memory for lein?
>>
>

-- 
Cecil Westerhof

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to