Esempio n. 1
0
        protected async override Task OnEnumChildren(bool deep)
        {
            Applications.Clear();
            var applications = await _fabricClient.QueryManager.GetApplicationListAsync();

            foreach (var application in applications)
            {
                var sfApplication = new SFApplication(_fabricClient, this, application);
                Applications.Add(sfApplication);
                if (deep)
                {
                    await sfApplication.EnumChildren(deep);
                }
            }

            Nodes.Clear();
            var nodes = await _fabricClient.QueryManager.GetNodeListAsync();

            foreach (var node in nodes)
            {
                var sfNode = new SFNode(_fabricClient, this, node);
                Nodes.Add(sfNode);
                if (deep)
                {
                    await sfNode.EnumChildren(deep);
                }
            }

            LoadInformation = await _fabricClient.QueryManager.GetClusterLoadInformationAsync();
        }
 public SFService(FabricClient fabricClient, SFApplication parent, Service service)
     : base(fabricClient)
 {
     _parent  = parent;
     _service = service;
 }