
Hi Graeme, I should think before I write: the code I sent is useless, as the delayed _run_ poses the problem (there is no submit_job as I used). Also, the run() must not take a parameter, as it comes from task. So, the association between job and job_service _has_ to happen on creation time. Anyway, as you rightly point out: a job_id won't be available before run got called: // we need job description saga::job_description js; // fill it... // create a job service, bound to a resource manager saga::job_service js ("RM"); // create a job instance which is not yet running. No // job id available (set to "Unknown" or so) saga::job j = js.create (jdes); // run the job, get a job_id from RM, put into // job list for the associated js j.run (); Sorry, Andre. Quoting [Andre Merzky] (Mar 06 2006):
As I stated earlier, I have not much experience with RM. However, pondering about your comments, the following seems possible as well:
1) // we need job description saga::job_description js; // fill it...
// keep job and job_service independend saga::job j (jdes); saga::job_service js ("RM");
// associate job and js js.submit_job (j);
2) // we need job description saga::job_description js; // fill it...
// keep job and job_service independend saga::job j (jdes); saga::job_service js;
// associate job and js, and RM js.submit_job (j, "RM");
Both versions would imply that a job_id is only available after submit. The js.run_job method would be unaffected (there seems no issue with that).
-- "So much time, so little to do..." -- Garfield