Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
ensembl-hive
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
7
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ensembl-gh-mirror
ensembl-hive
Commits
0d6c4bf4
Commit
0d6c4bf4
authored
10 years ago
by
Leo Gordon
Browse files
Options
Downloads
Patches
Plain Diff
cosmetic: rearrange the control flow for better readability
parent
35d32087
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/Bio/EnsEMBL/Hive/Queen.pm
+5
-6
5 additions, 6 deletions
modules/Bio/EnsEMBL/Hive/Queen.pm
with
5 additions
and
6 deletions
modules/Bio/EnsEMBL/Hive/Queen.pm
+
5
−
6
View file @
0d6c4bf4
...
...
@@ -369,12 +369,8 @@ sub check_for_dead_workers { # scans the whole Valley for lost Workers (but i
my
$meadow_type
=
$worker
->
meadow_type
;
if
(
my
$meadow
=
$valley
->
find_available_meadow_responsible_for_worker
(
$worker
))
{
$mt_and_pid_to_worker_status
{
$meadow_type
}
||=
$meadow
->
status_of_all_our_workers
;
}
else
{
$worker_status_counts
{
$meadow_type
}{'
UNREACHABLE
'}
++
;
next
;
# Worker is unreachable from this Valley
}
$mt_and_pid_to_worker_status
{
$meadow_type
}
||=
$meadow
->
status_of_all_our_workers
;
# only run this once per reachable Meadow
my
$process_id
=
$worker
->
process_id
;
if
(
my
$status
=
$mt_and_pid_to_worker_status
{
$meadow_type
}{
$process_id
})
{
# can be RUN|PEND|xSUSP
...
...
@@ -384,9 +380,12 @@ sub check_for_dead_workers { # scans the whole Valley for lost Workers (but i
$mt_and_pid_to_lost_worker
{
$meadow_type
}{
$process_id
}
=
$worker
;
}
}
else
{
$worker_status_counts
{
$meadow_type
}{'
UNREACHABLE
'}
++
;
# Worker is unreachable from this Valley
}
}
#
jus
t a quick summary report:
#
prin
t a quick summary report:
foreach
my
$meadow_type
(
keys
%worker_status_counts
)
{
warn
"
GarbageCollector:
\t
[
$meadow_type
Meadow:]
\t
"
.
join
('
,
',
map
{
"
$_
:
$worker_status_counts
{
$meadow_type
}{
$_
}
"
}
keys
%
{
$worker_status_counts
{
$meadow_type
}})
.
"
\n\n
";
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment