コード例 #1
0
        private void BuildAndRegisterTopic(TopicOptions options, ServiceBusOptions parentOptions)
        {
            var topic = new TopicWrapper(options, parentOptions, _provider);

            topic.Initialize();

            _registry.Register(topic);
        }
コード例 #2
0
        private async Task CloseTopicAsync(TopicWrapper topic)
        {
            if (topic.TopicClient.IsClosedOrClosing)
            {
                return;
            }

            try
            {
                await topic.TopicClient.CloseAsync();
            }
            catch (Exception ex)
            {
                _logger.LogError(ex, $"Closing of topic Client {topic.Name} failed");
            }
        }
コード例 #3
0
 internal void Register(TopicWrapper topic)
 {
     _topics.Add(topic.Name, topic);
 }