Esempio n. 1
0
        public HealthSensorStatus GetStatus()
        {
            if (activeHealthCheck != null)
            {
                var updateResult = activeHealthCheck.GetSensorStateUpdate();
                State     = updateResult.State;
                Message   = updateResult.Message;
                Exception = updateResult.Exception;
            }

            return(new HealthSensorStatus
            {
                Name = Name,
                Description = Description,
                Endpoint = Endpoint,
                IsEssential = IsEssential,
                IsExternal = IsExternal,
                KnowledgeBaseArticleUrl = KnowledgeBaseArticleUrl.ToString(),
                State = State.ToString(),
                Message = Message
            });
        }