private static void throwError(Object message) {
    if (debug) {
      System.out.flush();
      System.err.println("Assertion failure: " + message);
      try {
        throw new Exception("get Stack trace");
      } catch (Exception ex) {
        ex.printStackTrace();
      }
      System.out.println();
      System.out.flush();
      System.err.println("Waiting for debugger to attach");
      System.err.flush();
      while (true) {
        try {
          Thread.sleep(1000);
        } catch (InterruptedException ignore) {
          Thread.currentThread().interrupt();
        }
      }
    } else {
      InternalGemFireError ex = null;
      if (message != null) {
        ex = new InternalGemFireError(message);
      } else {
        ex = new InternalGemFireError();
      }
      throw ex;
    }
  }
Assert that a boolean value is true.

@param b the boolean value to check
@throws InternalGemFireError if false
geode-core/src/main/java/org/apache/geode/internal/Assert.java