Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gutyán Gábor
/
circlestack
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
b1f4a5e6
authored
Feb 17, 2014
by
Gregory Nagy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
TODOs in scheduler.py completed
parent
6fe3ab17
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
circle/manager/scheduler.py
+3
-3
No files found.
circle/manager/scheduler.py
View file @
b1f4a5e6
...
...
@@ -51,7 +51,7 @@ def has_enough_ram(ram_size, node):
ram_size mebibytes of memory; otherwise, false.
"""
total
=
node
.
ram_size
used
=
512
# TODO replace mock value with data from monitor
used
=
(
node
.
ram_usage
()
/
100
)
*
total
unused
=
total
-
used
overcommit
=
node
.
ram_size_with_overcommit
...
...
@@ -66,7 +66,7 @@ def free_cpu_time(node):
Higher values indicate more idle time.
"""
activity
=
0
activity
=
node
.
cpu_usage
()
/
10
0
inactivity
=
1
-
activity
cores
=
node
.
num_cores
return
cores
*
inactivity
# TODO replace mock value with data from monitor
return
cores
*
inactivity
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