Class NettyThreadFactory


  • @Singleton
    @Factory
    public class NettyThreadFactory
    extends java.lang.Object
    The Default thread factory the Netty NioEventLoopGroup will use within Micronaut to create threads.
    Since:
    1.0
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int DEFAULT_EVENT_LOOP_THREADS
      Constant with the default threads in the event loop.
      static java.lang.String NAME
      Name for Netty thread factory.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.util.concurrent.ThreadFactory nettyThreadFactory()
      Constructs the default thread factory used by the HTTP client.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • NAME

        public static final java.lang.String NAME
        Name for Netty thread factory.
        See Also:
        Constant Field Values
      • DEFAULT_EVENT_LOOP_THREADS

        public static final int DEFAULT_EVENT_LOOP_THREADS
        Constant with the default threads in the event loop.
    • Constructor Detail

      • NettyThreadFactory

        public NettyThreadFactory()
    • Method Detail

      • nettyThreadFactory

        @Singleton
        @Named("netty")
        protected java.util.concurrent.ThreadFactory nettyThreadFactory()
        Constructs the default thread factory used by the HTTP client.
        Returns:
        The thread factory