This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class ConsoleEventListener : EventListener | |
| { | |
| protected override void OnEventSourceCreated(EventSource eventSource) | |
| { | |
| if (eventSource.Name.StartsWith("OpenTelemetry")) | |
| EnableEvents(eventSource, EventLevel.Error); | |
| } | |
| protected override void OnEventWritten(EventWrittenEventArgs eventData) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Diagnostics; | |
| using BenchmarkDotNet.Attributes; | |
| using OpenTelemetry; | |
| using OpenTelemetry.Trace; | |
| public class OpenTelemetryTests | |
| { | |
| private readonly Dictionary<string, string> _dictionary = new(); | |
| private readonly ActivitySource _source = new("DummyTest"); | |
| public OpenTelemetryTests() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DECLARE @HASHBYTES VARBINARY(128) = hashbytes('sha2_256', N'secret') | |
| SELECT cast(N'' as xml).value('xs:base64Binary(sql:variable("@HASHBYTES"))', 'varchar(128)'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Update-R53ForCurrentHost { | |
| param($zoneName, $subdomain) | |
| Import-Module AWSPowershell | |
| Write-Output "Updating R53 record for $subdomain.$zoneName" | |
| $publicHostname = Invoke-WebRequest ` | |
| -Uri http://169.254.169.254/latest/meta-data/public-hostname | |
| Write-Output "New HostName is:$publicHostname" |