On Tue, Mar 17, 2015 at 9:07 AM, Keith B. firstname.lastname@example.org
Is speed not important in your case?
It’s not important. These are batch jobs that run nightly. This master
script runs a few sub scripts, each of which do a few calculations and
queue up many (more efficient and well-structured) jobs in my background
job system (sidekiq). Eventually I’d like to make the work in the sub
scripts be done in workers as well, but for the time being I’d like to
keep things as-is and bring all the invocations into one place, and then
If I were you, I’d look at minimum to shelling out once rather than a
times. Why do you want to shell out so many times?
As described above, I have many sub scripts which work and I don’t want
refactor them in this first phase.
Also, your script looks like it shells out only once, no?
That’s an example of the code that I’ll be doing about a dozen times in
On Tue, Mar 17, 2015 at 9:10 AM, Ted H. email@example.com wrote:
There’s a section about this in the jruby wiki:
“we will attempt to run it in the same JVM using a new JRuby instance”
Great news, thanks! FYI if others are interested, this feature can be
at the commandline:
JRUBY_OPTS="-J-Djruby.launch.inproc=true" rails runner
Or within your ruby code:
JRuby.runtime.instance_config.run_ruby_in_process = true