Author: justi9
Date: 2009-09-14 16:00:20 -0400 (Mon, 14 Sep 2009)
New Revision: 3628
Modified:
mgmt/trunk/cumin/python/cumin/grid/model.py
Log:
Make the submission task work from the tests
Modified: mgmt/trunk/cumin/python/cumin/grid/model.py
===================================================================
--- mgmt/trunk/cumin/python/cumin/grid/model.py 2009-09-14 19:56:20 UTC (rev 3627)
+++ mgmt/trunk/cumin/python/cumin/grid/model.py 2009-09-14 20:00:20 UTC (rev 3628)
@@ -45,18 +45,22 @@
self.form.pool.set(session, pool)
+ def do_invoke(self, completion, session, scheduler,
+ description, command, args):
+ if hasattr(session, "user_session"):
+ user = session.user_session.subject.name
+ else:
+ user = "nobody"
- def do_invoke(self, completion, session, scheduler, command, args):
- user = session.user_session.subject.name
-
- ad = {"Cmd": {"TYPE": self.STRING_TYPE,
"VALUE": command},
+ ad = {"Submission": {"TYPE": self.STRING_TYPE,
"VALUE": description},
+ "Cmd": {"TYPE": self.STRING_TYPE,
"VALUE": command},
"Args": {"TYPE": self.STRING_TYPE,
"VALUE": args},
"Requirements": {"TYPE": self.EXPR_TYPE,
"VALUE": "TRUE"},
"JobUniverse": {"TYPE": self.INTEGER_TYPE,
"VALUE": "%s" %
(self.UNIVERSE["VANILLA"],)},
"Iwd": {"TYPE": self.STRING_TYPE,
"VALUE": "/tmp"},
"User": {"TYPE": self.STRING_TYPE,
- "VALUE": "%s(a)example.com" % user}}
+ "VALUE": "%s@%s" % (user,
scheduler.Machine)}}
scheduler.Submit(self.app.model.mint.model, completion, ad, None)
Show replies by date