Re: [R] rJava garbage collect

2018-02-06 Thread Benjamin Tyner
Hi Martin, Thanks for providing the reference. In this particular case, it helped me to discover that 13 JVM threads were garbage collecting in parallel, occasionally resulting in a race condition. Setting     options(java.parameters = "-XS:ParallelGCThreads=1") appears to resolve the issue

Re: [R] rJava garbage collect

2018-02-06 Thread Benjamin Tyner
Thanks Jeff; indeed it works:    .jcall("java/lang/System", method = "gc") On 02/05/2018 11:53 PM, Jeff Newmiller wrote: rJava offers a mechanism to call arbitrary methods in Java. Wouldn't you use that mechanism to call whatever you would call if you were programming in Java (e.g. System.gc

Re: [R] rJava garbage collect

2018-02-06 Thread Martin Møller Skarbiniks Pedersen
On 6 February 2018 at 04:34, Benjamin Tyner wrote: > Hi > > Does rJava offer a way to instruct the JVM to perform a garbage collection? Do you really, really need to run the garbage collector? Consider reading: https://stackoverflow.com/questions/5086800/java-garbage-collection Regards Martin

Re: [R] rJava garbage collect

2018-02-05 Thread Jeff Newmiller
rJava offers a mechanism to call arbitrary methods in Java. Wouldn't you use that mechanism to call whatever you would call if you were programming in Java (e.g. System.gc)? -- Sent from my phone. Please excuse my brevity. On February 5, 2018 7:34:17 PM PST, Benjamin Tyner wrote: >Hi > >Does

[R] rJava garbage collect

2018-02-05 Thread Benjamin Tyner
Hi Does rJava offer a way to instruct the JVM to perform a garbage collection? Regards Ben __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R