Inheritance: log4net.Appender.AppenderSkeleton
Exemplo n.º 1
0
        public void Init()
        {
            var layout = new PatternLayout("%utcdate %-5level - %message%newline");
            layout.ActivateOptions();

            var appender = new Log4NetAppender
                {
                    Layout = layout,
                    Server = TestSettings.Instance.MetricsLoggingUrl,
                    AccessKey = TestSettings.Instance.AccessKey,
                    ApplicationKey = AppKey,
                };
            appender.ActivateOptions();

            _tracker = appender.Tracker;

            var appender2 = new TraceAppender
                {
                    Layout = layout,
                };

            BasicConfigurator.Configure(appender);
            BasicConfigurator.Configure(appender2);
        }