You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: services/onboarding-service/src/main/java/com/amazon/aws/partners/saasfactory/saasboost/OnboardingService.java
+68-2Lines changed: 68 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -646,8 +646,16 @@ protected void handleOnboardingStackStatusChanged(Map<String, Object> event, Con
646
646
stack.setStatus(stackStatus);
647
647
}
648
648
if (status != onboarding.getStatus()) {
649
-
onboarding.setStatus(status);
650
-
LOGGER.info("Onboarding status changing from {} to {}", onboarding.getStatus(), status);
649
+
if (OnboardingStatus.deleted == status && !stack.isBaseStack()) {
650
+
// If we're receiving a DELETE_COMPLETE status for one of the app stacks,
651
+
// the onboarding record is still in a deleting state because we have to
652
+
// delete the base stack after all the app stacks are complete
653
+
LOGGER.info("Skipping onboarding status deleted for app stack {}", stack.getName());
654
+
onboarding.setStatus(OnboardingStatus.deleting);
655
+
} else {
656
+
onboarding.setStatus(status);
657
+
LOGGER.info("Onboarding status changing from {} to {}", onboarding.getStatus(), status);
658
+
}
651
659
}
652
660
dal.updateOnboarding(onboarding);
653
661
if (stack.isComplete()) {
@@ -672,6 +680,17 @@ protected void handleOnboardingStackStatusChanged(Map<String, Object> event, Con
0 commit comments