web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Error When Installing ...
Power Apps
Unanswered

Error When Installing Plugin Profiler and when Profiling Plugin (PRT 9.1.0.167)

(0) ShareShare
ReportReport
Posted on by 18

I'm using the latest Plugin Registration Tool (PRT), 9.1.0.167, installed through the PAC CLI process. Dataverse database version is 9.2.22111.00206.

 

When installing the Profiler I get the following error:

Unhandled Exception: System.InvalidCastException: Unable to cast object of type 'Microsoft.Xrm.Sdk.Entity' to type 'CrmSdk.PluginType'.

   at Microsoft.Crm.Tools.Libraries.OrganizationHelper.InstallProfiler(CrmOrganization org, String prtPath)

   at Microsoft.Crm.Tools.PluginRegistration.OrganizationControlViewModel.<>c__DisplayClass302_0.<InstallProfiler_Clicked>b__2(Object o, DoWorkEventArgs e)

 

But the profiler solution is installed and the PRT will allow you to enable profiling.

 

The plugin runs successfully. Then we turn on profiling for the plugin step and when executing the exact same transaction receive the follow error:

nicknow_0-1672955924014.png

 

When looking at the plugin trace we can see there is an infinite loop occurring in the profiler code that is eventually errors out:

nicknow_1-1672955996837.png

 

Here is the error message content from the first trace (Depth = 1):

