示例#1
0
    def prepare(self):

        job = JobSubmissionObjectImpl()
        job.setTimestampJobname("gt4_5_bench")
        job.setCommandline("echo hello")
        job.setApplication(Constants.GENERIC_APPLICATION_NAME)
        job.setSubmissionLocation(self.subLoc)
        fqan = GrisuRegistryManager.getDefault(self.si).getUserEnvironmentManager().getCurrentFqan()
        self.jobname = self.si.createJob(job.getJobDescriptionDocumentAsString(), fqan, Constants.FORCE_NAME_METHOD)
示例#2
0
'''
Created on 11/12/2009

@author: markus
'''
from org.vpac.grisu.frontend.control.login import LoginManager
from org.vpac.grisu.model import GrisuRegistryManager
import sys


si = LoginManager.login()

resource = GrisuRegistryManager.getDefault(si)

subLocs = resource.getResourceInformation().getAllSubmissionLocations()

for subLoc in subLocs:
    print subLoc
    
# don't forget to exit properly. this cleans up possible existing threads/executors
sys.exit()
示例#3
0
'''
Created on 11/12/2009

@author: markus
'''

from org.vpac.grisu.frontend.control.login import LoginManager
from org.vpac.grisu.model import GrisuRegistryManager
import sys


si = LoginManager.loginCommandline()

registry = GrisuRegistryManager.getDefault(si)

for app in sys.argv:
    
    info = registry.getApplicationInformation(app)
    print 'Application: '+app
    
    info = registry.getApplicationInformation(app)
    
    for subLoc in info.getAvailableAllSubmissionLocations():
        
        print("\tSubmissionLocation: "+subLoc)
        print("\tVersions: ")
        for version in info.getAvailableVersions(subLoc):
            
            print "\t\t" + version
            print "\t\t\tDetails:"
            
示例#4
0
from org.vpac.grisu.frontend.control.login import LoginManager
from org.vpac.grisu.frontend.model.job import JobObject
from org.vpac.grisu.model import GrisuRegistryManager

si = LoginManager.loginCommandline("LOCAL")

appInfo = GrisuRegistryManager.getDefault(si).getApplicationInformation("ImageJ")

print 'app: '+appInfo.getApplicationName()

for subloc in appInfo.getAvailableAllSubmissionLocations():
    print subloc

job = JobObject(si);
job.setTimestampJobname("imageJ");
job.setApplication("java");
job.setApplication("ImageJ");
job.setCommandline("echo Hello");

job.setSubmissionLocation("normal:ng2.ivec.org");

job.createJob("/ARCS/StartUp");
job.submitJob();

job.waitForJobToFinish(3);

print "Stdout: "+job.getStdOutContent()
print "Stderr: "+job.getStdErrContent()