Class ThreadDumpUtil

java.lang.Object
org.codelibs.fess.util.ThreadDumpUtil

public class ThreadDumpUtil extends Object
Utility class for generating and writing thread dumps. Provides methods to capture thread information for debugging purposes.
  • Constructor Details

    • ThreadDumpUtil

      protected ThreadDumpUtil()
      Private constructor to prevent instantiation of this utility class.
  • Method Details

    • printThreadDump

      public static void printThreadDump()
      Prints thread dump information to the logger at INFO level.
    • printThreadDumpAsWarn

      public static void printThreadDumpAsWarn()
      Prints thread dump information to the logger at WARN level.
    • printThreadDumpAsError

      public static void printThreadDumpAsError()
      Prints thread dump information to the logger at ERROR level.
    • writeThreadDump

      public static void writeThreadDump(String file)
      Writes thread dump information to the specified file.
      Parameters:
      file - the file path to write the thread dump to
    • processThreadDump

      public static void processThreadDump(Consumer<String> writer)
      Processes all thread information and sends it to the provided consumer.
      Parameters:
      writer - the consumer that will handle each line of thread dump output