• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# ITraceManager类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中ITraceManager的典型用法代码示例。如果您正苦于以下问题:C# ITraceManager类的具体用法?C# ITraceManager怎么用?C# ITraceManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ITraceManager类属于命名空间,在下文中一共展示了ITraceManager类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: Connection

        public Connection(IMessageBus newMessageBus,
                          IJsonSerializer jsonSerializer,
                          string baseSignal,
                          string connectionId,
                          IList<string> signals,
                          IList<string> groups,
                          ITraceManager traceManager,
                          IAckHandler ackHandler,
                          IPerformanceCounterManager performanceCounterManager,
                          IProtectedData protectedData)
        {
            if (traceManager == null)
            {
                throw new ArgumentNullException("traceManager");
            }

            _bus = newMessageBus;
            _serializer = jsonSerializer;
            _baseSignal = baseSignal;
            _connectionId = connectionId;
            _signals = new List<string>(signals.Concat(groups));
            _groups = new DiffSet<string>(groups);
            _traceSource = traceManager["SignalR.Connection"];
            _ackHandler = ackHandler;
            _counters = performanceCounterManager;
            _protectedData = protectedData;
        }
开发者ID:Djohnnie,项目名称:Sonarr,代码行数:27,代码来源:Connection.cs


示例2: Connection

        public Connection(IMessageBus newMessageBus,
                          IJsonSerializer jsonSerializer,
                          string baseSignal,
                          string connectionId,
                          IEnumerable<string> signals,
                          IEnumerable<string> groups,
                          ITraceManager traceManager,
                          IAckHandler ackHandler,
                          IPerformanceCounterWriter performanceCounterWriter)
        {
            _bus = newMessageBus;
            _serializer = jsonSerializer;
            _baseSignal = baseSignal;
            _connectionId = connectionId;
            _signals = new HashSet<string>(signals);
            _groups = new SafeSet<string>(groups);
            _traceSource = new Lazy<TraceSource>(() => traceManager["SignalR.Connection"]);
            _ackHandler = ackHandler;

            var counters = performanceCounterWriter;
            _msgsRecTotalCounter = counters.GetCounter(PerformanceCounters.ConnectionMessagesReceivedTotal);
            _msgsRecPerSecCounter = counters.GetCounter(PerformanceCounters.ConnectionMessagesReceivedPerSec);
            _msgsSentTotalCounter = counters.GetCounter(PerformanceCounters.ConnectionMessagesSentTotal);
            _msgsSentPerSecCounter = counters.GetCounter(PerformanceCounters.ConnectionMessagesSentPerSec);
        }
开发者ID:paigecook,项目名称:SignalR,代码行数:25,代码来源:Connection.cs


示例3: TransportDisconnectBase

        protected TransportDisconnectBase(HostContext context, IJsonSerializer jsonSerializer, ITransportHeartbeat heartbeat, IPerformanceCounterManager performanceCounterManager, ITraceManager traceManager)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            if (jsonSerializer == null)
            {
                throw new ArgumentNullException("jsonSerializer");
            }

            if (heartbeat == null)
            {
                throw new ArgumentNullException("heartbeat");
            }

            if (performanceCounterManager == null)
            {
                throw new ArgumentNullException("performanceCounterManager");
            }

            if (traceManager == null)
            {
                throw new ArgumentNullException("traceManager");
            }

            _context = context;
            _jsonSerializer = jsonSerializer;
            _heartbeat = heartbeat;
            _counters = performanceCounterManager;

            _trace = traceManager["SignalR.Transports." + GetType().Name];
        }
开发者ID:kppullin,项目名称:SignalR,代码行数:34,代码来源:TransportDisconnectBase.cs


示例4: TransportDisconnectBase

        protected TransportDisconnectBase(HostContext context, ITransportHeartbeat heartbeat, IPerformanceCounterManager performanceCounterManager, ITraceManager traceManager)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            if (heartbeat == null)
            {
                throw new ArgumentNullException("heartbeat");
            }

            if (performanceCounterManager == null)
            {
                throw new ArgumentNullException("performanceCounterManager");
            }

            if (traceManager == null)
            {
                throw new ArgumentNullException("traceManager");
            }

            _context = context;
            _heartbeat = heartbeat;
            _counters = performanceCounterManager;

            // Queue to protect against overlapping writes to the underlying response stream
            WriteQueue = new TaskQueue();

            _trace = traceManager["SignalR.Transports." + GetType().Name];
        }
开发者ID:Choulla-Naresh8264,项目名称:SignalR,代码行数:31,代码来源:TransportDisconnectBase.cs


示例5: AuthorizationService

 public AuthorizationService(
     IUnitOfWork unitOfWork, 
     ISymmetricAlgorithmProvider symmetricAlgorithmProvider,
     ITraceManager traceManager)
     : base(unitOfWork, symmetricAlgorithmProvider)
 {
     this._traceManager = traceManager;
 }