Exception type: System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]
Message: Unable to persist the profile.Detail:
<OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts">
<ActivityId>0107fa88-e11c-42ee-92ad-bbda48862d72</ActivityId>
<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:int">3</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>SubErrorCode</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:int">-2146233088</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>Plugin.ExceptionFromPluginExecute</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">PluginProfiler.Plugins.ProfilerPlugin</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>Plugin.ExceptionRetriable</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:boolean">false</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>Plugin.ExceptionSource</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">PluginExecution</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>Plugin.OriginalException</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">PluginExecution</d2p1:value>
</KeyValuePairOfstringanyType>
<KeyValuePairOfstringanyType>
<d2p1:key>Plugin.PluginTrace</d2p1:key>
<d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">Getting PostUpdateImage
Getting afsdc_response from preMessageImage
Post - afsdc_response equals Yes
Unexpected Exception occurred in Profiler while persisting the profile:
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=9.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.
&lt;OrganizationServiceFault xmlns="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;ActivityId&gt;07d7adb0-f7fd-42c8-8ade-a01a1fa437bd&lt;/ActivityId&gt;&lt;ErrorCode&gt;-2146893812&lt;/ErrorCode&gt;&lt;ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic"&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionSourceKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;Api/PostPipeline&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiSourceActivityKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"/&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionOwnerKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;OwnershipNotFoundInExceptionOwnerSettings&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiOriginalExceptionKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;Microsoft.Crm.CrmException: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&amp;#xD;
at Microsoft.Crm.BusinessEntities.ExecutionContext.ThrowIfInvalidPluginTransaction(Int32 countThreshold)&amp;#xD;
at Microsoft.Crm.BusinessEntities.ExecutionContext.CommitTransaction(ProcessDependenciesOption option, FlushCacheOption flushOption)&amp;#xD;
at Microsoft.Crm.Extensibility.MessageProcessor.Execute(PipelineExecutionContext context)&amp;#xD;
at Microsoft.Crm.Extensibility.InternalMessageDispatcher.&amp;lt;&amp;gt;c__DisplayClass5_0.&amp;lt;Execute&amp;gt;b__0()&amp;#xD;
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)&amp;#xD;
at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute(ILogger logger, XrmTelemetryActivityType activityType, Action action)&amp;#xD;
at Microsoft.Crm.Extensibility.ExternalMessageDispatcher.ExecuteInternal(IInProcessOrganizationServiceFactory serviceFactory, IPlatformMessageDispatcherFactory dispatcherFactory, Guid callerRegardingObjectId, Int32 invocationSource, Version endpointVersion, OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.DispatchRequest(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest, SdkResponseDescription responseDescription, SdkPerformanceCounterContext sdkPerformanceCounterContext)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequestRequestWithInstrumentation(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequestRequestWithInstrumentationOperation(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.&amp;lt;&amp;gt;c__DisplayClass22_0.&amp;lt;ExecuteRequest&amp;gt;b__0()&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiStepKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;00000000-0000-0000-0000-000000000000&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiDepthKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;2&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiActivityIdKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;07d7adb0-f7fd-42c8-8ade-a01a1fa437bd&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiPluginSolutionNameKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;System&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiStepSolutionNameKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;System&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionCategory&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;ClientError&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionMessageName&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;IsvTransactionCount&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionHttpStatusCode&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;400&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;/ErrorDetails&gt;&lt;HelpLink&gt;http://go.microsoft.com/fwlink/?LinkID=398563&amp;amp;error=Microsoft.Crm.CrmException%3a8009000c&amp;amp;client=platform&lt;/HelpLink&gt;&lt;Message&gt;ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&lt;/Message&gt;&lt;Timestamp&gt;2023-01-05T21:23:47&lt;/Timestamp&gt;&lt;ExceptionRetriable&gt;false&lt;/ExceptionRetriable&gt;&lt;ExceptionSource&gt;SdkClientError&lt;/ExceptionSource&gt;&lt;InnerFault i:nil="true"/&gt;&lt;OriginalException&gt;System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing. (Fault Detail is equal to Exception details: &amp;#xD;
ErrorCode: 0x8009000C&amp;#xD;
Message: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&amp;#xD;
TimeStamp: 2023-01-05T21:23:47.8013818Z&amp;#xD;
--&amp;#xD;
).&lt;/OriginalException&gt;&lt;TraceText i:nil="true"/&gt;&lt;/OrganizationServiceFault&gt;
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.&lt;&gt;c__DisplayClass16_1.&lt;ExecuteStreamingCallBack&gt;b__1(ExecuteRequest response)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.GrpcClientSendAndReceive(ExecuteResponse executeResponse, Func`2 isTerminalResponse)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.&lt;&gt;c__DisplayClass16_0.&lt;ExecuteStreamingCallBack&gt;b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.ExecuteStreamingCallBack(Func`2 callback, Func`2 isTerminalChunk, Func`2 HandleClientException)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationService.Execute(String operation, ByteString serializedRequest, Assembly proxyTypes, Object traceSettings)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.&lt;&gt;c__DisplayClass23_0.&lt;ExecuteInternal&gt;b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.ExecuteInternal(OrganizationRequest request)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.CreateInternal(Entity entity)
at PluginProfiler.Plugins.ServiceWrappers.OrganizationServiceWrapper.Create(Entity entity)
at PluginProfiler.Plugins.ProfilerBase`1.Execute(T operationContext, ProfilerPluginContext context, ProfilerPluginReport report, Object inputParameter)
</d2p1:value>
</KeyValuePairOfstringanyType>
</ErrorDetails>
<HelpLink i:nil="true" />
<Message>Unable to persist the profile.</Message>
<Timestamp>2023-01-05T21:23:47.8013818Z</Timestamp>
<ExceptionRetriable>false</ExceptionRetriable>
<ExceptionSource>PluginExecution</ExceptionSource>
<InnerFault i:nil="true" />
<OriginalException>PluginExecution</OriginalException>
<TraceText>
Getting PostUpdateImage
Getting afsdc_response from preMessageImage
Post - afsdc_response equals Yes
Unexpected Exception occurred in Profiler while persisting the profile:
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=9.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.
&lt;OrganizationServiceFault xmlns="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;ActivityId&gt;07d7adb0-f7fd-42c8-8ade-a01a1fa437bd&lt;/ActivityId&gt;&lt;ErrorCode&gt;-2146893812&lt;/ErrorCode&gt;&lt;ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic"&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionSourceKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;Api/PostPipeline&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiSourceActivityKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"/&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionOwnerKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;OwnershipNotFoundInExceptionOwnerSettings&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiOriginalExceptionKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;Microsoft.Crm.CrmException: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&amp;#xD;
at Microsoft.Crm.BusinessEntities.ExecutionContext.ThrowIfInvalidPluginTransaction(Int32 countThreshold)&amp;#xD;
at Microsoft.Crm.BusinessEntities.ExecutionContext.CommitTransaction(ProcessDependenciesOption option, FlushCacheOption flushOption)&amp;#xD;
at Microsoft.Crm.Extensibility.MessageProcessor.Execute(PipelineExecutionContext context)&amp;#xD;
at Microsoft.Crm.Extensibility.InternalMessageDispatcher.&amp;lt;&amp;gt;c__DisplayClass5_0.&amp;lt;Execute&amp;gt;b__0()&amp;#xD;
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)&amp;#xD;
at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute(ILogger logger, XrmTelemetryActivityType activityType, Action action)&amp;#xD;
at Microsoft.Crm.Extensibility.ExternalMessageDispatcher.ExecuteInternal(IInProcessOrganizationServiceFactory serviceFactory, IPlatformMessageDispatcherFactory dispatcherFactory, Guid callerRegardingObjectId, Int32 invocationSource, Version endpointVersion, OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.DispatchRequest(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest, SdkResponseDescription responseDescription, SdkPerformanceCounterContext sdkPerformanceCounterContext)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequestRequestWithInstrumentation(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequestRequestWithInstrumentationOperation(OrganizationRequest request, OrganizationInternalRequest organizationInternalRequest)&amp;#xD;
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.&amp;lt;&amp;gt;c__DisplayClass22_0.&amp;lt;ExecuteRequest&amp;gt;b__0()&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiStepKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;00000000-0000-0000-0000-000000000000&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiDepthKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;2&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiActivityIdKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;07d7adb0-f7fd-42c8-8ade-a01a1fa437bd&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiPluginSolutionNameKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;System&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiStepSolutionNameKey&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;System&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionCategory&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;ClientError&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionMessageName&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;IsvTransactionCount&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;KeyValuePairOfstringanyType&gt;&lt;a:key&gt;ApiExceptionHttpStatusCode&lt;/a:key&gt;&lt;a:value i:type="b:string" xmlns:b="http://www.w3.org/2001/XMLSchema"&gt;400&lt;/a:value&gt;&lt;/KeyValuePairOfstringanyType&gt;&lt;/ErrorDetails&gt;&lt;HelpLink&gt;http://go.microsoft.com/fwlink/?LinkID=398563&amp;amp;error=Microsoft.Crm.CrmException%3a8009000c&amp;amp;client=platform&lt;/HelpLink&gt;&lt;Message&gt;ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&lt;/Message&gt;&lt;Timestamp&gt;2023-01-05T21:23:47&lt;/Timestamp&gt;&lt;ExceptionRetriable&gt;false&lt;/ExceptionRetriable&gt;&lt;ExceptionSource&gt;SdkClientError&lt;/ExceptionSource&gt;&lt;InnerFault i:nil="true"/&gt;&lt;OriginalException&gt;System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing. (Fault Detail is equal to Exception details: &amp;#xD;
ErrorCode: 0x8009000C&amp;#xD;
Message: ISV code reduced the open transaction count. Custom plug-ins should not catch exceptions from OrganizationService calls and continue processing.&amp;#xD;
TimeStamp: 2023-01-05T21:23:47.8013818Z&amp;#xD;
--&amp;#xD;
).&lt;/OriginalException&gt;&lt;TraceText i:nil="true"/&gt;&lt;/OrganizationServiceFault&gt;
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.&lt;&gt;c__DisplayClass16_1.&lt;ExecuteStreamingCallBack&gt;b__1(ExecuteRequest response)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.GrpcClientSendAndReceive(ExecuteResponse executeResponse, Func`2 isTerminalResponse)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.&lt;&gt;c__DisplayClass16_0.&lt;ExecuteStreamingCallBack&gt;b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)
at Microsoft.CDSRuntime.SandboxWorker.SandboxCallbackService.ExecuteStreamingCallBack(Func`2 callback, Func`2 isTerminalChunk, Func`2 HandleClientException)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationService.Execute(String operation, ByteString serializedRequest, Assembly proxyTypes, Object traceSettings)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.&lt;&gt;c__DisplayClass23_0.&lt;ExecuteInternal&gt;b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.ExecuteInternal(OrganizationRequest request)
at Microsoft.CDSRuntime.SandboxWorker.SandboxOrganizationServiceWrapper.CreateInternal(Entity entity)
at PluginProfiler.Plugins.ServiceWrappers.OrganizationServiceWrapper.Create(Entity entity)
at PluginProfiler.Plugins.ProfilerBase`1.Execute(T operationContext, ProfilerPluginContext context, ProfilerPluginReport report, Object inputParameter)

</TraceText>
</OrganizationServiceFault>

 

This only occurs when the plugin attempts to execute an UpdateRequest. If I comment out that line of code the plugin runs to completion without error. And if I turn off profiling then the plugin always runs successfully.

I have the same question (0)
  • Joeri Stroy Profile Picture
    49 on at

    This error usually occurs when the plugin you are trying to profile causes an infinite execution loop, meaning it is constantly retriggering itself, or when the profiled plugin triggers another plugin that throws an exception deeper down the execution pipeline.

     

    The fact that it doesn't fail when you comment out the update line also supports this theory. 

     

    I would look in that direction.

     

    Add some tracing to your code an see what gets written to the plugin trace log. 

  • nicknow Profile Picture
    18 on at

    The plugin code isn't creating an infinite loop. Filtering is applied on the Update step to ensure it won't trigger twice. Additionally, if we turn off profiling the plugin runs successfully without error. It's only when the profiler is wrapping the plugin execution that the error occurs.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Nick,
    could you find a solution? 
    I got the same error message.

     

    Best regards

  • Atilio Profile Picture
    2 on at

    Hi Teams, 

     

    Somebody know how i can fix it?

     

    i got the same error :'(

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 541

#2
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 289

Last 30 days Overall leaderboard