Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RadioObservatory
LOFAR
Commits
f764afb9
Commit
f764afb9
authored
4 years ago
by
Jorrit Schaap
Browse files
Options
Downloads
Patches
Plain Diff
TMSS-190
: added pipelinecontrol as background service for tmsstestenv
parent
123e21b5
No related branches found
No related tags found
1 merge request
!252
Resolve TMSS-190
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
SAS/TMSS/test/test_utils.py
+14
-2
14 additions, 2 deletions
SAS/TMSS/test/test_utils.py
with
14 additions
and
2 deletions
SAS/TMSS/test/test_utils.py
+
14
−
2
View file @
f764afb9
...
@@ -272,7 +272,7 @@ class TMSSTestEnvironment:
...
@@ -272,7 +272,7 @@ class TMSSTestEnvironment:
populate_schemas
:
bool
=
False
,
populate_test_data
:
bool
=
False
,
populate_schemas
:
bool
=
False
,
populate_test_data
:
bool
=
False
,
start_ra_test_environment
:
bool
=
False
,
start_postgres_listener
:
bool
=
False
,
start_ra_test_environment
:
bool
=
False
,
start_postgres_listener
:
bool
=
False
,
start_subtask_scheduler
:
bool
=
False
,
start_dynamic_scheduler
:
bool
=
False
,
start_subtask_scheduler
:
bool
=
False
,
start_dynamic_scheduler
:
bool
=
False
,
enable_viewflow
:
bool
=
False
):
start_pipeline_control
:
bool
=
False
,
enable_viewflow
:
bool
=
False
):
self
.
_exchange
=
exchange
self
.
_exchange
=
exchange
self
.
_broker
=
broker
self
.
_broker
=
broker
self
.
_populate_schemas
=
populate_schemas
self
.
_populate_schemas
=
populate_schemas
...
@@ -299,6 +299,9 @@ class TMSSTestEnvironment:
...
@@ -299,6 +299,9 @@ class TMSSTestEnvironment:
self
.
_start_dynamic_scheduler
=
start_dynamic_scheduler
self
.
_start_dynamic_scheduler
=
start_dynamic_scheduler
self
.
dynamic_scheduler
=
None
self
.
dynamic_scheduler
=
None
self
.
_start_pipeline_control
=
start_pipeline_control
self
.
pipeline_control
=
None
if
enable_viewflow
:
if
enable_viewflow
:
os
.
environ
[
'
TMSS_ENABLE_VIEWFLOW
'
]
=
'
True
'
os
.
environ
[
'
TMSS_ENABLE_VIEWFLOW
'
]
=
'
True
'
...
@@ -353,6 +356,11 @@ class TMSSTestEnvironment:
...
@@ -353,6 +356,11 @@ class TMSSTestEnvironment:
self
.
dynamic_scheduler
=
create_dynamic_scheduling_service
(
exchange
=
self
.
_exchange
,
broker
=
self
.
_broker
)
self
.
dynamic_scheduler
=
create_dynamic_scheduling_service
(
exchange
=
self
.
_exchange
,
broker
=
self
.
_broker
)
self
.
dynamic_scheduler
.
start_listening
()
self
.
dynamic_scheduler
.
start_listening
()
if
self
.
_start_pipeline_control
:
from
lofar.mac.PipelineControl
import
PipelineControlTMSS
self
.
pipeline_control
=
PipelineControlTMSS
(
exchange
=
self
.
_exchange
,
broker
=
self
.
_broker
)
self
.
pipeline_control
.
start_listening
()
if
self
.
_populate_schemas
or
self
.
_populate_test_data
:
if
self
.
_populate_schemas
or
self
.
_populate_test_data
:
self
.
populate_schemas
()
self
.
populate_schemas
()
...
@@ -373,6 +381,10 @@ class TMSSTestEnvironment:
...
@@ -373,6 +381,10 @@ class TMSSTestEnvironment:
self
.
dynamic_scheduler
.
stop_listening
()
self
.
dynamic_scheduler
.
stop_listening
()
self
.
dynamic_scheduler
=
None
self
.
dynamic_scheduler
=
None
if
self
.
pipeline_control
is
not
None
:
self
.
pipeline_control
.
stop_listening
()
self
.
pipeline_control
=
None
if
self
.
ra_test_environment
is
not
None
:
if
self
.
ra_test_environment
is
not
None
:
self
.
ra_test_environment
.
stop
()
self
.
ra_test_environment
.
stop
()
self
.
ra_test_environment
=
None
self
.
ra_test_environment
=
None
...
@@ -471,7 +483,7 @@ def main_test_environment():
...
@@ -471,7 +483,7 @@ def main_test_environment():
populate_schemas
=
options
.
schemas
,
populate_test_data
=
options
.
data
,
populate_schemas
=
options
.
schemas
,
populate_test_data
=
options
.
data
,
start_ra_test_environment
=
options
.
services
,
start_postgres_listener
=
options
.
services
,
start_ra_test_environment
=
options
.
services
,
start_postgres_listener
=
options
.
services
,
start_subtask_scheduler
=
options
.
services
,
start_dynamic_scheduler
=
options
.
services
,
start_subtask_scheduler
=
options
.
services
,
start_dynamic_scheduler
=
options
.
services
,
enable_viewflow
=
options
.
viewflow
)
as
tmss_test_env
:
start_pipeline_control
=
options
.
services
,
enable_viewflow
=
options
.
viewflow
)
as
tmss_test_env
:
# print some nice info for the user to use the test servers...
# print some nice info for the user to use the test servers...
# use print instead of log for clean lines.
# use print instead of log for clean lines.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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