ILMerge / Dependent Assemblies in Plugin – System.IO.FileNotFoundException: Could not load file or assembly ‘System.Memory.Data’ – Dynamics 365 / Dataverse


Recently in one of our Plugins, which was using Azure.Storage.Blobs and Azure.Storage.Common libraries to move attachments from notes to Azure Blob Storage suddenly started throwing the below exception. The Plugin had been working fine and had been deployed long back to the production environment.

System.TypeInitializationException: The type initializer for ‘Azure.Response’ threw an exception. —> System.IO.FileNotFoundException: Could not load file or assembly ‘System.Memory.Data, Version=1.0.2.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51’ or one of its dependencies. The system cannot find the file specified.

We raised the Microsoft Support for it and were informed that the reason for this was there was a platform update over that particular weekend to stop loading the “System.Memory.Data” assembly on the plugin server. And as we hadn’t included that assembly in our package (ILMerge), we started getting the exception.

Also as per Microsoft Docs


So the quick fix at that time was to include (set Copy Local as True) for that System.Memory.Data along with Azure assemblies.

Also now we can look into using Plugin Package to package the dependent assemblies.

Hope it helps..

Advertisements

The plug-in execution failed because the Sandbox Worker process crashed. This is typically due to an error in the plug-in code – Dataverse / Dynamics 365


Recently we got the below exception for one of our plugins.

Message: The plug-in execution failed because the Sandbox Worker process crashed. This is typically due to an error in the plug-in code. Please refer to this document: https://go.microsoft.com/fwlink/?linkid=2189390
Microsoft.Xrm.RemotePlugin.Grpc.ExceptionHandlers.SandboxFabricWorkerCommunicationException: Error communicating with SandboxFabric Worker —> Grpc.Core.RpcException: Status(StatusCode=”DeadlineExceeded”, Detail=”Deadline Exceeded”

If we refer to Microsoft Documentation below seems to be the cause of the issue in our case.

In our scenario, we had a Plugin that was Asynchronous and it was triggered on the Post Update of Work Order Service task. The plugin will fetch all the attachments (to notes associated with inspection attachments > inspection response > work order service task). There were many Service Tasks having more than 20 attachments exceeding 100 mb size total.

We were doing bulk updates which triggered the plugin creating too many requests eventually leading to that error.

Get more details – Error “Sandbox Worker Process Crashed”

Also, check – https://cloudblogs.microsoft.com/dynamics365/it/2017/02/20/microsoft-dynamics-365-online-asynchronous-service-quotas/

Hope it helps..

Advertisements

Only notes are available in Offline mode. Please check your internet connection to view other timeline records – Dataverse / Dynamics 365


We were recently exploring the Dynamics 365 Field Service mobile app, we saw that for the users with a mobile offline profile configured – Add the user to an offline profile, when they go offline they will see the below message –

“Only Notes are available in offline mode. If you would like to view your other items, please reconnect to online mode when possible”. 

What it means is that if users go offline, only the Notes records (along with the attachment) will be available on the timelines. The users can also add/remove attachment in the offline mode. This capability was added as part of the 2019 Release Wave 2

Offline Supported Capabilities

Hope it helps..

Advertisements

Fixed – Duplicate records in Azure Synapse Link (Dataverse)


Recently for some of our Dataverse environments, we found duplicate records getting created (same GUID) for Notes and Work Order Incident tables in the corresponding CSV files.

Here we were using In place updateIn-place updates vs. append-only writes

This was causing the Power BI reports built on top of it to fail.

On raising the ticket, the Microsoft Support team mentioned that this is a known bug for certain regions, and they immediately ran the de-duplication scripts in the background which quickly fixed the issue for us. Also, they specified they will be deploying the fix for the issue in the coming days.

Hope it helps..

Advertisements

Fixed – System.InvalidOperationException: Message size exceeded when attempting to send response to sandbox. Message Size 123 Mb. Max Allowed 128974848 Mb (Dataverse / Dynamics 365 )


Recently we got the below exception for one of our plugins
Message: System.InvalidOperationException: Message size exceeded when attempting to send response to sandbox. Message Size 123 Mb. Max Allowed 128974848 Mb.

Below is the code where we were getting the error. We were retrieving the notes records associated with the inspection response/inspection attachments. (Dynamics 365 Field Service)

And if we had a total of all attachments to it more than 100 mb it was failing.

Below is the test Work Order Service Task record for which we were getting the error.

There were a couple of other attachments also to it making a total of more than 100 Mb.

Here to fix the error instead of fetching all the note details at once and then processing the notes attachments, we updated our logic to process the notes attachments one by one.

Hope it helps..

Advertisements

Block unmanaged customizations (preview) – Dataverse / Dynamics 365


We were recently trying out the new block unmanaged customizations feature introduced.

Now with more and more adoption of Managed Solutions, having this feature could help the administrators to manage and control the environment.

It is still in preview, with its sets of known limitations.

To see it in action, enable it from Environment >> [Environment] >> Settings >> Features

With this feature enabled, although we can create and export unmanaged solutions in the environment, we cannot

create a new table

Or create a new column or any other unmanaged solution component

Import an unmanaged solution –

Update a form (i.e. adding unmanaged changes to existing managed components)

On trying to update a Plugin Step –

Get full details here

Hope it helps..

Advertisements

Nishant Rana's Weblog

Everything related to Microsoft .NET Technology

Skip to content ↓