开发者ID:RamanBut-Husaim,项目名称:ZIRKSiS,代码行数:8,代码来源:AuthorizationService.cs


示例6: MessageBus

 /// <summary>
 /// 
 /// </summary>
 /// <param name="traceManager"></param>
 public MessageBus(ITraceManager traceManager)
 {
     _trace = traceManager;
     _engine = new Engine(_topics)
     {
         Trace = Trace
     };
 }
开发者ID:Shira-Z,项目名称:SignalR-1,代码行数:12,代码来源:MessageBus.cs


示例7: WebSocketTransport

 public WebSocketTransport(HostContext context,
                           IJsonSerializer serializer,
                           ITransportHeartbeat heartbeat,
                           IPerformanceCounterManager performanceCounterWriter,
                           ITraceManager traceManager)
     : base(context, serializer, heartbeat, performanceCounterWriter, traceManager)
 {
     _context = context;
 }
开发者ID:Jozef89,项目名称:SignalR,代码行数:9,代码来源:WebSocketTransport.cs


示例8: AuthenticationService

 public AuthenticationService(
     IUnitOfWork unitOfWork, 
     ISymmetricAlgorithmProvider symmetricAlgorithmProvider,
     ITraceManager traceManager)
     : base(unitOfWork, symmetricAlgorithmProvider)
 {
     this._priorAuthenticationRequired = false;
     this._traceManager = traceManager;
 }
开发者ID:RamanBut-Husaim,项目名称:ZIRKSiS,代码行数:9,代码来源:AuthenticationService.cs


示例9: InProcessMessageBus

        public InProcessMessageBus(ITraceManager traceManager, bool garbageCollectMessages)
        {
            _trace = traceManager;

            if (garbageCollectMessages)
            {
                _timer = new Timer(RemoveExpiredEntries, null, _cleanupInterval, _cleanupInterval);
            }
        }
开发者ID:arygg,项目名称:SignalR,代码行数:9,代码来源:InProcessMessageBus.cs


示例10: MessageBus

        /// <summary>
        /// 
        /// </summary>
        /// <param name="traceManager"></param>
        public MessageBus(ITraceManager traceManager, IPerformanceCounterManager performanceCounterManager)
        {
            _trace = traceManager;
            _counters = performanceCounterManager;

            _broker = new MessageBroker(_topics, _counters)
            {
                Trace = Trace
            };
        }
开发者ID:Kazzje,项目名称:SignalR,代码行数:14,代码来源:MessageBus.cs


示例11: TestLongPollingTransport

 private TestLongPollingTransport(
     HostContext context,
     JsonSerializer json,
     ITransportHeartbeat heartBeat,
     IPerformanceCounterManager counters,
     ITraceManager traceManager,
     IConfigurationManager configuarionManager)
     : base(context, json, heartBeat, counters, traceManager, configuarionManager)
 {
 }
开发者ID:GondhiDinesh,项目名称:SignalR,代码行数:10,代码来源:LongPollingTransportFacts.cs


示例12: LongPollingTransport

 public LongPollingTransport(HostContext context,
                             JsonSerializer jsonSerializer,
                             ITransportHeartbeat heartbeat,
                             IPerformanceCounterManager performanceCounterManager,
                             ITraceManager traceManager,
                             IConfigurationManager configurationManager)
     : base(context, jsonSerializer, heartbeat, performanceCounterManager, traceManager)
 {
     _configurationManager = configurationManager;
 }
开发者ID:GaneshBachhao,项目名称:SignalR,代码行数:10,代码来源:LongPollingTransport.cs


示例13: LongPollingTransport

 public LongPollingTransport(HostContext context,
                             IJsonSerializer jsonSerializer,
                             ITransportHeartbeat heartbeat,
                             IPerformanceCounterManager performanceCounterManager,
                             ITraceManager traceManager)
     : base(context, heartbeat, performanceCounterManager, traceManager)
 {
     _jsonSerializer = jsonSerializer;
     _counters = performanceCounterManager;
 }
开发者ID:bjarteskogoy,项目名称:SignalR,代码行数:10,代码来源:LongPollingTransport.cs


示例14: ForeverTransport

 protected ForeverTransport(HostContext context,
                            IJsonSerializer jsonSerializer,
                            ITransportHeartbeat heartbeat,
                            IPerformanceCounterManager performanceCounterWriter,
                            ITraceManager traceManager)
     : base(context, jsonSerializer, heartbeat, performanceCounterWriter, traceManager)
 {
     _jsonSerializer = jsonSerializer;
     _counters = performanceCounterWriter;
 }
开发者ID:Jozef89,项目名称:SignalR,代码行数:10,代码来源:ForeverTransport.cs


