Skip to content

A2 #85

@shaykeren

Description

@shaykeren

Issue Description

The MonitorService has been throwing IllegalStateException during monitoring operations, causing service instability. This needs to be fixed and the service implementation improved.

Current Behavior

  • MonitorService throws IllegalStateException during monitoring
  • isRunning() always returns false
  • Poor thread management and error handling
  • No proper state validation

Root Cause

The monitor() method was deliberately throwing exceptions and the service state management was incorrect.

Solution

PR #84 has been created to fix these issues by:

  1. Implementing proper state management
  2. Fixing isRunning() method
  3. Removing deliberate exception throwing
  4. Adding proper thread management
  5. Improving error handling and logging
  6. Adding proper documentation

Related Pull Request

PR #84 contains the implementation fixes.

Additional Notes

  • The monitor() method now has a placeholder for actual monitoring logic
  • Thread management has been improved with proper interrupt handling
  • Added daemon thread setting for better JVM lifecycle management

Labels

  • bug
  • enhancement

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions