2 Replies Latest reply on Feb 2, 2018 7:55 PM by lacr77

    Rename the threads in WildFly 10.1

    lacr77

      Hello,

      I am updated the application server to WildFly 10.1 but I have the following problem that I can not solve:

      In previous versions, we changed in the name of the threads, configuring the thread factory in thread pool subsystem (with thread-name-pattern).

      This object is no longer available in WildFly 10 since the thread pool subsystem has been removed.

      Would there be any way to get the same in WildFly 10?

      I've been looking at the possible configurations for a long time and I have not been able to find it.

      Many Thanks,

        • 1. Re: Rename the threads in WildFly 10.1
          ctomc

          what threads do you have in mind?

          there are lots of different thread pools...

          • 2. Re: Rename the threads in WildFly 10.1
            lacr77

            In previous versions, I modified the Thread subsystem

            <subsystem xmlns = "urn: jboss: domain: threads: 1.1">
                 
            <thread-factory name = "http-connector-factory" thread-name-pattern = "HiloHTTP-% t" priority = "9" group-name = "uq-thread-pool" />
                  
            <unbounded-queue-thread-pool name = "uq-thread-pool">
                    
            <thread-factory name = "http-connector-factory" />
                    
            <max-threads count = "300" />
                    
            <keepalive-time time = "30" unit = "seconds" />
                  
            </ unbounded-queue-thread-pool>
               
            </ subsystem>
            ....
            <connector name = "http" protocol = "HTTP / 1.1" scheme = "http" socket-binding = "http" executor = "uq-thread-pool" />

             


            In the current version I do not know which pool I have to modify.

             

             

            The threads are the so-called:  "default task-xxx"

            These are dump from the threads I need to modify the name:

            "default task-26" # 183 prio = 5 os_prio = 0 tid = 0x00000000048c9000 nid = 0x78f8 waiting on condition [0x00007fca4d4ee000]
              
            java.lang.Thread.State: WAITING (parking)
                   
            at sun.misc.Unsafe.park (Native Method)
                   
            - parking to wait for <0x000000008b3d2f40> (to java.util.concurrent.locks.AbstractQueuedSynchronizer $ ConditionObject)
                   
            at java.util.concurrent.locks.LockSupport.park (LockSupport.java:175)
                   
            at java.util.concurrent.locks.AbstractQueuedSynchronizer $ ConditionObject.await (AbstractQueuedSynchronizer.java:2039)
                   
            at java.util.concurrent.LinkedBlockingQueue.take (LinkedBlockingQueue.java:442)
                   
            at java.util.concurrent.ThreadPoolExecutor.getTask (ThreadPoolExecutor.java:1067)
                   
            at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1127)
                   
            at java.util.concurrent.ThreadPoolExecutor $ Worker.run (ThreadPoolExecutor.java:617)
                   
            at java.lang.Thread.run (Thread.java:748)

            -------------------------------------------------- -------------------------------------------------- ------------

            "default task-19" # 176 prio = 5 os_prio = 0 tid = 0x00000000045fd800 nid = 0x78f0 waiting on condition [0x00007fca4c1a4000]
              
            java.lang.Thread.State: WAITING (parking)
                   
            at sun.misc.Unsafe.park (Native Method)
                   
            - parking to wait for <0x000000008b3d2f40> (to java.util.concurrent.locks.AbstractQueuedSynchronizer $ ConditionObject)
                   
            at java.util.concurrent.locks.LockSupport.park (LockSupport.java:175)
                   
            at java.util.concurrent.locks.AbstractQueuedSynchronizer $ ConditionObject.await (AbstractQueuedSynchronizer.java:2039)
                   
            at java.util.concurrent.LinkedBlockingQueue.take (LinkedBlockingQueue.java:442)
                   
            at java.util.concurrent.ThreadPoolExecutor.getTask (ThreadPoolExecutor.java:1067)
                   
            at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1127)
                   
            at java.util.concurrent.ThreadPoolExecutor $ Worker.run (ThreadPoolExecutor.java:617)
                   
            at java.lang.Thread.run (Thread.java:748)