evaluate-azure-migration-assessment
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseEvaluate Azure Migration Assessment
评估 Azure Migration Assessment
The bundled references define the ARM API contracts and assessment output contract.
随附的参考文档定义了 ARM API 契约和评估输出契约。
When to Use
适用场景
Use directly or from for Azure SQL Server
instances.
run-migration-assessment可直接使用,也可通过 针对 Azure SQL Server
实例使用。
run-migration-assessmentWorkflow
工作流
Step 1: Resolve the Resource
第 1 步:解析资源
Collect subscription, resource group, and instance name using
ARM resource identification if not in context.
Before calling ARM, initialize the API versions and instance endpoint from .
references/command-execution.md如果上下文中没有相关信息,请使用
ARM 资源标识收集订阅、资源组和实例名称。
调用 ARM 前,根据 初始化 API 版本和实例终结点。
references/command-execution.mdStep 2: Check Existing Assessment
第 2 步:检查现有评估
Always check for an existing assessment first for a general request such as
"run migration assessment".
Skip this check only when the user explicitly asks to refresh, rerun,
replace, or generate a new/fresh assessment, or explicitly says to
ignore existing results.
Invoke with the resolved identifiers.
get-migration-assessment- Existing data -> render it before asking anything else. Trigger a fresh assessment only after the user explicitly confirms.
- Enabled with no data -> continue to Step 3.
- Explicitly disabled -> offer ARM enablement, portal enablement, or Local assessment if the host tool allows.
对于“运行迁移评估”等常规请求,始终先检查是否存在现有评估。
仅当用户明确要求 刷新、重新运行、替换,或生成 新的/全新的评估,或者明确表示
忽略现有结果时,才跳过此检查。
使用解析出的标识符调用 。
get-migration-assessment- 存在数据 -> 在询问任何其他问题之前先呈现数据。只有用户明确确认后,才能触发全新评估。
- 已启用但没有数据 -> 继续执行第 3 步。
- 明确禁用 -> 提供通过 ARM 启用、通过 Azure 门户启用或运行 Local assessment 的选项(如果宿主工具允许)。
Step 3: Trigger and Monitor Assessment
第 3 步:触发并监控评估
Record the trigger request time and run the assessment trigger from
when starting a fresh assessment. Continue in the same command by polling
using the configurable attempt count and interval from
that reference.
references/command-execution.mdMigrationJobOnDemand- 2xx or 409 -> continue.
- Other 4xx/5xx -> report the error and stop.
- -> continue polling in the same turn without asking the user.
InProgress - with
Succeededlater than the trigger request time -> continue to Step 4.lastExecutionTime - with an older
Succeeded-> continue polling.lastExecutionTime - -> show
Failedand stop.jobException - Still running after the polling window -> show the portal link and stop; the user can return later to refresh.
启动全新评估时,记录触发请求的时间,并根据
运行评估触发操作。在同一条命令中,使用该参考文档中可配置的重试次数和间隔轮询
。
references/command-execution.mdMigrationJobOnDemand- 2xx 或 409 -> 继续执行。
- 其他 4xx/5xx -> 报告错误并停止。
- -> 在当前轮次中继续轮询,无需询问用户。
InProgress - 且
Succeeded晚于触发请求时间 -> 继续执行第 4 步。lastExecutionTime - 且
Succeeded早于触发请求时间 -> 继续轮询。lastExecutionTime - -> 显示
Failed并停止。jobException - 轮询窗口结束后仍在运行 -> 显示门户链接并停止;用户可以稍后返回并刷新。
Step 4: Retrieve Telemetry
第 4 步:检索 Telemetry
Run , capture its URL, and poll it using
when retrieving a completed report. Save the full response to a temporary file.
getTelemetryAzure-AsyncOperationreferences/command-execution.md- -> decode the response.
Succeeded - or
Failed-> report the error.Canceled - Timeout -> show the portal link and stop.
运行 ,捕获其 URL,并在检索已完成的报告时,
根据 对其进行轮询。将完整响应保存到临时文件。
getTelemetryAzure-AsyncOperationreferences/command-execution.md- -> 解码响应。
Succeeded - 或
Failed-> 报告错误。Canceled - 超时 -> 显示门户链接并停止。
Step 5: Confirm Fresh Results
第 5 步:确认最新结果
Decode the portal's four telemetry report families:
- /
Suitability.Suitability_V2 - /
SKURecommendation_AzureSQLVM._V2 - /
SKURecommendation_AzureSQLMI._V2 - /
SKURecommendation_AzureSQLDB._V2
For each family, select the report with the newer telemetry
. Use Suitability for readiness and blockers, and the
three SKU reports for sizing and recommendation details.
ObservedTimestampUTCCompare the selected Suitability with the trigger request time after
converting both to UTC. Also require each available
selected SKU report's to be later than the trigger
request time. If any selected report is stale, repeat telemetry retrieval and
decoding up to three times for report propagation. Use the job only for running,
fresh success, and failure state.
EndedOnObservedTimestampUTCUse the selected fresh telemetry reports as the source for readiness, blockers,
target SKU, requirements, recommendation details, and available monetary cost
fields.
解码门户中的四个 telemetry 报告族:
- /
Suitability。Suitability_V2 - /
SKURecommendation_AzureSQLVM。_V2 - /
SKURecommendation_AzureSQLMI。_V2 - /
SKURecommendation_AzureSQLDB。_V2
对于每个报告族,选择 telemetry 较新的报告。
使用 Suitability 获取就绪性和阻碍因素,使用三个 SKU 报告获取规模调整和推荐详情。
ObservedTimestampUTC将选定的 Suitability 和触发请求时间都转换为 UTC 后再进行比较。此外,要求每个
可用的已选定 SKU 报告的 都晚于触发请求时间。如果任何选定报告
已过期,则最多重复三次 telemetry 检索和解码,以处理报告传播延迟。作业仅用于确定运行中、
最新成功和失败状态。
EndedOnObservedTimestampUTC使用选定的最新 telemetry 报告作为以下信息的数据源:就绪性、阻碍因素、
目标 SKU、要求、推荐详情以及可用的货币成本字段。
Step 6: Render
第 6 步:呈现结果
Use the recommended target and available cost from the fresh telemetry selected
in Step 5.
Use assessment output when rendering the combined
readiness and SKU recommendation. Include the portal report link.
使用第 5 步中选定的最新 telemetry 所提供的推荐目标和可用成本。
呈现综合就绪性和 SKU 推荐时,使用评估输出。
包含门户报告链接。
Check it worked
验证是否成功
- Positive verification: When reusing existing assessment data, confirm it was retrieved and rendered without triggering a refresh. When a fresh assessment was requested, require a successful assessment job, completed report retrieval, and selected report timestamps later than the recorded trigger time.
- Cleanup verification: Clear the ARM token and signed operation URL, then remove the temporary run directory only after any requested report has been saved elsewhere.
- 正向验证: 复用现有评估数据时,确认已成功检索并呈现数据,且未触发刷新。请求全新评估时,要求评估作业成功、报告检索完成,且选定报告的时间戳晚于记录的触发时间。
- 清理验证: 清除 ARM token 和签名操作 URL,然后仅在请求的报告已另存到其他位置后,删除临时运行目录。
Notes
注意事项
- Follow the transport rules in whenever calling ARM.
references/command-execution.md - Run its PowerShell sections in order and execute each fenced block as one terminal command.
- The telemetry operation URL comes from .
getTelemetry - Treat a successful telemetry LRO as report-read completion. Use
for assessment-job completion.
MigrationJobOnDemand - Use as the generated time.
EndedOn - Use only the recommended target and user databases in output.
- 每次调用 ARM 时,都应遵循 中的传输规则。
references/command-execution.md - 按顺序运行其中的 PowerShell 部分,并将每个围栏代码块作为一条终端命令执行。
- telemetry 操作 URL 来自 。
getTelemetry - 将成功的 telemetry LRO 视为报告读取完成。使用 判断评估作业是否完成。
MigrationJobOnDemand - 使用 作为生成时间。
EndedOn - 输出中仅使用推荐目标和用户数据库。
References
参考文档
- Open before triggering, polling, or retrieving an assessment.
references/command-execution.md - ARM resource identification
- Assessment output
- 触发、轮询或检索评估前,打开 。
references/command-execution.md - ARM 资源标识
- 评估输出