Salesforce Platform · DevOps Center

Deploy Destructive Metadata Changes

MeshMesh removes metadata an org no longer needs, such as flows, demo apps, objects, permission sets and Lightning pages. The user ends up with a cleaner org, with any blocking dependencies either cleared or flagged.

41 tasks
Method

How MeshMesh does it

  1. Clears references before deleting. In one case a flow was used on a record page, so MeshMesh removed the reference from the page metadata first and then deleted the flow.
  2. Picks the removal route for each component. It deleted some flows through the browser UI. It archived survey flows and then removed them with a destructive metadata deployment.
  3. Removes components in dependency order, including OmniScripts, DataRaptors, Apex classes, child objects, permission sets, apps and Lightning pages.
  4. Runs a data cleanup before the metadata cleanup, keeping Knowledge content in place. It then deactivates agents and flows, disables a portal user, takes sites offline and hides standard apps.
  5. Confirms the result. It runs a Tooling API query to show nothing is left.
  6. Flags what it cannot remove. For example, a parent object blocked by a soft-deleted lookup field needs a manual erase in Setup. Before the main destructive deploy, it asks for explicit approval.

Next capability: Deploy Metadata Across Orgs.