Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ensembl-gh-mirror
ensembl-hive
Commits
7ab2d639
Commit
7ab2d639
authored
Jul 15, 2011
by
Leo Gordon
Browse files
do not update counters unnecessarily
parent
942f9a29
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
modules/Bio/EnsEMBL/Hive/Queen.pm
modules/Bio/EnsEMBL/Hive/Queen.pm
+13
-10
No files found.
modules/Bio/EnsEMBL/Hive/Queen.pm
View file @
7ab2d639
...
...
@@ -164,20 +164,23 @@ sub create_new_worker {
unless
(
$job
)
{
#go into autonomous mode
return
undef
if
(
$self
->
get_hive_current_load
()
>=
1.1
);
$analysis_stats_adaptor
->
decrease_needed_workers
(
$analysisStats
->
analysis_id
);
$analysis_stats_adaptor
->
increase_running_workers
(
$analysisStats
->
analysis_id
);
$analysisStats
->
print_stats
;
if
(
$self
->
get_hive_current_load
()
>=
1.1
)
{
print
"
Hive is overloaded, can't create a worker
\n
";
return
;
}
if
(
$analysisStats
->
status
eq
'
BLOCKED
')
{
print
(
"
Analysis is BLOCKED, can't create workers
\n
"
)
;
return
undef
;
print
"
Analysis is BLOCKED, can't create workers
\n
";
return
;
}
if
(
$analysisStats
->
status
eq
'
DONE
')
{
print
(
"
Analysis is DONE, don't need to create workers
\n
"
)
;
return
undef
;
print
"
Analysis is DONE, don't need to create workers
\n
";
return
;
}
$analysis_stats_adaptor
->
decrease_needed_workers
(
$analysisStats
->
analysis_id
);
$analysis_stats_adaptor
->
increase_running_workers
(
$analysisStats
->
analysis_id
);
$analysisStats
->
print_stats
;
}
my
$sql
=
q{INSERT INTO worker
...
...
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