From c65be37322a6b5b1f7f7a5ce6055149eb11602b4 Mon Sep 17 00:00:00 2001 From: Chris Baker Date: Mon, 9 Dec 2024 15:37:11 +0000 Subject: [PATCH] Updated to version 4.0.2, see CHANGELOG.md for details. --- CHANGELOG.md | 5 +++++ ...ws-cloud-migration-factory-solution-automation.template | 2 +- solution-manifest.yaml | 2 +- source/frontend/package.json | 2 +- source/integrations/mgn/lambdas/lambda_mgn.py | 7 ++++--- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ceae24a..7c6a25b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [4.0.2] - 2024-12-09 +### Fixed +- MGN: Resolved server does not exist error when archiving server that is disconnected. +### Changed +- SSM CMF Document updated runtime to use Python 3.11. ## [4.0.1] - 2024-11-20 ### Fixed - Deployment: Added missing dependency for ToolsAPIDeploy & AdminAPIDeploy resources in main CF template, this was causing some deployments to fail. diff --git a/deployment/CFN-templates/aws-cloud-migration-factory-solution-automation.template b/deployment/CFN-templates/aws-cloud-migration-factory-solution-automation.template index d1b281c..17d3cf6 100644 --- a/deployment/CFN-templates/aws-cloud-migration-factory-solution-automation.template +++ b/deployment/CFN-templates/aws-cloud-migration-factory-solution-automation.template @@ -1537,7 +1537,7 @@ Resources: maxAttempts: 3 action: 'aws:executeScript' inputs: - Runtime: python3.8 + Runtime: python3.11 Handler: script_handler InputPayload: bucket_name: '{{bucketName}}' diff --git a/solution-manifest.yaml b/solution-manifest.yaml index d7e7f14..3e61644 100644 --- a/solution-manifest.yaml +++ b/solution-manifest.yaml @@ -1,7 +1,7 @@ --- id: SO0097 # Solution Id name: cloud-migration-factory-on-aws # trademarked name -version: v3.3.4 # current version of the solution. Used to verify template headers +version: v4.0.2 # current version of the solution. Used to verify template headers cloudformation_templates: # This list should match with AWS CloudFormation templates section of IG - template: aws-cloud-migration-factory-solution.template main_template: true diff --git a/source/frontend/package.json b/source/frontend/package.json index 559a7b2..8ce1860 100644 --- a/source/frontend/package.json +++ b/source/frontend/package.json @@ -1,7 +1,7 @@ { "name": "migration-factory-frontend", "description": "List of dependencies for Frontend ", - "version": "4.0.0", + "version": "4.0.2", "license": "Apache-2.0", "private": true, "type": "module", diff --git a/source/integrations/mgn/lambdas/lambda_mgn.py b/source/integrations/mgn/lambdas/lambda_mgn.py index 84b7834..807dac1 100644 --- a/source/integrations/mgn/lambdas/lambda_mgn.py +++ b/source/integrations/mgn/lambdas/lambda_mgn.py @@ -374,7 +374,7 @@ def verify_account_server(account, mgn_sourceservers, processes, errors, log.error(msg) return msg, account, source_server_ids else: - is_server_exist, is_mgn_server_archived, mgn_sourceservers = \ + is_server_exist, is_mgn_server_archived = \ verify_server( mgn_sourceservers, factoryserver, source_server_ids, target_account_creds, @@ -414,6 +414,7 @@ def verify_server(mgn_sourceservers, factoryserver, factoryserver['source_server_id'] = sourceserver['sourceServerID'] source_server_ids.append(factoryserver['source_server_id']) if sourceserver['dataReplicationInfo']['dataReplicationState'].lower() != 'disconnected': + # if agent connected then get launch template, if not connected the template is not present. p = multiprocessing.Process( target=get_mgn_launch_template_id, args=(target_account_creds, @@ -424,9 +425,9 @@ def verify_server(mgn_sourceservers, factoryserver, ) processes.append(p) p.start() - break + break - return is_server_exist, is_mgn_server_archived, mgn_sourceservers + return is_server_exist, is_mgn_server_archived def validate_server_exist_and_archived(is_server_exist, is_mgn_server_archived,