Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ophélie Gagnard
slapos.core
Commits
7baf7f24
Commit
7baf7f24
authored
May 19, 2021
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_cloud&accounting: Improvements on Alarm's queries
Contributed by Romain.
parent
a74838cc
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
5 deletions
+6
-5
master/bt5/slapos_accounting/SkinTemplateItem/portal_skins/slapos_simulation/Alarm_buildSlapOSPath.py
...m/portal_skins/slapos_simulation/Alarm_buildSlapOSPath.py
+2
-1
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Alarm_allocateInstance.py
...eItem/portal_skins/slapos_cloud/Alarm_allocateInstance.py
+1
-2
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Alarm_searchComputerPartitionAndMarkFree.py
.../slapos_cloud/Alarm_searchComputerPartitionAndMarkFree.py
+3
-2
No files found.
master/bt5/slapos_accounting/SkinTemplateItem/portal_skins/slapos_simulation/Alarm_buildSlapOSPath.py
View file @
7baf7f24
...
...
@@ -2,7 +2,8 @@ kw = {}
select_dict
=
{
'delivery_uid'
:
None
}
kw
.
update
(
portal_type
=
'Simulation Movement'
,
select_dict
=
select_dict
,
# This is an optimisation to help mariadb selecting a better index
simulation_state
=
[
'draft'
,
'planned'
,
None
],
left_join_list
=
select_dict
.
keys
(),
delivery_uid
=
None
)
...
...
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Alarm_allocateInstance.py
View file @
7baf7f24
portal
=
context
.
getPortalObject
()
select_dict
=
{
'default_aggregate_uid'
:
None
}
portal
.
portal_catalog
.
searchAndActivate
(
p
ortal_type
=
(
'Slave Instance'
,
'Software Instance'
),
p
arent_uid
=
context
.
getPortalObject
().
software_instance_module
.
getUid
(
),
validation_state
=
'validated'
,
default_aggregate_uid
=
None
,
select_dict
=
select_dict
,
left_join_list
=
select_dict
.
keys
(),
method_id
=
'SoftwareInstance_tryToAllocatePartition'
,
...
...
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Alarm_searchComputerPartitionAndMarkFree.py
View file @
7baf7f24
portal
=
context
.
getPortalObject
()
portal
.
portal_catalog
.
searchAndActivate
(
portal_type
=
[
"Software Instance"
,
"Slave Instance"
],
default_aggregate_relative_url
=
"computer_module/%/%"
,
aggregate__uid
=
"%"
,
validation_state
=
"invalidated"
,
slap_state
=
"destroy_requested"
,
parent_uid
=
context
.
getPortalObject
().
software_instance_module
.
getUid
(),
method_id
=
'SoftwareInstance_tryToUnallocatePartition'
,
activate_kw
=
{
'tag'
:
tag
}
)
...
...
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