Пример #1
0
        public PostprocessorsInitializer(
            IPostprocessorsManager postprocessorsManager,
            IUserDefinedFormatsManager userDefinedFormatsManager,
            StateInspector.IPostprocessorsFactory stateInspectorPostprocessorsFactory,
            TimeSeries.IPostprocessorsFactory timeSeriesPostprocessorsFactory
            )
        {
            Func <string, UDF> findFormat = formatName =>
            {
                var ret = userDefinedFormatsManager.Items.FirstOrDefault(
                    f => f.CompanyName == "Google" && f.FormatName == formatName) as UDF;
                if (ret == null)
                {
                    throw new Exception(string.Format("Log format {0} is not registered in LogJoint", formatName));
                }
                return(ret);
            };

            this.chromeDebugLogFormat      = findFormat("Chrome debug log");
            this.webRtcInternalsDumpFormat = findFormat("Chrome WebRTC internals dump as log");

            this.chromeDebugLogMeta = new LogSourceMetadata(
                chromeDebugLogFormat,
                stateInspectorPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateChromeDebugPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.chromeDebugLogMeta);

            this.webRtcInternalsDumpMeta = new LogSourceMetadata(
                webRtcInternalsDumpFormat,
                stateInspectorPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.webRtcInternalsDumpMeta);
        }
Пример #2
0
        public PostprocessorsInitializer(
            IManager postprocessorsManager,
            IUserDefinedFormatsManager userDefinedFormatsManager,
            Timeline.IPostprocessorsFactory timelinePostprocessorsFactory
            )
        {
            IUserDefinedFactory findFormat(string company, string formatName)
            {
                var ret = userDefinedFormatsManager.Items.FirstOrDefault(
                    f => f.CompanyName == company && f.FormatName == formatName);

                if (ret == null)
                {
                    throw new Exception(string.Format("Log format {0} is not registered in LogJoint", formatName));
                }
                return(ret);
            }

            this.wiresharkPdmlFormat = findFormat("Wireshark", "pdml");

            this.wiresharkPdml = new LogSourceMetadata(
                wiresharkPdmlFormat,
                timelinePostprocessorsFactory.CreateWiresharkDpmlPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.wiresharkPdml);
        }
Пример #3
0
        public PostprocessorsInitializer(
            IManager postprocessorsManager,
            IUserDefinedFormatsManager userDefinedFormatsManager,
            StateInspector.IPostprocessorsFactory stateInspectorPostprocessorsFactory,
            TimeSeries.IPostprocessorsFactory timeSeriesPostprocessorsFactory,
            Correlator.IPostprocessorsFactory correlatorPostprocessorsFactory,
            Timeline.IPostprocessorsFactory timelinePostprocessorsFactory,
            SequenceDiagram.IPostprocessorsFactory sequenceDiagramPostprocessorsFactory
            )
        {
            IUserDefinedFactory findFormat(string company, string formatName)
            {
                var ret = userDefinedFormatsManager.Items.FirstOrDefault(
                    f => f.CompanyName == company && f.FormatName == formatName);

                if (ret == null)
                {
                    throw new Exception(string.Format("Log format {0} is not registered in LogJoint", formatName));
                }
                return(ret);
            }

            this.chromeDebugLogFormat      = findFormat("Google", "Chrome debug log");
            this.webRtcInternalsDumpFormat = findFormat("Google", "Chrome WebRTC internals dump as log");
            this.chromeDriverLogFormat     = findFormat("Google", "chromedriver");
            this.httpArchiveFormat         = findFormat("W3C", "HTTP Archive (HAR)");

            this.chromeDebugLogMeta = new LogSourceMetadata(
                chromeDebugLogFormat,
                stateInspectorPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                timelinePostprocessorsFactory.CreateChromeDebugPostprocessor(),
                sequenceDiagramPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                correlatorPostprocessorsFactory.CreateChromeDebugPostprocessor()
                );
            postprocessorsManager.Register(this.chromeDebugLogMeta);

            this.webRtcInternalsDumpMeta = new LogSourceMetadata(
                webRtcInternalsDumpFormat,
                stateInspectorPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor(),
                correlatorPostprocessorsFactory.CreateWebRtcInternalsPostprocessor()
                );
            postprocessorsManager.Register(this.webRtcInternalsDumpMeta);

            this.chromeDriverLogMeta = new LogSourceMetadata(
                chromeDriverLogFormat,
                timelinePostprocessorsFactory.CreateChromeDriverPostprocessor(),
                correlatorPostprocessorsFactory.CreateChromeDriverPostprocessor()
                );
            postprocessorsManager.Register(this.chromeDriverLogMeta);

            this.httpArchiveMeta = new LogSourceMetadata(
                httpArchiveFormat,
                timelinePostprocessorsFactory.CreateHttpArchivePostprocessor(),
                sequenceDiagramPostprocessorsFactory.CreateHttpArchivePostprocessor()
                );
            postprocessorsManager.Register(this.httpArchiveMeta);
        }
