Start Transitioning your Dynamics 365 Client Applications to use Dataverse Client

Hi Folks,

This blog post deals about what you need to do for your client applications in specific to use Dataverse Client API instead of existing CrmServiceClient(Core Assemblies) API.

Below were 3 reasons cited by Microsoft and why we need to just be aware of this move.

1.Cross Platform Application Support: With the introduction of Microsoft.PowerPlatform.Dataverse.Client, the new Dataverse Service Client supports Cross Platform Support.

2. MSAL Authentication: New Dataverse ServiceClient API uses MSAL while our older CrmServiceClient API uses ADAL. ADAL.Net is no longer supported.

3. Performance and functional benefits: We can have one authentication handler per web service connection instead of just one per process. The Dataverse Service Client class supports a smaller interface surface, inline authentication by instance, and Microsoft.Extensions.Logging.ILogger.

What’s the impact?

  • Plug-ins or custom workflow activities – no changes
  • New or existing online applications – changes are needed but not immediately…
  • On-premises applications – this article is not for you, yet

So, meaning it impacts Online Client applications only. While you really don’t need to worry much about this the class member signatures of ServiceClient and CrmServiceClient are the same, except for the class names themselves being slightly different. Application code should not need any significant changes.

As of now, no changes to your code are required, but it is better to keep in mind that in the future the CRM 2011 Service End Point would be deprecated, and this change would be made mandatory.

So, what should you do to incorporate this change?

Use the following assemblies from Nuget instead of CrmSdk.CoreAssemblies

Add the below using statement to use Microsoft.PowerPlatform.Dataverse.Client

Use ServiceClient instead of CrmServiceClient, ServiceClient would return your OrganizationService.

Instead of

Be strategic to minimize the impact to your apps.

Cheers,

PMDY

Unable to profile Custom Workflow using Profiler – Quick Fix

Hi Folks,

I am a big fan of Power Automate…but this post is not about flows but features about Custom Workflow in Dynamics 365 CE.

Did you ever come across this problem where you were not able to debug custom workflow extension. I had come across this and this blog post is all about it…I successfully registered my Custom workflow, but it is not triggering at all.

So, I need to debug it to see what the exact issue was…as I am encounter this error.

Error message says Duplicate workflow activity group name: ‘EcellorsDemo.Cases(1.0.0.0) (Profiled)‘. So, I tried to check my code, plugin steps and any activated plugins but couldn’t find any duplicates.

Usually while debugging your custom workflow using profiler, your workflow will go into draft mode and another copy of the same workflow gets created with name of (Profiled) attached to the name. However, in my case, I didn’t see the same behavior and at the same time, I was unable to use Profiler after the first profiling session and it gave me error shown above.

In order to resolve, this just delete the Plugin Assemblies which could find in the default solution like highlighted below…

Once you have deleted this, try to debug the custom workflow and voila!!!

Hope this helps someone troubleshooting Custom workflow…!

Cheers,

PMDY