Implement error handling mechanism with retry logic for failed services. Includes:
- ServiceControl struct to track service state
- HandleErrorProcess function to attempt service restarts
- Integration with monitor to automatically recover services
- Enhanced exception handling with status checks and monitoring restart
Improve exception message formatting by adding XML tags for better parsing and processing downstream. The new format includes explicit tags for exception type, service name, and error message.
- Move command handler to variable for better flexibility
- Add SendMsg function for sending messages through socket
- Fix missing return statements in command execution
- Improve error handling in monitor exception reporting
Implement a new monitoring system that tracks service status and logs using systemd commands. The monitor includes:
- Periodic status checks via systemctl
- Log analysis via journalctl
- Thread-safe service tracking
- Error detection and reporting