Uploaded image for project: 'REEF (Retired)'
  1. REEF (Retired)
  2. REEF-1020

Improve OSUtils to support Windows and Mac

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Implemented
    • None
    • 0.14
    • REEF-Common
    • None

    Description

      As of today, OSUtils in reef-common module only supports Linux in the following functions.

      • `getPID()`
      • `kill()`

      This issue improves OSUtils to support Windows and Mac by implementing the following items.

      • For `OSUtils.isLinux`, it returns true for both Linux and Mac. This enables `getPID()` and `kill()` on Mac.
      • For `OSUtils.getPID()`, it uses `powershell -Command wmic process where processid=$pid get parentprocessid` to get pid in Windows.
      • For `OSUtils.kill()`, it uses `taskkill /pid` for Windows.
      • Add OSUtilsTest.java

      Also, this issue fixes the followings.

      • Add No-Op `ActiveContextHandler` to EvaluatorFailureDuringAlarmDriver. `DefaultContextActiveHandler` suicides by closing itself.
      • `RunnableProcess` cleans up both linux and windows.
      • `RunnableProcess` catches `NumberFormatException` from `RunnableProcess.readPID()`.
      • Bind `PIDStoreStartHandler` to `LocalRuntimeConfiguration`.

      Attachments

        Issue Links

          Activity

            People

              dongjoon Dongjoon Hyun
              dongjoon Dongjoon Hyun
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: