-
Notifications
You must be signed in to change notification settings - Fork 120
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v2v: Wait for VM to appear before finalizing it
Added VmImportWaitForVm state machine that is created when IMPORTEXPORT_IMPORT_VM event arrives. VmImportWaitForVm state machine waits for the converted VM to appear in the database and then sets its import status. After that VmImport state machine can continue its operation. VmImportWaitForVm state machine replaces update_vm_import_status method, because when IMPORTEXPORT_IMPORT_VM event arrives, nobody guarantees that the VM object is accessible. VmImportWaitForVm state machine will wait until the VM object is accessible and only after that will update its import status. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1469492
- Loading branch information
Showing
6 changed files
with
110 additions
and
21 deletions.
There are no files selected for viewing
73 changes: 73 additions & 0 deletions
73
...ManageIQ/Infrastructure/VM/Transform/StateMachines/VmImportWaitForVm.class/__class__.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
--- | ||
object_type: class | ||
version: 1.0 | ||
object: | ||
attributes: | ||
description: | ||
display_name: | ||
name: VmImportWaitForVm | ||
type: | ||
inherits: | ||
visibility: | ||
owner: | ||
schema: | ||
- field: | ||
aetype: state | ||
name: start | ||
display_name: | ||
datatype: string | ||
priority: 1 | ||
owner: | ||
default_value: | ||
substitute: true | ||
message: create | ||
visibility: | ||
collect: | ||
scope: | ||
description: | ||
condition: | ||
on_entry: | ||
on_exit: | ||
on_error: | ||
max_retries: | ||
max_time: | ||
- field: | ||
aetype: state | ||
name: Launch | ||
display_name: | ||
datatype: string | ||
priority: 2 | ||
owner: | ||
default_value: METHOD::wait_for_imported_vm | ||
substitute: false | ||
message: create | ||
visibility: | ||
collect: | ||
scope: | ||
description: | ||
condition: | ||
on_entry: | ||
on_exit: | ||
on_error: | ||
max_retries: '100' | ||
max_time: | ||
- field: | ||
aetype: state | ||
name: finish | ||
display_name: | ||
datatype: string | ||
priority: 3 | ||
owner: | ||
default_value: | ||
substitute: true | ||
message: create | ||
visibility: | ||
collect: | ||
scope: | ||
description: | ||
condition: | ||
on_entry: | ||
on_exit: | ||
on_error: | ||
max_retries: | ||
max_time: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
...e/ManageIQ/Infrastructure/VM/Transform/StateMachines/VmImportWaitForVm.class/default.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
object_type: instance | ||
version: 1.0 | ||
object: | ||
attributes: | ||
display_name: | ||
name: default | ||
inherits: | ||
description: | ||
fields: [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters