Re: Support for IBM JVM?
Some fun (for some value of "fun") vaguely related history: A fix has gone into IBM Java 1.7 for a crash triggered by Leiningen. see: http://www-01.ibm.com/support/docview.wss?uid=swg1IV32629 (where "Clojure" is misspelled) and https://github.com/technomancy/leiningen/issues/954. - Bruce On Thu, Mar 19, 2015, at 07:08 PM, Alex Miller wrote: > You are welcome to file a jira ticket for this problem in the system and a > patch would be welcome if it seems like an issue in the tests (assuming > things that should not be assumed across JDKs). The percentage of users on > IBM JDK is very small so it is not the highest priority platform, but I > don't know of any reason that Clojure itself would have issues on it. > > Alex > > On Thursday, March 19, 2015 at 11:03:12 AM UTC-5, Thomas wrote: >> FYI: At IBM we are suppose to only the IBM JVM and not other version due >> to legal reason. >> >> Thomas > > -- > 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. -- 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.
Re: Confused by Clojure floating-point differences (compared to other languages)
Modern JVM's pick default heap sizes based on the physical memory in your machine. With more than 1GB of physical memory, initial heap is 1/64 and maximum heap is 1/4 of physical memory.[1] For OpenJDK and Oracle, this command: java -XX:+PrintFlagsFinal -version | grep HeapSize will show the initial and maximum heap sizes (along with a few other numbers). Also, you may not want to set the initial heap size as large as the maximum heap size. Oracle[2] says (in part): > Setting -Xms and -Xmx to the same value increases predictability by removing > the most important sizing decision from the virtual machine. However, the > virtual machine is then unable to compensate if you make a poor choice. - Bruce [1] http://stackoverflow.com/questions/2915276/what-is-the-default-maximum-heap-size-for-suns-jvm-from-java-se-6 [2] http://www.oracle.com/technetwork/java/javase/gc-tuning-6-140523.html#generation_sizing.total_heap On Wed, Feb 5, 2014, at 08:28 PM, Lee Spector wrote: > > On Feb 5, 2014, at 6:05 PM, Alex Miller wrote: > > > To override the default tiered compilation, add this to your project.clj: > > :jvm-opts ^:replace [] > > I was under the impression that one can get the same effect by running > your program with: > > lein trampoline with-profile production run [etc] > > True? I *think* the text here implies this too: > https://github.com/technomancy/leiningen/blob/master/doc/TUTORIAL.md > > FWIW my goal is to be able to run a project with one command, starting > with a project that contains only source code (with none of my code > pre-compiled), and have it do whatever it has to do to launch (I don't > much care how long the launch takes) and then run as fast as possible > (often for hours or days, CPU-bound). I launch my current runs with a > command line like the one above, and I do also specify :jvm-opts in > project.clj, specificially: > > :jvm-opts ["-Xmx12g" "-Xms12g" "-XX:+UseParallelGC"] > > Except that I have to tweak those 12s manually for different machines... > Is there any way to specify "just use whatever's available"? > > Since I'm supplying other :jvm-opts I was under the impression that I > couldn't do the ^:replace [] thing... So is "with-profile production" > going to have the same effect? > > BTW I would also love input on the GC option. I'm also not at all sure > that one is the best, but I generate lots of garbage across large numbers > of cores so it seemed like a good idea. But then I read something here > about the G1 GC... is that likely to be better? If so, does anyone know > the string to include in :jvm-opts to use it? > > Thanks (& sorry to include so many questions!), > > -Lee > > -- > 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/groups/opt_out. -- 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/groups/opt_out.
Re: [ANN] overload-middleware 0.1.1
Even for a web site used exclusively by people, "fail fast" when overloaded can be good. You would rather give an error (one hopes a "gee, so sorry, we having some trouble right now" page) to some users rather than be extremely slow for many users. What do I do when I get a slow web page? I hit reload (and I am not alone). This further overloads the system and doesn't even cancel the earlier requests (from the servers point of view). A "fail fast" response didn't cost the server very much. With luck, the load will be lower a few seconds later when the user hits reload. On Sun, Nov 17, 2013, at 12:25 AM, Cedric Greevey wrote: On Sat, Nov 16, 2013 at 9:35 PM, James Reeves <[1]ja...@booleanknot.com> wrote: On 17 November 2013 01:52, Cedric Greevey <[2]cgree...@gmail.com> wrote: The distribution will be narrow and peak at around 1 second, though, which may not be what you want. Of course, the OP has since indicated that he meant non-web uses of HTTP rather than serving web sites... Web services are generally considered to be part of the web, hence the term "web service" :) Well, which is it? Either it's the web, and the user will probably promptly hit reload if faced with a 503 error at what should be a working URL, or else it's not the web, and lies outside the scope of my original remark. References 1. mailto:ja...@booleanknot.com 2. mailto:cgree...@gmail.com -- -- 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/groups/opt_out.
Re: StackOverflowError
In this line: (if TRACE (do (println [:OFACTS (count ofacts)]) (clojure.stacktrace/e))) the StackOverflowError must be occurring in the evaluation of ofacts. The error breaks out of the evaluation, preventing (clojure.stacktrace/e) from being evaluated. The error sends you back to the Clojure repl prompt, as you showed: StackOverflowError clojure.lang.RT.nth (RT.java:764) rete.core=> Here, at the "rete.core=>" prompt after the error, is where you want to call (clojure.stacktrace/e). - Bruce On Fri, Nov 8, 2013, at 06:10 AM, Jim wrote: > On 08/11/13 10:46, ru wrote: > > > > I am afraid, that I am not sure where to put (clojure.stacktrace/e) to > > make it work :( > > Or, may be this is not an exception? > > use (clojure.stacktrace/e) after the exception has been thrown to get > some more information than just a line. Don't put it in your code, but > rather call it on the repl right after the error. It will probably point > you to some more places to have a look. Also, as John suggested, if > you've got a lot of lazy operations that might be the cause. Have you > looked at reducers? > > Jim -- -- 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/groups/opt_out.
Re: Error - Clojure
Your project.clj file contains (defn -main ([] (-main )) ([port] (run-jetty app {:port (Integer. port)}))) near the end of the defproject form. That's not right. I'm not quite sure what question to ask here. The (defn -main ...) belongs in a source file, not in the project.clj. Can you try setting up a new project, with "lein new storm-starter"? Then you can put your project.clj in there, well, after removing the (defn ...) part from project.clj. It looks like you are starting with something from Storm. Can you double check the documentation for what ever you started with? On Mon, Oct 21, 2013, at 06:57 PM, ingy abbas wrote: Exception in thread "main" java.lang.IllegalArgumentException: No value supplied for key: 1.7.1 (project.clj:1) at clojure.lang.Compiler.eval(Compiler.java:5441) at clojure.lang.Compiler.load(Compiler.java:5858) at clojure.lang.Compiler.loadFile(Compiler.java:5821) at clojure.lang.RT$3.invoke(RT.java:296) at leiningen.core$read_project$fn__2128.invoke(core.clj:127) at leiningen.core$read_project.invoke(core.clj:126) at leiningen.core$read_project.invoke(core.clj:130) at leiningen.core$_main.doInvoke(core.clj:320) at clojure.lang.RestFn.invoke(RestFn.java:410) at clojure.lang.AFn.applyToHelper(AFn.java:161) at clojure.lang.RestFn.applyTo(RestFn.java:132) at clojure.core$apply.invoke(core.clj:542) at leiningen.core$_main.invoke(core.clj:332) at user$eval42.invoke(NO_SOURCE_FILE:1) at clojure.lang.Compiler.eval(Compiler.java:5425) at clojure.lang.Compiler.eval(Compiler.java:5392) at clojure.core$eval.invoke(core.clj:2382) at clojure.main$eval_opt.invoke(main.clj:235) at clojure.main$initialize.invoke(main.clj:254) at clojure.main$script_opt.invoke(main.clj:270) at clojure.main$main.doInvoke(main.clj:354) at clojure.lang.RestFn.invoke(RestFn.java:457) at clojure.lang.Var.invoke(Var.java:377) at clojure.lang.AFn.applyToHelper(AFn.java:172) at clojure.lang.Var.applyTo(Var.java:482) at clojure.main.main(main.java:37) Caused by: java.lang.IllegalArgumentException: No value supplied for key: 1.7.1 at clojure.lang.PersistentHashMap.createWithCheck(PersistentHashMap.java:8 9) at clojure.core$hash_map.doInvoke(core.clj:327) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:540) at leiningen.core$eval44.invoke(project.clj:1) at clojure.lang.Compiler.eval(Compiler.java:5425) ... 25 more Above is Error i get while running " lein run " please i need help -- -- 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 [1]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 [2]https://groups.google.com/groups/opt_out. Email had 1 attachment: * project.clj * 1k (application/octet-stream) References 1. http://groups.google.com/group/clojure?hl=en 2. https://groups.google.com/groups/opt_out -- -- 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/groups/opt_out.
Re: Trying to use Heroku and Postgresql
(System/getenv "DATABASE_URL") is returning nil. This will happen when the system environment variable DATABASE_URL is not defined. - Bruce On Sat, Oct 5, 2013, at 04:54 PM, Zeynel wrote: I am going through this Heroku tutorial [1]https://devcenter.heroku.com/articles/clojure-web-applicati on. I am getting the following error when I try to create a table in the local Postgresql database user=>(sql/with-connection (System/getenv "DATABASE_URL") (sql/create-table :testing [:data :text])) IllegalArgumentException db-spec null is missing a required parameter clojure.java.jdbc/get-connection (jdbc.clj:192) What am I doing wrong? I also have a question at SO for a related issue: [2]http://stackoverflow.com/questions/19201133/postgresql-log-au tovacuum-launcher-started-is-hung-apparently -- -- 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 [3]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 [4]https://groups.google.com/groups/opt_out. References 1. https://devcenter.heroku.com/articles/clojure-web-application 2. http://stackoverflow.com/questions/19201133/postgresql-log-autovacuum-launcher-started-is-hung-apparently 3. http://groups.google.com/group/clojure?hl=en 4. https://groups.google.com/groups/opt_out -- -- 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/groups/opt_out.