本文整理汇总了C#中IScheduleService类的典型用法代码示例。如果您正苦于以下问题:C# IScheduleService类的具体用法?C# IScheduleService怎么用?C# IScheduleService使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IScheduleService类属于命名空间,在下文中一共展示了IScheduleService类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: DefaultCleanAggregateService
public DefaultCleanAggregateService(IMemoryCache memoryCache, IScheduleService scheduleService)
{
TimeoutSeconds = ENodeConfiguration.Instance.Setting.AggregateRootMaxInactiveSeconds;
_memoryCache = memoryCache;
_scheduleService = scheduleService;
_scheduleService.StartTask("CleanAggregates", Clean, 1000, ENodeConfiguration.Instance.Setting.ScanExpiredAggregateIntervalMilliseconds);
}
示例2: MessageHandler
public MessageHandler()
{
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_scheduleService.StartTask("PrintThroughput", PrintThroughput, 1000, 1000);
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(typeof(Program).Name);
_throughputLogger = ObjectContainer.Resolve<ILoggerFactory>().Create("throughput");
}
示例3: DisplayLunchViewModel
public DisplayLunchViewModel(IScheduleService service)
{
this.Service = service;
this.Week = new ObservableCollection<LunchTimeDto>();
this.WeekView = CollectionViewSource.GetDefaultView(Week);
this.WeekView.GroupDescriptions.Add(new PropertyGroupDescription("DayOfWeek"));
}
示例4: DefaultEventService
public DefaultEventService(
IJsonSerializer jsonSerializer,
IScheduleService scheduleService,
ITypeNameProvider typeNameProvider,
IMemoryCache memoryCache,
IAggregateRootFactory aggregateRootFactory,
IAggregateStorage aggregateStorage,
IEventStore eventStore,
IMessagePublisher<DomainEventStreamMessage> domainEventPublisher,
IOHelper ioHelper,
ILoggerFactory loggerFactory)
{
_eventMailboxDict = new ConcurrentDictionary<string, EventMailBox>();
_ioHelper = ioHelper;
_jsonSerializer = jsonSerializer;
_scheduleService = scheduleService;
_typeNameProvider = typeNameProvider;
_memoryCache = memoryCache;
_aggregateRootFactory = aggregateRootFactory;
_aggregateStorage = aggregateStorage;
_eventStore = eventStore;
_domainEventPublisher = domainEventPublisher;
_logger = loggerFactory.Create(GetType().FullName);
_batchSize = ENodeConfiguration.Instance.Setting.EventMailBoxPersistenceMaxBatchSize;
}
示例5: ClientService
public ClientService(ClientSetting setting, Producer producer, Consumer consumer)
{
Ensure.NotNull(setting, "setting");
if (producer == null && consumer == null)
{
throw new ArgumentException("producer or consumer must set at least one of them.");
}
else if (producer != null && consumer != null)
{
throw new ArgumentException("producer or consumer cannot set both of them.");
}
Interlocked.Increment(ref _instanceNumber);
_producer = producer;
_consumer = consumer;
_setting = setting;
_clientId = BuildClientId(setting.ClientName);
_brokerConnectionDict = new ConcurrentDictionary<string, BrokerConnection>();
_topicMessageQueueDict = new ConcurrentDictionary<string, IList<MessageQueue>>();
_binarySerializer = ObjectContainer.Resolve<IBinarySerializer>();
_jsonSerializer = ObjectContainer.Resolve<IJsonSerializer>();
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
_nameServerRemotingClientList = RemotingClientUtils.CreateRemotingClientList(_setting.NameServerList, _setting.SocketSetting).ToList();
}
示例6: MessageService
public MessageService(IMessageStore messageStore, IOffsetManager offsetManager, IScheduleService scheduleService)
{
_messageStore = messageStore;
_offsetManager = offsetManager;
_scheduleService = scheduleService;
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
}
示例7: ChunkWriter
public ChunkWriter(ChunkManager chunkManager)
{
Ensure.NotNull(chunkManager, "chunkManager");
_chunkManager = chunkManager;
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
}
示例8: ScheduleController
public ScheduleController(IRepository repository, IScheduleService schedService, ITruckService truckService, IMappingEngine mapper)
{
this.repository = repository;
this.schedService = schedService;
this.truckService = truckService;
this.mapper = mapper;
}
示例9: ActivityGridViewModel
public ActivityGridViewModel(IScheduleService service)
{
this.Service = service;
this.Activities = new ObservableCollection<ActivityModel>();
this.ActivitiesView = CollectionViewSource.GetDefaultView(Activities);
this.ActivitiesView.GroupDescriptions.Add(new PropertyGroupDescription("DayOfWeek"));
}
示例10: Consumer
public Consumer(string groupName, ConsumerSetting setting)
{
if (groupName == null)
{
throw new ArgumentNullException("groupName");
}
GroupName = groupName;
Setting = setting ?? new ConsumerSetting();
_lockObject = new object();
_subscriptionTopics = new Dictionary<string, HashSet<string>>();
_topicQueuesDict = new ConcurrentDictionary<string, IList<MessageQueue>>();
_pullRequestDict = new ConcurrentDictionary<string, PullRequest>();
_remotingClient = new SocketRemotingClient(Setting.BrokerAddress, Setting.SocketSetting, Setting.LocalAddress);
_adminRemotingClient = new SocketRemotingClient(Setting.BrokerAdminAddress, Setting.SocketSetting, Setting.LocalAdminAddress);
_binarySerializer = ObjectContainer.Resolve<IBinarySerializer>();
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_allocateMessageQueueStragegy = ObjectContainer.Resolve<IAllocateMessageQueueStrategy>();
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
_remotingClient.RegisterConnectionEventListener(new ConnectionEventListener(this));
if (Setting.MessageHandleMode == MessageHandleMode.Sequential)
{
_consumingMessageQueue = new BlockingCollection<ConsumingMessage>();
_consumeMessageWorker = new Worker("ConsumeMessage", () => HandleMessage(_consumingMessageQueue.Take()));
}
_messageRetryQueue = new BlockingCollection<ConsumingMessage>();
}
示例11: Consumer
public Consumer(string id, string groupName, ConsumerSetting setting)
{
if (id == null)
{
throw new ArgumentNullException("id");
}
if (groupName == null)
{
throw new ArgumentNullException("groupName");
}
Id = id;
GroupName = groupName;
Setting = setting ?? new ConsumerSetting();
_lockObject = new object();
_subscriptionTopics = new List<string>();
_topicQueuesDict = new ConcurrentDictionary<string, IList<MessageQueue>>();
_pullRequestQueue = new BlockingCollection<PullRequest>(new ConcurrentQueue<PullRequest>());
_pullRequestDict = new ConcurrentDictionary<string, PullRequest>();
_consumingMessageQueue = new BlockingCollection<ConsumingMessage>(new ConcurrentQueue<ConsumingMessage>());
_messageRetryQueue = new BlockingCollection<ConsumingMessage>(new ConcurrentQueue<ConsumingMessage>());
_handlingMessageDict = new ConcurrentDictionary<long, ConsumingMessage>();
_taskIds = new List<int>();
_remotingClient = new SocketRemotingClient(Setting.BrokerAddress, Setting.BrokerPort);
_binarySerializer = ObjectContainer.Resolve<IBinarySerializer>();
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_allocateMessageQueueStragegy = ObjectContainer.Resolve<IAllocateMessageQueueStrategy>();
_executePullRequestWorker = new Worker("Consumer.ExecutePullRequest", ExecutePullRequest);
_handleMessageWorker = new Worker("Consumer.HandleMessage", HandleMessage);
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
}
示例12: Consumer
public Consumer(string groupName, ConsumerSetting setting)
{
if (groupName == null)
{
throw new ArgumentNullException("groupName");
}
GroupName = groupName;
Setting = setting ?? new ConsumerSetting();
_lockObject = new object();
_subscriptionTopics = new Dictionary<string, HashSet<string>>();
_topicQueuesDict = new ConcurrentDictionary<string, IList<MessageQueue>>();
_pullRequestQueue = new BlockingCollection<PullRequest>(new ConcurrentQueue<PullRequest>());
_pullRequestDict = new ConcurrentDictionary<string, PullRequest>();
_messageRetryQueue = new BlockingCollection<ConsumingMessage>(new ConcurrentQueue<ConsumingMessage>());
_taskFactory = new TaskFactory(new LimitedConcurrencyLevelTaskScheduler(Setting.ConsumeThreadMaxCount));
_remotingClient = new SocketRemotingClient(Setting.BrokerAddress, Setting.SocketSetting, Setting.LocalAddress);
_adminRemotingClient = new SocketRemotingClient(Setting.BrokerAdminAddress, Setting.SocketSetting, Setting.LocalAdminAddress);
_binarySerializer = ObjectContainer.Resolve<IBinarySerializer>();
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_allocateMessageQueueStragegy = ObjectContainer.Resolve<IAllocateMessageQueueStrategy>();
_executePullRequestWorker = new Worker("ExecutePullRequest", ExecutePullRequest);
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
_remotingClient.RegisterConnectionEventListener(new ConnectionEventListener(this));
}
示例13: ScheduleDisplayViewModel
public ScheduleDisplayViewModel(IScheduleService service)
{
this.RefreshDatesCommand = new RelayCommand(RefreshDates);
this.Mondays = new ObservableCollection<DateTime>();
this.Service = service;
}
示例14: ExaminationDatasheetsController
public ExaminationDatasheetsController(IGroupService gs, ICourseService cs, IAcademicProgressService aps,
IScheduleService scs)
{
groupService = gs;
courseService = cs;
academicProgressService = aps;
scheduleService = scs;
}
示例15: SendReplyService
public SendReplyService()
{
_clientWrapperDict = new ConcurrentDictionary<string, SocketRemotingClientWrapper>();
_jsonSerializer = ObjectContainer.Resolve<IJsonSerializer>();
_scheduleService = ObjectContainer.Resolve<IScheduleService>();
_ioHelper = ObjectContainer.Resolve<IOHelper>();
_logger = ObjectContainer.Resolve<ILoggerFactory>().Create(GetType().FullName);
}