Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Jonas Rapp rappen

🏠
Working from home
View GitHub Profile
@rappen
rappen / CanaryTracer.cs
Last active Sep 30, 2020
CanaryTracer - writes IExecutionContext to Plugin Trace Log
View CanaryTracer.cs
/* ***********************************************************
* CanaryTracer.cs
* Found at: https://jonasr.app/canary
* Created by: Jonas Rapp https://jonasr.app/
*
* Writes everything from an IExecutionContext to the Plugin Trace Log.
*
* Sample call:
* tracingservice.TraceContext(context,
* includeparentcontext,
View XRMOrgSvcExtensions.cs
using Microsoft.Crm.Sdk.Messages;
using Microsoft.Xrm.Sdk;
using Microsoft.Xrm.Sdk.Query;
using System.Xml;
namespace Rappen.Xrm.Extensions
{
public static class ServiceExtensions
{
/// <summary>
View XTBAppInsights.cs
/* ***********************************************************
* XTBAppInsights.cs
* Found at: https://gist.github.com/rappen/fbdbb644b3fffec1305b00a51b007fa6
* Created by: Jonas Rapp https://jonasr.app/
* Immensely inspired by: code from Jason Lattimer https://github.com/jlattimer/D365AppInsights
*
* Simplifies logging to Azure Application Insights from XrmToolBox tools.
*
* Sample from tool constructor:
* ai = new AppInsights("https://dc.services.visualstudio.com/v2/track", "[a guid that is the key to your appinsights resource]", Assembly.GetExecutingAssembly(), "[my custom tool name]");
You can’t perform that action at this time.