public void Dispose() { //Are we shutting down clean if so write 'nice shutdown' cookie if (DynamoModel.IsCrashing) { StabilityCookie.WriteCrashingShutdown(); } else { StabilityCookie.WriteCleanShutdown(); } // If the Analytics Client was initialized, shut it down. // Otherwise skip this step because it would cause an exception. if (Service.IsInitialized) { Service.ShutDown(); // Unregister the GATrackerFactory only after shutdown is recorded. // Unregister is required, so that the host app can re-start Analytics service. Service.Instance.Unregister(GATrackerFactory.Name); } if (null != heartbeat) { Heartbeat.DestroyInstance(); } heartbeat = null; if (null != logger) { logger.Dispose(); } logger = null; }
private void DestroyInternal() { //Are we shutting down clean if so write 'nice shutdown' cookie if (DynamoModel.IsCrashing) { StabilityCookie.WriteCrashingShutdown(); } else { StabilityCookie.WriteCleanShutdown(); } System.Diagnostics.Debug.WriteLine("Heartbeat Destory Internal called"); shutdownEvent.Set(); // Signal the shutdown event... // TODO: Temporary comment out this Join statement. It currently // causes Dynamo to go into a deadlock when it is shutdown for the // second time on Revit (that's when the HeartbeatThread is trying // to call 'GetStringRepOfWorkspaceSync' below (the method has no // chance of executing, and therefore, will never return due to the // main thread being held up here waiting for the heartbeat thread // to end). // // heartbeatThread.Join(); // ... wait for thread to end. heartbeatThread = null; }
public void Dispose() { //Are we shutting down clean if so write 'nice shutdown' cookie if (DynamoModel.IsCrashing) { StabilityCookie.WriteCrashingShutdown(); } else { StabilityCookie.WriteCleanShutdown(); } Service.ShutDown(); //Unregister the GATrackerFactory only after shutdown is recorded. //Unregister is required, so that the host app can re-start Analytics service. Service.Instance.Unregister(GATrackerFactory.Name); if (null != heartbeat) { Heartbeat.DestroyInstance(); } heartbeat = null; if (null != logger) { logger.Dispose(); } logger = null; }
public void Dispose() { //Are we shutting down clean if so write 'nice shutdown' cookie if (DynamoModel.IsCrashing) { StabilityCookie.WriteCrashingShutdown(); } else { StabilityCookie.WriteCleanShutdown(); } }
public void Dispose() { //Are we shutting down clean if so write 'nice shutdown' cookie if (DynamoModel.IsCrashing) { StabilityCookie.WriteCrashingShutdown(); } else { StabilityCookie.WriteCleanShutdown(); } if (null != heartbeat) { Heartbeat.DestroyInstance(); } heartbeat = null; if (null != logger) { logger.Dispose(); } logger = null; }