static Map<Long, ThreadInfo> createThreadInfoMap(ThreadMXBean threadMXBean,
      Set<Long> stuckThreadIds,
      final boolean showLocks, final boolean batchCalls) {
    if (stuckThreadIds.isEmpty()) {
      return Collections.emptyMap();
    }
    logger.info(
        "Obtaining ThreadInfo for {} threads. Configuration: showLocks={} batchCalls={}. This is an expensive operation for the JVM and on most JVMs causes all threads to be paused.",
        stuckThreadIds.size(), showLocks, batchCalls);
    Map<Long, ThreadInfo> result = new HashMap<>();
    if (batchCalls) {
      createThreadInfoMapUsingSingleCall(threadMXBean, stuckThreadIds, showLocks, result);
    } else {
      for (long id : stuckThreadIds) {
        ThreadInfo threadInfo = createThreadInfoForSingleThread(threadMXBean, showLocks, id);
        if (threadInfo != null) {
          result.put(threadInfo.getThreadId(), threadInfo);
        }
      }
    }
    logger.info("finished obtaining ThreadInfo");
    return result;
  }
If set to true, then the JVM will be asked for all potential stuck threads with one call.
Since getThreadInfo on many JVMs, stops ALL threads from running, and since getting info
on multiple threads with one call is additional work, setting this can cause an extra long
stop the world that can then cause other problems (like a forced disconnect).
So be careful setting this to true.
geode-core/src/main/java/org/apache/geode/internal/monitoring/ThreadsMonitoringProcess.java