示例15: PerformanceCounterManager

        /// <summary>
        /// Creates a new instance.
        /// </summary>
        public PerformanceCounterManager(ITraceManager traceManager)
            : this()
        {
            if (traceManager == null)
            {
                throw new ArgumentNullException("traceManager");
            }

            _trace = traceManager["SignalR.PerformanceCounterManager"];
        }
开发者ID:ZixiangBoy,项目名称:SignalR-1,代码行数:13,代码来源:PerformanceCounterManager.cs


示例16: MessageBus

        public MessageBus(IStringMinifier stringMinifier,
                          ITraceManager traceManager,
                          IPerformanceCounterManager performanceCounterManager,
                          IConfigurationManager configurationManager,
                          int maxTopicsWithNoSubscriptions)
        {
            if (stringMinifier == null)
            {
                throw new ArgumentNullException("stringMinifier");
            }

            if (traceManager == null)
            {
                throw new ArgumentNullException("traceManager");
            }

            if (performanceCounterManager == null)
            {
                throw new ArgumentNullException("performanceCounterManager");
            }

            if (configurationManager == null)
            {
                throw new ArgumentNullException("configurationManager");
            }

            if (configurationManager.DefaultMessageBufferSize < 0)
            {
                throw new ArgumentOutOfRangeException(Resources.Error_BufferSizeOutOfRange);
            }

            _stringMinifier = stringMinifier;
            _traceManager = traceManager;
            Counters = performanceCounterManager;
            _trace = _traceManager["SignalR." + typeof(MessageBus).Name];
            _maxTopicsWithNoSubscriptions = maxTopicsWithNoSubscriptions;

            _gcTimer = new Timer(_ => GarbageCollectTopics(), state: null, dueTime: _gcInterval, period: _gcInterval);

            _broker = new MessageBroker(Counters)
            {
                Trace = _trace
            };

            // The default message store size
            _messageStoreSize = (uint)configurationManager.DefaultMessageBufferSize;

            _topicTtl = configurationManager.TopicTtl();
            _createTopic = CreateTopic;
            _addEvent = AddEvent;
            _removeEvent = RemoveEvent;
            _disposeSubscription = o => DisposeSubscription(o);

            Topics = new TopicLookup();
        }
开发者ID:SaveTrees,项目名称:SignalR,代码行数:55,代码来源:MessageBus.cs


示例17: WebSocketTransport

 public WebSocketTransport(HostContext context,
                           JsonSerializer serializer,
                           ITransportHeartbeat heartbeat,
                           IPerformanceCounterManager performanceCounterWriter,
                           ITraceManager traceManager)
     : base(context, serializer, heartbeat, performanceCounterWriter, traceManager)
 {
     _context = context;
     _message = OnMessage;
     _closed = OnClosed;
     _error = OnError;
 }
开发者ID:nirmana,项目名称:SignalR,代码行数:12,代码来源:WebSocketTransport.cs


示例18: ForeverTransport

 protected ForeverTransport(HostContext context,
                            JsonSerializer jsonSerializer,
                            ITransportHeartbeat heartbeat,
                            IPerformanceCounterManager performanceCounterManager,
                            ITraceManager traceManager,
                            IMemoryPool pool)
     : base(context, heartbeat, performanceCounterManager, traceManager)
 {
     Pool = pool;
     _jsonSerializer = jsonSerializer;
     _counters = performanceCounterManager;
 }
开发者ID:Choulla-Naresh8264,项目名称:SignalR,代码行数:12,代码来源:ForeverTransport.cs


示例19: PersistentConnection

 protected PersistentConnection(IMessageBus messageBus,
                                IConnectionIdFactory connectionIdFactory,
                                IJsonSerializer jsonSerializer,
                                ITransportManager transportManager,
                                ITraceManager traceManager)
 {
     _messageBus = messageBus;
     _connectionIdFactory = connectionIdFactory;
     _jsonSerializer = jsonSerializer;
     _transportManager = transportManager;
     _trace = traceManager;
 }
开发者ID:stevehebert,项目名称:SignalR,代码行数:12,代码来源:PersistentConnection.cs


示例20: MessageBus

        /// <summary>
        /// 
        /// </summary>
        /// <param name="traceManager"></param>
        public MessageBus(ITraceManager traceManager, IPerformanceCounterWriter performanceCounterWriter)
        {
            _trace = traceManager;

            _counters = performanceCounterWriter;
            _msgsTotalCounter = _counters.GetCounter(PerformanceCounters.MessageBusMessagesPublishedTotal);
            _msgsPerSecCounter = _counters.GetCounter(PerformanceCounters.MessageBusMessagesPublishedPerSec);

            _engine = new Engine(_topics, _counters)
            {
                Trace = Trace
            };
        }
开发者ID:khushal999p,项目名称:SignalR,代码行数:17,代码来源:MessageBus.cs



注:本文中的ITraceManager类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# ITraceWriter类代码示例发布时间:2022-05-24
下一篇:
C# ITraceFactory类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap