code: public void start() {
          executor.submit(new Runnable() {
              @Override
              public void run() {
                  try {
                      process = new ProcessBuilder().redirectErrorStream(true).command(command).start();
                      BufferedReader reader = new BufferedReader(new InputStreamReader(process.getInputStream()));
                      String line;
                      while ((line = reader.readLine()) != null) {
                          output.add(line);
                      }
                  } catch (IOException e) {
                      throw new RuntimeException(e);
                  }
              }
          });
      }
docs: Life-cycle