Author: eallen
Date: 2010-05-21 13:07:08 -0400 (Fri, 21 May 2010)
New Revision: 3983
Modified:
mgmt/newdata/cumin/model/Makefile
mgmt/newdata/cumin/model/condor.xml
mgmt/newdata/cumin/model/qpid.xml
mgmt/newdata/cumin/python/cumin/grid/collector.py
mgmt/newdata/cumin/python/cumin/grid/main.py
mgmt/newdata/cumin/python/cumin/grid/negotiator.py
mgmt/newdata/cumin/python/cumin/grid/pool.py
mgmt/newdata/cumin/python/cumin/grid/scheduler.py
mgmt/newdata/cumin/python/cumin/grid/slot.py
mgmt/newdata/cumin/python/cumin/grid/submission.py
mgmt/newdata/cumin/python/cumin/grid/submitter.py
mgmt/newdata/cumin/python/cumin/main.py
mgmt/newdata/cumin/python/cumin/model.py
mgmt/newdata/cumin/python/cumin/parameters.py
Log:
Changes to support going from mrg.grid to com.redhat.grid
Modified: mgmt/newdata/cumin/model/Makefile
===================================================================
--- mgmt/newdata/cumin/model/Makefile 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/model/Makefile 2010-05-21 17:07:08 UTC (rev 3983)
@@ -20,7 +20,7 @@
svn export
http://svn.apache.org/repos/asf/qpid/trunk/qpid/cpp/src/qpid/cluster/mana...
qpid-cluster.xml
condor.xml:
- wget
"http://git.fedorahosted.org/git/grid.git?p=grid.git;a=blob_plain;f=src/management/condor-management-schema.xml;hb=V7_4-QMF-branch"
-O condor.xml
+ wget
"http://git.fedorahosted.org/git/?p=grid.git;a=blob_plain;f=src/management/condor-management-schema.xml;hb=V7_4-QMF-branch"
-O condor.xml
sesame.xml:
svn export
http://anonsvn.jboss.org/repos/rhmessaging/mgmt/trunk/sesame/cpp/src/qmfg...
sesame.xml
Modified: mgmt/newdata/cumin/model/condor.xml
===================================================================
--- mgmt/newdata/cumin/model/condor.xml 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/model/condor.xml 2010-05-21 17:07:08 UTC (rev 3983)
@@ -1,4 +1,4 @@
-<schema package="mrg.grid">
+<schema package="com.redhat.grid">
<!--
/*
@@ -18,7 +18,7 @@
*/
-->
-<group name="daemon-stats">
+<group name="DaemonProperties">
<property name="CondorPlatform"
type="sstr"
desc="The Condor platform string for the daemon's platform"/>
@@ -29,7 +29,9 @@
type="absTime" unit="nanosecond"
desc="Number of nanoseconds since epoch when the daemon
was started"/>
+</group>
+<group name="DaemonStatistics">
<statistic name="MonitorSelfAge" type="uint32"/>
<statistic name="MonitorSelfCPUUsage" type="double"/>
<statistic name="MonitorSelfImageSize" type="double"/>
@@ -38,6 +40,15 @@
<statistic name="MonitorSelfTime" type="absTime"/>
</group>
+<group name="GridMethods">
+ <!-- quick test method across agents/objects -->
+ <method name="echo">
+ <arg name="sequence" dir="IO" type="uint32"/>
+ <arg name="body" dir="IO" type="lstr"/>
+ </method>
+
+</group>
+
<!--
CpuBusy = ((LoadAvg - CondorLoadAvg) >= 0.500000)
CpuBusyTime = 0
@@ -73,7 +84,9 @@
<class name="Slot">
- <group name="daemon-stats"/>
+ <group name="DaemonProperties"/>
+ <group name="DaemonStatistics"/>
+ <group name="GridMethods"/>
<property name="Pool" type="sstr" index="y"/>
<property name="System" type="sstr" index="y"/>
@@ -210,14 +223,7 @@
desc="The number of nanoseconds since epoch when the
job last performed a periodic checkpoint, only
present when a job is executing"
- optional="y"/>
-<!--
- <statistic name="LastHeardFrom"
- type="absTime" unit="nanosecond"
- desc="Time when the Collector received an update from
- the slot, nanoseconds since epoch, inserted by
- Collector"/>
--->
+ optional="y"/>
<statistic name="LoadAvg"
type="double"
desc="Load average of CPUs hosting the slot"/>
@@ -245,11 +251,6 @@
type="absTime" unit="nanosecond"
desc="The number of nanoseconds since epoch that the
slot produced an updated ad"/>
-<!--
- <property name="MyType"
- type="sstr"
- desc="Always 'Machine'"\>
--->
<property name="Name"
type="sstr"
index="y"
@@ -337,11 +338,6 @@
claimed and job likely running (see Activity);
Preempting, running job is being kicked off the
slot"/>
-<!--
- <statistic name="TargetType"
- type="sstr"
- desc="Always 'Job'"/>
--->
<property name="TimeToLive"
type="uint32" unit="second"
desc="Number of second until StartD managing the slot
@@ -486,126 +482,12 @@
representing a minor version numer for a Windows
operating system, only present on Windows
slots, e.g. 2 for OpSys=WINNT52"/>
-
-<!--
- <property name="AdditionalAttributes" type="map"/>
--->
</class>
-<!--
-Exec Host, Order(Rank?), StartTime, TotalTime (Sys, User), Project, AccountingGroup
--->
-<!--
- <class name="Job">
- <property name="schedulerRef" type="objId"
parentRef="y" index="y"
references="mrg.grid:Scheduler"/>
- <property name="submitterRef" type="objId"
references="mrg.grid.Submitter"/>
-
- <property name="AccountingGroup" type="sstr"
optional="y" desc=""/>
- <property name="Args" type="lstr" optional="y"
desc=""/>
- <property name="ClusterId"
- type="uint32" index="y"
- desc="The id of the cluster the job belongs
- to. ClusterIds are unique within a SchedD."/>
- <property name="Cmd" type="lstr" desc=""/>
- <property name="ConcurrencyLimits" type="lstr"
optional="y" desc=""/>
- <property name="CustomGroup" type="sstr"
optional="y" desc=""/>
- <property name="CustomId" type="sstr" optional="y"
desc=""/>
- <property name="CustomPriority" type="uint32"
optional="y" desc=""/>
- <property name="GlobalJobId" type="sstr"
desc=""/>
- <property name="In"
- type="lstr"
- desc="The file where the job's standard input is read
- from."/>
- <property name="Iwd" type="lstr" desc=""/>
- <property name="JobStatus"
- type="uint32"
- desc="One of: 0, unexpanded; 1, idle; 2, running; 3,
- removed; 4, completed; 5, held; or, 6, submission
- error"/>
- <property name="Note"
- type="lstr" optional="y"
- desc="An arbitrary note attached to the job."/>
- <property name="Out"
- type="lstr"
- desc="The file where the job's standard output is
- written."/>
- <property name="Owner"
- type="sstr"
- desc="The submitter of the job."/>
- <property name="User"
- type="sstr"
- desc="The Owner '@' the configured UidDomain namespace"/>
- <property name="ProcId"
- type="uint32" index="y"
- desc="The id of the job within its cluster. ProcIds re
- unique within a cluster."/>
- <property name="QDate"
- type="absTime" unit="nanoseconds"
- desc="The number of nanoseconds since epoch when the
- job was submitted."/>
-
-
-// <property name="Requirements" type="lstr"
desc=""/>
-// <property name="Scheduler" type="sstr"
desc=""/>
-
-
- <property name="JobUniverse"
- type="uint32"
- desc=""/>
-
- <property name="Title" type="sstr" optional="y"
desc=""/>
- <property name="UserLog" type="lstr" optional="y"
desc=""/>
-
- <property name="HoldReason" type="lstr" optional="y"
desc=""/>
-
- <property name="DAGNodeName"
- type="sstr" optional="y" desc=""/>
- <property name="DAGParentNodeNames"
- type="lstr" optional="y"
- desc="Comma separated list of the job's parent's node
- names"/>
- <property name="DAGManJobId"
- type="uint32" optional="y"
- desc="The ClusterId of the DAGMan job who spawned the
- job"/>
-
- <property name="Ad" type="map" optional="y"
desc=""/>
-
- <method name="GetAd">
- <arg name="JobAd" dir="O" type="map"
- desc="(name,value,type) tuples; Values are INTEGER, FLOAT,
- STRING and EXPR. The EXPR value is not first class,
- it is an unquoted, with double quotes, string"/>
- </method>
-
- <method name="SetAttribute">
- <arg name="Name" dir="I" type="sstr"/>
- <arg name="Value" dir="I" type="lstr"/>
- </method>
-
- <method name="Hold">
- <arg name="Reason" dir="I" type="sstr"/>
- </method>
-
- <method name="Release">
- <arg name="Reason" dir="I" type="sstr"/>
- </method>
-
- <method name="Remove">
- <arg name="Reason" dir="I" type="sstr"/>
- </method>
-
- <method name="Fetch">
- <arg name="File" dir="I" type="sstr"/>
- <arg name="Start" dir="I" type="int32"/>
- <arg name="End" dir="I" type="int32"/>
- <arg name="Data" dir="O" type="lstr"/>
- </method>
- </class>
--->
-
<class name="Scheduler">
- <group name="daemon-stats"/>
+ <group name="DaemonProperties"/>
+ <group name="DaemonStatistics"/>
+ <group name="GridMethods"/>
<property name="Pool" type="sstr" index="y"/>
<property name="System" type="sstr" index="y"/>
@@ -622,73 +504,43 @@
<statistic name="TotalRemovedJobs" type="uint32"/>
<statistic name="TotalRunningJobs" type="uint32"/>
- <method name="Submit">
+ <method name="SubmitJob">
<arg name="Ad" dir="I" type="map"/>
<arg name="Id" dir="O" type="sstr"/>
</method>
- <method name="GetAd">
+ <method name="SetJobAttribute">
<arg name="Id" dir="I" type="sstr"
desc="Job's Id, the string ClusterId.ProcId"/>
- <arg name="JobAd" dir="O" type="map"
- desc="(name,value,type) tuples; Values are INTEGER, FLOAT,
- STRING and EXPR. The EXPR value is not first class,
- it is an unquoted, with double quotes, string"/>
- </method>
-
- <method name="SetAttribute">
- <arg name="Id" dir="I" type="sstr"
- desc="Job's Id, the string ClusterId.ProcId"/>
<arg name="Name" dir="I" type="sstr"/>
<arg name="Value" dir="I" type="lstr"/>
</method>
- <method name="Hold">
+ <method name="HoldJob">
<arg name="Id" dir="I" type="sstr"
desc="Job's Id, the string ClusterId.ProcId"/>
<arg name="Reason" dir="I" type="sstr"/>
</method>
- <method name="Release">
+ <method name="ReleaseJob">
<arg name="Id" dir="I" type="sstr"
desc="Job's Id, the string ClusterId.ProcId"/>
<arg name="Reason" dir="I" type="sstr"/>
</method>
- <method name="Remove">
+ <method name="RemoveJob">
<arg name="Id" dir="I" type="sstr"
desc="Job's Id, the string ClusterId.ProcId"/>
<arg name="Reason" dir="I" type="sstr"/>
</method>
- <method name="Fetch">
- <arg name="Id" dir="I" type="sstr"
- desc="Job's Id, the string ClusterId.ProcId"/>
- <arg name="File" dir="I" type="sstr"/>
- <arg name="Start" dir="I" type="int32"/>
- <arg name="End" dir="I" type="int32"/>
- <arg name="Data" dir="O" type="lstr"/>
- </method>
-
- <method name="GetStates">
- <arg name="Submission" dir="I" type="sstr"/>
- <arg name="State" dir="I" type="uint32"/>
- <arg name="Count" dir="O" type="uint32"/>
- </method>
-
- <method name="GetJobs">
- <arg name="Submission" dir="I" type="sstr"/>
- <arg name="Jobs" dir="O" type="map"/>
- </method>
-
- <method name="echo">
- <arg name="sequence" dir="IO" type="uint32"/>
- <arg name="body" dir="IO" type="lstr"/>
- </method>
</class>
<class name="Submitter">
- <property name="schedulerRef" type="objId"
parentRef="y" index="y"
references="mrg.grid:Scheduler"/>
+
+ <group name="GridMethods"/>
+
+ <property name="schedulerRef" type="objId"
parentRef="y" index="y"
references="com.redhat.grid:Scheduler"/>
<statistic name="HeldJobs" type="uint32"/>
<statistic name="IdleJobs" type="uint32"/>
@@ -708,7 +560,9 @@
<property name="MyAddress" type="sstr" desc=""/>
<!-- NOTE: MonitorSelf* statistics are currently missing in 7.0.0 -->
- <group name="daemon-stats"/>
+ <group name="DaemonProperties"/>
+ <group name="DaemonStatistics"/>
+ <group name="GridMethods"/>
<method name="GetLimits">
<arg name="Limits" dir="O" type="map"/>
@@ -722,13 +576,6 @@
<method name="GetStats">
<arg name="Name" dir="I" type="sstr"
desc="User or group name"/>
<arg name="Ad" dir="O" type="map"/>
-<!--
- <arg name="Effective" dir="O" type="double"/>
- <arg name="Real" dir="O" type="double"/>
- <arg name="Factor" dir="O" type="double"/>
- <arg name="Resources" dir="O" type="unit32"/>
- <arg name="Usage" dir="O" type="double"
units="hours"/>
--->
</method>
<method name="SetPriority">
@@ -746,28 +593,6 @@
<arg name="Usage" dir="I" type="double"/>
</method>
- <!--
- <method name="GetStaticQuota">
- <arg name="Name" dir="I" type="sstr"
desc="Group name"/>
- <arg name="Quota" dir="O" type="uint32"/>
- </method>
-
- <method name="GetDynamicQuota">
- <arg name="Name" dir="I" type="sstr"
desc="Group name"/>
- <arg name="Quota" dir="O" type="double"/>
- </method>
-
- <method name="SetStaticQuota">
- <arg name="Name" dir="I" type="sstr"
desc="Group name"/>
- <arg name="Quota" dir="I" type="uint32"/>
- </method>
-
- <method name="SetDynamicQuota">
- <arg name="Name" dir="I" type="sstr"
desc="Group name"/>
- <arg name="Quota" dir="I" type="double"/>
- </method>
--->
-
<method name="GetRawConfig">
<arg name="Name" dir="I" type="sstr"
desc="Config param name"/>
<arg name="Value" dir="O" type="lstr"/>
@@ -782,11 +607,12 @@
</class>
<class name="Collector">
+ <group name="DaemonProperties"/>
+ <group name="GridMethods"/>
+
<property name="Pool" type="sstr" index="y"/>
<property name="System" type="sstr" index="y"/>
- <property name="CondorPlatform" type="sstr"/>
- <property name="CondorVersion" type="sstr"/>
<property name="Name" type="sstr" index="y"/>
<property name="MyAddress" type="sstr"/>
@@ -800,7 +626,9 @@
<class name="Master">
- <group name="daemon-stats"/>
+ <group name="DaemonProperties"/>
+ <group name="DaemonStatistics"/>
+ <group name="GridMethods"/>
<property name="Pool" type="sstr" index="y"/>
<property name="System" type="sstr" index="y"/>
@@ -826,13 +654,14 @@
</class>
<class name="Grid">
- <property name="Pool" type="sstr" index="y"/>
+
+ <group name="GridMethods"/>
+ <property name="Pool" type="sstr" index="y"/>
<property name="Name" type="sstr"/>
<property name="ScheddName" type="sstr"/>
<property name="Owner" type="sstr"/>
- <statistic name="NumJobs" type="uint32"/>
<property name="JobLimit"
type="uint32"
desc="Maximum number of jobs that can be in the process
@@ -841,24 +670,64 @@
type="uint32"
desc="Limit on the number of jobs that will be submitted
to the grid resource at once."/>
-
- <statistic name="SubmitsInProgress" type="uint32"/>
- <statistic name="SubmitsQueued" type="uint32"/>
- <statistic name="SubmitsAllowed" type="uint32"/>
- <statistic name="SubmitsWanted" type="uint32"/>
-
<property name="GridResourceUnavailableTime"
type="absTime" unit="nanosecond"
optional="y"
desc="If present, the Grid is down for the specified
- amount of time."/>
+ amount of time."/>
+ <statistic name="NumJobs" type="uint32"/>
+ <statistic name="SubmitsInProgress" type="uint32"/>
+ <statistic name="SubmitsQueued" type="uint32"/>
+ <statistic name="SubmitsAllowed" type="uint32"/>
+ <statistic name="SubmitsWanted" type="uint32"/>
<statistic name="RunningJobs" type="uint32"/>
<statistic name="IdleJobs" type="uint32"/>
+
</class>
+
+ <!-- NOTE: at deployment, only one daemon between the schedd and the job server will
publish this interface -->
+ <class name="JobServer">
+
+ <group name="DaemonProperties"/>
+ <group name="DaemonStatistics"/>
+ <group name="GridMethods"/>
+
+ <property name="Pool" type="sstr" index="y"/>
+ <property name="System" type="sstr" index="y"/>
+
+ <property name="Machine" type="sstr" desc=""/>
+ <property name="MyAddress" type="sstr" desc=""/>
+ <property name="Name" type="sstr" index="y"
desc=""/>
+ <property name="PublicNetworkIpAddr" type="sstr"
desc=""/>
+
+ <method name="GetJobAd">
+ <arg name="Id" dir="I" type="sstr"
+ desc="Job's Id, the string ClusterId.ProcId"/>
+ <arg name="JobAd" dir="O" type="map"
+ desc="(name,value,type) tuples; Values are INTEGER, FLOAT,
+ STRING and EXPR. The EXPR value is not first class,
+ it is an unquoted, with double quotes, string"/>
+ </method>
+ <method name="FetchJobData">
+ <arg name="Id" dir="I" type="sstr"
+ desc="Job's Id, the string ClusterId.ProcId"/>
+ <arg name="File" dir="I" type="sstr"/>
+ <arg name="Start" dir="I" type="int32"/>
+ <arg name="End" dir="I" type="int32"/>
+ <arg name="Data" dir="O" type="lstr"/>
+ </method>
+
+ </class>
+
+
<class name="Submission">
- <property name="schedulerRef" type="objId"
parentRef="y" index="y"
references="mrg.grid:Scheduler"/>
+
+ <group name="GridMethods"/>
+
+ <!-- navigate from a submission to a job server to get its pool -->
+ <property name="jobserverRef" type="objId"
parentRef="y" index="y"
references="com.redhat.grid:JobServer"/>
<property name="Name" type="sstr" index="y"/>
<property name="Owner" type="sstr" index="y"/>
@@ -868,6 +737,12 @@
<statistic name="Removed" type="count32"/>
<statistic name="Completed" type="count32"/>
<statistic name="Held" type="count32"/>
+
+ <!-- summary info -->
+ <method name="GetJobSummaries">
+ <arg name="Jobs" dir="O" type="map"/>
+ </method>
+
</class>
</schema>
Modified: mgmt/newdata/cumin/model/qpid.xml
===================================================================
--- mgmt/newdata/cumin/model/qpid.xml 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/model/qpid.xml 2010-05-21 17:07:08 UTC (rev 3983)
@@ -61,8 +61,9 @@
===============================================================
-->
<class name="Broker">
- <property name="systemRef" type="objId"
references="System" access="RC" index="y" desc="System
ID" parentRef="y"/>
- <property name="port" type="uint16"
access="RC" index="y" desc="TCP Port for AMQP Service"/>
+ <property name="name" type="sstr"
access="RC" index="y" desc="Index for the broker at this
agent"/>
+ <property name="systemRef" type="objId"
references="System" access="RO" desc="System ID"
parentRef="y"/>
+ <property name="port" type="uint16"
access="RO" desc="TCP Port for AMQP Service"/>
<property name="workerThreads" type="uint16"
access="RO" desc="Thread pool size"/>
<property name="maxConns" type="uint16"
access="RO" desc="Maximum allowed connections"/>
<property name="connBacklog" type="uint16"
access="RO" desc="Connection backlog limit for listening socket"/>
Modified: mgmt/newdata/cumin/python/cumin/grid/collector.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/collector.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/collector.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -21,7 +21,7 @@
class CollectorFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Collector
+ cls = app.model.com_redhat_grid.Collector
super(CollectorFrame, self).__init__(app, name, cls)
Modified: mgmt/newdata/cumin/python/cumin/grid/main.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/main.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/main.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -16,14 +16,14 @@
def __init__(self, app, name):
super(Module, self).__init__(app, name)
- # cls = app.model.mrg_grid.Job
+ # cls = app.model.com_redhat_grid.Job
# JobHold(self, cls)
# JobRelease(self, cls)
# JobRemove(self, cls)
# JobSetAttribute(self, cls)
- # cls = app.model.mrg_grid.Negotiator
+ # cls = app.model.com_redhat_grid.Negotiator
# NegotiatorEditDynamicQuota(self, cls)
# NegotiatorEditStaticQuota(self, cls)
Modified: mgmt/newdata/cumin/python/cumin/grid/negotiator.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/negotiator.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/negotiator.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -20,7 +20,7 @@
class NegotiatorFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Negotiator
+ cls = app.model.com_redhat_grid.Negotiator
super(NegotiatorFrame, self).__init__(app, name, cls)
@@ -41,7 +41,7 @@
class NegotiatorSelector(ObjectSelector):
def __init__(self, app, name, pool):
- cls = app.model.mrg_grid.Negotiator
+ cls = app.model.com_redhat_grid.Negotiator
super(NegotiatorSelector, self).__init__(app, name, cls)
@@ -279,8 +279,9 @@
groups = self.groups.get(session)
if len(groups) == 0:
negotiator = self.negotiator.get(session)
- action = FetchRawConfig(self.app)
- results = action.execute(negotiator, "GROUP_NAMES", timeout=10)
+
+ action = NewQmfCall(self.app, {'Value': None})
+ results = action.qmf_call(negotiator, "GetRawConfig",
("GROUP_NAMES",))
groups = results.data
try:
groups = self.split_group_names(groups['Value'])
@@ -426,14 +427,14 @@
ret = True
return ret
-class GroupForm(CuminTaskForm):
+class GroupForm(ObjectTaskForm):
def __init__(self, app, name, task):
super(GroupForm, self).__init__(app, name, task)
self.defer_enabled = True
- self.object = NegotiatorParameter(app, "negotiator")
- self.add_parameter(self.object)
+ #self.object = NegotiatorParameter(app, "negotiator")
+ #self.add_parameter(self.object)
self.group_helper = GroupHelper(app, "groups", self.object)
self.add_child(self.group_helper)
@@ -873,9 +874,10 @@
self.form = NegotiatorLimitSetForm(module.app, self.name, self)
- def do_enter(self, session, limit):
- self.form.negotiator.set(session, limit[0])
- self.form.limit_name.set(session, limit[1])
+ def do_enter(self, session):
+ pass
+ #self.form.negotiator.set(session, limit[0])
+ #self.form.limit_name.set(session, limit[1])
def get_title(self, session):
return "Set limit"
@@ -949,13 +951,13 @@
return "Edit static quota"
class NegotiatorUserTask(NegotiatorGroupTask):
- def do_enter(self, session, ng):
- try:
- negotiator, group = ng
- except:
- raise Exception("Must supply group for user forms")
- super(NegotiatorUserTask, self).do_enter(session, negotiator)
- self.form.group.set(session, group)
+ def do_enter(self, session):
+ #try:
+ # negotiator, group = ng
+ #except:
+ # raise Exception("Must supply group for user forms")
+ super(NegotiatorUserTask, self).do_enter(session)
+ #self.form.group.set(session, group)
class NegotiatorUserPrioFactor(NegotiatorUserTask):
def __init__(self, app, frame):
@@ -964,7 +966,7 @@
self.form = UserPrioFactorForm(app, self.name, self)
def get_title(self, session):
- return "Edit priority factor"
+ return "Edit user priority factor"
class NegotiatorUserRegroup(NegotiatorUserTask):
def __init__(self, app, frame):
@@ -973,4 +975,4 @@
self.form = UserRegroupForm(app, self.name, self)
def get_title(self, session):
- return "Edit autoregroup"
+ return "Edit user autoregroup"
Modified: mgmt/newdata/cumin/python/cumin/grid/pool.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/pool.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/pool.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -34,7 +34,7 @@
class PoolSelector(ObjectSelector):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Collector
+ cls = app.model.com_redhat_grid.Collector
super(PoolSelector, self).__init__(app, name, cls)
@@ -48,7 +48,7 @@
class PoolFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Collector
+ cls = app.model.com_redhat_grid.Collector
super(PoolFrame, self).__init__(app, name, cls)
@@ -229,7 +229,7 @@
class PoolSlotMapPage(SlotMapPage):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Collector
+ cls = app.model.com_redhat_grid.Collector
self.collector = RosemaryObjectParameter(app, "id", cls)
super(PoolSlotMapPage, self).__init__(app, name, self.collector,
"Pool")
@@ -330,7 +330,7 @@
def __init__(self, app, name):
super(PoolSlotFullPage, self).__init__(app, name)
- cls = app.model.mrg_grid.Collector
+ cls = app.model.com_redhat_grid.Collector
self.collector = RosemaryObjectParameter(app, "id", cls)
self.add_parameter(self.collector)
Modified: mgmt/newdata/cumin/python/cumin/grid/scheduler.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/scheduler.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/scheduler.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -25,7 +25,7 @@
class SchedulerFrame(ObjectFrame):
def __init__(self, app, name, pool):
- cls = app.model.mrg_grid.Scheduler
+ cls = app.model.com_redhat_grid.Scheduler
super(SchedulerFrame, self).__init__(app, name, cls)
@@ -39,7 +39,7 @@
self.view.add_tab(submissions)
cls = submissions.cls
- submissions.add_reference_filter(self.object, cls.schedulerRef)
+ submissions.add_reference_filter(self.object, cls.jobserverRef)
submitters = SubmitterSelector(app, "submitters", self.object)
self.view.add_tab(submitters)
@@ -49,7 +49,7 @@
class SchedulerSelector(ObjectSelector):
def __init__(self, app, name, pool):
- cls = app.model.mrg_grid.Scheduler
+ cls = app.model.com_redhat_grid.Scheduler
super(SchedulerSelector, self).__init__(app, name, cls)
@@ -97,7 +97,7 @@
def do_get_items(self, session):
collector = self.form.object.get(session)
- cls = self.app.model.mrg_grid.Scheduler
+ cls = self.app.model.com_redhat_grid.Scheduler
if collector:
schedulers = cls.get_selection(session.cursor, Pool=collector.Pool)
else:
Modified: mgmt/newdata/cumin/python/cumin/grid/slot.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/slot.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/slot.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -17,7 +17,7 @@
class SlotSelector(ObjectSelector):
def __init__(self, app, name, pool):
- cls = app.model.mrg_grid.Slot
+ cls = app.model.com_redhat_grid.Slot
super(SlotSelector, self).__init__(app, name, cls)
@@ -35,7 +35,7 @@
class SlotFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Slot
+ cls = app.model.com_redhat_grid.Slot
super(SlotFrame, self).__init__(app, name, cls)
Modified: mgmt/newdata/cumin/python/cumin/grid/submission.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/submission.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/submission.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -13,13 +13,13 @@
class SubmissionFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Submission
+ cls = app.model.com_redhat_grid.Submission
super(SubmissionFrame, self).__init__(app, name, cls)
class SubmissionSelector(ObjectSelector):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Submission
+ cls = app.model.com_redhat_grid.Submission
super(SubmissionSelector, self).__init__(app, name, cls)
Modified: mgmt/newdata/cumin/python/cumin/grid/submitter.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/grid/submitter.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/grid/submitter.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -21,7 +21,7 @@
class SubmitterFrame(ObjectFrame):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Submitter
+ cls = app.model.com_redhat_grid.Submitter
super(SubmitterFrame, self).__init__(app, name, cls)
@@ -32,7 +32,7 @@
class SubmitterSelector(ObjectSelector):
def __init__(self, app, name, scheduler):
- cls = app.model.mrg_grid.Submitter
+ cls = app.model.com_redhat_grid.Submitter
super(SubmitterSelector, self).__init__(app, name, cls)
Modified: mgmt/newdata/cumin/python/cumin/main.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/main.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/main.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -335,7 +335,7 @@
class TopSubmissionTable(TopObjectTable):
def __init__(self, app, name):
- cls = app.model.mrg_grid.Submission
+ cls = app.model.com_redhat_grid.Submission
super(TopSubmissionTable, self).__init__(app, name, cls)
Modified: mgmt/newdata/cumin/python/cumin/model.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/model.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/model.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -1614,6 +1614,36 @@
def done(self):
return self.got_data or self.error
+class NewQmfCall(object):
+ def __init__(self, app, default=None):
+ self.app = app
+ self.data = default
+ self.got_data = False
+ self.error = False
+ self.status = None
+ self.timeout = 5
+
+ def qmf_call(self, obj, meth, *args):
+ def completion(status_code, output_args):
+ self.status = status_code
+ if (status == 0) or (status == "OK"):
+ self.data = output_args
+ self.got_data = True
+ else:
+ self.data = self.default
+ self.error = True
+
+ session = self.app.session
+ session.call_method(completion, obj, meth, *args)
+ return self.do_wait(self.timeout)
+
+ def do_wait(self, timeout=5):
+ wait(self.done, timeout=timeout)
+ return self
+
+ def done(self):
+ return self.got_data or self.error
+
class QmfCallSet(object):
def __init__(self, app):
self.app = app
Modified: mgmt/newdata/cumin/python/cumin/parameters.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/parameters.py 2010-05-21 16:46:34 UTC (rev 3982)
+++ mgmt/newdata/cumin/python/cumin/parameters.py 2010-05-21 17:07:08 UTC (rev 3983)
@@ -169,13 +169,13 @@
class CollectorGridAttribute(ObjectAssociateAttribute):
def get_associate(self, session, collector):
- cls = self.app.model.mrg_grid.Grid
+ cls = self.app.model.com_redhat_grid.Grid
grid = cls.get_object(session.cursor, Pool=collector.Pool)
return grid
class CollectorNegotiatorAttribute(ObjectAssociateAttribute):
def get_associate(self, session, collector):
- cls = self.app.model.mrg_grid.Negotiator
+ cls = self.app.model.com_redhat_grid.Negotiator
negotiator = cls.get_object(session.cursor, Pool=collector.Pool)
return negotiator