public SimpleTelemetryProvider() { if (SimpleTelemetryProvider.bEnableTelemetryProvider) { try { proxy = new JSONClient(HostURL); // Ping the server if it faild null the provider var response = proxy.Exec(proxy.CreateRequest("request_id")); SessionID = (new JavaScriptSerializer()).Deserialize <SessionResponse>(response).result; } catch (Exception Exception) { Log.TraceError("SimpleTelemetryProvider Exception: " + Exception); proxy = null; SessionID = null; } } }
public SimpleTelemetryProvider() { if (SimpleTelemetryProvider.bEnableTelemetryProvider) { try { proxy = new JSONClient(HostURL); // Ping the server if it faild null the provider var response = proxy.Exec(proxy.CreateRequest("request_id")); SessionID = (new JavaScriptSerializer()).Deserialize<SessionResponse>(response).result; // Create the request request = proxy.CreateRequest(SimpleTelemetryProvider.MethodName, SessionID); } catch (Exception Exception) { Log.TraceError("SimpleTelemetryProvider Exception: " + Exception); proxy = null; SessionID = null; } } }