Codeunit 46858 "BC14 Migration Status Mgr."
HybridBC14 · Microsoft.DataMigration.BC14Reimplementation
Across versions
- BC23-28not present
- BC29-30present
Neighbourhood 7 connected objects and pages
HybridBC14 · Microsoft.DataMigration.BC14Reimplementation · BC29-30 · source at ea08af5e · facts from BC29
Properties
| Property | Value |
|---|---|
| Access | Internal |
Procedures
MarkCompanyStarted(CompanyName: Text[30]): Boolean: Transitions a company into Started. Returns false on invalid prior state (missing row, Completed, or Failed); caller should abort the upgrade.MarkCompanyCompleted(CompanyName: Text[30])MarkCompanyFailed(CompanyName: Text[30]; StatusMessage: Text)SetFinalCompanyStatus(CompanyName: Text[30]; HasErrors: Boolean): Called by FinalizeMigration after Posting + Historical complete. Does not overwrite an existing Failed (set by FailureHandler) — fail wins.UpdateCompanyMessage(CompanyName: Text[30]; MessageText: Text): Writes an informational message to the company’s Status Message blob without changing the Upgrade Status. Use when the upgrade has not failed but we want to surface a note on the Upgrading Companies page (e.g. “TaskScheduler busy, falling back to StartSession”).MarkPendingCompaniesAsFailed(StatusMessage: Text)ResetFailedCompaniesToPending(): Integer: Flips every Failed company back to Pending so the operator can retry them after fixing the underlying data. Clears the per-row failure message — the durable error history lives in the BC14 Migration Error table, not on Hybrid Company Status. Returns the number of rows reset.SetSummaryInProgress(var HybridReplicationSummary: Record "Hybrid Replication Summary")SetSummaryFailed(var HybridReplicationSummary: Record "Hybrid Replication Summary")EvaluateAndSetFinalSummaryStatus(var HybridReplicationSummary: Record "Hybrid Replication Summary")AfterCompanyMigrationCompleted(CompanyName: Text[30]; HasErrors: Boolean; HistoricalCompleted: Boolean; var HybridReplicationSummary: Record "Hybrid Replication Summary"): Unified post-company decision used by both the initial run and rerun paths. Failure + Stop On First Error -> Company Failed, Summary UpgradeFailed, stop. Failure + Continue On Error -> Company Failed, chain to next pending company; Summary failure is decided at TryFinalizeOverallStatus. Success + Hi…TryFinalizeOverallStatus(var HybridReplicationSummary: Record "Hybrid Replication Summary"): Idempotent: the terminal-state check makes repeat calls (e.g. from the main flow and a late Historical worker) a no-op once the summary has been finalized.AcquireRerunSlot(CompanyName: Text[30]): Atomic rerun guard. Errors if another rerun is already Started, or if the status row was wiped (e.g. Reset All Cloud Data) — never silently accept a rerun against missing state.IsCompanyRunning(CompanyName: Text[30]): BooleanIsCompanyFailed(CompanyName: Text[30]): BooleanHasPendingCompanies(): BooleanAnyCompanyHasFailedUpgrade(): BooleanAreAllCompaniesUpgradeCompleted(): BooleanAreAllCompaniesProcessed(): BooleanGetCompletedCompanyCount(): IntegerGetCompanyStatusCounts(var PendingCount: Integer; var StartedCount: Integer; var CompletedCount: Integer; var FailedCount: Integer): Excludes the empty-name PerDatabase row so counts match the companies shown on the page.FilterPendingCompanies(var HybridCompanyStatus: Record "Hybrid Company Status")FilterFailedCompanies(var HybridCompanyStatus: Record "Hybrid Company Status")GetFirstPendingCompanyName(): Text[30]PerDatabaseStatusExists(): BooleanDeleteAllCompanyStatus()DeleteCompanyStatus(CompanyName: Text[30])
Plus 7 local procedures.
Calls
From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an Object::"Name" argument. Interface dispatch and calls through events are not counted, so the list is not complete.
- Codeunit 46862 “BC14 Migration Orchestrator” (1 call:
AfterCompanyMigrationCompleted → DispatchNextReadyCompany)
Called by
- Codeunit 46862 “BC14 Migration Orchestrator” (15 calls:
DispatchNextReadyCompany → FilterPendingCompanies,DispatchNextReadyCompany → TryFinalizeOverallStatus,DispatchNextReadyCompany → UpdateCompanyMessage, …) - Codeunit 46875 “BC14 Migration Runner” (7 calls:
ContinueCompanyMigration → AfterCompanyMigrationCompleted,ContinueMigrationForCompany → AcquireRerunSlot,ContinueMigrationForCompany → SetSummaryInProgress, …) - Page extension 46870 “BC14 Cloud Migration Mgmt Ext” (4 calls:
RerunFailedCompanies → FilterFailedCompanies,ResumeBC14UpgradeAction → GetCompanyStatusCounts,UpdateCompanyUpgradeStatus → GetCompanyStatusCounts, …) - Codeunit 46853 “BC14 Company Upgrade Task” (3 calls:
ExecuteCompanyUpgrade → AfterCompanyMigrationCompleted,ExecuteCompanyUpgrade → MarkCompanyCompleted,ExecuteCompanyUpgrade → MarkCompanyStarted) - Codeunit 46860 “BC14 Migration Failure Handler” (3 calls:
MarkUpgradeFailed → IsCompanyFailed,MarkUpgradeFailed → MarkCompanyFailed,OnRun → SetSummaryFailed) - Codeunit 46861 “BC14 Wizard” (2 calls:
CompanyOnAfterDelete → DeleteCompanyStatus,OnResetAllCloudData → DeleteAllCompanyStatus) - Codeunit 46864 “BC14 Historical Task Worker” (2 calls:
HandleHistoricalFailure → MarkCompanyFailed,OnRun → IsCompanyFailed)
Recent changes
- 2026-07-23 #9200 Cloud Migration bug fixes (BC14 reimplementation, custom mapping, OnPrem dev companies) (main, BC30, fix)
Ask your agent
Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: bcatlas_resolve_node(object_type: "codeunit", object_name: "BC14 Migration Status Mgr."), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.