D365 F&O - Restart PPAC UDE Environment

D365 F&O - Restart PPAC UDE Environment  

As developers working in the Unified Development Experience (UDE) for Dynamics 365 Finance and Operations, we often encounter situations where the environment becomes unresponsive or certain services stop working as expected. In traditional development environments, we could easily restart or stop services, but in the Unified Development Environment, those options are not directly available.

The Recommended Approach: Deploy Models to Restart UDE

While you can’t restart the environment directly, deploying models to the online environment effectively resets the system context and reloads the deployed components, which can resolve several runtime and accessibility issues.

Here’s how to do it:

In Visual Studio, navigate to: Extensions > Dynamics 365 > Deploy > Deploy Models to Online Environment.

Article content

In the Deploy Models dialog box, select the models you wish to deploy. Typically, this can be your active model or the specific model you were working on when the issue occurred.

Article content

Click Deploy to start the process.

Once the deployment starts, UDE will synchronize and redeploy the selected models. This refreshes the application context similar to restarting services and can often fix login or runtime errors.

When to Use This Method

Use the “Deploy Models to Online Environment” option when:

  • The environment becomes unresponsive.
  • You cannot sign in to the UDE.
  • Code changes appear not to take effect.
  • The debugger fails to attach, or breakpoints stop working.

In most cases, the deployment process restores normal functionality without requiring further administrative intervention.

Deploy a Unified Developer Environment (UDE) for D365 F&SCM

Deploying a Unified Developer Environment (UDE) for Dynamics 365 Finance & Supply Chain Management (F&SCM) is a game-changer for developers. It streamlines the development experience by integrating D365FO with the Power Platform, Dataverse, and Visual Studio, all within a local or cloud-hosted environment.

Here’s a step-by-step guide to help you get started:

🧰 Prerequisites

Before deploying UDE, make sure you have:

  • Visual Studio 2022 (Enterprise or Professional)

    • Include Modeling SDK and DGML Editor components

  • SQL Server Express or Developer Edition

  • Power Platform Tools for Visual Studio

    • Install via Extensions > Manage Extensions > Online > Search: Power Platform

  • Azure AD App Registration with valid secret key

  • Admin rights in Power Platform Admin Center

  • At least 20 GB of free disk space

  • Dataverse environment with ~1–1.5 GB available

🚀 Deployment Steps

1. Install PowerShell Modules

Launch PowerShell as Administrator and run:

powershell
Install-Module -Name Microsoft.PowerApps.Administration.PowerShell

Confirm any prompts to install dependencies.

2. Set Up Dataverse Environment

  • Go to

  • Create a new environment (type: Developer or Sandbox)

  • Assign System Administrator and System Customizer roles to your user

(OR)

2.1 Using Power Shell Script:

Step 1: 

Install-Module -Name Microsoft.PowerApps.Administration.PowerShell -Scope CurrentUser


Step 2: 

Import-Module -Name Microsoft.PowerApps.Administration.PowerShell
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
Add-PowerAppsAccount -Endpoint prod

 

Step 3:  

$jsonObject= @" 

  "PostProvisioningPackages": 
    [ 
      { 
        "applicationUniqueName": "msdyn_FinanceAndOperationsProvisioningAppAnchor", 
        "parameters": "DevToolsEnabled=true|DemoDataEnabled=True" 
      } 
    ] 

"@ | ConvertFrom-Json

 Step 4:

New-AdminPowerAppEnvironment -DisplayName "ude-dev01" -EnvironmentSku Sandbox -Templates "D365_FinOps_Finance" -TemplateMetadata $jsonObject -LocationName "europe" -ProvisionDatabase

 

3. Connect Visual Studio to Dataverse

  • Open Visual Studio → “Continue without code”

  • Go to Tools > Connect to Dataverse

  • Choose Deployment Type: Office 365

  • Authenticate manually (avoid “Sign in as current user” to prevent login errors)

  • Select your environment and solution (usually “Default”)

4. Download D365FO Assets

  • From the same menu, choose Download Dynamics 365 FinOps assets

  • This pulls metadata and components needed for development

🧪 Test Your Setup

