Exemplo n.º 1
0
        public ServiceBusClient(ServiceBusCfg cfg)
        {
            if (cfg is null)
            {
                throw new ArgumentNullException(nameof(cfg));
            }

            cfg.Production
            .ToList()
            .ForEach(e => managers.Add(NamespaceManager.CreateFromConnectionString(e)));
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            ServiceBusCfg    serviceBusCfg    = ServiceBusCfg.Create(@"config/serviceBusConfig.json");
            ServiceBusClient serviceBusClient = new ServiceBusClient(serviceBusCfg);

            try
            {
                var queues = serviceBusClient.GetQueueDescriptions();

                queues.ForEach(q => Console.WriteLine(q.Path));
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }


            Console.ReadLine();
        }