Skip to content

Commit

Permalink
Mark internal classes sealed (#37724)
Browse files Browse the repository at this point in the history
* Mark internal classes sealed

* exporters
  • Loading branch information
vishweshbankwar authored Jul 19, 2023
1 parent c940870 commit 84803ca
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter
{
internal class AzureMonitorLogExporter : BaseExporter<LogRecord>
internal sealed class AzureMonitorLogExporter : BaseExporter<LogRecord>
{
private readonly ITransmitter _transmitter;
private readonly string _instrumentationKey;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter
{
internal class AzureMonitorMetricExporter : BaseExporter<Metric>
internal sealed class AzureMonitorMetricExporter : BaseExporter<Metric>
{
private readonly ITransmitter _transmitter;
private readonly string _instrumentationKey;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter
{
internal class AzureMonitorTraceExporter : BaseExporter<Activity>
internal sealed class AzureMonitorTraceExporter : BaseExporter<Activity>
{
private readonly ITransmitter _transmitter;
private readonly string _instrumentationKey;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals;

internal class AksResourceProcessor
internal sealed class AksResourceProcessor
{
private static readonly Dictionary<string, Action<AksResourceProcessor, string>> s_propertySetters = new(7)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace Azure.Monitor.OpenTelemetry.Exporter.Internals;
/// Sample configurable for OpenTelemetry exporters for compatibility
/// with Application Insight SDKs.
/// </summary>
internal class ApplicationInsightsSampler : Sampler
internal sealed class ApplicationInsightsSampler : Sampler
{
private static readonly SamplingResult RecordOnlySamplingResult = new(SamplingDecision.RecordOnly);
private readonly SamplingResult recordAndSampleSamplingResult;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class AzureMonitorResource
internal sealed class AzureMonitorResource
{
internal string? RoleName { get; set; }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class LogsHelper
internal static class LogsHelper
{
private const int Version = 2;
private static readonly ConcurrentDictionary<int, string> s_depthCache = new ConcurrentDictionary<int, string>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class MetricHelper
internal static class MetricHelper
{
private const int Version = 2;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class NDJsonWriter : IDisposable
internal sealed class NDJsonWriter : IDisposable
{
private static readonly byte[] s_separator = { (byte)'\n' };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class ResponseStatusCodes
internal static class ResponseStatusCodes
{
public const int Success = 200;
public const int PartialSuccess = 206;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class StandardMetricConstants
internal static class StandardMetricConstants
{
internal const string StandardMetricMeterName = "StandardMetricMeter";
internal const string RequestDurationInstrumentName = "RequestDurationStandardMetric";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
{
internal class StandardMetricsExtractionProcessor : BaseProcessor<Activity>
internal sealed class StandardMetricsExtractionProcessor : BaseProcessor<Activity>
{
private bool _disposed;
private AzureMonitorResource? _resource;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace Azure.Monitor.OpenTelemetry.Exporter.Internals
/// This factory should ensure that only one instance of the Transmitter is created for
/// any unique connection string.
/// </summary>
internal class TransmitterFactory
internal sealed class TransmitterFactory
{
public static readonly TransmitterFactory Instance = new();
public static readonly IPlatform platform = new DefaultPlatform();
Expand Down

0 comments on commit 84803ca

Please sign in to comment.