Once everything is connected:

  • Try building a simple extension or customization

  • Use the integrated debugging and deployment tools

  • Confirm that changes sync with Dataverse and reflect in your Power Platform apps

D365 F&O X++ code Update_Recordset and SkipDataMethods still calling update method

D365 F&O X++ code Update_Recordset and SkipDataMethods still calling update method


It sounds like you're encountering an issue where the update_recordset statement in Dynamics 365 Finance & Operations (D365 F&O) X++ code is still calling the update method, even though you're using SkipDataMethods. This can be frustrating!

Here's a brief overview of what might be happening:

  1. update_recordset Statement: This statement is designed to update multiple records in one database trip, which improves performance by reducing communication between the application and the database.

  2. SkipDataMethods: This setting is used to skip certain methods, such as update, insert, and delete, to avoid performance issues.

However, if update_recordset is still calling the update method, it might be due to certain conditions or configurations that are causing the operation to fall back to record-by-record operations.

 

Answer: 

Use the below to resolve the issue:

myTable.skipEvents(true);  

D365 F&O Release Pipeline Step by Step Configuration Without ISV's

 

Step-by-Step Guide: Creating D365FO Build and Deploy Pipelines

Azure DevOps Build Pipeline

I will walk through the standard procedures for setting up a D365FO Azure DevOps build pipeline.

Microsoft References:

Before we begin, please refer to the following documentation for context:

Step 1:

 

Deploy the Build Server from LCS:

 



 

 

Login to Azure DevOps and install  Dynamics 365 Finance and Operation tools:

 

Install the «Dynamics 365 Finance and Operations Tools» extension

 



 

 

Step 2 :  Create personal access token (PAT)



Navigate to DevOps > User Settings > Personal Access Tokens. Scopes: Full Access, Expiration (choose the date as you wish, longer the better).

 

Step 3: Navigate to Azure DevOps  >> Pipeline

 



 

Step 4:  Clone the pipeline and name it as you wish (Example: Build Dev)

 



 

Step 5  Edit the Build Dev Pipeline:

 

Choose the Agent pool:

 



 

Step 6:  Provide the repo branch path on the server path column.

 


 

 

Step 7:  Modify the repo branch name if needed:



 

Rest of the pipelines are standard. We will proceed with the Release pipeline.

 

Steps to create a new release pipeline.

 

Step 1: Navigate to Azure DevOps >Pipeline > Release.

 



 

Step 2:  Click on the New , to create a new release pipeline



 

Step 3 : Select Empty Job

 



Step 4:  Rename the Release Pipeline, Click  “Add an artifact”



Step 5:  Select the Project Name & Source Build Pipeline

 



Step 6:   Add the task in Stages.

 

 


 

Step 7:   In total we need 3 stages as shown below.

 



 

Ø  Select the Agent pool


 

Stage 1 :  Select “Install MSAL.PS” to enable authentication. 



 

Stage 2:  Select “Dynamics Lifecycle Services (LCS) Asset Upload”



 

Fill the details as shown below.



 

Click on +New on the LCS Connection



 

Fill the details for the LCS connection.



 

File to upload:  Click on the three dots and select the AXDeployableRuntime.

To automate the process and to select the latest build generated by the pipeline use the _$(Build.BuildNumber).zip  as shown in the below command

 



 

$(System.DefaultWorkingDirectory)/_Build Dev/Packages/AXDeployableRuntime_XXXXXXX_$(Build.BuildNumber).zip

 

LCS Asset Name: Dev branch -$(Release.ReleaseName)

 

LCS Asset Descritpion: Dev branch - $(Release.ReleaseName) - $(Build.BuildNumber)

 

Enter the name on the Reference name: “OutputVariableName”

 



 

Stage 3: Select “Dynamics Lifecycle Services (LCS) Asset Deployment”



 

Fill the mandatory fields on the stage 3:


 

LCS Environment Id :  Fill the details of the environment you plan to deploy. The Environment Id details found in LCS.

LCS File Asset Id: $(OutputVariableName.FileAssetId)



You can setup the Gated Check-In:










D365 F&O - Restart PPAC UDE Environment

D365 F&O - Restart PPAC UDE Environment    As developers working in the Unified Development Experience (UDE) for Dynamics 365 Finance...