Refactored AlertService to handle logs and loading events