Skip to content
GitLab
Explore
Sign in
Register
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
32c47bda
Commit
32c47bda
authored
1 year ago
by
Jorrit Schaap
Browse files
Options
Downloads
Patches
Plain Diff
non-triggered dynamically scheduled units are not allowed to unschedule fixed_time scheduled units
parent
abf5d1d9
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
SAS/TMSS/backend/services/scheduling/lib/dynamic_scheduling.py
+4
-0
4 additions, 0 deletions
...MSS/backend/services/scheduling/lib/dynamic_scheduling.py
SAS/TMSS/backend/src/tmss/tmssapp/models/specification.py
+14
-0
14 additions, 0 deletions
SAS/TMSS/backend/src/tmss/tmssapp/models/specification.py
with
18 additions
and
0 deletions
SAS/TMSS/backend/services/scheduling/lib/dynamic_scheduling.py
+
4
−
0
View file @
32c47bda
...
...
@@ -1163,6 +1163,10 @@ def unschededule_blocking_scheduled_units_if_needed_and_possible(candidate_sched
if
candidate_scheduling_unit
.
priority_queue
.
value
==
models
.
PriorityQueueType
.
Choices
.
B
.
value
:
overlapping_scheduled_scheduling_units
=
overlapping_scheduled_scheduling_units
.
exclude
(
priority_queue__value
=
models
.
PriorityQueueType
.
Choices
.
A
.
value
)
# non-triggered dynamically scheduled units are not allowed to unschedule fixed_time scheduled units
if
candidate_scheduling_unit
.
is_dynamically_scheduled
and
not
candidate_scheduling_unit
.
interrupts_telescope
:
overlapping_scheduled_scheduling_units
=
overlapping_scheduled_scheduling_units
.
exclude
(
scheduling_constraints_doc__scheduler
=
'
fixed_time
'
)
if
not
overlapping_scheduled_scheduling_units
.
exists
():
logger
.
debug
(
'
no scheduled scheduling_units are blocking candidate scheduling_unit id=%s name=%s, nothing needs to be unscheduled
'
,
candidate_scheduling_unit
.
id
,
candidate_scheduling_unit
.
name
)
return
...
...
This diff is collapsed.
Click to expand it.
SAS/TMSS/backend/src/tmss/tmssapp/models/specification.py
+
14
−
0
View file @
32c47bda
...
...
@@ -1368,6 +1368,20 @@ class SchedulingUnitBlueprint(ProjectPropertyMixin, TemplateSchemaMixin, Schedul
'''
return
self
.
draft
.
scheduling_set
.
project
@property
def
is_dynamically_scheduled
(
self
)
->
bool
:
'''
is this unit scheduled dynamically?
'''
if
self
.
scheduling_constraints_doc
is
not
None
:
return
self
.
scheduling_constraints_doc
.
get
(
'
scheduler
'
,
''
)
==
'
dynamic
'
return
False
@property
def
is_fixed_time_scheduled
(
self
)
->
bool
:
'''
is this unit scheduled at fixed time?
'''
if
self
.
scheduling_constraints_doc
is
not
None
:
return
self
.
scheduling_constraints_doc
.
get
(
'
scheduler
'
,
''
)
==
'
fixed_time
'
return
False
@property
def
main_observation_used_stations
(
self
)
->
list
:
'''
return the list of used stations of the main observation task
'''
...
...
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