The next step is going through the User Guide. Although this was written for 4.2, there's nothing I found which didn't basically work in 4.3.1.
It's quite easy to setup and run simple jobs:
In :j=Job(application=Executable(exe='/bin/echo',args=['Hello, World']))
Ganga.GPIDev.Lib.Job : INFO submitting job 0
Ganga.GPIDev.Adapters : INFO submitting job 0 to Local backend
Ganga.GPIDev.Lib.Job : INFO job 0 status changed to "submitted"
Ganga.GPIDev.Lib.Job : INFO job 0 status changed to "running"
Ganga.GPIDev.Lib.Job : INFO job 0 status changed to "completed"
In :print outfile.read()
However, that's spawning a job which just runs on the local machine - how easy was it to run on the grid?
Answer: very easy!
In :l1.application=Executable(exe='/bin/echo',args=['Hello, World'])
Ganga.GPIDev.Lib.Job : INFO submitting job 3
Ganga.GPIDev.Adapters : INFO submitting job 3 to LCG backend
Ganga.GPIDev.Lib.Job : INFO job 3 status changed to "submitted"
Out: LCG (
status = 'Ready' ,
reason = 'unavailable' ,
iocache = '' ,
CE = None ,
middleware = 'EDG' ,
actualCE = 'ce.ulakbim.gov.tr:2119/jobmanager-lcgpbs-dteam' ,
id = 'https://svr023.gla.scotgrid.ac.uk:9000/-wOjj5xKfjcrKIXiCEISNA' ,
jobtype = 'Normal' ,
exitcode = None ,
requirements = LCGRequirements (
other =  ,
nodenumber = 1 ,
memory = None ,
software =  ,
ipconnectivity = 0 ,
cputime = None ,
walltime = None
Ganga.GPIDev.Lib.Job : INFO job 3 status changed to "completing"
Ganga.GPIDev.Lib.Job : INFO job 3 status changed to "completed"
In :print file(l1.outputdir+'stdout').read()
Wonderful! Didn't have to do any of that nasty edg-job-* stuff. And it ran in Turkey - pretty cool.
I have also now discovered how to define and submit batches of jobs to the grid. This snippet defines a set of 10 jobs:
for i in range(10):
Submitted that and I'm running jobs in China, Italy, Greece, Pakistan, Russia, Austria, France, Spain and Switzerland.
I think this is the first time in a while I've thought "Hey! The grid is actually cool."