From 651c1d6a56f9e2482cdada18fce2914f7ab03a09 Mon Sep 17 00:00:00 2001 From: Denis-Cosmin Nutiu Date: Mon, 25 Nov 2019 11:40:17 +0200 Subject: [PATCH] Refactor SensorTelemetry to use builder method --- NucuCar.Sensors/Telemetry/SensorTelemetry.cs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/NucuCar.Sensors/Telemetry/SensorTelemetry.cs b/NucuCar.Sensors/Telemetry/SensorTelemetry.cs index 679043e..f440cdd 100644 --- a/NucuCar.Sensors/Telemetry/SensorTelemetry.cs +++ b/NucuCar.Sensors/Telemetry/SensorTelemetry.cs @@ -11,12 +11,8 @@ namespace NucuCar.Sensors.Telemetry { if (configuration.ServiceEnabled) { - Publisher = new TelemetryPublisherAzure(new TelemetryPublisherBuilderOptions() - { - ConnectionString = configuration.ConnectionString, - TelemetrySource = "NucuCar.Sensors", - Logger = logger - }); + Publisher = TelemetryPublisherAzure.CreateFromConnectionString(configuration.ConnectionString, + "NucuCar.Sensors", logger); } else {