ThreadUtil (Cloud Bigtable HBase Client for Java 1.12.0 API)

com.google.cloud.bigtable.util

Class ThreadUtil



  • public class ThreadUtil
    extends Object
    Creates a ThreadFactory that's safe to use in App Engine.

    This class copies code that originates in GrpcUtil.getThreadFactory(String, boolean).

    • Constructor Detail

      • ThreadUtil

        public ThreadUtil()
    • Method Detail

      • getThreadFactory

        public static ThreadFactory getThreadFactory(String nameFormat,
                                                     boolean daemon)
        Get a ThreadFactory suitable for use in the current environment.
        Parameters:
        nameFormat - to apply to threads created by the factory.
        daemon - true if the threads the factory creates are daemon threads, false otherwise.
        Returns:
        a ThreadFactory.