When you need a debugging for your CRM 2011/2013 Plugin, you can do the debugging using 2 methods :
1. Using “Debug –> Attach to Process” then attach to w3wp.exe for OnPremise Plugin
2. Using Plugin Profiler
For some messages, PluginProfiler cannot be used to debug.
But, well here I will not explain you how to use PluginProfiler debugger, but I give you resolution to fix pluginprofiler error.
Now, I am trying to debug using Plugin Profiler, but instead of having a good Profiler when I trigger a plugin to do download error log, even I this following error message :
Then I Download log file :
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: System.Security.SecurityException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #D42EB3A1Detail: <OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts"> <ErrorCode>-2147220970</ErrorCode> <ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" /> <Message>System.Security.SecurityException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #D42EB3A1</Message> <Timestamp>2014-05-04T07:31:17.7584456Z</Timestamp> <InnerFault i:nil="true" /> <TraceText> [PluginProfiler.Plugins: PluginProfiler.Plugins.ProfilerPlugin] [d69ec10c-5ed3-e311-940f-001cc4eecdd6: TFP.Xrm.Konica.PluginLogic.AccountPluginPreUpdate: Update of account (Profiler)] </TraceText> </OrganizationServiceFault> |
Then I try to debug my plugin using that profile :
Unhandled Exception: System.ArgumentException: Unable to parse the OrganizationServiceFault. Parameter name: serializedReport at PluginProfiler.Library.ProfilerUtility.ExtractReport(String serializedReport) at PluginProfiler.Library.ProfilerUtility.DeserializeProfilerReport(String assemblyFilePath, String logFilePath) at PluginProfiler.Library.ProfilerExecutionUtility.RetrieveReport(String logFilePath) at Microsoft.Crm.Tools.PluginRegistration.OrganizationHelper.ParseReportOrShowError(IWin32Window owner, FileBrowserControl profilePathControl, Boolean requireReportParse, ProfilerPluginReport& report) Inner Exception: System.InvalidOperationException: Message does not contain a serialized value. at PluginProfiler.Library.ProfilerUtility.ExtractReportFromFault(OrganizationServiceFault fault) at PluginProfiler.Library.ProfilerUtility.ExtractReport(String serializedReport) |
I tried and searching and I was tired and frustated about this, then I tried using my first method debugging, but finally I try again using older SDK, especially for CRM 2011 SDK that I have.
I tried some SDK, and then try this SDK and using this Plugin Registration Tool inside this folder :
“..\SDK\tools\pluginregistration\bin\Debug”
In newest CRM SDK version, you will not longer see pluginregistration folder inside tools folder, but you will find in the bin folder.
Yes, I try to install my profiler using that SDK and that.
I can have this Profile :
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Download the details and load with Plug-in Profiler. |7R1dc+I48q9QPGzdPRgbDMFhCVuzk8wttTsDFTJXW/tyJcttoosteWU5CfvrV7IN4cMBw0wM0ZIHgmS11OputVr qbtz/6TkMao/AY8LoVb3ZsOo1oJh5hE6v6l/vPhlOvfbToH8LEeOiJhvTuEeu6vdCRD3TfHp6ajzZDcanZsuymubvn3 +b4HsIkUFoLBDFUB/0PzLqk2nCkZBj1EiPkuCqLngCdTN9GMvvWDB+nTcZ0s8kCEgMmFEvHlh9c3ej5X5unjFEO8a aCMTFHQlh0LKabcPqGFb7zur22navaTda3WbL7tp/rIz8AqI6EvAsBj8E4sdSBPxhKn5UjcdBMiX05hlwohDM+zmEr PMef05iQiGOv1Iihp6qdTzsOuDZhuNddgywm03DsVzHkB11Op7ValtWS0Gam6Cq+iPjHIKMxmklvrjoetAEo4svW kYb4aaBZNfGBcKtpo2R27500/42IFXttWTFvSo00zaLoioN5cBEtqfTrzHwDKaNXOx0ZPe7sC8CzjqNEjFGHIUgJFdy 2qIFbeOUkHEjJJizmPmigVloPvNQkrrZVAwXHGER13NIdwPSQwLhvNmcR23T6pqTWSwgbHxk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ihJE2t8cHeceh9cwHbN7MXfgz+Bg==|Detail: <OrganizationServiceFault xmlns:i=http://www.w3.org/2001/XMLSchema-instance xmlns="http://schemas.microsoft.com/xrm/2011/Contracts"> <ErrorCode>-2147220891</ErrorCode> <ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic"> <KeyValuePairOfstringanyType> <d2p1:key>OperationStatus</d2p1:key> <d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">0</d2p1:value> </KeyValuePairOfstringanyType> <KeyValuePairOfstringanyType> <d2p1:key>SubErrorCode</d2p1:key> <d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">-2146233088</d2p1:value> </KeyValuePairOfstringanyType> </ErrorDetails> <Message>Download the details and load with Plug-in Profiler. |7R1dc+I48q9QPGzdPRgbDMFhCVuzk8wttTsDFTJXW/tyJcttoosteWU5CfvrV7IN4cMBw0wM0ZIHgmS11OputVr qbtz/6TkMao/AY8LoVb3ZsOo1oJh5hE6v6l/vPhlOvfbToH8LEeOiJhvTuEeu6vdCRD3TfHp6ajzZDcanZsuymubvn3 +b4HsIkUFoLBDFUB/0PzLqk2nCkZBj1EiPkuCqLngCdTN9GMvvWDB+nTcZ0s8kCEgMmFEvHlh9c3ej5X5unjFEO8a aCMTFHQlh0LKabcPqGFb7zur22navaTda3WbL7tp/rIz8AqI6EvAsBj8E4sdSBPxhKn5UjcdBMiX05hlwohDM+zmEr PMef05iQiGOv1Iihp6qdTzsOuDZhuNddgywm03DsVzHkB11Op7ValtWS0Gam6Cq+iPjHIKMxmklvrjoetAEo4svW kYb4aaBZNfGBcKtpo2R27500/42IFXttWTFvSo00zaLoioN5cBEtqfTrzHwDKaNXOx0ZPe7sC8CzjqNEjFGHIUgJFdy 2qIFbeOUkHEjJJizmPmigVloPvNQkrrZVAwXHGER13NIdwPSQwLhvNmcR23T6pqTWSwgbHxkQQBYkSFu/AcocII X7EK9X2H2XxQkM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g==|</Message> <Timestamp>2014-05-04T07:43:13.3182314Z</Timestamp> <InnerFault i:nil="true" /> <TraceText> [PluginProfiler.Plugins: PluginProfiler.Plugins.ProfilerPlugin] [c0bd8b04-5dd3-e311-80bb-00155d02400c: TFP.Xrm.Konica.PluginLogic.AccountPluginPreCreate: Create of account (Profiler)] </TraceText> </OrganizationServiceFault> |
I just try to view my profile using that downloaded log file error.
From here, I can see my input arguments and also I can do debugging as usual.
Okay, here is the final resolutions I can do :
ERROR :
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: System.Security.SecurityException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #D42EB3A1Detail: <OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts"> <ErrorCode>-2147220970</ErrorCode> <ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" /> <Message>System.Security.SecurityException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #D42EB3A1</Message> <Timestamp>2014-05-04T07:31:17.7584456Z</Timestamp> <InnerFault i:nil="true" /> <TraceText> [PluginProfiler.Plugins: PluginProfiler.Plugins.ProfilerPlugin] [d69ec10c-5ed3-e311-940f-001cc4eecdd6: TFP.Xrm.Konica.PluginLogic.AccountPluginPreUpdate: Update of account (Profiler)] </TraceText> </OrganizationServiceFault> |
Problem in PluginProfiler.Solution file
RESOLUTIONS :
1. Using CRM 2011 Plugin Registration older SDK, this is to ease you, please download this :
PluginRegistration to Fix Plugin Profiler Error
or using this one
PluginRegistration to Fix Plugin profiler Error SDK CRM 2011 - Bin Only
2. Using CRM 2013 Plugin Registration tool, but using the PluginProfiler.Solution from CRM 2011
Well, if you still insist to using CRM 2013 Tool, here you can do these steps.
This is can be tricky, because those two files have different format.
CRM 2013 SDK :
CRM 2011 SDK
So you have to combine that and create new .zip file.
Okay, again I would like to make it easier for you, just download this PluginProfiler.solution
PluginProfiler.SolutionFixCombined
and then copy paste to your CRM 2013 SDK bin folder, don’t forget to backup your old .zip file.
Then as usual go to your Plugin Registration Tool and Install Profiler.
(If you don’t combine the file and just copy file from 2011 to 2013, which is there is no web resources folder, then when you install the Profiler you will get error)
And you can see after that you will be able to see your Plugin Profile
Test this by creating a new Account to trigger plugin
Look, now I can debug my Plugin :)
So, you can download these files :
CRM 2011 Plugin Registration Tool SDK - Bin Only Fix Plugin Profiler
CRM 2013 Plugin Registration Tool SDK - Fix Plugin Profiler
Hope it helps!
No comments:
Post a Comment