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
Cédric Le Ninivin
slapos.core
Commits
74feb1de
Commit
74feb1de
authored
Jul 22, 2022
by
Cédric Le Ninivin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wip slapgrid add update Related Instance List
parent
af23c67d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
6 deletions
+12
-6
slapos/grid/slapgrid.py
slapos/grid/slapgrid.py
+12
-6
No files found.
slapos/grid/slapgrid.py
View file @
74feb1de
...
...
@@ -813,10 +813,16 @@ stderr_logfile_backups=1
if
os
.
path
.
exists
(
transaction_file_path
):
with
open
(
transaction_file_path
,
'r'
)
as
tf
:
try
:
# XXX CLN
computer_partition
.
setComputerPartitionRelatedInstanceList
(
[
reference
for
reference
in
tf
.
read
().
split
(
'
\
n
'
)
if
reference
]
)
if
not
self
.
api_backward_compatibility
:
self
.
slap
.
jio_api_connector
.
put
({
"portal_type"
:
"Software Instance"
,
"reference"
:
computer_partition
.
get
(
"reference"
),
"requested_instance_list"
:
[
reference
for
reference
in
tf
.
read
().
split
(
'
\
n
'
)
if
reference
],
})
else
:
computer_partition
[
"slap_partition"
].
setComputerPartitionRelatedInstanceList
(
[
reference
for
reference
in
tf
.
read
().
split
(
'
\
n
'
)
if
reference
]
)
except
NotFoundError
as
e
:
# Master doesn't implement this feature ?
self
.
logger
.
warning
(
"NotFoundError: %s.
\
n
Cannot send requested instance "
\
...
...
@@ -1507,7 +1513,7 @@ stderr_logfile_backups=1
# even if something is terribly wrong while processing an instance, it
# won't prevent processing other ones.
if
not
self
.
api_backward_compatibility
:
computer_partition
=
self
.
slap
.
jio_connector
.
get
({
computer_partition
=
self
.
slap
.
jio_
api_
connector
.
get
({
"portal_type"
:
"Software Instance"
,
"reference"
:
computer_partition
[
"reference"
]
})
...
...
@@ -1590,7 +1596,7 @@ stderr_logfile_backups=1
promise_error_partition_list
=
[]
for
computer_partition
in
computer_partition_list
:
if
not
self
.
api_backward_compatibility
:
computer_partition
=
self
.
slap
.
jio_connector
.
get
({
computer_partition
=
self
.
slap
.
jio_
api_
connector
.
get
({
"portal_type"
:
"Software Instance"
,
"reference"
:
computer_partition
[
"reference"
]
})
...
...
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