Commit ab338a6
Zhang Wenhao
<fix>[kvm]: remove TPM from VM individually instead of batch delete
Change the TPM deletion logic from batch SQL delete to individual
deletion using While loop. This ensures proper cleanup for each TPM
by calling removeTpmFromVm method. Added error handling to continue
even if deletion fails for individual TPM.
Changes:
- Replace batch SQL delete with While loop iteration
- Call removeTpmFromVm for each TPM to ensure proper cleanup
- Add error handling to continue on individual failures
- Log warnings for failed TPM deletions
Resolves: ZSV-11439
Related: ZSV-11310
Change-Id: I616d746d6a6f677a6772796f63676e61776763711 parent 912b02f commit ab338a6
1 file changed
Lines changed: 30 additions & 4 deletions
Lines changed: 30 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
305 | 305 | | |
306 | 306 | | |
307 | 307 | | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
308 | 312 | | |
309 | 313 | | |
310 | 314 | | |
| |||
318 | 322 | | |
319 | 323 | | |
320 | 324 | | |
| 325 | + | |
321 | 326 | | |
322 | 327 | | |
323 | 328 | | |
| |||
457 | 462 | | |
458 | 463 | | |
459 | 464 | | |
460 | | - | |
461 | | - | |
462 | | - | |
463 | | - | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
464 | 490 | | |
465 | 491 | | |
466 | 492 | | |
| |||
0 commit comments