예제 #1
0
        public static void LogAnalyzerCrashCount(DiagnosticAnalyzer analyzer, Exception ex, LogAggregator logAggregator, ProjectId projectId)
        {
            if (logAggregator == null || analyzer == null || ex == null || ex is OperationCanceledException)
            {
                return;
            }

            // TODO: once we create description manager, pass that into here.
            bool telemetry = DiagnosticAnalyzerLogger.AllowsTelemetry(null, analyzer, projectId);
            var tuple = ValueTuple.Create(telemetry, analyzer.GetType(), ex.GetType());
            logAggregator.IncreaseCount(tuple);
        }
예제 #2
0
 internal static void LogTypeImportCompletionTimeout() =>
 s_logAggregator.IncreaseCount((int)ActionInfo.TypeImportCompletionTimeoutCount);
예제 #3
0
        public static void LogProcessProject(LogAggregator logAggregator, Guid projectId, bool processed)
        {
            if (processed)
            {
                logAggregator.IncreaseCount(ProcessProject);
            }
            else
            {
                logAggregator.IncreaseCount(ProcessProjectCancellation);
            }

            logAggregator.IncreaseCount(ValueTuple.Create(ProcessProject, projectId));
        }
예제 #4
0
        public static void LogProcessDocument(LogAggregator logAggregator, Guid documentId, bool processed)
        {
            if (processed)
            {
                logAggregator.IncreaseCount(ProcessDocument);
            }
            else
            {
                logAggregator.IncreaseCount(ProcessDocumentCancellation);
            }

            logAggregator.IncreaseCount(ValueTuple.Create(ProcessDocument, documentId));
        }
예제 #5
0
 public static void LogProcessOpenDocument(LogAggregator logAggregator, Guid documentId)
 {
     logAggregator.IncreaseCount(OpenDocument);
     logAggregator.IncreaseCount(ValueTuple.Create(OpenDocument, documentId));
 }
예제 #6
0
 public static void LogHigherPriority(LogAggregator logAggregator, Guid documentId)
 {
     logAggregator.IncreaseCount(HigherPriority);
     logAggregator.IncreaseCount(ValueTuple.Create(HigherPriority, documentId));
 }
예제 #7
0
 public static void LogWorkItemEnqueue(LogAggregator logAggregator, ProjectId projectId)
 {
     logAggregator.IncreaseCount(ProjectEnqueue);
 }
예제 #8
0
 public static void LogGlobalOperation(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(GlobalOperation);
 }
예제 #9
0
 public static void LogProcessProjectNotExist(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(ProjectNotExist);
 }
예제 #10
0
 public static void LogProcessDocumentNotExist(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(DocumentNotExist);
 }
 internal static void LogSessionWithTypeImportCompletionEnabled() =>
 s_logAggregator.IncreaseCount((int)ActionInfo.SessionWithTypeImportCompletionEnabled);
예제 #12
0
 internal static void LogTypeImportCompletionCacheMiss() =>
 s_logAggregator.IncreaseCount((int)ActionInfo.TypeImportCompletionCacheMissCount);
예제 #13
0
 internal static void LogCommitWithTargetTypeCompletionExperimentEnabled() =>
 s_logAggregator.IncreaseCount((int)ActionInfo.CommitWithTargetTypeCompletionExperimentEnabled);
예제 #14
0
 public static void UseExistingPartialProjectState()
 {
     s_logAggregator.IncreaseCount(nameof(UseExistingPartialProjectState));
 }
예제 #15
0
 public static void LogWorkspaceEvent(LogAggregator logAggregator, int kind)
 => logAggregator.IncreaseCount(kind);
예제 #16
0
 public static void LogWorkspaceEvent(LogAggregator logAggregator, int kind)
 {
     logAggregator.IncreaseCount(kind);
 }
예제 #17
0
 public static void LogGlobalOperation(LogAggregator logAggregator)
 => logAggregator.IncreaseCount(GlobalOperation);
예제 #18
0
 public static void LogActiveFileEnqueue(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(ActiveFileEnqueue);
 }
예제 #19
0
 public static void LogActiveFileEnqueue(LogAggregator logAggregator)
 => logAggregator.IncreaseCount(ActiveFileEnqueue);
예제 #20
0
        public static void LogWorkItemEnqueue(
            LogAggregator logAggregator, string language, DocumentId documentId, InvocationReasons reasons, bool lowPriority, SyntaxPath activeMember, bool added)
        {
            logAggregator.IncreaseCount(language);
            logAggregator.IncreaseCount(added ? NewWorkItem : UpdateWorkItem);

            if (documentId != null)
            {
                logAggregator.IncreaseCount(activeMember == null ? TopLevel : MemberLevel);

                if (lowPriority)
                {
                    logAggregator.IncreaseCount(LowerPriority);
                    logAggregator.IncreaseCount(ValueTuple.Create(LowerPriority, documentId.Id));
                }
            }

            foreach (var reason in reasons)
            {
                logAggregator.IncreaseCount(reason);
            }
        }
예제 #21
0
 public static void LogWorkItemEnqueue(LogAggregator logAggregator, ProjectId _)
 => logAggregator.IncreaseCount(ProjectEnqueue);
예제 #22
0
 public static void LogResetStates(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(ResetStates);
 }
예제 #23
0
 public static void LogHigherPriority(LogAggregator logAggregator, Guid documentId)
 {
     logAggregator.IncreaseCount(HigherPriority);
     logAggregator.IncreaseCount(ValueTuple.Create(HigherPriority, documentId));
 }
예제 #24
0
 public static void LogProcessActiveFileDocument(LogAggregator logAggregator, Guid documentId, bool processed)
 {
     if (processed)
     {
         logAggregator.IncreaseCount(ActiveFileProcessDocument);
     }
     else
     {
         logAggregator.IncreaseCount(ActiveFileProcessDocumentCancellation);
     }
 }
예제 #25
0
 public static void LogResetStates(LogAggregator logAggregator)
 => logAggregator.IncreaseCount(ResetStates);
예제 #26
0
 public static void LogProcessDocumentNotExist(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(DocumentNotExist);
 }
예제 #27
0
 public static void LogProcessCloseDocument(LogAggregator logAggregator, Guid documentId)
 {
     logAggregator.IncreaseCount(CloseDocument);
     logAggregator.IncreaseCount(ValueTuple.Create(CloseDocument, documentId));
 }
예제 #28
0
 public static void LogProcessProjectNotExist(LogAggregator logAggregator)
 {
     logAggregator.IncreaseCount(ProjectNotExist);
 }
 internal static void LogChangeSignatureDialogLaunched() =>
 s_logAggregator.IncreaseCount((int)ActionInfo.ChangeSignatureDialogLaunched);