Пример #4
0
        public PostprocessorsInitializer(
            IPostprocessorsManager postprocessorsManager,
            IUserDefinedFormatsManager userDefinedFormatsManager,
            StateInspector.IPostprocessorsFactory stateInspectorPostprocessorsFactory,
            TimeSeries.IPostprocessorsFactory timeSeriesPostprocessorsFactory,
            Correlator.IPostprocessorsFactory correlatorPostprocessorsFactory,
            Timeline.IPostprocessorsFactory timelinePostprocessorsFactory
            )
        {
            Func <string, string, UDF> findFormat = (company, formatName) =>
            {
                var ret = userDefinedFormatsManager.Items.FirstOrDefault(
                    f => f.CompanyName == company && f.FormatName == formatName) as UDF;
                if (ret == null)
                {
                    throw new Exception(string.Format("Log format {0} is not registered in LogJoint", formatName));
                }
                return(ret);
            };

            this.chromeDebugLogFormat      = findFormat("Google", "Chrome debug log");
            this.webRtcInternalsDumpFormat = findFormat("Google", "Chrome WebRTC internals dump as log");
            this.chromeDriverLogFormat     = findFormat("Google", "chromedriver");
            this.symRtcLogFormat           = findFormat("Symphony", "RTC log");

            var correlatorPostprocessorType = correlatorPostprocessorsFactory.CreatePostprocessor(this);

            postprocessorsManager.RegisterCrossLogSourcePostprocessor(correlatorPostprocessorType);

            this.chromeDebugLogMeta = new LogSourceMetadata(
                chromeDebugLogFormat,
                stateInspectorPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateChromeDebugPostprocessor(),
                timelinePostprocessorsFactory.CreateChromeDebugPostprocessor(),
                correlatorPostprocessorType
                );
            postprocessorsManager.RegisterLogType(this.chromeDebugLogMeta);

            this.webRtcInternalsDumpMeta = new LogSourceMetadata(
                webRtcInternalsDumpFormat,
                stateInspectorPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateWebRtcInternalsDumpPostprocessor(),
                correlatorPostprocessorType
                );
            postprocessorsManager.RegisterLogType(this.webRtcInternalsDumpMeta);

            this.chromeDriverLogMeta = new LogSourceMetadata(
                chromeDriverLogFormat,
                timelinePostprocessorsFactory.CreateChromeDriverPostprocessor(),
                correlatorPostprocessorType
                );
            postprocessorsManager.RegisterLogType(this.chromeDriverLogMeta);

            this.symRtcLogMeta = new LogSourceMetadata(
                symRtcLogFormat,
                stateInspectorPostprocessorsFactory.CreateSymphontRtcPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.symRtcLogMeta);
        }
Пример #5
0
        public PostprocessorsInitializer(
            IManager postprocessorsManager,
            IUserDefinedFormatsManager userDefinedFormatsManager,
            StateInspector.IPostprocessorsFactory stateInspectorPostprocessorsFactory,
            TimeSeries.IPostprocessorsFactory timeSeriesPostprocessorsFactory,
            Correlator.IPostprocessorsFactory correlatorPostprocessorsFactory,
            Timeline.IPostprocessorsFactory timelinePostprocessorsFactory,
            SequenceDiagram.IPostprocessorsFactory sequenceDiagramPostprocessorsFactory
            )
        {
            IUserDefinedFactory findFormat(string company, string formatName)
            {
                var ret = userDefinedFormatsManager.Items.FirstOrDefault(
                    f => f.CompanyName == company && f.FormatName == formatName);

                if (ret == null)
                {
                    throw new Exception(string.Format("Log format {0} is not registered in LogJoint", formatName));
                }
                return(ret);
            }

            this.symRtcLogFormat        = findFormat("Symphony", "RTC log");
            this.springServiceLogFormat = findFormat("Symphony", "RTC Java Spring Service log");
            this.smbLogFormat           = findFormat("Symphony", "SMB log");

            var correlatorPostprocessorType = correlatorPostprocessorsFactory.CreatePostprocessor(this);

            postprocessorsManager.RegisterCrossLogSourcePostprocessor(correlatorPostprocessorType);

            this.springServiceLogMeta = new LogSourceMetadata(
                springServiceLogFormat,
                sequenceDiagramPostprocessorsFactory.CreateSpringServiceLogPostprocessor(),
                timelinePostprocessorsFactory.CreateSpringServiceLogPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.springServiceLogMeta);

            this.symRtcLogMeta = new LogSourceMetadata(
                symRtcLogFormat,
                stateInspectorPostprocessorsFactory.CreateSymphonyRtcPostprocessor(),
                timeSeriesPostprocessorsFactory.CreateSymphonyRtcPostprocessor(),
                timelinePostprocessorsFactory.CreateSymRtcPostprocessor(),
                sequenceDiagramPostprocessorsFactory.CreateRtcLogPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.symRtcLogMeta);

            this.smbLogMeta = new LogSourceMetadata(
                smbLogFormat,
                sequenceDiagramPostprocessorsFactory.CreateSMBPostprocessor()
                );
            postprocessorsManager.RegisterLogType(this.smbLogMeta);
        }