// Token: 0x06001BD4 RID: 7124 RVA: 0x00077F58 File Offset: 0x00076158 private void WriterProc(object o) { ExTraceGlobals.ClusterTracer.TraceDebug((long)this.GetHashCode(), "ClusterBatchWriter.WriterProc entered."); try { if (!DagHelper.IsLocalNodeClustered()) { ClusterBatchWriter.Tracer.Information(0L, "The local machine is not clustered. Skipping cluster batch writer proc."); return; } } catch (ExClusTransientException arg) { ClusterBatchWriter.Tracer.Information <ExClusTransientException>(0L, "ClusterBatchWriter.WriterProc failed to determine clustering: {0}", arg); return; } lock (this.s_lock) { if (this.m_fRunning) { ExTraceGlobals.ClusterTracer.TraceDebug((long)this.GetHashCode(), "ClusterBatchWriter WriterProc bailing as another thread is running."); return; } this.m_fRunning = true; } try { Dictionary <string, string> clusdbUpdates; lock (this.s_lock) { ExTraceGlobals.ClusterTracer.TraceDebug <int>((long)this.GetHashCode(), "ClusterBatchWriter m_clusdbUpdates.Count={0}.", this.m_clusdbUpdates.Count); clusdbUpdates = this.m_clusdbUpdates; this.m_clusdbUpdates = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase); } bool flag3 = this.SendUpdatesAndCheckIfLocalUpdateRequired(clusdbUpdates); if (flag3) { ActiveManagerServerPerfmon.LastLogLocalClusterBatchUpdatesAttempted.Increment(); if (!this.UpdateClusdb(clusdbUpdates)) { ActiveManagerServerPerfmon.LastLogLocalClusterBatchUpdatesFailed.Increment(); lock (this.s_lock) { foreach (string key in clusdbUpdates.Keys) { if (!this.m_clusdbUpdates.ContainsKey(key)) { this.m_clusdbUpdates[key] = clusdbUpdates[key]; } } ExTraceGlobals.ClusterTracer.TraceDebug <int>((long)this.GetHashCode(), "ClusterBatchWriter UpdateClusdb failed. m_clusdbUpdates.Count={0}.", this.m_clusdbUpdates.Count); } } } } finally { lock (this.s_lock) { this.m_fRunning = false; } } ExTraceGlobals.ClusterTracer.TraceDebug((long)this.GetHashCode(), "ClusterBatchWriter.WriterProc completed."); }
public static bool IsLocalNodeClustered() { return(DagHelper.IsLocalNodeClustered()); }