Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
slapos.core
Commits
09748757
Commit
09748757
authored
Apr 25, 2013
by
Marco Mariani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
realRun() now handles a single method
parent
d03a91a3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
11 deletions
+10
-11
slapos/grid/slapgrid.py
slapos/grid/slapgrid.py
+10
-11
No files found.
slapos/grid/slapgrid.py
View file @
09748757
...
@@ -334,7 +334,7 @@ def parseArgumentTupleAndReturnSlapgridObject(*argument_tuple):
...
@@ -334,7 +334,7 @@ def parseArgumentTupleAndReturnSlapgridObject(*argument_tuple):
options
])
options
])
def
realRun
(
argument_tuple
,
method
_list
):
def
realRun
(
argument_tuple
,
method
):
slapgrid_object
,
options
=
\
slapgrid_object
,
options
=
\
parseArgumentTupleAndReturnSlapgridObject
(
*
argument_tuple
)
parseArgumentTupleAndReturnSlapgridObject
(
*
argument_tuple
)
pidfile
=
options
.
get
(
'pidfile'
)
pidfile
=
options
.
get
(
'pidfile'
)
...
@@ -343,13 +343,12 @@ def realRun(argument_tuple, method_list):
...
@@ -343,13 +343,12 @@ def realRun(argument_tuple, method_list):
try
:
try
:
failed
=
False
failed
=
False
failed_promise
=
False
failed_promise
=
False
for
method
in
method_list
:
# Quite complicated way to figure out if everything went fine
# Quite complicated way to figure out if everything went fine
return_value
=
getattr
(
slapgrid_object
,
method
)()
return_value
=
getattr
(
slapgrid_object
,
method
)()
if
return_value
==
SLAPGRID_FAIL
:
if
return_value
==
SLAPGRID_FAIL
:
failed
=
True
failed
=
True
if
return_value
==
SLAPGRID_PROMISE_FAIL
:
if
return_value
==
SLAPGRID_PROMISE_FAIL
:
failed_promise
=
True
failed_promise
=
True
finally
:
finally
:
if
pidfile
:
if
pidfile
:
setFinished
(
pidfile
)
setFinished
(
pidfile
)
...
@@ -363,19 +362,19 @@ def realRun(argument_tuple, method_list):
...
@@ -363,19 +362,19 @@ def realRun(argument_tuple, method_list):
def
runSoftwareRelease
(
*
argument_tuple
):
def
runSoftwareRelease
(
*
argument_tuple
):
"""Hook for entry point to process Software Releases only
"""Hook for entry point to process Software Releases only
"""
"""
realRun
(
argument_tuple
,
[
'processSoftwareReleaseList'
]
)
realRun
(
argument_tuple
,
'processSoftwareReleaseList'
)
def
runComputerPartition
(
*
argument_tuple
):
def
runComputerPartition
(
*
argument_tuple
):
"""Hook for entry point to process Computer Partitions only
"""Hook for entry point to process Computer Partitions only
"""
"""
realRun
(
argument_tuple
,
[
'processComputerPartitionList'
]
)
realRun
(
argument_tuple
,
'processComputerPartitionList'
)
def
runUsageReport
(
*
argument_tuple
):
def
runUsageReport
(
*
argument_tuple
):
"""Hook for entry point to process Usage Reports only
"""Hook for entry point to process Usage Reports only
"""
"""
realRun
(
argument_tuple
,
[
'agregateAndSendUsage'
]
)
realRun
(
argument_tuple
,
'agregateAndSendUsage'
)
class
Slapgrid
(
object
):
class
Slapgrid
(
object
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment