Beispiel #1
0
        public Task <ServiceHealth> IsHealthOk()
        {
            ServiceHealth health = new ServiceHealth();

            (bool Ok, string Message) = _cosmosRepository.IsHealthOk();

            health.Name = nameof(DataSetsRepository);
            health.Dependencies.Add(new DependencyHealth {
                HealthOk = Ok, DependencyName = this.GetType().Name, Message = Message
            });

            return(Task.FromResult(health));
        }
Beispiel #2
0
        public async Task <ServiceHealth> IsHealthOk()
        {
            ServiceHealth health = new ServiceHealth();

            (bool Ok, string Message)cosmosHealth = await _cosmosRepository.IsHealthOk();

            health.Name = nameof(DataSetsRepository);
            health.Dependencies.Add(new DependencyHealth {
                HealthOk = cosmosHealth.Ok, DependencyName = this.GetType().Name, Message = cosmosHealth.Message
            });

            return(health);
        }
        public async Task <ServiceHealth> IsHealthOk()
        {
            ServiceHealth health = new ServiceHealth();

            var cosmosHealth = await _cosmosRepository.IsHealthOk();

            health.Name = this.GetType().Name;
            health.Dependencies.Add(new DependencyHealth {
                HealthOk = cosmosHealth.Ok, DependencyName = typeof(CosmosRepository).Name, Message = cosmosHealth.Message
            });

            return(health);
        }
Beispiel #4
0
        public Task <ServiceHealth> IsHealthOk()
        {
            (bool Ok, string Message) = _cosmosRepository.IsHealthOk();

            ServiceHealth health = new ServiceHealth()
            {
                Name = nameof(ProviderSourceDatasetsRepository)
            };

            health.Dependencies.Add(new DependencyHealth {
                HealthOk = Ok, DependencyName = _cosmosRepository.GetType().GetFriendlyName(), Message = Message
            });

            return(Task.FromResult(health));
        }
        public async Task <ServiceHealth> IsHealthOk()
        {
            var cosmosRepoHealth = await _cosmosRepository.IsHealthOk();

            ServiceHealth health = new ServiceHealth()
            {
                Name = nameof(ScenariosRepository)
            };

            health.Dependencies.Add(new DependencyHealth {
                HealthOk = cosmosRepoHealth.Ok, DependencyName = _cosmosRepository.GetType().GetFriendlyName(), Message = cosmosRepoHealth.Message
            });

            return(health);
        }